I create some led widgets and set the color is Green.The problem is that they show Green when i run the project in code blocks but they show White in TFT-LCD.The picture like below :
add picture and code as below
lv_obj_t * led4 = lv_led_create(lv_scr_act());
lv_obj_align(led4, LV_ALIGN_CENTER, -80, 0);
lv_led_off(led4);
/*Copy the previous LED and set a brightness*/
lv_obj_t * led5 = lv_led_create(lv_scr_act());
lv_obj_align(led5, LV_ALIGN_CENTER, 0, 0);
lv_led_set_brightness(led5, 255);
lv_led_set_color(led5, lv_palette_main(LV_PALETTE_RED));
/*Copy the previous LED and switch it ON*/
lv_obj_t * led6 = lv_led_create(lv_scr_act());
lv_obj_align(led6, LV_ALIGN_CENTER, 80, 0);
lv_led_on(led6);
Which LVGL version do you use?
If you are not using the latest version I suggest updating it from the release/v8.3
branch.