Prusa MINI Firmware overview
test_window.c File Reference
#include "cmsis_os.h"
#include "config.h"
#include "gui.h"
#include "window.h"
#include "jogwheel.h"
#include "screen.h"

Functions

void test_window (void)
 

Variables

osThreadId displayTaskHandle
 
const screen_tpscreen_test
 

Function Documentation

◆ test_window()

void test_window ( void  )
57  {
58  // pscreen_test->init(pscreen_test);
59  // pscreen_test->init(pscreen_test);
60  /*
61  font_t* font = resource_font(IDR_FNT_11x18_4);
62  int16_t id0 = window_frame_create(-1, rect_ui16(0,0,0,0), COLOR_GRAY);
63  int16_t id1 = window_icon_create(id0, rect_ui16(10, 0, 0, 0), IDR_PNG_splash_logo_prusamini, COLOR_BLACK);
64  int16_t id2 = window_text_create(id0, rect_ui16(10, 70, 60, 22), "Test0", font, COLOR_BLACK, COLOR_WHITE, padding_ui8(2, 2, 2, 2), ALIGN_LEFT_CENTER);
65  int16_t id3 = window_text_create(id0, rect_ui16(80, 70, 60, 22), "Test1", font, COLOR_BLACK, COLOR_WHITE, padding_ui8(2, 2, 2, 2), ALIGN_LEFT_CENTER);
66  int16_t id4 = window_numb_create(id0, rect_ui16(10, 100, 60, 22), 10.0F, "%1.0f", font, COLOR_BLACK, COLOR_WHITE, padding_ui8(2, 2, 2, 2), ALIGN_LEFT_CENTER);
67  int16_t id5 = window_numb_create(id0, rect_ui16(80, 100, 60, 22), 1.500F, "%.3f", font, COLOR_BLACK, COLOR_WHITE, padding_ui8(2, 2, 2, 2), ALIGN_LEFT_CENTER);
68  int16_t id6 = window_spin_create_min_max_step(id0, rect_ui16(10, 130, 60, 22), 100.0F, "%1.0f", font, COLOR_BLACK, COLOR_WHITE, padding_ui8(2, 2, 2, 2), ALIGN_LEFT_CENTER, 0.0F, 100.0F, 1.0F);
69  int16_t id7 = window_spin_create_min_max_step(id0, rect_ui16(80, 130, 60, 22), 1.000F, "%.3f", font, COLOR_BLACK, COLOR_WHITE, padding_ui8(2, 2, 2, 2), ALIGN_LEFT_CENTER, 0.0F, 1.0F, 0.001F);
70  int16_t id8 = window_list_create(id0, rect_ui16(10, 160, 220, 88), font, COLOR_BLACK, COLOR_WHITE, padding_ui8(18, 2, 2, 2), ALIGN_LEFT_CENTER, 0);
71  int16_t id9 = window_icon_create(id0, rect_ui16(10, 250, 64, 64), IDR_PNG_menu_icon_print, COLOR_BLACK);
72  int16_t id10 = window_icon_create(id0, rect_ui16(80, 250, 64, 64), IDR_PNG_menu_icon_preheat, COLOR_BLACK);
73  int16_t id11 = window_icon_create(id0, rect_ui16(150, 250, 64, 64), IDR_PNG_menu_icon_spool, COLOR_BLACK);
74  //int16_t id12 = window_icon_create(id0, rect_ui16(10, 250, 64, 64), IDR_PNG_menu_icon_print, COLOR_BLACK, ALIGN_CENTER);
75  window_enable(id1);
76  window_enable(id2);
77  window_enable(id3);
78  window_enable(id4);
79  window_enable(id5);
80  window_enable(id8);
81  window_enable(id9);
82  window_enable(id10);
83  window_enable(id11);
84  //window_enable(id12);*/
85  // ui_loop();
86  while (1)
87  gui_loop();
88 }

Variable Documentation

◆ displayTaskHandle

osThreadId displayTaskHandle

◆ pscreen_test

const screen_t* pscreen_test