/* * Copyright 2025 NXP * NXP Proprietary. This software is owned or controlled by NXP and may only be used strictly in * accordance with the applicable license terms. By expressly accepting such terms or by downloading, installing, * activating and/or otherwise using the software, you are agreeing that you have read, and that you agree to * comply with and are bound by, such license terms. If you do not agree to be bound by the applicable license * terms, then you may not retain, install, activate or otherwise use the software. */ #include "lvgl.h" #include #include "gui_guider.h" #include "events_init.h" #include "widgets_init.h" #include "custom.h" #include "xf_controller.h" void set_xf_mode(lv_ui *ui, uint16_t mode) { lv_obj_t *cont = ui->screen_main_cont_mode; uint32_t count = lv_obj_get_child_count(cont); for (int i = 0; i < count; i++) { lv_obj_t *child = lv_obj_get_child(cont, i); lv_obj_remove_state(child, LV_STATE_CHECKED); } switch (mode) { case CS: lv_obj_add_state(ui->screen_main_imgbtn_cs, LV_STATE_CHECKED); break; case JS: lv_obj_add_state(ui->screen_main_imgbtn_js, LV_STATE_CHECKED); break; case SF: lv_obj_add_state(ui->screen_main_imgbtn_sf, LV_STATE_CHECKED); break; default: break; } } void setup_scr_screen_main(lv_ui *ui) { //Write codes screen_main ui->screen_main = lv_obj_create(NULL); lv_obj_set_size(ui->screen_main, 480, 480); lv_obj_set_scrollbar_mode(ui->screen_main, LV_SCROLLBAR_MODE_OFF); //Write style for screen_main, Part: LV_PART_MAIN, State: LV_STATE_DEFAULT. lv_obj_set_style_bg_opa(ui->screen_main, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_bg_image_src(ui->screen_main, &_back_RGB565A8_480x480, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_bg_image_opa(ui->screen_main, 255, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_bg_image_recolor_opa(ui->screen_main, 0, LV_PART_MAIN|LV_STATE_DEFAULT); //Write codes screen_main_arc_hum ui->screen_main_arc_hum = lv_arc_create(ui->screen_main); lv_obj_set_pos(ui->screen_main_arc_hum, 110, 77); lv_obj_set_size(ui->screen_main_arc_hum, 256, 256); lv_arc_set_mode(ui->screen_main_arc_hum, LV_ARC_MODE_NORMAL); lv_arc_set_range(ui->screen_main_arc_hum, 0, 100); lv_arc_set_bg_angles(ui->screen_main_arc_hum, 20, 19); lv_arc_set_value(ui->screen_main_arc_hum, 70); lv_arc_set_rotation(ui->screen_main_arc_hum, 0); //Write style for screen_main_arc_hum, Part: LV_PART_MAIN, State: LV_STATE_DEFAULT. lv_obj_set_style_bg_opa(ui->screen_main_arc_hum, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_border_width(ui->screen_main_arc_hum, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_arc_width(ui->screen_main_arc_hum, 12, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_arc_opa(ui->screen_main_arc_hum, 90, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_arc_color(ui->screen_main_arc_hum, lv_color_hex(0x005cff), LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_arc_rounded(ui->screen_main_arc_hum, true, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_radius(ui->screen_main_arc_hum, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_top(ui->screen_main_arc_hum, 20, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_bottom(ui->screen_main_arc_hum, 20, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_left(ui->screen_main_arc_hum, 20, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_right(ui->screen_main_arc_hum, 20, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_shadow_width(ui->screen_main_arc_hum, 0, LV_PART_MAIN|LV_STATE_DEFAULT); //Write style for screen_main_arc_hum, Part: LV_PART_INDICATOR, State: LV_STATE_DEFAULT. lv_obj_set_style_arc_width(ui->screen_main_arc_hum, 17, LV_PART_INDICATOR|LV_STATE_DEFAULT); lv_obj_set_style_arc_opa(ui->screen_main_arc_hum, 255, LV_PART_INDICATOR|LV_STATE_DEFAULT); lv_obj_set_style_arc_color(ui->screen_main_arc_hum, lv_color_hex(0x00afff), LV_PART_INDICATOR|LV_STATE_DEFAULT); lv_obj_set_style_arc_rounded(ui->screen_main_arc_hum, true, LV_PART_INDICATOR|LV_STATE_DEFAULT); //Write style for screen_main_arc_hum, Part: LV_PART_KNOB, State: LV_STATE_DEFAULT. lv_obj_set_style_bg_opa(ui->screen_main_arc_hum, 0, LV_PART_KNOB|LV_STATE_DEFAULT); lv_obj_set_style_pad_all(ui->screen_main_arc_hum, 5, LV_PART_KNOB|LV_STATE_DEFAULT); //Write codes screen_main_label_temp ui->screen_main_label_temp = lv_label_create(ui->screen_main); lv_obj_set_pos(ui->screen_main_label_temp, 222, 339); lv_obj_set_size(ui->screen_main_label_temp, 34, 30); lv_label_set_text(ui->screen_main_label_temp, "30"); lv_label_set_long_mode(ui->screen_main_label_temp, LV_LABEL_LONG_WRAP); //Write style for screen_main_label_temp, Part: LV_PART_MAIN, State: LV_STATE_DEFAULT. lv_obj_set_style_border_width(ui->screen_main_label_temp, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_radius(ui->screen_main_label_temp, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_color(ui->screen_main_label_temp, lv_color_hex(0xFFFFFF), LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_font(ui->screen_main_label_temp, &lv_font_Alibaba_PuHuiTi_Medium_26, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_opa(ui->screen_main_label_temp, 255, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_letter_space(ui->screen_main_label_temp, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_line_space(ui->screen_main_label_temp, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_align(ui->screen_main_label_temp, LV_TEXT_ALIGN_RIGHT, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_bg_opa(ui->screen_main_label_temp, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_top(ui->screen_main_label_temp, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_right(ui->screen_main_label_temp, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_bottom(ui->screen_main_label_temp, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_left(ui->screen_main_label_temp, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_shadow_width(ui->screen_main_label_temp, 0, LV_PART_MAIN|LV_STATE_DEFAULT); //Write codes screen_main_label_hum_vul2 ui->screen_main_label_hum_vul2 = lv_label_create(ui->screen_main); lv_obj_set_pos(ui->screen_main_label_hum_vul2, 183, 217); lv_obj_set_size(ui->screen_main_label_hum_vul2, 81, 47); lv_label_set_text(ui->screen_main_label_hum_vul2, "60"); lv_label_set_long_mode(ui->screen_main_label_hum_vul2, LV_LABEL_LONG_WRAP); //Write style for screen_main_label_hum_vul2, Part: LV_PART_MAIN, State: LV_STATE_DEFAULT. lv_obj_set_style_border_width(ui->screen_main_label_hum_vul2, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_radius(ui->screen_main_label_hum_vul2, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_color(ui->screen_main_label_hum_vul2, lv_color_hex(0xFFFFFF), LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_font(ui->screen_main_label_hum_vul2, &lv_font_Alibaba_PuHuiTi_Medium_48, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_opa(ui->screen_main_label_hum_vul2, 255, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_letter_space(ui->screen_main_label_hum_vul2, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_line_space(ui->screen_main_label_hum_vul2, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_align(ui->screen_main_label_hum_vul2, LV_TEXT_ALIGN_RIGHT, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_bg_opa(ui->screen_main_label_hum_vul2, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_top(ui->screen_main_label_hum_vul2, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_right(ui->screen_main_label_hum_vul2, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_bottom(ui->screen_main_label_hum_vul2, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_left(ui->screen_main_label_hum_vul2, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_shadow_width(ui->screen_main_label_hum_vul2, 0, LV_PART_MAIN|LV_STATE_DEFAULT); //Write codes screen_main_label_7 ui->screen_main_label_7 = lv_label_create(ui->screen_main); lv_obj_set_pos(ui->screen_main_label_7, 267, 228); lv_obj_set_size(ui->screen_main_label_7, 66, 31); lv_label_set_text(ui->screen_main_label_7, "%"); lv_label_set_long_mode(ui->screen_main_label_7, LV_LABEL_LONG_WRAP); //Write style for screen_main_label_7, Part: LV_PART_MAIN, State: LV_STATE_DEFAULT. lv_obj_set_style_border_width(ui->screen_main_label_7, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_radius(ui->screen_main_label_7, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_color(ui->screen_main_label_7, lv_color_hex(0x8a90a7), LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_font(ui->screen_main_label_7, &lv_font_Alibaba_PuHuiTi_Medium_32, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_opa(ui->screen_main_label_7, 255, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_letter_space(ui->screen_main_label_7, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_line_space(ui->screen_main_label_7, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_align(ui->screen_main_label_7, LV_TEXT_ALIGN_LEFT, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_bg_opa(ui->screen_main_label_7, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_top(ui->screen_main_label_7, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_right(ui->screen_main_label_7, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_bottom(ui->screen_main_label_7, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_left(ui->screen_main_label_7, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_shadow_width(ui->screen_main_label_7, 0, LV_PART_MAIN|LV_STATE_DEFAULT); //Write codes screen_main_label_8 ui->screen_main_label_8 = lv_label_create(ui->screen_main); lv_obj_set_pos(ui->screen_main_label_8, 264, 347); lv_obj_set_size(ui->screen_main_label_8, 66, 18); lv_label_set_text(ui->screen_main_label_8, "℃"); lv_label_set_long_mode(ui->screen_main_label_8, LV_LABEL_LONG_WRAP); //Write style for screen_main_label_8, Part: LV_PART_MAIN, State: LV_STATE_DEFAULT. lv_obj_set_style_border_width(ui->screen_main_label_8, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_radius(ui->screen_main_label_8, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_color(ui->screen_main_label_8, lv_color_hex(0x8a90a7), LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_font(ui->screen_main_label_8, &lv_font_Alibaba_PuHuiTi_Medium_16, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_opa(ui->screen_main_label_8, 255, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_letter_space(ui->screen_main_label_8, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_line_space(ui->screen_main_label_8, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_align(ui->screen_main_label_8, LV_TEXT_ALIGN_LEFT, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_bg_opa(ui->screen_main_label_8, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_top(ui->screen_main_label_8, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_right(ui->screen_main_label_8, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_bottom(ui->screen_main_label_8, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_left(ui->screen_main_label_8, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_shadow_width(ui->screen_main_label_8, 0, LV_PART_MAIN|LV_STATE_DEFAULT); //Write codes screen_main_label_9 ui->screen_main_label_9 = lv_label_create(ui->screen_main); lv_obj_set_pos(ui->screen_main_label_9, 195, 339); lv_obj_set_size(ui->screen_main_label_9, 27, 26); lv_label_set_text(ui->screen_main_label_9, ""); lv_label_set_long_mode(ui->screen_main_label_9, LV_LABEL_LONG_WRAP); //Write style for screen_main_label_9, Part: LV_PART_MAIN, State: LV_STATE_DEFAULT. lv_obj_set_style_border_width(ui->screen_main_label_9, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_radius(ui->screen_main_label_9, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_color(ui->screen_main_label_9, lv_color_hex(0x8a90a7), LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_font(ui->screen_main_label_9, &lv_font_iconfont_24, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_opa(ui->screen_main_label_9, 255, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_letter_space(ui->screen_main_label_9, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_line_space(ui->screen_main_label_9, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_align(ui->screen_main_label_9, LV_TEXT_ALIGN_LEFT, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_bg_opa(ui->screen_main_label_9, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_top(ui->screen_main_label_9, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_right(ui->screen_main_label_9, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_bottom(ui->screen_main_label_9, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_left(ui->screen_main_label_9, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_shadow_width(ui->screen_main_label_9, 0, LV_PART_MAIN|LV_STATE_DEFAULT); //Write codes screen_main_label_10 ui->screen_main_label_10 = lv_label_create(ui->screen_main); lv_obj_set_pos(ui->screen_main_label_10, 222, 149); lv_obj_set_size(ui->screen_main_label_10, 36, 40); lv_label_set_text(ui->screen_main_label_10, ""); lv_label_set_long_mode(ui->screen_main_label_10, LV_LABEL_LONG_WRAP); //Write style for screen_main_label_10, Part: LV_PART_MAIN, State: LV_STATE_DEFAULT. lv_obj_set_style_border_width(ui->screen_main_label_10, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_radius(ui->screen_main_label_10, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_color(ui->screen_main_label_10, lv_color_hex(0x8a90a7), LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_font(ui->screen_main_label_10, &lv_font_iconfont_32, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_opa(ui->screen_main_label_10, 255, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_letter_space(ui->screen_main_label_10, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_line_space(ui->screen_main_label_10, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_align(ui->screen_main_label_10, LV_TEXT_ALIGN_LEFT, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_bg_opa(ui->screen_main_label_10, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_top(ui->screen_main_label_10, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_right(ui->screen_main_label_10, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_bottom(ui->screen_main_label_10, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_left(ui->screen_main_label_10, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_shadow_width(ui->screen_main_label_10, 0, LV_PART_MAIN|LV_STATE_DEFAULT); //Write codes screen_main_label_14 ui->screen_main_label_14 = lv_label_create(ui->screen_main); lv_obj_set_pos(ui->screen_main_label_14, 505, 2); lv_obj_set_size(ui->screen_main_label_14, 127, 20); lv_obj_add_flag(ui->screen_main_label_14, LV_OBJ_FLAG_HIDDEN); lv_obj_add_flag(ui->screen_main_label_14, LV_OBJ_FLAG_HIDDEN); lv_label_set_text(ui->screen_main_label_14, "滤芯剩余:"); lv_label_set_long_mode(ui->screen_main_label_14, LV_LABEL_LONG_WRAP); //Write style for screen_main_label_14, Part: LV_PART_MAIN, State: LV_STATE_DEFAULT. lv_obj_set_style_border_width(ui->screen_main_label_14, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_radius(ui->screen_main_label_14, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_color(ui->screen_main_label_14, lv_color_hex(0x8a90a7), LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_font(ui->screen_main_label_14, &lv_font_Alibaba_PuHuiTi_Medium_18, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_opa(ui->screen_main_label_14, 255, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_letter_space(ui->screen_main_label_14, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_line_space(ui->screen_main_label_14, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_align(ui->screen_main_label_14, LV_TEXT_ALIGN_RIGHT, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_bg_opa(ui->screen_main_label_14, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_top(ui->screen_main_label_14, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_right(ui->screen_main_label_14, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_bottom(ui->screen_main_label_14, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_left(ui->screen_main_label_14, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_shadow_width(ui->screen_main_label_14, 0, LV_PART_MAIN|LV_STATE_DEFAULT); //Write codes screen_main_cont_mode ui->screen_main_cont_mode = lv_obj_create(ui->screen_main); lv_obj_set_pos(ui->screen_main_cont_mode, 14, 372); lv_obj_set_size(ui->screen_main_cont_mode, 349, 103); lv_obj_set_scrollbar_mode(ui->screen_main_cont_mode, LV_SCROLLBAR_MODE_OFF); //Write style for screen_main_cont_mode, Part: LV_PART_MAIN, State: LV_STATE_DEFAULT. lv_obj_set_style_border_width(ui->screen_main_cont_mode, 2, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_border_opa(ui->screen_main_cont_mode, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_border_color(ui->screen_main_cont_mode, lv_color_hex(0x2195f6), LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_border_side(ui->screen_main_cont_mode, LV_BORDER_SIDE_FULL, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_radius(ui->screen_main_cont_mode, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_bg_opa(ui->screen_main_cont_mode, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_top(ui->screen_main_cont_mode, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_bottom(ui->screen_main_cont_mode, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_left(ui->screen_main_cont_mode, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_right(ui->screen_main_cont_mode, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_shadow_width(ui->screen_main_cont_mode, 0, LV_PART_MAIN|LV_STATE_DEFAULT); //Write codes screen_main_imgbtn_sf ui->screen_main_imgbtn_sf = lv_imagebutton_create(ui->screen_main_cont_mode); lv_obj_set_pos(ui->screen_main_imgbtn_sf, 256, 10); lv_obj_set_size(ui->screen_main_imgbtn_sf, 60, 60); lv_obj_add_flag(ui->screen_main_imgbtn_sf, LV_OBJ_FLAG_EVENT_BUBBLE); lv_obj_add_flag(ui->screen_main_imgbtn_sf, LV_OBJ_FLAG_CHECKABLE); lv_imagebutton_set_src(ui->screen_main_imgbtn_sf, LV_IMAGEBUTTON_STATE_RELEASED, &_songfeng_RGB565A8_60x60, NULL, NULL); lv_imagebutton_set_src(ui->screen_main_imgbtn_sf, LV_IMAGEBUTTON_STATE_PRESSED, &_songfengkai_RGB565A8_60x60, NULL, NULL); lv_imagebutton_set_src(ui->screen_main_imgbtn_sf, LV_IMAGEBUTTON_STATE_CHECKED_RELEASED, &_songfengkai_RGB565A8_60x60, NULL, NULL); ui->screen_main_imgbtn_sf_label = lv_label_create(ui->screen_main_imgbtn_sf); lv_label_set_text(ui->screen_main_imgbtn_sf_label, ""); lv_label_set_long_mode(ui->screen_main_imgbtn_sf_label, LV_LABEL_LONG_WRAP); lv_obj_align(ui->screen_main_imgbtn_sf_label, LV_ALIGN_CENTER, 0, 0); lv_obj_set_style_pad_all(ui->screen_main_imgbtn_sf, 0, LV_STATE_DEFAULT); //Write style for screen_main_imgbtn_sf, Part: LV_PART_MAIN, State: LV_STATE_DEFAULT. lv_obj_set_style_text_color(ui->screen_main_imgbtn_sf, lv_color_hex(0x000000), LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_font(ui->screen_main_imgbtn_sf, &lv_font_montserratMedium_12, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_opa(ui->screen_main_imgbtn_sf, 255, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_align(ui->screen_main_imgbtn_sf, LV_TEXT_ALIGN_CENTER, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_shadow_width(ui->screen_main_imgbtn_sf, 0, LV_PART_MAIN|LV_STATE_DEFAULT); //Write style for screen_main_imgbtn_sf, Part: LV_PART_MAIN, State: LV_STATE_PRESSED. lv_obj_set_style_image_recolor_opa(ui->screen_main_imgbtn_sf, 0, LV_PART_MAIN|LV_STATE_PRESSED); lv_obj_set_style_image_opa(ui->screen_main_imgbtn_sf, 255, LV_PART_MAIN|LV_STATE_PRESSED); lv_obj_set_style_text_color(ui->screen_main_imgbtn_sf, lv_color_hex(0xFF33FF), LV_PART_MAIN|LV_STATE_PRESSED); lv_obj_set_style_text_font(ui->screen_main_imgbtn_sf, &lv_font_montserratMedium_12, LV_PART_MAIN|LV_STATE_PRESSED); lv_obj_set_style_text_opa(ui->screen_main_imgbtn_sf, 255, LV_PART_MAIN|LV_STATE_PRESSED); lv_obj_set_style_shadow_width(ui->screen_main_imgbtn_sf, 0, LV_PART_MAIN|LV_STATE_PRESSED); //Write style for screen_main_imgbtn_sf, Part: LV_PART_MAIN, State: LV_STATE_CHECKED. lv_obj_set_style_image_recolor_opa(ui->screen_main_imgbtn_sf, 0, LV_PART_MAIN|LV_STATE_CHECKED); lv_obj_set_style_image_opa(ui->screen_main_imgbtn_sf, 255, LV_PART_MAIN|LV_STATE_CHECKED); lv_obj_set_style_text_color(ui->screen_main_imgbtn_sf, lv_color_hex(0xFF33FF), LV_PART_MAIN|LV_STATE_CHECKED); lv_obj_set_style_text_font(ui->screen_main_imgbtn_sf, &lv_font_montserratMedium_12, LV_PART_MAIN|LV_STATE_CHECKED); lv_obj_set_style_text_opa(ui->screen_main_imgbtn_sf, 255, LV_PART_MAIN|LV_STATE_CHECKED); lv_obj_set_style_shadow_width(ui->screen_main_imgbtn_sf, 0, LV_PART_MAIN|LV_STATE_CHECKED); //Write style for screen_main_imgbtn_sf, Part: LV_PART_MAIN, State: LV_IMAGEBUTTON_STATE_RELEASED. lv_obj_set_style_image_recolor_opa(ui->screen_main_imgbtn_sf, 0, LV_PART_MAIN|LV_IMAGEBUTTON_STATE_RELEASED); lv_obj_set_style_image_opa(ui->screen_main_imgbtn_sf, 255, LV_PART_MAIN|LV_IMAGEBUTTON_STATE_RELEASED); //Write codes screen_main_imgbtn_js ui->screen_main_imgbtn_js = lv_imagebutton_create(ui->screen_main_cont_mode); lv_obj_set_pos(ui->screen_main_imgbtn_js, 144, 10); lv_obj_set_size(ui->screen_main_imgbtn_js, 60, 60); lv_obj_add_flag(ui->screen_main_imgbtn_js, LV_OBJ_FLAG_EVENT_BUBBLE); lv_obj_add_flag(ui->screen_main_imgbtn_js, LV_OBJ_FLAG_CHECKABLE); lv_imagebutton_set_src(ui->screen_main_imgbtn_js, LV_IMAGEBUTTON_STATE_RELEASED, &_jiashi_RGB565A8_60x60, NULL, NULL); lv_imagebutton_set_src(ui->screen_main_imgbtn_js, LV_IMAGEBUTTON_STATE_PRESSED, &_jiashikai_RGB565A8_60x60, NULL, NULL); lv_imagebutton_set_src(ui->screen_main_imgbtn_js, LV_IMAGEBUTTON_STATE_CHECKED_RELEASED, &_jiashikai_RGB565A8_60x60, NULL, NULL); ui->screen_main_imgbtn_js_label = lv_label_create(ui->screen_main_imgbtn_js); lv_label_set_text(ui->screen_main_imgbtn_js_label, ""); lv_label_set_long_mode(ui->screen_main_imgbtn_js_label, LV_LABEL_LONG_WRAP); lv_obj_align(ui->screen_main_imgbtn_js_label, LV_ALIGN_CENTER, 0, 0); lv_obj_set_style_pad_all(ui->screen_main_imgbtn_js, 0, LV_STATE_DEFAULT); //Write style for screen_main_imgbtn_js, Part: LV_PART_MAIN, State: LV_STATE_DEFAULT. lv_obj_set_style_text_color(ui->screen_main_imgbtn_js, lv_color_hex(0x000000), LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_font(ui->screen_main_imgbtn_js, &lv_font_montserratMedium_12, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_opa(ui->screen_main_imgbtn_js, 255, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_align(ui->screen_main_imgbtn_js, LV_TEXT_ALIGN_CENTER, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_shadow_width(ui->screen_main_imgbtn_js, 0, LV_PART_MAIN|LV_STATE_DEFAULT); //Write style for screen_main_imgbtn_js, Part: LV_PART_MAIN, State: LV_STATE_PRESSED. lv_obj_set_style_image_recolor_opa(ui->screen_main_imgbtn_js, 0, LV_PART_MAIN|LV_STATE_PRESSED); lv_obj_set_style_image_opa(ui->screen_main_imgbtn_js, 255, LV_PART_MAIN|LV_STATE_PRESSED); lv_obj_set_style_text_color(ui->screen_main_imgbtn_js, lv_color_hex(0xFF33FF), LV_PART_MAIN|LV_STATE_PRESSED); lv_obj_set_style_text_font(ui->screen_main_imgbtn_js, &lv_font_montserratMedium_12, LV_PART_MAIN|LV_STATE_PRESSED); lv_obj_set_style_text_opa(ui->screen_main_imgbtn_js, 255, LV_PART_MAIN|LV_STATE_PRESSED); lv_obj_set_style_shadow_width(ui->screen_main_imgbtn_js, 0, LV_PART_MAIN|LV_STATE_PRESSED); //Write style for screen_main_imgbtn_js, Part: LV_PART_MAIN, State: LV_STATE_CHECKED. lv_obj_set_style_image_recolor_opa(ui->screen_main_imgbtn_js, 0, LV_PART_MAIN|LV_STATE_CHECKED); lv_obj_set_style_image_opa(ui->screen_main_imgbtn_js, 255, LV_PART_MAIN|LV_STATE_CHECKED); lv_obj_set_style_text_color(ui->screen_main_imgbtn_js, lv_color_hex(0xFF33FF), LV_PART_MAIN|LV_STATE_CHECKED); lv_obj_set_style_text_font(ui->screen_main_imgbtn_js, &lv_font_montserratMedium_12, LV_PART_MAIN|LV_STATE_CHECKED); lv_obj_set_style_text_opa(ui->screen_main_imgbtn_js, 255, LV_PART_MAIN|LV_STATE_CHECKED); lv_obj_set_style_shadow_width(ui->screen_main_imgbtn_js, 0, LV_PART_MAIN|LV_STATE_CHECKED); //Write style for screen_main_imgbtn_js, Part: LV_PART_MAIN, State: LV_IMAGEBUTTON_STATE_RELEASED. lv_obj_set_style_image_recolor_opa(ui->screen_main_imgbtn_js, 0, LV_PART_MAIN|LV_IMAGEBUTTON_STATE_RELEASED); lv_obj_set_style_image_opa(ui->screen_main_imgbtn_js, 255, LV_PART_MAIN|LV_IMAGEBUTTON_STATE_RELEASED); //Write codes screen_main_imgbtn_cs ui->screen_main_imgbtn_cs = lv_imagebutton_create(ui->screen_main_cont_mode); lv_obj_set_pos(ui->screen_main_imgbtn_cs, 32, 10); lv_obj_set_size(ui->screen_main_imgbtn_cs, 60, 60); lv_obj_add_flag(ui->screen_main_imgbtn_cs, LV_OBJ_FLAG_EVENT_BUBBLE); lv_obj_add_flag(ui->screen_main_imgbtn_cs, LV_OBJ_FLAG_CHECKABLE); lv_imagebutton_set_src(ui->screen_main_imgbtn_cs, LV_IMAGEBUTTON_STATE_RELEASED, &_chushi_RGB565A8_60x60, NULL, NULL); lv_imagebutton_set_src(ui->screen_main_imgbtn_cs, LV_IMAGEBUTTON_STATE_PRESSED, &_chushikai_RGB565A8_60x60, NULL, NULL); lv_imagebutton_set_src(ui->screen_main_imgbtn_cs, LV_IMAGEBUTTON_STATE_CHECKED_RELEASED, &_chushikai_RGB565A8_60x60, NULL, NULL); ui->screen_main_imgbtn_cs_label = lv_label_create(ui->screen_main_imgbtn_cs); lv_label_set_text(ui->screen_main_imgbtn_cs_label, ""); lv_label_set_long_mode(ui->screen_main_imgbtn_cs_label, LV_LABEL_LONG_WRAP); lv_obj_align(ui->screen_main_imgbtn_cs_label, LV_ALIGN_CENTER, 0, 0); lv_obj_set_style_pad_all(ui->screen_main_imgbtn_cs, 0, LV_STATE_DEFAULT); //Write style for screen_main_imgbtn_cs, Part: LV_PART_MAIN, State: LV_STATE_DEFAULT. lv_obj_set_style_text_color(ui->screen_main_imgbtn_cs, lv_color_hex(0x000000), LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_font(ui->screen_main_imgbtn_cs, &lv_font_montserratMedium_12, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_opa(ui->screen_main_imgbtn_cs, 255, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_align(ui->screen_main_imgbtn_cs, LV_TEXT_ALIGN_CENTER, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_shadow_width(ui->screen_main_imgbtn_cs, 0, LV_PART_MAIN|LV_STATE_DEFAULT); //Write style for screen_main_imgbtn_cs, Part: LV_PART_MAIN, State: LV_STATE_PRESSED. lv_obj_set_style_image_recolor_opa(ui->screen_main_imgbtn_cs, 0, LV_PART_MAIN|LV_STATE_PRESSED); lv_obj_set_style_image_opa(ui->screen_main_imgbtn_cs, 255, LV_PART_MAIN|LV_STATE_PRESSED); lv_obj_set_style_text_color(ui->screen_main_imgbtn_cs, lv_color_hex(0xFF33FF), LV_PART_MAIN|LV_STATE_PRESSED); lv_obj_set_style_text_font(ui->screen_main_imgbtn_cs, &lv_font_montserratMedium_12, LV_PART_MAIN|LV_STATE_PRESSED); lv_obj_set_style_text_opa(ui->screen_main_imgbtn_cs, 255, LV_PART_MAIN|LV_STATE_PRESSED); lv_obj_set_style_shadow_width(ui->screen_main_imgbtn_cs, 0, LV_PART_MAIN|LV_STATE_PRESSED); //Write style for screen_main_imgbtn_cs, Part: LV_PART_MAIN, State: LV_STATE_CHECKED. lv_obj_set_style_image_recolor_opa(ui->screen_main_imgbtn_cs, 0, LV_PART_MAIN|LV_STATE_CHECKED); lv_obj_set_style_image_opa(ui->screen_main_imgbtn_cs, 255, LV_PART_MAIN|LV_STATE_CHECKED); lv_obj_set_style_text_color(ui->screen_main_imgbtn_cs, lv_color_hex(0xFF33FF), LV_PART_MAIN|LV_STATE_CHECKED); lv_obj_set_style_text_font(ui->screen_main_imgbtn_cs, &lv_font_montserratMedium_12, LV_PART_MAIN|LV_STATE_CHECKED); lv_obj_set_style_text_opa(ui->screen_main_imgbtn_cs, 255, LV_PART_MAIN|LV_STATE_CHECKED); lv_obj_set_style_shadow_width(ui->screen_main_imgbtn_cs, 0, LV_PART_MAIN|LV_STATE_CHECKED); //Write style for screen_main_imgbtn_cs, Part: LV_PART_MAIN, State: LV_IMAGEBUTTON_STATE_RELEASED. lv_obj_set_style_image_recolor_opa(ui->screen_main_imgbtn_cs, 0, LV_PART_MAIN|LV_IMAGEBUTTON_STATE_RELEASED); lv_obj_set_style_image_opa(ui->screen_main_imgbtn_cs, 255, LV_PART_MAIN|LV_IMAGEBUTTON_STATE_RELEASED); //Write codes screen_main_imgbtn_power ui->screen_main_imgbtn_power = lv_imagebutton_create(ui->screen_main); lv_obj_set_pos(ui->screen_main_imgbtn_power, 35, 32); lv_obj_set_size(ui->screen_main_imgbtn_power, 50, 50); lv_obj_add_flag(ui->screen_main_imgbtn_power, LV_OBJ_FLAG_CHECKABLE); lv_imagebutton_set_src(ui->screen_main_imgbtn_power, LV_IMAGEBUTTON_STATE_RELEASED, &_power_RGB565A8_50x50, NULL, NULL); lv_imagebutton_set_src(ui->screen_main_imgbtn_power, LV_IMAGEBUTTON_STATE_PRESSED, &_power_open_RGB565A8_50x50, NULL, NULL); lv_imagebutton_set_src(ui->screen_main_imgbtn_power, LV_IMAGEBUTTON_STATE_CHECKED_RELEASED, &_power_open_RGB565A8_50x50, NULL, NULL); ui->screen_main_imgbtn_power_label = lv_label_create(ui->screen_main_imgbtn_power); lv_label_set_text(ui->screen_main_imgbtn_power_label, ""); lv_label_set_long_mode(ui->screen_main_imgbtn_power_label, LV_LABEL_LONG_WRAP); lv_obj_align(ui->screen_main_imgbtn_power_label, LV_ALIGN_CENTER, 0, 0); lv_obj_set_style_pad_all(ui->screen_main_imgbtn_power, 0, LV_STATE_DEFAULT); //Write style for screen_main_imgbtn_power, Part: LV_PART_MAIN, State: LV_STATE_DEFAULT. lv_obj_set_style_text_color(ui->screen_main_imgbtn_power, lv_color_hex(0x000000), LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_font(ui->screen_main_imgbtn_power, &lv_font_montserratMedium_12, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_opa(ui->screen_main_imgbtn_power, 255, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_align(ui->screen_main_imgbtn_power, LV_TEXT_ALIGN_CENTER, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_shadow_width(ui->screen_main_imgbtn_power, 0, LV_PART_MAIN|LV_STATE_DEFAULT); //Write style for screen_main_imgbtn_power, Part: LV_PART_MAIN, State: LV_STATE_PRESSED. lv_obj_set_style_image_recolor_opa(ui->screen_main_imgbtn_power, 0, LV_PART_MAIN|LV_STATE_PRESSED); lv_obj_set_style_image_opa(ui->screen_main_imgbtn_power, 255, LV_PART_MAIN|LV_STATE_PRESSED); lv_obj_set_style_text_color(ui->screen_main_imgbtn_power, lv_color_hex(0xFF33FF), LV_PART_MAIN|LV_STATE_PRESSED); lv_obj_set_style_text_font(ui->screen_main_imgbtn_power, &lv_font_montserratMedium_12, LV_PART_MAIN|LV_STATE_PRESSED); lv_obj_set_style_text_opa(ui->screen_main_imgbtn_power, 255, LV_PART_MAIN|LV_STATE_PRESSED); lv_obj_set_style_shadow_width(ui->screen_main_imgbtn_power, 0, LV_PART_MAIN|LV_STATE_PRESSED); //Write style for screen_main_imgbtn_power, Part: LV_PART_MAIN, State: LV_STATE_CHECKED. lv_obj_set_style_image_recolor_opa(ui->screen_main_imgbtn_power, 0, LV_PART_MAIN|LV_STATE_CHECKED); lv_obj_set_style_image_opa(ui->screen_main_imgbtn_power, 255, LV_PART_MAIN|LV_STATE_CHECKED); lv_obj_set_style_text_color(ui->screen_main_imgbtn_power, lv_color_hex(0xFF33FF), LV_PART_MAIN|LV_STATE_CHECKED); lv_obj_set_style_text_font(ui->screen_main_imgbtn_power, &lv_font_montserratMedium_12, LV_PART_MAIN|LV_STATE_CHECKED); lv_obj_set_style_text_opa(ui->screen_main_imgbtn_power, 255, LV_PART_MAIN|LV_STATE_CHECKED); lv_obj_set_style_shadow_width(ui->screen_main_imgbtn_power, 0, LV_PART_MAIN|LV_STATE_CHECKED); //Write style for screen_main_imgbtn_power, Part: LV_PART_MAIN, State: LV_IMAGEBUTTON_STATE_RELEASED. lv_obj_set_style_image_recolor_opa(ui->screen_main_imgbtn_power, 0, LV_PART_MAIN|LV_IMAGEBUTTON_STATE_RELEASED); lv_obj_set_style_image_opa(ui->screen_main_imgbtn_power, 255, LV_PART_MAIN|LV_IMAGEBUTTON_STATE_RELEASED); //Write codes screen_main_cont_speedset ui->screen_main_cont_speedset = lv_obj_create(ui->screen_main); lv_obj_set_pos(ui->screen_main_cont_speedset, 35, 95); lv_obj_set_size(ui->screen_main_cont_speedset, 43, 248); lv_obj_set_scrollbar_mode(ui->screen_main_cont_speedset, LV_SCROLLBAR_MODE_OFF); lv_obj_remove_flag(ui->screen_main_cont_speedset, LV_OBJ_FLAG_SCROLLABLE); //Write style for screen_main_cont_speedset, Part: LV_PART_MAIN, State: LV_STATE_DEFAULT. lv_obj_set_style_border_width(ui->screen_main_cont_speedset, 2, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_border_opa(ui->screen_main_cont_speedset, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_border_color(ui->screen_main_cont_speedset, lv_color_hex(0x2195f6), LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_border_side(ui->screen_main_cont_speedset, LV_BORDER_SIDE_FULL, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_radius(ui->screen_main_cont_speedset, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_bg_opa(ui->screen_main_cont_speedset, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_top(ui->screen_main_cont_speedset, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_bottom(ui->screen_main_cont_speedset, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_left(ui->screen_main_cont_speedset, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_right(ui->screen_main_cont_speedset, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_shadow_width(ui->screen_main_cont_speedset, 0, LV_PART_MAIN|LV_STATE_DEFAULT); //Write codes screen_main_slider_speedSet_sign ui->screen_main_slider_speedSet_sign = lv_slider_create(ui->screen_main_cont_speedset); lv_obj_set_pos(ui->screen_main_slider_speedSet_sign, 0, 0); lv_obj_set_size(ui->screen_main_slider_speedSet_sign, 40, 245); lv_slider_set_range(ui->screen_main_slider_speedSet_sign, 0, 90); lv_slider_set_mode(ui->screen_main_slider_speedSet_sign, LV_SLIDER_MODE_NORMAL); lv_slider_set_value(ui->screen_main_slider_speedSet_sign, 30, LV_ANIM_OFF); //Write style for screen_main_slider_speedSet_sign, Part: LV_PART_MAIN, State: LV_STATE_DEFAULT. lv_obj_set_style_bg_opa(ui->screen_main_slider_speedSet_sign, 255, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_bg_color(ui->screen_main_slider_speedSet_sign, lv_color_hex(0x565B6E), LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_bg_grad_dir(ui->screen_main_slider_speedSet_sign, LV_GRAD_DIR_NONE, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_radius(ui->screen_main_slider_speedSet_sign, 10, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_outline_width(ui->screen_main_slider_speedSet_sign, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_shadow_width(ui->screen_main_slider_speedSet_sign, 0, LV_PART_MAIN|LV_STATE_DEFAULT); //Write style for screen_main_slider_speedSet_sign, Part: LV_PART_MAIN, State: LV_STATE_FOCUSED. lv_obj_set_style_shadow_width(ui->screen_main_slider_speedSet_sign, 0, LV_PART_MAIN|LV_STATE_FOCUSED); //Write style for screen_main_slider_speedSet_sign, Part: LV_PART_INDICATOR, State: LV_STATE_DEFAULT. lv_obj_set_style_bg_opa(ui->screen_main_slider_speedSet_sign, 255, LV_PART_INDICATOR|LV_STATE_DEFAULT); lv_obj_set_style_bg_color(ui->screen_main_slider_speedSet_sign, lv_color_hex(0x0ACF7A), LV_PART_INDICATOR|LV_STATE_DEFAULT); lv_obj_set_style_bg_grad_dir(ui->screen_main_slider_speedSet_sign, LV_GRAD_DIR_NONE, LV_PART_INDICATOR|LV_STATE_DEFAULT); lv_obj_set_style_radius(ui->screen_main_slider_speedSet_sign, 6, LV_PART_INDICATOR|LV_STATE_DEFAULT); //Write style for screen_main_slider_speedSet_sign, Part: LV_PART_KNOB, State: LV_STATE_DEFAULT. lv_obj_set_style_bg_opa(ui->screen_main_slider_speedSet_sign, 0, LV_PART_KNOB|LV_STATE_DEFAULT); lv_obj_set_style_radius(ui->screen_main_slider_speedSet_sign, 50, LV_PART_KNOB|LV_STATE_DEFAULT); //Write codes screen_main_line_1 ui->screen_main_line_1 = lv_line_create(ui->screen_main_cont_speedset); lv_obj_set_pos(ui->screen_main_line_1, 1, 165); lv_obj_set_size(ui->screen_main_line_1, 37, 48); static lv_point_precise_t screen_main_line_1[] = {{0, 0},{180, 0}}; lv_line_set_points(ui->screen_main_line_1, screen_main_line_1, 2); //Write style for screen_main_line_1, Part: LV_PART_MAIN, State: LV_STATE_DEFAULT. lv_obj_set_style_line_width(ui->screen_main_line_1, 2, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_line_color(ui->screen_main_line_1, lv_color_hex(0xffffff), LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_line_opa(ui->screen_main_line_1, 255, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_line_rounded(ui->screen_main_line_1, true, LV_PART_MAIN|LV_STATE_DEFAULT); //Write codes screen_main_line_5 ui->screen_main_line_5 = lv_line_create(ui->screen_main_cont_speedset); lv_obj_set_pos(ui->screen_main_line_5, 1, 84); lv_obj_set_size(ui->screen_main_line_5, 37, 48); static lv_point_precise_t screen_main_line_5[] = {{0, 0},{180, 0}}; lv_line_set_points(ui->screen_main_line_5, screen_main_line_5, 2); //Write style for screen_main_line_5, Part: LV_PART_MAIN, State: LV_STATE_DEFAULT. lv_obj_set_style_line_width(ui->screen_main_line_5, 2, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_line_color(ui->screen_main_line_5, lv_color_hex(0xffffff), LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_line_opa(ui->screen_main_line_5, 255, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_line_rounded(ui->screen_main_line_5, true, LV_PART_MAIN|LV_STATE_DEFAULT); //Write codes screen_main_label_spedSet_vul ui->screen_main_label_spedSet_vul = lv_label_create(ui->screen_main_cont_speedset); lv_obj_set_pos(ui->screen_main_label_spedSet_vul, 10, 25); lv_obj_set_size(ui->screen_main_label_spedSet_vul, 24, 14); lv_label_set_text(ui->screen_main_label_spedSet_vul, "2档"); lv_label_set_long_mode(ui->screen_main_label_spedSet_vul, LV_LABEL_LONG_WRAP); //Write style for screen_main_label_spedSet_vul, Part: LV_PART_MAIN, State: LV_STATE_DEFAULT. lv_obj_set_style_border_width(ui->screen_main_label_spedSet_vul, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_radius(ui->screen_main_label_spedSet_vul, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_color(ui->screen_main_label_spedSet_vul, lv_color_hex(0xffffff), LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_font(ui->screen_main_label_spedSet_vul, &lv_font_Alibaba_PuHuiTi_Medium_12, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_opa(ui->screen_main_label_spedSet_vul, 255, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_letter_space(ui->screen_main_label_spedSet_vul, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_line_space(ui->screen_main_label_spedSet_vul, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_align(ui->screen_main_label_spedSet_vul, LV_TEXT_ALIGN_LEFT, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_bg_opa(ui->screen_main_label_spedSet_vul, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_top(ui->screen_main_label_spedSet_vul, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_right(ui->screen_main_label_spedSet_vul, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_bottom(ui->screen_main_label_spedSet_vul, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_left(ui->screen_main_label_spedSet_vul, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_shadow_width(ui->screen_main_label_spedSet_vul, 0, LV_PART_MAIN|LV_STATE_DEFAULT); //Write codes screen_main_label_1 ui->screen_main_label_1 = lv_label_create(ui->screen_main_cont_speedset); lv_obj_set_pos(ui->screen_main_label_1, 10, 215); lv_obj_set_size(ui->screen_main_label_1, 20, 20); lv_label_set_text(ui->screen_main_label_1, ""); lv_label_set_long_mode(ui->screen_main_label_1, LV_LABEL_LONG_WRAP); //Write style for screen_main_label_1, Part: LV_PART_MAIN, State: LV_STATE_DEFAULT. lv_obj_set_style_border_width(ui->screen_main_label_1, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_radius(ui->screen_main_label_1, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_color(ui->screen_main_label_1, lv_color_hex(0x000000), LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_font(ui->screen_main_label_1, &lv_font_montserratMedium_16, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_opa(ui->screen_main_label_1, 255, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_letter_space(ui->screen_main_label_1, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_line_space(ui->screen_main_label_1, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_align(ui->screen_main_label_1, LV_TEXT_ALIGN_CENTER, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_bg_opa(ui->screen_main_label_1, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_top(ui->screen_main_label_1, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_right(ui->screen_main_label_1, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_bottom(ui->screen_main_label_1, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_left(ui->screen_main_label_1, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_bg_image_src(ui->screen_main_label_1, &_speed_RGB565A8_20x20, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_bg_image_opa(ui->screen_main_label_1, 255, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_bg_image_recolor_opa(ui->screen_main_label_1, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_shadow_width(ui->screen_main_label_1, 0, LV_PART_MAIN|LV_STATE_DEFAULT); //Write codes screen_main_cont_humSet ui->screen_main_cont_humSet = lv_obj_create(ui->screen_main); lv_obj_set_pos(ui->screen_main_cont_humSet, 407, 95); lv_obj_set_size(ui->screen_main_cont_humSet, 48, 248); lv_obj_set_scrollbar_mode(ui->screen_main_cont_humSet, LV_SCROLLBAR_MODE_OFF); lv_obj_remove_flag(ui->screen_main_cont_humSet, LV_OBJ_FLAG_SCROLLABLE); //Write style for screen_main_cont_humSet, Part: LV_PART_MAIN, State: LV_STATE_DEFAULT. lv_obj_set_style_border_width(ui->screen_main_cont_humSet, 2, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_border_opa(ui->screen_main_cont_humSet, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_border_color(ui->screen_main_cont_humSet, lv_color_hex(0x2195f6), LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_border_side(ui->screen_main_cont_humSet, LV_BORDER_SIDE_FULL, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_radius(ui->screen_main_cont_humSet, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_bg_opa(ui->screen_main_cont_humSet, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_top(ui->screen_main_cont_humSet, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_bottom(ui->screen_main_cont_humSet, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_left(ui->screen_main_cont_humSet, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_right(ui->screen_main_cont_humSet, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_shadow_width(ui->screen_main_cont_humSet, 0, LV_PART_MAIN|LV_STATE_DEFAULT); //Write codes screen_main_slider_humSet_sign ui->screen_main_slider_humSet_sign = lv_slider_create(ui->screen_main_cont_humSet); lv_obj_set_pos(ui->screen_main_slider_humSet_sign, 0, 0); lv_obj_set_size(ui->screen_main_slider_humSet_sign, 40, 245); lv_slider_set_range(ui->screen_main_slider_humSet_sign, 30, 70); lv_slider_set_mode(ui->screen_main_slider_humSet_sign, LV_SLIDER_MODE_NORMAL); lv_slider_set_value(ui->screen_main_slider_humSet_sign, 50, LV_ANIM_OFF); //Write style for screen_main_slider_humSet_sign, Part: LV_PART_MAIN, State: LV_STATE_DEFAULT. lv_obj_set_style_bg_opa(ui->screen_main_slider_humSet_sign, 255, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_bg_color(ui->screen_main_slider_humSet_sign, lv_color_hex(0x565B6E), LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_bg_grad_dir(ui->screen_main_slider_humSet_sign, LV_GRAD_DIR_NONE, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_radius(ui->screen_main_slider_humSet_sign, 10, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_outline_width(ui->screen_main_slider_humSet_sign, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_shadow_width(ui->screen_main_slider_humSet_sign, 0, LV_PART_MAIN|LV_STATE_DEFAULT); //Write style for screen_main_slider_humSet_sign, Part: LV_PART_MAIN, State: LV_STATE_FOCUSED. lv_obj_set_style_shadow_width(ui->screen_main_slider_humSet_sign, 0, LV_PART_MAIN|LV_STATE_FOCUSED); //Write style for screen_main_slider_humSet_sign, Part: LV_PART_INDICATOR, State: LV_STATE_DEFAULT. lv_obj_set_style_bg_opa(ui->screen_main_slider_humSet_sign, 255, LV_PART_INDICATOR|LV_STATE_DEFAULT); lv_obj_set_style_bg_color(ui->screen_main_slider_humSet_sign, lv_color_hex(0x2195f6), LV_PART_INDICATOR|LV_STATE_DEFAULT); lv_obj_set_style_bg_grad_dir(ui->screen_main_slider_humSet_sign, LV_GRAD_DIR_NONE, LV_PART_INDICATOR|LV_STATE_DEFAULT); lv_obj_set_style_radius(ui->screen_main_slider_humSet_sign, 6, LV_PART_INDICATOR|LV_STATE_DEFAULT); //Write style for screen_main_slider_humSet_sign, Part: LV_PART_KNOB, State: LV_STATE_DEFAULT. lv_obj_set_style_bg_opa(ui->screen_main_slider_humSet_sign, 0, LV_PART_KNOB|LV_STATE_DEFAULT); lv_obj_set_style_radius(ui->screen_main_slider_humSet_sign, 50, LV_PART_KNOB|LV_STATE_DEFAULT); //Write codes screen_main_label_2 ui->screen_main_label_2 = lv_label_create(ui->screen_main_cont_humSet); lv_obj_set_pos(ui->screen_main_label_2, 10, 215); lv_obj_set_size(ui->screen_main_label_2, 20, 20); lv_label_set_text(ui->screen_main_label_2, ""); lv_label_set_long_mode(ui->screen_main_label_2, LV_LABEL_LONG_WRAP); //Write style for screen_main_label_2, Part: LV_PART_MAIN, State: LV_STATE_DEFAULT. lv_obj_set_style_border_width(ui->screen_main_label_2, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_radius(ui->screen_main_label_2, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_color(ui->screen_main_label_2, lv_color_hex(0x000000), LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_font(ui->screen_main_label_2, &lv_font_montserratMedium_16, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_opa(ui->screen_main_label_2, 255, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_letter_space(ui->screen_main_label_2, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_line_space(ui->screen_main_label_2, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_align(ui->screen_main_label_2, LV_TEXT_ALIGN_CENTER, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_bg_opa(ui->screen_main_label_2, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_top(ui->screen_main_label_2, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_right(ui->screen_main_label_2, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_bottom(ui->screen_main_label_2, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_left(ui->screen_main_label_2, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_bg_image_src(ui->screen_main_label_2, &_hum_RGB565A8_20x20, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_bg_image_opa(ui->screen_main_label_2, 255, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_bg_image_recolor_opa(ui->screen_main_label_2, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_shadow_width(ui->screen_main_label_2, 0, LV_PART_MAIN|LV_STATE_DEFAULT); //Write codes screen_main_label_humSet_vul ui->screen_main_label_humSet_vul = lv_label_create(ui->screen_main_cont_humSet); lv_obj_set_pos(ui->screen_main_label_humSet_vul, -2, 25); lv_obj_set_size(ui->screen_main_label_humSet_vul, 36, 14); lv_label_set_text(ui->screen_main_label_humSet_vul, "24%"); lv_label_set_long_mode(ui->screen_main_label_humSet_vul, LV_LABEL_LONG_WRAP); //Write style for screen_main_label_humSet_vul, Part: LV_PART_MAIN, State: LV_STATE_DEFAULT. lv_obj_set_style_border_width(ui->screen_main_label_humSet_vul, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_radius(ui->screen_main_label_humSet_vul, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_color(ui->screen_main_label_humSet_vul, lv_color_hex(0xffffff), LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_font(ui->screen_main_label_humSet_vul, &lv_font_Alibaba_PuHuiTi_Medium_12, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_opa(ui->screen_main_label_humSet_vul, 255, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_letter_space(ui->screen_main_label_humSet_vul, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_line_space(ui->screen_main_label_humSet_vul, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_align(ui->screen_main_label_humSet_vul, LV_TEXT_ALIGN_RIGHT, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_bg_opa(ui->screen_main_label_humSet_vul, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_top(ui->screen_main_label_humSet_vul, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_right(ui->screen_main_label_humSet_vul, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_bottom(ui->screen_main_label_humSet_vul, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_left(ui->screen_main_label_humSet_vul, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_shadow_width(ui->screen_main_label_humSet_vul, 0, LV_PART_MAIN|LV_STATE_DEFAULT); //Write codes screen_main_lab_err ui->screen_main_lab_err = lv_label_create(ui->screen_main); lv_obj_set_pos(ui->screen_main_lab_err, 292, 7); lv_obj_set_size(ui->screen_main_lab_err, 32, 32); lv_obj_add_flag(ui->screen_main_lab_err, LV_OBJ_FLAG_HIDDEN); lv_label_set_text(ui->screen_main_lab_err, ""); lv_label_set_long_mode(ui->screen_main_lab_err, LV_LABEL_LONG_WRAP); //Write style for screen_main_lab_err, Part: LV_PART_MAIN, State: LV_STATE_DEFAULT. lv_obj_set_style_border_width(ui->screen_main_lab_err, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_radius(ui->screen_main_lab_err, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_color(ui->screen_main_lab_err, lv_color_hex(0xfa052b), LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_font(ui->screen_main_lab_err, &lv_font_iconfont_22, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_opa(ui->screen_main_lab_err, 255, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_letter_space(ui->screen_main_lab_err, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_line_space(ui->screen_main_lab_err, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_align(ui->screen_main_lab_err, LV_TEXT_ALIGN_CENTER, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_bg_opa(ui->screen_main_lab_err, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_top(ui->screen_main_lab_err, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_right(ui->screen_main_lab_err, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_bottom(ui->screen_main_lab_err, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_left(ui->screen_main_lab_err, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_shadow_width(ui->screen_main_lab_err, 0, LV_PART_MAIN|LV_STATE_DEFAULT); //Write codes screen_main_lab_485_err ui->screen_main_lab_485_err = lv_label_create(ui->screen_main); lv_obj_set_pos(ui->screen_main_lab_485_err, 359, 7); lv_obj_set_size(ui->screen_main_lab_485_err, 32, 32); lv_obj_add_flag(ui->screen_main_lab_485_err, LV_OBJ_FLAG_HIDDEN); lv_label_set_text(ui->screen_main_lab_485_err, ""); lv_label_set_long_mode(ui->screen_main_lab_485_err, LV_LABEL_LONG_WRAP); //Write style for screen_main_lab_485_err, Part: LV_PART_MAIN, State: LV_STATE_DEFAULT. lv_obj_set_style_border_width(ui->screen_main_lab_485_err, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_radius(ui->screen_main_lab_485_err, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_color(ui->screen_main_lab_485_err, lv_color_hex(0xf7da00), LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_font(ui->screen_main_lab_485_err, &lv_font_iconfont_22, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_opa(ui->screen_main_lab_485_err, 255, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_letter_space(ui->screen_main_lab_485_err, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_line_space(ui->screen_main_lab_485_err, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_align(ui->screen_main_lab_485_err, LV_TEXT_ALIGN_CENTER, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_bg_opa(ui->screen_main_lab_485_err, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_top(ui->screen_main_lab_485_err, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_right(ui->screen_main_lab_485_err, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_bottom(ui->screen_main_lab_485_err, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_left(ui->screen_main_lab_485_err, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_shadow_width(ui->screen_main_lab_485_err, 0, LV_PART_MAIN|LV_STATE_DEFAULT); //Write codes screen_main_label_wifi ui->screen_main_label_wifi = lv_label_create(ui->screen_main); lv_obj_set_pos(ui->screen_main_label_wifi, 425, 2); lv_obj_set_size(ui->screen_main_label_wifi, 30, 30); lv_obj_add_flag(ui->screen_main_label_wifi, LV_OBJ_FLAG_HIDDEN); lv_label_set_text(ui->screen_main_label_wifi, ""); lv_label_set_long_mode(ui->screen_main_label_wifi, LV_LABEL_LONG_WRAP); //Write style for screen_main_label_wifi, Part: LV_PART_MAIN, State: LV_STATE_DEFAULT. lv_obj_set_style_border_width(ui->screen_main_label_wifi, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_radius(ui->screen_main_label_wifi, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_color(ui->screen_main_label_wifi, lv_color_hex(0xffffff), LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_font(ui->screen_main_label_wifi, &lv_font_iconfont_16, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_opa(ui->screen_main_label_wifi, 255, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_letter_space(ui->screen_main_label_wifi, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_line_space(ui->screen_main_label_wifi, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_align(ui->screen_main_label_wifi, LV_TEXT_ALIGN_CENTER, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_bg_opa(ui->screen_main_label_wifi, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_top(ui->screen_main_label_wifi, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_right(ui->screen_main_label_wifi, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_bottom(ui->screen_main_label_wifi, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_left(ui->screen_main_label_wifi, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_bg_image_src(ui->screen_main_label_wifi, &_WiFiruo_RGB565A8_30x30, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_bg_image_opa(ui->screen_main_label_wifi, 255, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_bg_image_recolor_opa(ui->screen_main_label_wifi, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_shadow_width(ui->screen_main_label_wifi, 0, LV_PART_MAIN|LV_STATE_DEFAULT); //Write codes screen_main_label_19 ui->screen_main_label_19 = lv_label_create(ui->screen_main); lv_obj_set_pos(ui->screen_main_label_19, 539, 29); lv_obj_set_size(ui->screen_main_label_19, 100, 32); lv_obj_add_flag(ui->screen_main_label_19, LV_OBJ_FLAG_HIDDEN); lv_obj_add_flag(ui->screen_main_label_19, LV_OBJ_FLAG_HIDDEN); lv_label_set_text(ui->screen_main_label_19, ""); lv_label_set_long_mode(ui->screen_main_label_19, LV_LABEL_LONG_WRAP); //Write style for screen_main_label_19, Part: LV_PART_MAIN, State: LV_STATE_DEFAULT. lv_obj_set_style_border_width(ui->screen_main_label_19, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_radius(ui->screen_main_label_19, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_color(ui->screen_main_label_19, lv_color_hex(0xffffff), LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_font(ui->screen_main_label_19, &lv_font_iconfont_16, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_opa(ui->screen_main_label_19, 255, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_letter_space(ui->screen_main_label_19, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_line_space(ui->screen_main_label_19, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_align(ui->screen_main_label_19, LV_TEXT_ALIGN_CENTER, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_bg_opa(ui->screen_main_label_19, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_top(ui->screen_main_label_19, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_right(ui->screen_main_label_19, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_bottom(ui->screen_main_label_19, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_left(ui->screen_main_label_19, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_shadow_width(ui->screen_main_label_19, 0, LV_PART_MAIN|LV_STATE_DEFAULT); //Write codes screen_main_lab_cloud1 ui->screen_main_lab_cloud1 = lv_label_create(ui->screen_main); lv_obj_set_pos(ui->screen_main_lab_cloud1, 393, 7); lv_obj_set_size(ui->screen_main_lab_cloud1, 32, 32); lv_obj_add_flag(ui->screen_main_lab_cloud1, LV_OBJ_FLAG_HIDDEN); lv_label_set_text(ui->screen_main_lab_cloud1, ""); lv_label_set_long_mode(ui->screen_main_lab_cloud1, LV_LABEL_LONG_WRAP); //Write style for screen_main_lab_cloud1, Part: LV_PART_MAIN, State: LV_STATE_DEFAULT. lv_obj_set_style_border_width(ui->screen_main_lab_cloud1, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_radius(ui->screen_main_lab_cloud1, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_color(ui->screen_main_lab_cloud1, lv_color_hex(0xffffff), LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_font(ui->screen_main_lab_cloud1, &lv_font_iconfont_22, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_opa(ui->screen_main_lab_cloud1, 255, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_letter_space(ui->screen_main_lab_cloud1, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_line_space(ui->screen_main_lab_cloud1, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_align(ui->screen_main_lab_cloud1, LV_TEXT_ALIGN_CENTER, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_bg_opa(ui->screen_main_lab_cloud1, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_top(ui->screen_main_lab_cloud1, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_right(ui->screen_main_lab_cloud1, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_bottom(ui->screen_main_lab_cloud1, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_left(ui->screen_main_lab_cloud1, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_shadow_width(ui->screen_main_lab_cloud1, 0, LV_PART_MAIN|LV_STATE_DEFAULT); //Write codes screen_main_label_filter_error ui->screen_main_label_filter_error = lv_label_create(ui->screen_main); lv_obj_set_pos(ui->screen_main_label_filter_error, 269, 7); lv_obj_set_size(ui->screen_main_label_filter_error, 21, 26); lv_obj_add_flag(ui->screen_main_label_filter_error, LV_OBJ_FLAG_HIDDEN); lv_label_set_text(ui->screen_main_label_filter_error, ""); lv_label_set_long_mode(ui->screen_main_label_filter_error, LV_LABEL_LONG_WRAP); //Write style for screen_main_label_filter_error, Part: LV_PART_MAIN, State: LV_STATE_DEFAULT. lv_obj_set_style_border_width(ui->screen_main_label_filter_error, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_radius(ui->screen_main_label_filter_error, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_color(ui->screen_main_label_filter_error, lv_color_hex(0xff6500), LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_font(ui->screen_main_label_filter_error, &lv_font_iconfont_22, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_opa(ui->screen_main_label_filter_error, 255, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_letter_space(ui->screen_main_label_filter_error, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_line_space(ui->screen_main_label_filter_error, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_align(ui->screen_main_label_filter_error, LV_TEXT_ALIGN_CENTER, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_bg_opa(ui->screen_main_label_filter_error, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_top(ui->screen_main_label_filter_error, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_right(ui->screen_main_label_filter_error, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_bottom(ui->screen_main_label_filter_error, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_left(ui->screen_main_label_filter_error, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_shadow_width(ui->screen_main_label_filter_error, 0, LV_PART_MAIN|LV_STATE_DEFAULT); //Write codes screen_main_imgbtn_new_fan ui->screen_main_imgbtn_new_fan = lv_imagebutton_create(ui->screen_main); lv_obj_set_pos(ui->screen_main_imgbtn_new_fan, 374, 385); lv_obj_set_size(ui->screen_main_imgbtn_new_fan, 60, 60); lv_obj_add_flag(ui->screen_main_imgbtn_new_fan, LV_OBJ_FLAG_CHECKABLE); lv_imagebutton_set_src(ui->screen_main_imgbtn_new_fan, LV_IMAGEBUTTON_STATE_RELEASED, &_xinfeng_RGB565A8_60x60, NULL, NULL); lv_imagebutton_set_src(ui->screen_main_imgbtn_new_fan, LV_IMAGEBUTTON_STATE_PRESSED, &_xinfengkai_RGB565A8_60x60, NULL, NULL); lv_imagebutton_set_src(ui->screen_main_imgbtn_new_fan, LV_IMAGEBUTTON_STATE_CHECKED_RELEASED, &_xinfengkai_RGB565A8_60x60, NULL, NULL); lv_imagebutton_set_src(ui->screen_main_imgbtn_new_fan, LV_IMAGEBUTTON_STATE_CHECKED_PRESSED, &_xinfeng_RGB565A8_60x60, NULL, NULL); ui->screen_main_imgbtn_new_fan_label = lv_label_create(ui->screen_main_imgbtn_new_fan); lv_label_set_text(ui->screen_main_imgbtn_new_fan_label, ""); lv_label_set_long_mode(ui->screen_main_imgbtn_new_fan_label, LV_LABEL_LONG_WRAP); lv_obj_align(ui->screen_main_imgbtn_new_fan_label, LV_ALIGN_CENTER, 0, 0); lv_obj_set_style_pad_all(ui->screen_main_imgbtn_new_fan, 0, LV_STATE_DEFAULT); //Write style for screen_main_imgbtn_new_fan, Part: LV_PART_MAIN, State: LV_STATE_DEFAULT. lv_obj_set_style_text_color(ui->screen_main_imgbtn_new_fan, lv_color_hex(0x000000), LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_font(ui->screen_main_imgbtn_new_fan, &lv_font_montserratMedium_12, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_opa(ui->screen_main_imgbtn_new_fan, 255, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_align(ui->screen_main_imgbtn_new_fan, LV_TEXT_ALIGN_CENTER, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_shadow_width(ui->screen_main_imgbtn_new_fan, 0, LV_PART_MAIN|LV_STATE_DEFAULT); //Write style for screen_main_imgbtn_new_fan, Part: LV_PART_MAIN, State: LV_STATE_PRESSED. lv_obj_set_style_image_recolor_opa(ui->screen_main_imgbtn_new_fan, 0, LV_PART_MAIN|LV_STATE_PRESSED); lv_obj_set_style_image_opa(ui->screen_main_imgbtn_new_fan, 255, LV_PART_MAIN|LV_STATE_PRESSED); lv_obj_set_style_text_color(ui->screen_main_imgbtn_new_fan, lv_color_hex(0xFF33FF), LV_PART_MAIN|LV_STATE_PRESSED); lv_obj_set_style_text_font(ui->screen_main_imgbtn_new_fan, &lv_font_montserratMedium_12, LV_PART_MAIN|LV_STATE_PRESSED); lv_obj_set_style_text_opa(ui->screen_main_imgbtn_new_fan, 255, LV_PART_MAIN|LV_STATE_PRESSED); lv_obj_set_style_shadow_width(ui->screen_main_imgbtn_new_fan, 0, LV_PART_MAIN|LV_STATE_PRESSED); //Write style for screen_main_imgbtn_new_fan, Part: LV_PART_MAIN, State: LV_STATE_CHECKED. lv_obj_set_style_image_recolor_opa(ui->screen_main_imgbtn_new_fan, 0, LV_PART_MAIN|LV_STATE_CHECKED); lv_obj_set_style_image_opa(ui->screen_main_imgbtn_new_fan, 255, LV_PART_MAIN|LV_STATE_CHECKED); lv_obj_set_style_text_color(ui->screen_main_imgbtn_new_fan, lv_color_hex(0xFF33FF), LV_PART_MAIN|LV_STATE_CHECKED); lv_obj_set_style_text_font(ui->screen_main_imgbtn_new_fan, &lv_font_montserratMedium_12, LV_PART_MAIN|LV_STATE_CHECKED); lv_obj_set_style_text_opa(ui->screen_main_imgbtn_new_fan, 255, LV_PART_MAIN|LV_STATE_CHECKED); lv_obj_set_style_shadow_width(ui->screen_main_imgbtn_new_fan, 0, LV_PART_MAIN|LV_STATE_CHECKED); //Write style for screen_main_imgbtn_new_fan, Part: LV_PART_MAIN, State: LV_IMAGEBUTTON_STATE_RELEASED. lv_obj_set_style_image_recolor_opa(ui->screen_main_imgbtn_new_fan, 0, LV_PART_MAIN|LV_IMAGEBUTTON_STATE_RELEASED); lv_obj_set_style_image_opa(ui->screen_main_imgbtn_new_fan, 255, LV_PART_MAIN|LV_IMAGEBUTTON_STATE_RELEASED); //Write codes screen_main_img_proof ui->screen_main_img_proof = lv_image_create(ui->screen_main); lv_obj_set_pos(ui->screen_main_img_proof, 237, 7); lv_obj_set_size(ui->screen_main_img_proof, 22, 22); lv_obj_add_flag(ui->screen_main_img_proof, LV_OBJ_FLAG_HIDDEN); lv_obj_add_flag(ui->screen_main_img_proof, LV_OBJ_FLAG_CLICKABLE); lv_image_set_src(ui->screen_main_img_proof, &_proof_RGB565A8_22x22); lv_image_set_pivot(ui->screen_main_img_proof, 50,50); lv_image_set_rotation(ui->screen_main_img_proof, 0); //Write style for screen_main_img_proof, Part: LV_PART_MAIN, State: LV_STATE_DEFAULT. lv_obj_set_style_image_recolor_opa(ui->screen_main_img_proof, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_image_opa(ui->screen_main_img_proof, 255, LV_PART_MAIN|LV_STATE_DEFAULT); //Write codes screen_main_lab_485_err_js ui->screen_main_lab_485_err_js = lv_label_create(ui->screen_main); lv_obj_set_pos(ui->screen_main_lab_485_err_js, 324, 7); lv_obj_set_size(ui->screen_main_lab_485_err_js, 32, 32); lv_obj_add_flag(ui->screen_main_lab_485_err_js, LV_OBJ_FLAG_HIDDEN); lv_label_set_text(ui->screen_main_lab_485_err_js, ""); lv_label_set_long_mode(ui->screen_main_lab_485_err_js, LV_LABEL_LONG_WRAP); //Write style for screen_main_lab_485_err_js, Part: LV_PART_MAIN, State: LV_STATE_DEFAULT. lv_obj_set_style_border_width(ui->screen_main_lab_485_err_js, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_radius(ui->screen_main_lab_485_err_js, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_color(ui->screen_main_lab_485_err_js, lv_color_hex(0xff7300), LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_font(ui->screen_main_lab_485_err_js, &lv_font_iconfont_22, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_opa(ui->screen_main_lab_485_err_js, 255, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_letter_space(ui->screen_main_lab_485_err_js, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_line_space(ui->screen_main_lab_485_err_js, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_text_align(ui->screen_main_lab_485_err_js, LV_TEXT_ALIGN_CENTER, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_bg_opa(ui->screen_main_lab_485_err_js, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_top(ui->screen_main_lab_485_err_js, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_right(ui->screen_main_lab_485_err_js, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_bottom(ui->screen_main_lab_485_err_js, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_pad_left(ui->screen_main_lab_485_err_js, 0, LV_PART_MAIN|LV_STATE_DEFAULT); lv_obj_set_style_shadow_width(ui->screen_main_lab_485_err_js, 0, LV_PART_MAIN|LV_STATE_DEFAULT); //The custom code of screen_main. lv_obj_remove_flag(ui->screen_main_slider_humSet_sign, LV_OBJ_FLAG_GESTURE_BUBBLE); lv_obj_remove_flag(ui->screen_main_slider_speedSet_sign, LV_OBJ_FLAG_GESTURE_BUBBLE); lv_obj_clear_flag(ui->screen_main_arc_hum, LV_OBJ_FLAG_CLICKABLE); if(xf_status.new_fan==1) { lv_obj_add_state(ui->screen_main_imgbtn_new_fan,LV_STATE_CHECKED); } else { lv_obj_remove_state(ui->screen_main_imgbtn_new_fan,LV_STATE_CHECKED); } lv_label_set_text_fmt(ui->screen_main_label_humSet_vul, "%d%%", xf_status.set_max_hum); lv_slider_set_value(ui->screen_main_slider_speedSet_sign, xf_status.fan_speed*30, LV_ANIM_ON); lv_label_set_text_fmt(ui->screen_main_label_spedSet_vul, "%d档",xf_status.fan_speed); lv_slider_set_value(ui->screen_main_slider_humSet_sign, xf_status.set_max_hum, LV_ANIM_ON); set_xf_mode(ui, xf_status.mode); xf_set_power(true); // 设置电源状态 lv_obj_add_state(ui->screen_main_imgbtn_power, xf_status.power == 1 ? LV_STATE_CHECKED : LV_STATE_DEFAULT); //Update current screen layout. lv_obj_update_layout(ui->screen_main); //Init events for screen. events_init_screen_main(ui); }