Prusa MINI Firmware overview
wizard_ui.h
Go to the documentation of this file.
1 // wizard_ui.h
2 #ifndef _WIZARD_UI_H
3 #define _WIZARD_UI_H
4 
5 #include "gui.h"
6 #include "wizard_types.h"
7 
8 #define WIZARD_MARGIN_LEFT 6
9 #define WIZARD_MARGIN_RIGHT 6
10 #define WIZARD_X_SPACE (240 - (WIZARD_MARGIN_LEFT + WIZARD_MARGIN_RIGHT))
11 
12 #define MSGBOX_BTN_NEXT MSGBOX_BTN_MAX + 1
13 #define MSGBOX_BTN_DONE MSGBOX_BTN_MAX + 2
14 
15 // types of wizard_timer()
16 // _WIZ_TIMER_AUTOPASS means - when progress reaches 100%, state automatically set to _TEST_PASSED
17 // _WIZ_TIMER_AUTOFAIL means - when progress reaches 100%, state automatically set to _TEST_FAILED
18 typedef enum {
22 } _WIZ_TIMER_t;
23 
24 #ifdef __cplusplus
25 extern "C" {
26 #endif //__cplusplus
27 
28 extern int wizard_timer(uint32_t *p_timer, uint32_t delay_ms, _TEST_STATE_t *pstate,
30 
31 extern void wizard_update_test_icon(int16_t win_id, uint8_t state);
32 
34 
35 extern int wizard_msgbox_ex(const char *text, uint16_t flags, uint16_t id_icon, rect_ui16_t rc);
36 
37 extern int wizard_msgbox(const char *text, uint16_t flags, uint16_t id_icon);
38 
39 extern int wizard_msgbox1(const char *text, uint16_t flags, uint16_t id_icon);
40 
41 extern int wizard_msgbox_btns(const char *text, uint16_t flags, uint16_t id_icon,
42  const char **buttons);
43 
44 extern void wizard_init(float t_noz, float t_bed /*, int16_t footer_id*/);
45 
46 extern void wizard_init_disable_PID(float t_noz, float t_bed /*, int16_t footer_id*/);
47 /*
48 extern void wizard_init_footer(float t_noz, float t_bed, int16_t footer_id);
49 
50 extern void wizard_init_footer_disable_PID(float t_noz, float t_bed, int16_t footer_id);
51 */
52 #ifdef __cplusplus
53 }
54 #endif //__cplusplus
55 
56 #endif //_WIZARD_UI_H
marlin_server.h
wizard_msgbox1
int wizard_msgbox1(const char *text, uint16_t flags, uint16_t id_icon)
Definition: wizard_ui.c:47
marlin_client.h
MSGBOX_MSK_BTN
#define MSGBOX_MSK_BTN
Definition: window_msgbox.h:9
_wizard_init_test
static void _wizard_init_test()
Definition: wizard_ui.c:91
MARLIN_EVT_LoadSettings
#define MARLIN_EVT_LoadSettings
Definition: marlin_events.h:22
wizard_update_test_icon
void wizard_update_test_icon(int16_t win_id, uint8_t state)
Definition: wizard_ui.c:24
wizard_init
void wizard_init(float t_noz, float t_bed)
Definition: wizard_ui.c:111
IDR_PNG_wizard_icon_ip1
#define IDR_PNG_wizard_icon_ip1
Definition: resource.h:55
_TEST_FAILED
Definition: wizard_types.h:88
wizard_ui.h
IDR_PNG_wizard_icon_ng
#define IDR_PNG_wizard_icon_ng
Definition: resource.h:53
type
uint8_t type
Definition: UsbCore.h:184
rect_ui16
static rect_ui16_t rect_ui16(uint16_t x, uint16_t y, uint16_t w, uint16_t h)
Definition: guitypes.h:159
marlin_processing
int marlin_processing(void)
Definition: marlin_client.c:145
wizard_msgbox
int wizard_msgbox(const char *text, uint16_t flags, uint16_t id_icon)
Definition: wizard_ui.c:42
_TEST_STATE_t
_TEST_STATE_t
Definition: wizard_types.h:84
state
static volatile fsensor_t state
Definition: filament_sensor.c:23
window_set_icon_id
void window_set_icon_id(int16_t id, uint16_t id_res)
Definition: window.c:659
wizard_init_disable_PID
void wizard_init_disable_PID(float t_noz, float t_bed)
Definition: wizard_ui.c:135
wizard_msgbox_btns
int wizard_msgbox_btns(const char *text, uint16_t flags, uint16_t id_icon, const char **buttons)
Definition: wizard_ui.c:52
MSGBOX_ICO_CUSTOM
#define MSGBOX_ICO_CUSTOM
Definition: window_msgbox.h:32
HAL_GetTick
uint32_t HAL_GetTick(void)
Provides a tick value in millisecond.
Definition: stm32f4xx_hal.c:339
MSGBOX_BTN_DONE
#define MSGBOX_BTN_DONE
Definition: wizard_ui.h:13
wizard_msgbox1
int wizard_msgbox1(const char *text, uint16_t flags, uint16_t id_icon)
Definition: wizard_ui.c:47
_TEST_RUN
Definition: wizard_types.h:86
IDR_PNG_wizard_icon_ip0
#define IDR_PNG_wizard_icon_ip0
Definition: resource.h:54
wizard_get_test_icon_resource
uint16_t wizard_get_test_icon_resource(uint8_t state)
Definition: wizard_ui.c:10
_WIZ_TIMER_AUTOFAIL
Definition: wizard_ui.h:21
wizard_msgbox_ex
int wizard_msgbox_ex(const char *text, uint16_t flags, uint16_t id_icon, rect_ui16_t rc)
Definition: wizard_ui.c:29
MSGBOX_BTN_CUSTOM1
#define MSGBOX_BTN_CUSTOM1
Definition: window_msgbox.h:26
wizard_timer
int wizard_timer(uint32_t *p_timer, uint32_t delay_ms, _TEST_STATE_t *pstate, _WIZ_TIMER_t type)
Definition: wizard_ui.c:58
marlin_gcode
void marlin_gcode(const char *gcode)
Definition: marlin_client.c:195
_rect_ui16_t
Definition: guitypes.h:69
IDR_PNG_wizard_icon_na
#define IDR_PNG_wizard_icon_na
Definition: resource.h:51
uint8_t
const uint8_t[]
Definition: 404_html.c:3
_WIZ_TIMER_AUTOPASS
Definition: wizard_ui.h:20
MARLIN_EVT_FactoryReset
#define MARLIN_EVT_FactoryReset
Definition: marlin_events.h:21
wizard_msgbox_btns
int wizard_msgbox_btns(const char *text, uint16_t flags, uint16_t id_icon, const char **buttons)
Definition: wizard_ui.c:52
_TEST_START
Definition: wizard_types.h:85
_WIZ_TIMER_t
_WIZ_TIMER_t
Definition: wizard_ui.h:18
stm32f4xx_hal.h
This file contains all the functions prototypes for the HAL module driver.
wizard_types.h
wizard_get_test_icon_resource
uint16_t wizard_get_test_icon_resource(uint8_t state)
Definition: wizard_ui.c:10
marlin_start_processing
void marlin_start_processing(void)
Definition: marlin_client.c:174
wizard_msgbox_ex
int wizard_msgbox_ex(const char *text, uint16_t flags, uint16_t id_icon, rect_ui16_t rc)
Definition: wizard_ui.c:29
wizard_timer
int wizard_timer(uint32_t *p_timer, uint32_t delay_ms, _TEST_STATE_t *pstate, _WIZ_TIMER_t type)
Definition: wizard_ui.c:58
wizard_msgbox
int wizard_msgbox(const char *text, uint16_t flags, uint16_t id_icon)
Definition: wizard_ui.c:42
_disable_PID
static void _disable_PID()
Definition: wizard_ui.c:102
gui.h
IDR_PNG_wizard_icon_ok
#define IDR_PNG_wizard_icon_ok
Definition: resource.h:52
wizard_init_disable_PID
void wizard_init_disable_PID(float t_noz, float t_bed)
Definition: wizard_ui.c:135
wizard_update_test_icon
void wizard_update_test_icon(int16_t win_id, uint8_t state)
Definition: wizard_ui.c:24
marlin_gcode_printf
int marlin_gcode_printf(const char *format,...)
Definition: marlin_client.c:206
wizard_init
void wizard_init(float t_noz, float t_bed)
Definition: wizard_ui.c:111
MSGBOX_BTN_NEXT
#define MSGBOX_BTN_NEXT
Definition: wizard_ui.h:12
_WIZ_TIMER
Definition: wizard_ui.h:19
_TEST_PASSED
Definition: wizard_types.h:87
marlin_event_clr
int marlin_event_clr(uint8_t evt_id)
Definition: marlin_client.c:252