gui_guider.h 8.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241
  1. /*
  2. * Copyright 2025 NXP
  3. * NXP Proprietary. This software is owned or controlled by NXP and may only be used strictly in
  4. * accordance with the applicable license terms. By expressly accepting such terms or by downloading, installing,
  5. * activating and/or otherwise using the software, you are agreeing that you have read, and that you agree to
  6. * comply with and are bound by, such license terms. If you do not agree to be bound by the applicable license
  7. * terms, then you may not retain, install, activate or otherwise use the software.
  8. */
  9. #ifndef GUI_GUIDER_H
  10. #define GUI_GUIDER_H
  11. #ifdef __cplusplus
  12. extern "C" {
  13. #endif
  14. #include "lvgl.h"
  15. typedef struct
  16. {
  17. lv_obj_t *screen_main;
  18. bool screen_main_del;
  19. lv_obj_t *screen_main_label_14;
  20. lv_obj_t *screen_main_label_lvxin;
  21. lv_obj_t *screen_main_label_19;
  22. lv_obj_t *screen_main_cont_open;
  23. lv_obj_t *screen_main_arc_temp;
  24. lv_obj_t *screen_main_cont_temp_set;
  25. lv_obj_t *screen_main_btn_temp_up;
  26. lv_obj_t *screen_main_btn_temp_up_label;
  27. lv_obj_t *screen_main_btn_temp_down;
  28. lv_obj_t *screen_main_btn_temp_down_label;
  29. lv_obj_t *screen_main_cont_speed;
  30. lv_obj_t *screen_main_imgbtn_speed3;
  31. lv_obj_t *screen_main_imgbtn_speed3_label;
  32. lv_obj_t *screen_main_imgbtn_speed2;
  33. lv_obj_t *screen_main_imgbtn_speed2_label;
  34. lv_obj_t *screen_main_imgbtn_speed1;
  35. lv_obj_t *screen_main_imgbtn_speed1_label;
  36. lv_obj_t *screen_main_cont_data;
  37. lv_obj_t *screen_main_label_temp;
  38. lv_obj_t *screen_main_label_9;
  39. lv_obj_t *screen_main_label_8;
  40. lv_obj_t *screen_main_label_hum_vul2;
  41. lv_obj_t *screen_main_label_10;
  42. lv_obj_t *screen_main_label_7;
  43. lv_obj_t *screen_main_cont_mode;
  44. lv_obj_t *screen_main_imgbtn_tf;
  45. lv_obj_t *screen_main_imgbtn_tf_label;
  46. lv_obj_t *screen_main_imgbtn_heat;
  47. lv_obj_t *screen_main_imgbtn_heat_label;
  48. lv_obj_t *screen_main_imgbtn_cold;
  49. lv_obj_t *screen_main_imgbtn_cold_label;
  50. lv_obj_t *screen_main_imgbtn_power;
  51. lv_obj_t *screen_main_imgbtn_power_label;
  52. lv_obj_t *screen_main_label_temp_set;
  53. lv_obj_t *screen_main_label_21;
  54. lv_obj_t *screen_main_label_20;
  55. lv_obj_t *screen_main_label_;
  56. lv_obj_t *screen_main_cont_close;
  57. lv_obj_t *screen_main_label_25;
  58. lv_obj_t *screen_main_label_22;
  59. lv_obj_t *screen_main_label_temp_2;
  60. lv_obj_t *screen_main_label_hum_2;
  61. lv_obj_t *screen_main_btn_close_power;
  62. lv_obj_t *screen_main_btn_close_power_label;
  63. lv_obj_t *screen_main_lab_485_err;
  64. lv_obj_t *screen_main_lab_err;
  65. lv_obj_t *screen_main_label_wifi;
  66. lv_obj_t *screen_main_lab_cloud1;
  67. lv_obj_t *screen_main_label_filter_error;
  68. lv_obj_t *screen_main_lab_new_fan_mode;
  69. lv_obj_t *screen_main_label_xf_conn;
  70. lv_obj_t *SettingPage;
  71. bool SettingPage_del;
  72. lv_obj_t *SettingPage_tabview_1;
  73. lv_obj_t *SettingPage_tabview_1_tab_1;
  74. lv_obj_t *SettingPage_tabview_1_tab_2;
  75. lv_obj_t *SettingPage_tabview_1_tab_3;
  76. lv_obj_t *SettingPage_tabview_1_tab_4;
  77. lv_obj_t *SettingPage_list_wifi;
  78. lv_obj_t *SettingPage_label_1;
  79. lv_obj_t *SettingPage_lab_wifi_status;
  80. lv_obj_t *SettingPage_btn_1;
  81. lv_obj_t *SettingPage_btn_1_label;
  82. lv_obj_t *SettingPage_p_wifi_connect;
  83. lv_obj_t *SettingPage_label_2;
  84. lv_obj_t *SettingPage_label_3;
  85. lv_obj_t *SettingPage_lab_wifi_ssid;
  86. lv_obj_t *SettingPage_btn_2;
  87. lv_obj_t *SettingPage_btn_2_label;
  88. lv_obj_t *SettingPage_txt_wifi_password;
  89. lv_obj_t *SettingPage_btn_3;
  90. lv_obj_t *SettingPage_btn_3_label;
  91. lv_obj_t *SettingPage_sp_wifi_scan;
  92. lv_obj_t *SettingPage_btn_5;
  93. lv_obj_t *SettingPage_btn_5_label;
  94. lv_obj_t *SettingPage_sw_sound;
  95. lv_obj_t *SettingPage_label_10;
  96. lv_obj_t *SettingPage_label_9;
  97. lv_obj_t *SettingPage_slider_sound_level;
  98. lv_obj_t *SettingPage_label_11;
  99. lv_obj_t *SettingPage_sw_1;
  100. lv_obj_t *SettingPage_label_12;
  101. lv_obj_t *SettingPage_spinbox_2;
  102. lv_obj_t *SettingPage_spinbox_2_btn_plus;
  103. lv_obj_t *SettingPage_spinbox_2_btn_minus;
  104. lv_obj_t *SettingPage_cont_1;
  105. lv_obj_t *SettingPage_btn_4;
  106. lv_obj_t *SettingPage_btn_4_label;
  107. lv_obj_t *SettingPage_ta_1;
  108. lv_obj_t *SettingPage_label_5;
  109. lv_obj_t *SettingPage_lab_password_incorrect;
  110. lv_obj_t *SettingPage_label_6;
  111. lv_obj_t *SettingPage_qr_device_code;
  112. lv_obj_t *SettingPage_lab_version;
  113. lv_obj_t *SettingPage_label_7;
  114. lv_obj_t *SettingPage_label_8;
  115. lv_obj_t *SettingPage_label_13;
  116. lv_obj_t *SettingPage_lab_serial;
  117. lv_obj_t *FactorySettingPage;
  118. bool FactorySettingPage_del;
  119. lv_obj_t *FactorySettingPage_tabview_1;
  120. lv_obj_t *FactorySettingPage_tabview_1_tab_1;
  121. lv_obj_t *FactorySettingPage_tabview_1_tab_2;
  122. lv_obj_t *FactorySettingPage_tabview_1_tab_3;
  123. lv_obj_t *FactorySettingPage_btn_set_save;
  124. lv_obj_t *FactorySettingPage_btn_set_save_label;
  125. lv_obj_t *FactorySettingPage_btn_refresh;
  126. lv_obj_t *FactorySettingPage_btn_refresh_label;
  127. lv_obj_t *FactorySettingPage_btn_7;
  128. lv_obj_t *FactorySettingPage_btn_7_label;
  129. lv_obj_t *FactorySettingPage_btn_8;
  130. lv_obj_t *FactorySettingPage_btn_8_label;
  131. lv_obj_t *FactorySettingPage_sp_hum_recoup;
  132. lv_obj_t *FactorySettingPage_sp_hum_recoup_btn_plus;
  133. lv_obj_t *FactorySettingPage_sp_hum_recoup_btn_minus;
  134. lv_obj_t *FactorySettingPage_sp_temp_recoup;
  135. lv_obj_t *FactorySettingPage_sp_temp_recoup_btn_plus;
  136. lv_obj_t *FactorySettingPage_sp_temp_recoup_btn_minus;
  137. lv_obj_t *FactorySettingPage_label_2;
  138. lv_obj_t *FactorySettingPage_label_1;
  139. lv_obj_t *FactorySettingPage_lab_inner_addr;
  140. lv_obj_t *FactorySettingPage_label_detail_error;
  141. lv_obj_t *FactorySettingPage_btn_error;
  142. lv_obj_t *FactorySettingPage_btn_error_label;
  143. lv_obj_t *FactorySettingPage_btn_4;
  144. lv_obj_t *FactorySettingPage_btn_4_label;
  145. lv_obj_t *FactorySettingPage_btn_5;
  146. lv_obj_t *FactorySettingPage_btn_5_label;
  147. lv_obj_t *FactorySettingPage_btn_filter_life_clear;
  148. lv_obj_t *FactorySettingPage_btn_filter_life_clear_label;
  149. lv_obj_t *FactorySettingPage_btn_6;
  150. lv_obj_t *FactorySettingPage_btn_6_label;
  151. lv_obj_t *OTAPage;
  152. bool OTAPage_del;
  153. lv_obj_t *OTAPage_label_1;
  154. lv_obj_t *OTAPage_label_2;
  155. lv_obj_t *OTAPage_label_3;
  156. lv_obj_t *OTAPage_lab_ota_current_version;
  157. lv_obj_t *OTAPage_lab_ota_remote_version;
  158. lv_obj_t *OTAPage_btn_exit;
  159. lv_obj_t *OTAPage_btn_exit_label;
  160. lv_obj_t *OTAPage_label_4;
  161. lv_obj_t *OTAPage_bar_ota_progress;
  162. lv_obj_t *g_kb_top_layer;
  163. }lv_ui;
  164. typedef void (*ui_setup_scr_t)(lv_ui * ui);
  165. void ui_init_style(lv_style_t * style);
  166. void ui_load_scr_animation(lv_ui *ui, lv_obj_t ** new_scr, bool new_scr_del, bool * old_scr_del, ui_setup_scr_t setup_scr,
  167. lv_screen_load_anim_t anim_type, uint32_t time, uint32_t delay, bool is_clean, bool auto_del);
  168. void ui_animation(void * var, uint32_t duration, int32_t delay, int32_t start_value, int32_t end_value, lv_anim_path_cb_t path_cb,
  169. uint32_t repeat_cnt, uint32_t repeat_delay, uint32_t playback_time, uint32_t playback_delay,
  170. lv_anim_exec_xcb_t exec_cb, lv_anim_start_cb_t start_cb, lv_anim_completed_cb_t ready_cb, lv_anim_deleted_cb_t deleted_cb);
  171. void init_scr_del_flag(lv_ui *ui);
  172. void setup_bottom_layer(void);
  173. void setup_ui(lv_ui *ui);
  174. void video_play(lv_ui *ui);
  175. void init_keyboard(lv_ui *ui);
  176. extern lv_ui guider_ui;
  177. void setup_scr_screen_main(lv_ui *ui);
  178. void setup_scr_SettingPage(lv_ui *ui);
  179. void setup_scr_FactorySettingPage(lv_ui *ui);
  180. void setup_scr_OTAPage(lv_ui *ui);
  181. LV_IMAGE_DECLARE(_back2_RGB565A8_480x480);
  182. LV_IMAGE_DECLARE(_jia_RGB565A8_38x38);
  183. LV_IMAGE_DECLARE(_jian_RGB565A8_38x38);
  184. LV_IMAGE_DECLARE(_speed3_off_RGB565A8_48x48);
  185. LV_IMAGE_DECLARE(_speed3_RGB565A8_48x48);
  186. LV_IMAGE_DECLARE(_speed2_off_RGB565A8_48x48);
  187. LV_IMAGE_DECLARE(_speed2_RGB565A8_48x48);
  188. LV_IMAGE_DECLARE(_speed1_off_RGB565A8_48x48);
  189. LV_IMAGE_DECLARE(_speed1_RGB565A8_48x48);
  190. LV_IMAGE_DECLARE(_tf_off_RGB565A8_48x48);
  191. LV_IMAGE_DECLARE(_tf_RGB565A8_48x48);
  192. LV_IMAGE_DECLARE(_heat_off_RGB565A8_48x48);
  193. LV_IMAGE_DECLARE(_heat_RGB565A8_48x48);
  194. LV_IMAGE_DECLARE(_cold_off_RGB565A8_48x48);
  195. LV_IMAGE_DECLARE(_cold_RGB565A8_48x48);
  196. LV_IMAGE_DECLARE(_power_RGB565A8_50x50);
  197. LV_IMAGE_DECLARE(_ac_power_on_RGB565A8_80x80);
  198. LV_IMAGE_DECLARE(_WiFiruo_RGB565A8_30x30);
  199. LV_FONT_DECLARE(lv_font_Alibaba_PuHuiTi_Medium_18)
  200. LV_FONT_DECLARE(lv_font_montserratMedium_16)
  201. LV_FONT_DECLARE(lv_font_iconfont_16)
  202. LV_FONT_DECLARE(lv_font_montserratMedium_12)
  203. LV_FONT_DECLARE(lv_font_Alibaba_PuHuiTi_Medium_24)
  204. LV_FONT_DECLARE(lv_font_iconfont_22)
  205. LV_FONT_DECLARE(lv_font_Alibaba_PuHuiTi_Medium_16)
  206. LV_FONT_DECLARE(lv_font_montserratMedium_48)
  207. LV_FONT_DECLARE(lv_font_Alibaba_PuHuiTi_Medium_26)
  208. LV_FONT_DECLARE(lv_font_iconfont_28)
  209. LV_FONT_DECLARE(lv_font_Alibaba_PuHuiTi_Medium_25)
  210. LV_FONT_DECLARE(lv_font_Alibaba_PuHuiTi_Medium_20)
  211. LV_FONT_DECLARE(lv_font_SourceHanSerifSC_Regular_18)
  212. #ifdef __cplusplus
  213. }
  214. #endif
  215. #endif