Skip to content

Commit

Permalink
fix arc
Browse files Browse the repository at this point in the history
  • Loading branch information
txp666 committed Jan 23, 2025
1 parent a33e5ea commit d4719d5
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
4 changes: 4 additions & 0 deletions Firmware/src/UIPE2/custom/screen_cpu.c
Original file line number Diff line number Diff line change
Expand Up @@ -24,10 +24,14 @@ static void cpu_timer_cb(lv_timer_t *timer)
snprintf(buf, sizeof(buf), "%.1f/%.1f GB", mem_used, mem_total);
lv_label_set_text(guider_ui.screen_cpu_label_mem2, buf);
lv_label_set_text(guider_ui.screen_cpu_label_time, date);
lv_arc_set_value(guider_ui.screen_cpu_arc_cpu, cpu_usage);
lv_arc_set_value(guider_ui.screen_cpu_arc_mem, mem_usage);
}

void screen_cpu_load_start()
{
lv_obj_clear_flag(guider_ui.screen_cpu_arc_cpu, LV_OBJ_FLAG_CLICKABLE);
lv_obj_clear_flag(guider_ui.screen_cpu_arc_mem, LV_OBJ_FLAG_CLICKABLE);
screen_cpu_timer = lv_timer_create(cpu_timer_cb, 50, NULL);
}

Expand Down
1 change: 1 addition & 0 deletions Firmware/src/UIPE2/custom/screen_ha.c
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,7 @@ static void ha_timer_cb()

void screen_ha_load_start()
{
lv_obj_clear_flag(guider_ui.screen_HA_arc_temp, LV_OBJ_FLAG_CLICKABLE);
ha_timer = lv_timer_create(ha_timer_cb, 500, NULL);
lv_obj_add_event_cb(guider_ui.screen_HA_sw_fan, fan_event_handler, LV_EVENT_VALUE_CHANGED, NULL);
lv_obj_add_event_cb(guider_ui.screen_HA_sw_light, light_event_handler, LV_EVENT_VALUE_CHANGED, NULL);
Expand Down

0 comments on commit d4719d5

Please sign in to comment.