diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index b233f926..ba2d5616 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -367,30 +367,7 @@ set(QCBOR_SRC ) list(APPEND IMAGE_FILES - displayapp/icons/battery/os_battery_error.c - displayapp/icons/battery/os_battery_100.c - displayapp/icons/battery/os_battery_090.c - displayapp/icons/battery/os_battery_080.c - displayapp/icons/battery/os_battery_070.c - displayapp/icons/battery/os_battery_060.c - displayapp/icons/battery/os_battery_050.c - displayapp/icons/battery/os_battery_040.c - displayapp/icons/battery/os_battery_030.c - displayapp/icons/battery/os_battery_020.c - displayapp/icons/battery/os_battery_010.c - displayapp/icons/battery/os_battery_005.c - - displayapp/icons/battery/os_batterycharging_100.c - displayapp/icons/battery/os_batterycharging_090.c - displayapp/icons/battery/os_batterycharging_080.c - displayapp/icons/battery/os_batterycharging_070.c - displayapp/icons/battery/os_batterycharging_060.c - displayapp/icons/battery/os_batterycharging_050.c - displayapp/icons/battery/os_batterycharging_040.c - displayapp/icons/battery/os_batterycharging_030.c - displayapp/icons/battery/os_batterycharging_020.c - displayapp/icons/battery/os_batterycharging_010.c - displayapp/icons/battery/os_batterycharging_005.c + displayapp/icons/battery/batteryicon.c displayapp/icons/bluetooth/os_bt_connected.c displayapp/icons/bluetooth/os_bt_disconnected.c diff --git a/src/displayapp/icons/battery/battery.png b/src/displayapp/icons/battery/battery.png new file mode 100644 index 00000000..0fca8048 Binary files /dev/null and b/src/displayapp/icons/battery/battery.png differ diff --git a/src/displayapp/icons/battery/batteryicon.c b/src/displayapp/icons/battery/batteryicon.c new file mode 100644 index 00000000..05ddf161 --- /dev/null +++ b/src/displayapp/icons/battery/batteryicon.c @@ -0,0 +1,52 @@ +#if defined(LV_LVGL_H_INCLUDE_SIMPLE) +#include "lvgl.h" +#else +#include "lvgl/lvgl.h" +#endif + + +#ifndef LV_ATTRIBUTE_MEM_ALIGN +#define LV_ATTRIBUTE_MEM_ALIGN +#endif + +#ifndef LV_ATTRIBUTE_IMG_BATTERYICON +#define LV_ATTRIBUTE_IMG_BATTERYICON +#endif + +const LV_ATTRIBUTE_MEM_ALIGN LV_ATTRIBUTE_LARGE_CONST LV_ATTRIBUTE_IMG_BATTERYICON uint8_t batteryicon_map[] = { + 0xff, 0xff, 0xff, 0xff, /*Color of index 0*/ + 0x6a, 0xfc, 0x6c, 0xff, /*Color of index 1*/ + + 0xe0, 0x70, + 0xe0, 0x70, + 0x00, 0x00, + 0x00, 0x00, + 0x3f, 0xc0, + 0x3f, 0xc0, + 0x3f, 0xc0, + 0x3f, 0xc0, + 0x3f, 0xc0, + 0x3f, 0xc0, + 0x3f, 0xc0, + 0x3f, 0xc0, + 0x3f, 0xc0, + 0x3f, 0xc0, + 0x3f, 0xc0, + 0x3f, 0xc0, + 0x3f, 0xc0, + 0x3f, 0xc0, + 0x00, 0x00, + 0x00, 0x00, +}; + +const lv_img_dsc_t batteryicon = { + { + LV_IMG_CF_INDEXED_1BIT, + 0, + 0, + 12, + 20, + }, + 48, + batteryicon_map, +}; diff --git a/src/displayapp/icons/battery/os_battery_005.c b/src/displayapp/icons/battery/os_battery_005.c deleted file mode 100644 index 64832b5c..00000000 --- a/src/displayapp/icons/battery/os_battery_005.c +++ /dev/null @@ -1,56 +0,0 @@ -#include "lvgl/lvgl.h" - -#ifndef LV_ATTRIBUTE_MEM_ALIGN -#define LV_ATTRIBUTE_MEM_ALIGN -#endif - -#ifndef LV_ATTRIBUTE_IMG_CK_OS_BATTERY_005 -#define LV_ATTRIBUTE_IMG_CK_OS_BATTERY_005 -#endif - -const LV_ATTRIBUTE_MEM_ALIGN LV_ATTRIBUTE_IMG_CK_OS_BATTERY_005 uint8_t ck_os_battery_005_map[] = { - 0x04, 0x02, 0xcc, 0xff, /*Color of index 0*/ - 0x6c, 0xfe, 0x6c, 0xff, /*Color of index 1*/ - - 0xfc, 0x00, 0x3f, - 0xf8, 0x00, 0x1f, - 0xf0, 0x00, 0x0f, - 0xf0, 0x00, 0x0f, - 0x00, 0xff, 0x00, - 0x00, 0xff, 0x00, - 0x00, 0xff, 0x00, - 0x00, 0xff, 0x00, - 0x0f, 0xff, 0xf0, - 0x0f, 0xff, 0xf0, - 0x0f, 0xff, 0xf0, - 0x0f, 0xff, 0xf0, - 0x0f, 0xff, 0xf0, - 0x0f, 0xff, 0xf0, - 0x0f, 0xff, 0xf0, - 0x0f, 0xff, 0xf0, - 0x0f, 0xff, 0xf0, - 0x0f, 0xff, 0xf0, - 0x0f, 0xff, 0xf0, - 0x0f, 0xff, 0xf0, - 0x0f, 0xff, 0xf0, - 0x0f, 0xff, 0xf0, - 0x0f, 0xff, 0xf0, - 0x0f, 0xff, 0xf0, - 0x0f, 0xff, 0xf0, - 0x0f, 0xff, 0xf0, - 0x0f, 0xff, 0xf0, - 0x0f, 0xff, 0xf0, - 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, -}; - -const lv_img_dsc_t ck_os_battery_005 = { - .header.always_zero = 0, - .header.w = 24, - .header.h = 32, - .data_size = 104, - .header.cf = LV_IMG_CF_INDEXED_1BIT, - .data = ck_os_battery_005_map, -}; diff --git a/src/displayapp/icons/battery/os_battery_005.png b/src/displayapp/icons/battery/os_battery_005.png deleted file mode 100644 index 963767be..00000000 Binary files a/src/displayapp/icons/battery/os_battery_005.png and /dev/null differ diff --git a/src/displayapp/icons/battery/os_battery_010.c b/src/displayapp/icons/battery/os_battery_010.c deleted file mode 100644 index f36b684b..00000000 --- a/src/displayapp/icons/battery/os_battery_010.c +++ /dev/null @@ -1,58 +0,0 @@ -#include "lvgl/lvgl.h" - -#ifndef LV_ATTRIBUTE_MEM_ALIGN -#define LV_ATTRIBUTE_MEM_ALIGN -#endif - -#ifndef LV_ATTRIBUTE_IMG_CK_OS_BATTERY_010 -#define LV_ATTRIBUTE_IMG_CK_OS_BATTERY_010 -#endif - -const LV_ATTRIBUTE_MEM_ALIGN LV_ATTRIBUTE_IMG_CK_OS_BATTERY_010 uint8_t ck_os_battery_010_map[] = { - 0x04, 0x02, 0xcc, 0xff, /*Color of index 0*/ - 0x6c, 0xfe, 0x6c, 0xff, /*Color of index 1*/ - 0x04, 0x7a, 0xf4, 0xff, /*Color of index 2*/ - 0xe4, 0xe6, 0xe4, 0xff, /*Color of index 3*/ - - 0x55, 0x5f, 0xff, 0xff, 0xf5, 0x55, 0x55, - 0x55, 0x7f, 0xff, 0xff, 0xfd, 0x55, 0x55, - 0x55, 0xff, 0xff, 0xff, 0xff, 0x55, 0x55, - 0x55, 0xff, 0xff, 0xff, 0xff, 0x55, 0x55, - 0xff, 0xff, 0x55, 0x55, 0xff, 0xff, 0x55, - 0xff, 0xff, 0x55, 0x55, 0xff, 0xff, 0x55, - 0xff, 0xff, 0x55, 0x55, 0xff, 0xff, 0x55, - 0xff, 0xff, 0x55, 0x55, 0xff, 0xff, 0x55, - 0xff, 0x55, 0x55, 0x55, 0x55, 0xff, 0x55, - 0xff, 0x55, 0x55, 0x55, 0x55, 0xff, 0x55, - 0xff, 0x55, 0x55, 0x55, 0x55, 0xff, 0x55, - 0xff, 0x55, 0x55, 0x55, 0x55, 0xff, 0x55, - 0xff, 0x55, 0x55, 0x55, 0x55, 0xff, 0x55, - 0xff, 0x55, 0x55, 0x55, 0x55, 0xff, 0x55, - 0xff, 0x55, 0x55, 0x55, 0x55, 0x55, 0x55, - 0xff, 0x55, 0x55, 0x55, 0x55, 0x55, 0x55, - 0xff, 0x55, 0x55, 0x6a, 0xaa, 0xaa, 0xa9, - 0xff, 0x55, 0x55, 0xaa, 0xaa, 0xaa, 0xaa, - 0xff, 0x55, 0x55, 0xaa, 0xa5, 0x5a, 0xaa, - 0xff, 0x55, 0x55, 0xaa, 0xa5, 0x5a, 0xaa, - 0xff, 0x55, 0x55, 0xaa, 0xa5, 0x5a, 0xaa, - 0xff, 0x55, 0x55, 0xaa, 0xa5, 0x5a, 0xaa, - 0xff, 0x55, 0x55, 0xaa, 0xa5, 0x5a, 0xaa, - 0xff, 0x55, 0x55, 0xaa, 0xa5, 0x5a, 0xaa, - 0xff, 0x50, 0x05, 0xaa, 0xaa, 0xaa, 0xaa, - 0xff, 0x50, 0x05, 0xaa, 0xaa, 0xaa, 0xaa, - 0xff, 0x55, 0x55, 0xaa, 0xa5, 0x5a, 0xaa, - 0xff, 0x55, 0x55, 0xaa, 0xa5, 0x5a, 0xaa, - 0xff, 0xff, 0xf5, 0xaa, 0xa5, 0x5a, 0xaa, - 0xff, 0xff, 0xf5, 0xaa, 0xa5, 0x5a, 0xaa, - 0xff, 0xff, 0xf5, 0xaa, 0xaa, 0xaa, 0xaa, - 0xff, 0xff, 0xf5, 0x6a, 0xaa, 0xaa, 0xa9, -}; - -const lv_img_dsc_t ck_os_battery_010 = { - .header.always_zero = 0, - .header.w = 28, - .header.h = 32, - .data_size = 240, - .header.cf = LV_IMG_CF_INDEXED_2BIT, - .data = ck_os_battery_010_map, -}; diff --git a/src/displayapp/icons/battery/os_battery_010.png b/src/displayapp/icons/battery/os_battery_010.png deleted file mode 100644 index 68a9f406..00000000 Binary files a/src/displayapp/icons/battery/os_battery_010.png and /dev/null differ diff --git a/src/displayapp/icons/battery/os_battery_020.c b/src/displayapp/icons/battery/os_battery_020.c deleted file mode 100644 index 3f648fb9..00000000 --- a/src/displayapp/icons/battery/os_battery_020.c +++ /dev/null @@ -1,58 +0,0 @@ -#include "lvgl/lvgl.h" - -#ifndef LV_ATTRIBUTE_MEM_ALIGN -#define LV_ATTRIBUTE_MEM_ALIGN -#endif - -#ifndef LV_ATTRIBUTE_IMG_CK_OS_BATTERY_020 -#define LV_ATTRIBUTE_IMG_CK_OS_BATTERY_020 -#endif - -const LV_ATTRIBUTE_MEM_ALIGN LV_ATTRIBUTE_IMG_CK_OS_BATTERY_020 uint8_t ck_os_battery_020_map[] = { - 0x04, 0x02, 0xcc, 0xff, /*Color of index 0*/ - 0x6c, 0xfe, 0x6c, 0xff, /*Color of index 1*/ - 0xe4, 0xe6, 0xe4, 0xff, /*Color of index 2*/ - 0xff, 0xff, 0xff, 0xff, /*Color of index 3*/ - - 0x55, 0x5a, 0xaa, 0xaa, 0xa5, 0x55, - 0x55, 0x6a, 0xaa, 0xaa, 0xa9, 0x55, - 0x55, 0xaa, 0xaa, 0xaa, 0xaa, 0x55, - 0x55, 0xaa, 0xaa, 0xaa, 0xaa, 0x55, - 0xaa, 0xaa, 0x55, 0x55, 0xaa, 0xaa, - 0xaa, 0xaa, 0x55, 0x55, 0xaa, 0xaa, - 0xaa, 0xaa, 0x55, 0x55, 0xaa, 0xaa, - 0xaa, 0xaa, 0x55, 0x55, 0xaa, 0xaa, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa, - 0xaa, 0x50, 0x00, 0x00, 0x05, 0xaa, - 0xaa, 0x50, 0x00, 0x00, 0x05, 0xaa, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa, - 0xaa, 0xaa, 0xaa, 0xaa, 0xaa, 0xaa, - 0xaa, 0xaa, 0xaa, 0xaa, 0xaa, 0xaa, - 0xaa, 0xaa, 0xaa, 0xaa, 0xaa, 0xaa, - 0xaa, 0xaa, 0xaa, 0xaa, 0xaa, 0xaa, -}; - -const lv_img_dsc_t ck_os_battery_020 = { - .header.always_zero = 0, - .header.w = 24, - .header.h = 32, - .data_size = 208, - .header.cf = LV_IMG_CF_INDEXED_2BIT, - .data = ck_os_battery_020_map, -}; diff --git a/src/displayapp/icons/battery/os_battery_020.png b/src/displayapp/icons/battery/os_battery_020.png deleted file mode 100644 index 32eca651..00000000 Binary files a/src/displayapp/icons/battery/os_battery_020.png and /dev/null differ diff --git a/src/displayapp/icons/battery/os_battery_030.c b/src/displayapp/icons/battery/os_battery_030.c deleted file mode 100644 index 4d5719b7..00000000 --- a/src/displayapp/icons/battery/os_battery_030.c +++ /dev/null @@ -1,58 +0,0 @@ -#include "lvgl/lvgl.h" - -#ifndef LV_ATTRIBUTE_MEM_ALIGN -#define LV_ATTRIBUTE_MEM_ALIGN -#endif - -#ifndef LV_ATTRIBUTE_IMG_CK_OS_BATTERY_030 -#define LV_ATTRIBUTE_IMG_CK_OS_BATTERY_030 -#endif - -const LV_ATTRIBUTE_MEM_ALIGN LV_ATTRIBUTE_IMG_CK_OS_BATTERY_030 uint8_t ck_os_battery_030_map[] = { - 0x04, 0x7a, 0xf4, 0xff, /*Color of index 0*/ - 0x6c, 0xfe, 0x6c, 0xff, /*Color of index 1*/ - 0xe4, 0xe6, 0xe4, 0xff, /*Color of index 2*/ - 0xff, 0xff, 0xff, 0xff, /*Color of index 3*/ - - 0x55, 0x5a, 0xaa, 0xaa, 0xa5, 0x55, - 0x55, 0x6a, 0xaa, 0xaa, 0xa9, 0x55, - 0x55, 0xaa, 0xaa, 0xaa, 0xaa, 0x55, - 0x55, 0xaa, 0xaa, 0xaa, 0xaa, 0x55, - 0xaa, 0xaa, 0x55, 0x55, 0xaa, 0xaa, - 0xaa, 0xaa, 0x55, 0x55, 0xaa, 0xaa, - 0xaa, 0xaa, 0x55, 0x55, 0xaa, 0xaa, - 0xaa, 0xaa, 0x55, 0x55, 0xaa, 0xaa, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa, - 0xaa, 0x50, 0x00, 0x00, 0x05, 0xaa, - 0xaa, 0x50, 0x00, 0x00, 0x05, 0xaa, - 0xaa, 0x50, 0x00, 0x00, 0x05, 0xaa, - 0xaa, 0x50, 0x00, 0x00, 0x05, 0xaa, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa, - 0xaa, 0xaa, 0xaa, 0xaa, 0xaa, 0xaa, - 0xaa, 0xaa, 0xaa, 0xaa, 0xaa, 0xaa, - 0xaa, 0xaa, 0xaa, 0xaa, 0xaa, 0xaa, - 0xaa, 0xaa, 0xaa, 0xaa, 0xaa, 0xaa, -}; - -const lv_img_dsc_t ck_os_battery_030 = { - .header.always_zero = 0, - .header.w = 24, - .header.h = 32, - .data_size = 208, - .header.cf = LV_IMG_CF_INDEXED_2BIT, - .data = ck_os_battery_030_map, -}; diff --git a/src/displayapp/icons/battery/os_battery_030.png b/src/displayapp/icons/battery/os_battery_030.png deleted file mode 100644 index aeb5eb1f..00000000 Binary files a/src/displayapp/icons/battery/os_battery_030.png and /dev/null differ diff --git a/src/displayapp/icons/battery/os_battery_040.c b/src/displayapp/icons/battery/os_battery_040.c deleted file mode 100644 index 0606fc35..00000000 --- a/src/displayapp/icons/battery/os_battery_040.c +++ /dev/null @@ -1,56 +0,0 @@ -#include "lvgl/lvgl.h" - -#ifndef LV_ATTRIBUTE_MEM_ALIGN -#define LV_ATTRIBUTE_MEM_ALIGN -#endif - -#ifndef LV_ATTRIBUTE_IMG_CK_OS_BATTERY_040 -#define LV_ATTRIBUTE_IMG_CK_OS_BATTERY_040 -#endif - -const LV_ATTRIBUTE_MEM_ALIGN LV_ATTRIBUTE_IMG_CK_OS_BATTERY_040 uint8_t ck_os_battery_040_map[] = { - 0x6c, 0xfe, 0x6c, 0xff, /*Color of index 0*/ - 0xe4, 0xe6, 0xe4, 0xff, /*Color of index 1*/ - - 0x03, 0xff, 0xc0, - 0x07, 0xff, 0xe0, - 0x0f, 0xff, 0xf0, - 0x0f, 0xff, 0xf0, - 0xff, 0x00, 0xff, - 0xff, 0x00, 0xff, - 0xff, 0x00, 0xff, - 0xff, 0x00, 0xff, - 0xf0, 0x00, 0x0f, - 0xf0, 0x00, 0x0f, - 0xf0, 0x00, 0x0f, - 0xf0, 0x00, 0x0f, - 0xf0, 0x00, 0x0f, - 0xf0, 0x00, 0x0f, - 0xf0, 0x00, 0x0f, - 0xf0, 0x00, 0x0f, - 0xf0, 0x00, 0x0f, - 0xf0, 0x00, 0x0f, - 0xf0, 0x00, 0x0f, - 0xf0, 0x00, 0x0f, - 0xf3, 0xff, 0xcf, - 0xf3, 0xff, 0xcf, - 0xf3, 0xff, 0xcf, - 0xf3, 0xff, 0xcf, - 0xf3, 0xff, 0xcf, - 0xf3, 0xff, 0xcf, - 0xf0, 0x00, 0x0f, - 0xf0, 0x00, 0x0f, - 0xff, 0xff, 0xff, - 0xff, 0xff, 0xff, - 0xff, 0xff, 0xff, - 0xff, 0xff, 0xff, -}; - -const lv_img_dsc_t ck_os_battery_040 = { - .header.always_zero = 0, - .header.w = 24, - .header.h = 32, - .data_size = 104, - .header.cf = LV_IMG_CF_INDEXED_1BIT, - .data = ck_os_battery_040_map, -}; diff --git a/src/displayapp/icons/battery/os_battery_040.png b/src/displayapp/icons/battery/os_battery_040.png deleted file mode 100644 index d84fda40..00000000 Binary files a/src/displayapp/icons/battery/os_battery_040.png and /dev/null differ diff --git a/src/displayapp/icons/battery/os_battery_050.c b/src/displayapp/icons/battery/os_battery_050.c deleted file mode 100644 index 8732dc7a..00000000 --- a/src/displayapp/icons/battery/os_battery_050.c +++ /dev/null @@ -1,56 +0,0 @@ -#include "lvgl/lvgl.h" - -#ifndef LV_ATTRIBUTE_MEM_ALIGN -#define LV_ATTRIBUTE_MEM_ALIGN -#endif - -#ifndef LV_ATTRIBUTE_IMG_CK_OS_BATTERY_050 -#define LV_ATTRIBUTE_IMG_CK_OS_BATTERY_050 -#endif - -const LV_ATTRIBUTE_MEM_ALIGN LV_ATTRIBUTE_IMG_CK_OS_BATTERY_050 uint8_t ck_os_battery_050_map[] = { - 0x6c, 0xfe, 0x6c, 0xff, /*Color of index 0*/ - 0xe4, 0xe6, 0xe4, 0xff, /*Color of index 1*/ - - 0x03, 0xff, 0xc0, - 0x07, 0xff, 0xe0, - 0x0f, 0xff, 0xf0, - 0x0f, 0xff, 0xf0, - 0xff, 0x00, 0xff, - 0xff, 0x00, 0xff, - 0xff, 0x00, 0xff, - 0xff, 0x00, 0xff, - 0xf0, 0x00, 0x0f, - 0xf0, 0x00, 0x0f, - 0xf0, 0x00, 0x0f, - 0xf0, 0x00, 0x0f, - 0xf0, 0x00, 0x0f, - 0xf0, 0x00, 0x0f, - 0xf0, 0x00, 0x0f, - 0xf0, 0x00, 0x0f, - 0xf0, 0x00, 0x0f, - 0xf0, 0x00, 0x0f, - 0xf3, 0xff, 0xcf, - 0xf3, 0xff, 0xcf, - 0xf3, 0xff, 0xcf, - 0xf3, 0xff, 0xcf, - 0xf3, 0xff, 0xcf, - 0xf3, 0xff, 0xcf, - 0xf3, 0xff, 0xcf, - 0xf3, 0xff, 0xcf, - 0xf0, 0x00, 0x0f, - 0xf0, 0x00, 0x0f, - 0xff, 0xff, 0xff, - 0xff, 0xff, 0xff, - 0xff, 0xff, 0xff, - 0xff, 0xff, 0xff, -}; - -const lv_img_dsc_t ck_os_battery_050 = { - .header.always_zero = 0, - .header.w = 24, - .header.h = 32, - .data_size = 104, - .header.cf = LV_IMG_CF_INDEXED_1BIT, - .data = ck_os_battery_050_map, -}; diff --git a/src/displayapp/icons/battery/os_battery_050.png b/src/displayapp/icons/battery/os_battery_050.png deleted file mode 100644 index 224d38d6..00000000 Binary files a/src/displayapp/icons/battery/os_battery_050.png and /dev/null differ diff --git a/src/displayapp/icons/battery/os_battery_060.c b/src/displayapp/icons/battery/os_battery_060.c deleted file mode 100644 index a65936bf..00000000 --- a/src/displayapp/icons/battery/os_battery_060.c +++ /dev/null @@ -1,56 +0,0 @@ -#include "lvgl/lvgl.h" - -#ifndef LV_ATTRIBUTE_MEM_ALIGN -#define LV_ATTRIBUTE_MEM_ALIGN -#endif - -#ifndef LV_ATTRIBUTE_IMG_CK_OS_BATTERY_060 -#define LV_ATTRIBUTE_IMG_CK_OS_BATTERY_060 -#endif - -const LV_ATTRIBUTE_MEM_ALIGN LV_ATTRIBUTE_IMG_CK_OS_BATTERY_060 uint8_t ck_os_battery_060_map[] = { - 0x6c, 0xfe, 0x6c, 0xff, /*Color of index 0*/ - 0xe4, 0xe6, 0xe4, 0xff, /*Color of index 1*/ - - 0x03, 0xff, 0xc0, - 0x07, 0xff, 0xe0, - 0x0f, 0xff, 0xf0, - 0x0f, 0xff, 0xf0, - 0xff, 0x00, 0xff, - 0xff, 0x00, 0xff, - 0xff, 0x00, 0xff, - 0xff, 0x00, 0xff, - 0xf0, 0x00, 0x0f, - 0xf0, 0x00, 0x0f, - 0xf0, 0x00, 0x0f, - 0xf0, 0x00, 0x0f, - 0xf0, 0x00, 0x0f, - 0xf0, 0x00, 0x0f, - 0xf0, 0x00, 0x0f, - 0xf0, 0x00, 0x0f, - 0xf3, 0xff, 0xcf, - 0xf3, 0xff, 0xcf, - 0xf3, 0xff, 0xcf, - 0xf3, 0xff, 0xcf, - 0xf3, 0xff, 0xcf, - 0xf3, 0xff, 0xcf, - 0xf3, 0xff, 0xcf, - 0xf3, 0xff, 0xcf, - 0xf3, 0xff, 0xcf, - 0xf3, 0xff, 0xcf, - 0xf0, 0x00, 0x0f, - 0xf0, 0x00, 0x0f, - 0xff, 0xff, 0xff, - 0xff, 0xff, 0xff, - 0xff, 0xff, 0xff, - 0xff, 0xff, 0xff, -}; - -const lv_img_dsc_t ck_os_battery_060 = { - .header.always_zero = 0, - .header.w = 24, - .header.h = 32, - .data_size = 104, - .header.cf = LV_IMG_CF_INDEXED_1BIT, - .data = ck_os_battery_060_map, -}; diff --git a/src/displayapp/icons/battery/os_battery_060.png b/src/displayapp/icons/battery/os_battery_060.png deleted file mode 100644 index e5e00eda..00000000 Binary files a/src/displayapp/icons/battery/os_battery_060.png and /dev/null differ diff --git a/src/displayapp/icons/battery/os_battery_070.c b/src/displayapp/icons/battery/os_battery_070.c deleted file mode 100644 index 949c0b8b..00000000 --- a/src/displayapp/icons/battery/os_battery_070.c +++ /dev/null @@ -1,56 +0,0 @@ -#include "lvgl/lvgl.h" - -#ifndef LV_ATTRIBUTE_MEM_ALIGN -#define LV_ATTRIBUTE_MEM_ALIGN -#endif - -#ifndef LV_ATTRIBUTE_IMG_CK_OS_BATTERY_070 -#define LV_ATTRIBUTE_IMG_CK_OS_BATTERY_070 -#endif - -const LV_ATTRIBUTE_MEM_ALIGN LV_ATTRIBUTE_IMG_CK_OS_BATTERY_070 uint8_t ck_os_battery_070_map[] = { - 0x6c, 0xfe, 0x6c, 0xff, /*Color of index 0*/ - 0xe4, 0xe6, 0xe4, 0xff, /*Color of index 1*/ - - 0x03, 0xff, 0xc0, - 0x07, 0xff, 0xe0, - 0x0f, 0xff, 0xf0, - 0x0f, 0xff, 0xf0, - 0xff, 0x00, 0xff, - 0xff, 0x00, 0xff, - 0xff, 0x00, 0xff, - 0xff, 0x00, 0xff, - 0xf0, 0x00, 0x0f, - 0xf0, 0x00, 0x0f, - 0xf0, 0x00, 0x0f, - 0xf0, 0x00, 0x0f, - 0xf0, 0x00, 0x0f, - 0xf0, 0x00, 0x0f, - 0xf3, 0xff, 0xcf, - 0xf3, 0xff, 0xcf, - 0xf3, 0xff, 0xcf, - 0xf3, 0xff, 0xcf, - 0xf3, 0xff, 0xcf, - 0xf3, 0xff, 0xcf, - 0xf3, 0xff, 0xcf, - 0xf3, 0xff, 0xcf, - 0xf3, 0xff, 0xcf, - 0xf3, 0xff, 0xcf, - 0xf3, 0xff, 0xcf, - 0xf3, 0xff, 0xcf, - 0xf0, 0x00, 0x0f, - 0xf0, 0x00, 0x0f, - 0xff, 0xff, 0xff, - 0xff, 0xff, 0xff, - 0xff, 0xff, 0xff, - 0xff, 0xff, 0xff, -}; - -const lv_img_dsc_t ck_os_battery_070 = { - .header.always_zero = 0, - .header.w = 24, - .header.h = 32, - .data_size = 104, - .header.cf = LV_IMG_CF_INDEXED_1BIT, - .data = ck_os_battery_070_map, -}; diff --git a/src/displayapp/icons/battery/os_battery_070.png b/src/displayapp/icons/battery/os_battery_070.png deleted file mode 100644 index dee969b8..00000000 Binary files a/src/displayapp/icons/battery/os_battery_070.png and /dev/null differ diff --git a/src/displayapp/icons/battery/os_battery_080.c b/src/displayapp/icons/battery/os_battery_080.c deleted file mode 100644 index f447370e..00000000 --- a/src/displayapp/icons/battery/os_battery_080.c +++ /dev/null @@ -1,56 +0,0 @@ -#include "lvgl/lvgl.h" - -#ifndef LV_ATTRIBUTE_MEM_ALIGN -#define LV_ATTRIBUTE_MEM_ALIGN -#endif - -#ifndef LV_ATTRIBUTE_IMG_CK_OS_BATTERY_080 -#define LV_ATTRIBUTE_IMG_CK_OS_BATTERY_080 -#endif - -const LV_ATTRIBUTE_MEM_ALIGN LV_ATTRIBUTE_IMG_CK_OS_BATTERY_080 uint8_t ck_os_battery_080_map[] = { - 0x6c, 0xfe, 0x6c, 0xff, /*Color of index 0*/ - 0xe4, 0xe6, 0xe4, 0xff, /*Color of index 1*/ - - 0x03, 0xff, 0xc0, - 0x07, 0xff, 0xe0, - 0x0f, 0xff, 0xf0, - 0x0f, 0xff, 0xf0, - 0xff, 0x00, 0xff, - 0xff, 0x00, 0xff, - 0xff, 0x00, 0xff, - 0xff, 0x00, 0xff, - 0xf0, 0x00, 0x0f, - 0xf0, 0x00, 0x0f, - 0xf0, 0x00, 0x0f, - 0xf0, 0x00, 0x0f, - 0xf3, 0xff, 0xcf, - 0xf3, 0xff, 0xcf, - 0xf3, 0xff, 0xcf, - 0xf3, 0xff, 0xcf, - 0xf3, 0xff, 0xcf, - 0xf3, 0xff, 0xcf, - 0xf3, 0xff, 0xcf, - 0xf3, 0xff, 0xcf, - 0xf3, 0xff, 0xcf, - 0xf3, 0xff, 0xcf, - 0xf3, 0xff, 0xcf, - 0xf3, 0xff, 0xcf, - 0xf3, 0xff, 0xcf, - 0xf3, 0xff, 0xcf, - 0xf0, 0x00, 0x0f, - 0xf0, 0x00, 0x0f, - 0xff, 0xff, 0xff, - 0xff, 0xff, 0xff, - 0xff, 0xff, 0xff, - 0xff, 0xff, 0xff, -}; - -const lv_img_dsc_t ck_os_battery_080 = { - .header.always_zero = 0, - .header.w = 24, - .header.h = 32, - .data_size = 104, - .header.cf = LV_IMG_CF_INDEXED_1BIT, - .data = ck_os_battery_080_map, -}; diff --git a/src/displayapp/icons/battery/os_battery_080.png b/src/displayapp/icons/battery/os_battery_080.png deleted file mode 100644 index 3b13fbb2..00000000 Binary files a/src/displayapp/icons/battery/os_battery_080.png and /dev/null differ diff --git a/src/displayapp/icons/battery/os_battery_090.c b/src/displayapp/icons/battery/os_battery_090.c deleted file mode 100644 index 6fa41b20..00000000 --- a/src/displayapp/icons/battery/os_battery_090.c +++ /dev/null @@ -1,56 +0,0 @@ -#include "lvgl/lvgl.h" - -#ifndef LV_ATTRIBUTE_MEM_ALIGN -#define LV_ATTRIBUTE_MEM_ALIGN -#endif - -#ifndef LV_ATTRIBUTE_IMG_CK_OS_BATTERY_090 -#define LV_ATTRIBUTE_IMG_CK_OS_BATTERY_090 -#endif - -const LV_ATTRIBUTE_MEM_ALIGN LV_ATTRIBUTE_IMG_CK_OS_BATTERY_090 uint8_t ck_os_battery_090_map[] = { - 0x6c, 0xfe, 0x6c, 0xff, /*Color of index 0*/ - 0xe4, 0xe6, 0xe4, 0xff, /*Color of index 1*/ - - 0x03, 0xff, 0xc0, - 0x07, 0xff, 0xe0, - 0x0f, 0xff, 0xf0, - 0x0f, 0xff, 0xf0, - 0xff, 0x00, 0xff, - 0xff, 0x00, 0xff, - 0xff, 0x00, 0xff, - 0xff, 0x00, 0xff, - 0xf0, 0x00, 0x0f, - 0xf0, 0x00, 0x0f, - 0xf3, 0xff, 0xcf, - 0xf3, 0xff, 0xcf, - 0xf3, 0xff, 0xcf, - 0xf3, 0xff, 0xcf, - 0xf3, 0xff, 0xcf, - 0xf3, 0xff, 0xcf, - 0xf3, 0xff, 0xcf, - 0xf3, 0xff, 0xcf, - 0xf3, 0xff, 0xcf, - 0xf3, 0xff, 0xcf, - 0xf3, 0xff, 0xcf, - 0xf3, 0xff, 0xcf, - 0xf3, 0xff, 0xcf, - 0xf3, 0xff, 0xcf, - 0xf3, 0xff, 0xcf, - 0xf3, 0xff, 0xcf, - 0xf0, 0x00, 0x0f, - 0xf0, 0x00, 0x0f, - 0xff, 0xff, 0xff, - 0xff, 0xff, 0xff, - 0xff, 0xff, 0xff, - 0xff, 0xff, 0xff, -}; - -const lv_img_dsc_t ck_os_battery_090 = { - .header.always_zero = 0, - .header.w = 24, - .header.h = 32, - .data_size = 104, - .header.cf = LV_IMG_CF_INDEXED_1BIT, - .data = ck_os_battery_090_map, -}; diff --git a/src/displayapp/icons/battery/os_battery_090.png b/src/displayapp/icons/battery/os_battery_090.png deleted file mode 100644 index d79f396b..00000000 Binary files a/src/displayapp/icons/battery/os_battery_090.png and /dev/null differ diff --git a/src/displayapp/icons/battery/os_battery_100.c b/src/displayapp/icons/battery/os_battery_100.c deleted file mode 100644 index 92cf9a41..00000000 --- a/src/displayapp/icons/battery/os_battery_100.c +++ /dev/null @@ -1,58 +0,0 @@ -#include "lvgl/lvgl.h" - -#ifndef LV_ATTRIBUTE_MEM_ALIGN -#define LV_ATTRIBUTE_MEM_ALIGN -#endif - -#ifndef LV_ATTRIBUTE_IMG_CK_OS_BATTERY_100 -#define LV_ATTRIBUTE_IMG_CK_OS_BATTERY_100 -#endif - -const LV_ATTRIBUTE_MEM_ALIGN LV_ATTRIBUTE_IMG_CK_OS_BATTERY_100 uint8_t ck_os_battery_100_map[] = { - 0x7c, 0xd2, 0x34, 0xff, /*Color of index 0*/ - 0xe4, 0xe6, 0xe4, 0xff, /*Color of index 1*/ - 0x6c, 0xfe, 0x6c, 0xff, /*Color of index 2*/ - 0xff, 0xff, 0xff, 0xff, /*Color of index 3*/ - - 0xaa, 0xa5, 0x55, 0x55, 0x5a, 0xaa, - 0xaa, 0x95, 0x55, 0x55, 0x56, 0xaa, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa, - 0x55, 0x55, 0xaa, 0xaa, 0x55, 0x55, - 0x55, 0x55, 0xaa, 0xaa, 0x55, 0x55, - 0x55, 0x55, 0xaa, 0xaa, 0x55, 0x55, - 0x55, 0x55, 0xaa, 0xaa, 0x55, 0x55, - 0x55, 0xaa, 0xaa, 0xaa, 0xaa, 0x55, - 0x55, 0xaa, 0xaa, 0xaa, 0xaa, 0x55, - 0x55, 0xa0, 0x00, 0x00, 0x0a, 0x55, - 0x55, 0xa0, 0x00, 0x00, 0x0a, 0x55, - 0x55, 0xa0, 0x00, 0x00, 0x0a, 0x55, - 0x55, 0xa0, 0x00, 0x00, 0x0a, 0x55, - 0x55, 0xa0, 0x00, 0x00, 0x0a, 0x55, - 0x55, 0xa0, 0x00, 0x00, 0x0a, 0x55, - 0x55, 0xa0, 0x00, 0x00, 0x0a, 0x55, - 0x55, 0xa0, 0x00, 0x00, 0x0a, 0x55, - 0x55, 0xa0, 0x00, 0x00, 0x0a, 0x55, - 0x55, 0xa0, 0x00, 0x00, 0x0a, 0x55, - 0x55, 0xa0, 0x00, 0x00, 0x0a, 0x55, - 0x55, 0xa0, 0x00, 0x00, 0x0a, 0x55, - 0x55, 0xa0, 0x00, 0x00, 0x0a, 0x55, - 0x55, 0xa0, 0x00, 0x00, 0x0a, 0x55, - 0x55, 0xa0, 0x00, 0x00, 0x0a, 0x55, - 0x55, 0xa0, 0x00, 0x00, 0x0a, 0x55, - 0x55, 0xaa, 0xaa, 0xaa, 0xaa, 0x55, - 0x55, 0xaa, 0xaa, 0xaa, 0xaa, 0x55, - 0x55, 0x55, 0x55, 0x55, 0x55, 0x55, - 0x55, 0x55, 0x55, 0x55, 0x55, 0x55, - 0x55, 0x55, 0x55, 0x55, 0x55, 0x55, - 0x55, 0x55, 0x55, 0x55, 0x55, 0x55, -}; - -const lv_img_dsc_t ck_os_battery_100 = { - .header.always_zero = 0, - .header.w = 24, - .header.h = 32, - .data_size = 208, - .header.cf = LV_IMG_CF_INDEXED_2BIT, - .data = ck_os_battery_100_map, -}; diff --git a/src/displayapp/icons/battery/os_battery_100.png b/src/displayapp/icons/battery/os_battery_100.png deleted file mode 100644 index dd0d306f..00000000 Binary files a/src/displayapp/icons/battery/os_battery_100.png and /dev/null differ diff --git a/src/displayapp/icons/battery/os_battery_error.c b/src/displayapp/icons/battery/os_battery_error.c deleted file mode 100644 index af6aba5d..00000000 --- a/src/displayapp/icons/battery/os_battery_error.c +++ /dev/null @@ -1,58 +0,0 @@ -#include "lvgl/lvgl.h" - -#ifndef LV_ATTRIBUTE_MEM_ALIGN -#define LV_ATTRIBUTE_MEM_ALIGN -#endif - -#ifndef LV_ATTRIBUTE_IMG_CK_OS_BATTERY_ERROR -#define LV_ATTRIBUTE_IMG_CK_OS_BATTERY_ERROR -#endif - -const LV_ATTRIBUTE_MEM_ALIGN LV_ATTRIBUTE_IMG_CK_OS_BATTERY_ERROR uint8_t ck_os_battery_error_map[] = { - 0x6c, 0xfe, 0x6c, 0xff, /*Color of index 0*/ - 0xc4, 0xc2, 0xc4, 0xff, /*Color of index 1*/ - 0xe4, 0xe6, 0xe4, 0xff, /*Color of index 2*/ - 0xff, 0xff, 0xff, 0xff, /*Color of index 3*/ - - 0x00, 0x05, 0x55, 0x55, 0x50, 0x00, - 0x00, 0x15, 0x55, 0x55, 0x54, 0x00, - 0x00, 0x55, 0x55, 0x55, 0x55, 0x00, - 0x00, 0x55, 0x55, 0x55, 0x55, 0x00, - 0x55, 0x55, 0x00, 0x00, 0x55, 0x55, - 0x55, 0x55, 0x00, 0x00, 0x55, 0x55, - 0x55, 0x55, 0x00, 0x00, 0x55, 0x55, - 0x55, 0x54, 0x00, 0x00, 0x15, 0x55, - 0x55, 0x00, 0x0a, 0xa0, 0x00, 0x55, - 0x55, 0x00, 0xaa, 0xaa, 0x00, 0x55, - 0x55, 0x02, 0xaa, 0xaa, 0x80, 0x55, - 0x55, 0x02, 0xaa, 0xaa, 0x80, 0x55, - 0x55, 0x0a, 0xa8, 0x2a, 0xa0, 0x55, - 0x55, 0x0a, 0xa0, 0x0a, 0xa0, 0x55, - 0x55, 0x00, 0x00, 0x0a, 0xa0, 0x55, - 0x55, 0x00, 0x00, 0x2a, 0xa0, 0x55, - 0x55, 0x00, 0x02, 0xaa, 0x80, 0x55, - 0x55, 0x00, 0x0a, 0xaa, 0x80, 0x55, - 0x55, 0x00, 0x0a, 0xaa, 0x00, 0x55, - 0x55, 0x00, 0x0a, 0xa0, 0x00, 0x55, - 0x55, 0x00, 0x0a, 0xa0, 0x00, 0x55, - 0x55, 0x00, 0x0a, 0xa0, 0x00, 0x55, - 0x55, 0x00, 0x00, 0x00, 0x00, 0x55, - 0x55, 0x00, 0x00, 0x00, 0x00, 0x55, - 0x55, 0x00, 0x02, 0x80, 0x00, 0x55, - 0x55, 0x00, 0x0a, 0xa0, 0x00, 0x55, - 0x55, 0x00, 0x0a, 0xa0, 0x00, 0x55, - 0x55, 0x00, 0x02, 0x80, 0x00, 0x55, - 0x55, 0x55, 0x40, 0x01, 0x55, 0x55, - 0x55, 0x55, 0x50, 0x05, 0x55, 0x55, - 0x55, 0x55, 0x55, 0x55, 0x55, 0x55, - 0x55, 0x55, 0x55, 0x55, 0x55, 0x55, -}; - -const lv_img_dsc_t ck_os_battery_error = { - .header.always_zero = 0, - .header.w = 24, - .header.h = 32, - .data_size = 208, - .header.cf = LV_IMG_CF_INDEXED_2BIT, - .data = ck_os_battery_error_map, -}; diff --git a/src/displayapp/icons/battery/os_battery_error.png b/src/displayapp/icons/battery/os_battery_error.png deleted file mode 100644 index 4c7632fe..00000000 Binary files a/src/displayapp/icons/battery/os_battery_error.png and /dev/null differ diff --git a/src/displayapp/icons/battery/os_batterycharging_005.c b/src/displayapp/icons/battery/os_batterycharging_005.c deleted file mode 100644 index 1b0c71df..00000000 --- a/src/displayapp/icons/battery/os_batterycharging_005.c +++ /dev/null @@ -1,56 +0,0 @@ -#include "lvgl/lvgl.h" - -#ifndef LV_ATTRIBUTE_MEM_ALIGN -#define LV_ATTRIBUTE_MEM_ALIGN -#endif - -#ifndef LV_ATTRIBUTE_IMG_CK_OS_BATTERYCHARGING_005 -#define LV_ATTRIBUTE_IMG_CK_OS_BATTERYCHARGING_005 -#endif - -const LV_ATTRIBUTE_MEM_ALIGN LV_ATTRIBUTE_IMG_CK_OS_BATTERYCHARGING_005 uint8_t ck_os_batterycharging_005_map[] = { - 0x6c, 0xfe, 0x6c, 0xff, /*Color of index 0*/ - 0xe4, 0xe6, 0xe4, 0xff, /*Color of index 1*/ - - 0x03, 0xff, 0xc0, 0x00, - 0x07, 0xff, 0xe0, 0x00, - 0x0f, 0xff, 0xf0, 0x00, - 0x0f, 0xff, 0xf0, 0x00, - 0xff, 0x00, 0xff, 0x00, - 0xff, 0x00, 0xff, 0x00, - 0xff, 0x00, 0xff, 0x00, - 0xff, 0x00, 0xff, 0x00, - 0xf0, 0x00, 0x0f, 0x00, - 0xf0, 0x00, 0x0f, 0x00, - 0xf0, 0x00, 0x0f, 0x00, - 0xf0, 0x00, 0x0f, 0x00, - 0xf0, 0x00, 0x0f, 0x00, - 0xf0, 0x00, 0x0f, 0x00, - 0xf0, 0x00, 0x00, 0x00, - 0xf0, 0x00, 0x00, 0x00, - 0xf0, 0x00, 0x07, 0x00, - 0xf0, 0x00, 0x0f, 0x00, - 0xf0, 0x00, 0x1f, 0x00, - 0xf0, 0x00, 0x3e, 0x00, - 0xf0, 0x00, 0x7e, 0x00, - 0xf0, 0x00, 0xfc, 0x00, - 0xf0, 0x01, 0xff, 0xf0, - 0xf0, 0x03, 0xff, 0xf0, - 0xf0, 0x03, 0xff, 0xf0, - 0xf0, 0x03, 0xff, 0xe0, - 0xf0, 0x00, 0x0f, 0xc0, - 0xf0, 0x00, 0x1f, 0x80, - 0xff, 0xff, 0x3f, 0x00, - 0xff, 0xff, 0x3e, 0x00, - 0xff, 0xff, 0x3c, 0x00, - 0xff, 0xff, 0x38, 0x00, -}; - -const lv_img_dsc_t ck_os_batterycharging_005 = { - .header.always_zero = 0, - .header.w = 28, - .header.h = 32, - .data_size = 136, - .header.cf = LV_IMG_CF_INDEXED_1BIT, - .data = ck_os_batterycharging_005_map, -}; diff --git a/src/displayapp/icons/battery/os_batterycharging_005.png b/src/displayapp/icons/battery/os_batterycharging_005.png deleted file mode 100644 index f9545bc1..00000000 Binary files a/src/displayapp/icons/battery/os_batterycharging_005.png and /dev/null differ diff --git a/src/displayapp/icons/battery/os_batterycharging_010.c b/src/displayapp/icons/battery/os_batterycharging_010.c deleted file mode 100644 index 304c0184..00000000 --- a/src/displayapp/icons/battery/os_batterycharging_010.c +++ /dev/null @@ -1,58 +0,0 @@ -#include "lvgl/lvgl.h" - -#ifndef LV_ATTRIBUTE_MEM_ALIGN -#define LV_ATTRIBUTE_MEM_ALIGN -#endif - -#ifndef LV_ATTRIBUTE_IMG_CK_OS_BATTERYCHARGING_010 -#define LV_ATTRIBUTE_IMG_CK_OS_BATTERYCHARGING_010 -#endif - -const LV_ATTRIBUTE_MEM_ALIGN LV_ATTRIBUTE_IMG_CK_OS_BATTERYCHARGING_010 uint8_t ck_os_batterycharging_010_map[] = { - 0x04, 0x02, 0xcc, 0xff, /*Color of index 0*/ - 0x6c, 0xfe, 0x6c, 0xff, /*Color of index 1*/ - 0xe4, 0xe6, 0xe4, 0xff, /*Color of index 2*/ - 0xff, 0xff, 0xff, 0xff, /*Color of index 3*/ - - 0x55, 0x5a, 0xaa, 0xaa, 0xa5, 0x55, 0x55, - 0x55, 0x6a, 0xaa, 0xaa, 0xa9, 0x55, 0x55, - 0x55, 0xaa, 0xaa, 0xaa, 0xaa, 0x55, 0x55, - 0x55, 0xaa, 0xaa, 0xaa, 0xaa, 0x55, 0x55, - 0xaa, 0xaa, 0x55, 0x55, 0xaa, 0xaa, 0x55, - 0xaa, 0xaa, 0x55, 0x55, 0xaa, 0xaa, 0x55, - 0xaa, 0xaa, 0x55, 0x55, 0xaa, 0xaa, 0x55, - 0xaa, 0xaa, 0x55, 0x55, 0xaa, 0xaa, 0x55, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa, 0x55, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa, 0x55, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa, 0x55, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa, 0x55, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa, 0x55, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa, 0x55, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0x55, 0x55, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0x55, 0x55, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0x6a, 0x55, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa, 0x55, - 0xaa, 0x55, 0x55, 0x55, 0x56, 0xaa, 0x55, - 0xaa, 0x55, 0x55, 0x55, 0x5a, 0xa9, 0x55, - 0xaa, 0x55, 0x55, 0x55, 0x6a, 0xa9, 0x55, - 0xaa, 0x55, 0x55, 0x55, 0xaa, 0xa5, 0x55, - 0xaa, 0x55, 0x55, 0x56, 0xaa, 0xaa, 0xaa, - 0xaa, 0x55, 0x55, 0x5a, 0xaa, 0xaa, 0xaa, - 0xaa, 0x50, 0x00, 0x5a, 0xaa, 0xaa, 0xaa, - 0xaa, 0x50, 0x00, 0x5a, 0xaa, 0xaa, 0xa9, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa, 0xa5, - 0xaa, 0x55, 0x55, 0x55, 0x56, 0xaa, 0x95, - 0xaa, 0xaa, 0xaa, 0xaa, 0x5a, 0xaa, 0x55, - 0xaa, 0xaa, 0xaa, 0xaa, 0x5a, 0xa9, 0x55, - 0xaa, 0xaa, 0xaa, 0xaa, 0x5a, 0xa5, 0x55, - 0xaa, 0xaa, 0xaa, 0xaa, 0x5a, 0x95, 0x55, -}; - -const lv_img_dsc_t ck_os_batterycharging_010 = { - .header.always_zero = 0, - .header.w = 28, - .header.h = 32, - .data_size = 240, - .header.cf = LV_IMG_CF_INDEXED_2BIT, - .data = ck_os_batterycharging_010_map, -}; diff --git a/src/displayapp/icons/battery/os_batterycharging_010.png b/src/displayapp/icons/battery/os_batterycharging_010.png deleted file mode 100644 index 04d5f820..00000000 Binary files a/src/displayapp/icons/battery/os_batterycharging_010.png and /dev/null differ diff --git a/src/displayapp/icons/battery/os_batterycharging_020.c b/src/displayapp/icons/battery/os_batterycharging_020.c deleted file mode 100644 index 1721be15..00000000 --- a/src/displayapp/icons/battery/os_batterycharging_020.c +++ /dev/null @@ -1,58 +0,0 @@ -#include "lvgl/lvgl.h" - -#ifndef LV_ATTRIBUTE_MEM_ALIGN -#define LV_ATTRIBUTE_MEM_ALIGN -#endif - -#ifndef LV_ATTRIBUTE_IMG_CK_OS_BATTERYCHARGING_020 -#define LV_ATTRIBUTE_IMG_CK_OS_BATTERYCHARGING_020 -#endif - -const LV_ATTRIBUTE_MEM_ALIGN LV_ATTRIBUTE_IMG_CK_OS_BATTERYCHARGING_020 uint8_t ck_os_batterycharging_020_map[] = { - 0x04, 0x02, 0xcc, 0xff, /*Color of index 0*/ - 0x6c, 0xfe, 0x6c, 0xff, /*Color of index 1*/ - 0xe4, 0xe6, 0xe4, 0xff, /*Color of index 2*/ - 0xff, 0xff, 0xff, 0xff, /*Color of index 3*/ - - 0x55, 0x5a, 0xaa, 0xaa, 0xa5, 0x55, 0x55, - 0x55, 0x6a, 0xaa, 0xaa, 0xa9, 0x55, 0x55, - 0x55, 0xaa, 0xaa, 0xaa, 0xaa, 0x55, 0x55, - 0x55, 0xaa, 0xaa, 0xaa, 0xaa, 0x55, 0x55, - 0xaa, 0xaa, 0x55, 0x55, 0xaa, 0xaa, 0x55, - 0xaa, 0xaa, 0x55, 0x55, 0xaa, 0xaa, 0x55, - 0xaa, 0xaa, 0x55, 0x55, 0xaa, 0xaa, 0x55, - 0xaa, 0xaa, 0x55, 0x55, 0xaa, 0xaa, 0x55, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa, 0x55, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa, 0x55, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa, 0x55, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa, 0x55, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa, 0x55, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa, 0x55, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0x55, 0x55, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0x55, 0x55, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0x6a, 0x55, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa, 0x55, - 0xaa, 0x55, 0x55, 0x55, 0x56, 0xaa, 0x55, - 0xaa, 0x55, 0x55, 0x55, 0x5a, 0xa9, 0x55, - 0xaa, 0x55, 0x55, 0x55, 0x6a, 0xa9, 0x55, - 0xaa, 0x55, 0x55, 0x55, 0xaa, 0xa5, 0x55, - 0xaa, 0x55, 0x55, 0x56, 0xaa, 0xaa, 0xaa, - 0xaa, 0x55, 0x55, 0x5a, 0xaa, 0xaa, 0xaa, - 0xaa, 0x50, 0x00, 0x5a, 0xaa, 0xaa, 0xaa, - 0xaa, 0x50, 0x00, 0x5a, 0xaa, 0xaa, 0xa9, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa, 0xa5, - 0xaa, 0x55, 0x55, 0x55, 0x56, 0xaa, 0x95, - 0xaa, 0xaa, 0xaa, 0xaa, 0x5a, 0xaa, 0x55, - 0xaa, 0xaa, 0xaa, 0xaa, 0x5a, 0xa9, 0x55, - 0xaa, 0xaa, 0xaa, 0xaa, 0x5a, 0xa5, 0x55, - 0xaa, 0xaa, 0xaa, 0xaa, 0x5a, 0x95, 0x55, -}; - -const lv_img_dsc_t ck_os_batterycharging_020 = { - .header.always_zero = 0, - .header.w = 28, - .header.h = 32, - .data_size = 240, - .header.cf = LV_IMG_CF_INDEXED_2BIT, - .data = ck_os_batterycharging_020_map, -}; diff --git a/src/displayapp/icons/battery/os_batterycharging_020.png b/src/displayapp/icons/battery/os_batterycharging_020.png deleted file mode 100644 index 6416e1e6..00000000 Binary files a/src/displayapp/icons/battery/os_batterycharging_020.png and /dev/null differ diff --git a/src/displayapp/icons/battery/os_batterycharging_030.c b/src/displayapp/icons/battery/os_batterycharging_030.c deleted file mode 100644 index 83101fd9..00000000 --- a/src/displayapp/icons/battery/os_batterycharging_030.c +++ /dev/null @@ -1,58 +0,0 @@ -#include "lvgl/lvgl.h" - -#ifndef LV_ATTRIBUTE_MEM_ALIGN -#define LV_ATTRIBUTE_MEM_ALIGN -#endif - -#ifndef LV_ATTRIBUTE_IMG_CK_OS_BATTERYCHARGING_030 -#define LV_ATTRIBUTE_IMG_CK_OS_BATTERYCHARGING_030 -#endif - -const LV_ATTRIBUTE_MEM_ALIGN LV_ATTRIBUTE_IMG_CK_OS_BATTERYCHARGING_030 uint8_t ck_os_batterycharging_030_map[] = { - 0x04, 0x7a, 0xf4, 0xff, /*Color of index 0*/ - 0x6c, 0xfe, 0x6c, 0xff, /*Color of index 1*/ - 0xe4, 0xe6, 0xe4, 0xff, /*Color of index 2*/ - 0xff, 0xff, 0xff, 0xff, /*Color of index 3*/ - - 0x55, 0x5a, 0xaa, 0xaa, 0xa5, 0x55, 0x55, - 0x55, 0x6a, 0xaa, 0xaa, 0xa9, 0x55, 0x55, - 0x55, 0xaa, 0xaa, 0xaa, 0xaa, 0x55, 0x55, - 0x55, 0xaa, 0xaa, 0xaa, 0xaa, 0x55, 0x55, - 0xaa, 0xaa, 0x55, 0x55, 0xaa, 0xaa, 0x55, - 0xaa, 0xaa, 0x55, 0x55, 0xaa, 0xaa, 0x55, - 0xaa, 0xaa, 0x55, 0x55, 0xaa, 0xaa, 0x55, - 0xaa, 0xaa, 0x55, 0x55, 0xaa, 0xaa, 0x55, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa, 0x55, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa, 0x55, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa, 0x55, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa, 0x55, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa, 0x55, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa, 0x55, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0x55, 0x55, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0x55, 0x55, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0x6a, 0x55, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa, 0x55, - 0xaa, 0x55, 0x55, 0x55, 0x56, 0xaa, 0x55, - 0xaa, 0x55, 0x55, 0x55, 0x5a, 0xa9, 0x55, - 0xaa, 0x55, 0x55, 0x55, 0x6a, 0xa9, 0x55, - 0xaa, 0x55, 0x55, 0x55, 0xaa, 0xa5, 0x55, - 0xaa, 0x50, 0x00, 0x56, 0xaa, 0xaa, 0xaa, - 0xaa, 0x50, 0x00, 0x5a, 0xaa, 0xaa, 0xaa, - 0xaa, 0x50, 0x00, 0x5a, 0xaa, 0xaa, 0xaa, - 0xaa, 0x50, 0x00, 0x5a, 0xaa, 0xaa, 0xa9, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa, 0xa5, - 0xaa, 0x55, 0x55, 0x55, 0x56, 0xaa, 0x95, - 0xaa, 0xaa, 0xaa, 0xaa, 0x5a, 0xaa, 0x55, - 0xaa, 0xaa, 0xaa, 0xaa, 0x5a, 0xa9, 0x55, - 0xaa, 0xaa, 0xaa, 0xaa, 0x5a, 0xa5, 0x55, - 0xaa, 0xaa, 0xaa, 0xaa, 0x5a, 0x95, 0x55, -}; - -const lv_img_dsc_t ck_os_batterycharging_030 = { - .header.always_zero = 0, - .header.w = 28, - .header.h = 32, - .data_size = 240, - .header.cf = LV_IMG_CF_INDEXED_2BIT, - .data = ck_os_batterycharging_030_map, -}; diff --git a/src/displayapp/icons/battery/os_batterycharging_030.png b/src/displayapp/icons/battery/os_batterycharging_030.png deleted file mode 100644 index 96b44d2e..00000000 Binary files a/src/displayapp/icons/battery/os_batterycharging_030.png and /dev/null differ diff --git a/src/displayapp/icons/battery/os_batterycharging_040.c b/src/displayapp/icons/battery/os_batterycharging_040.c deleted file mode 100644 index 02af00e5..00000000 --- a/src/displayapp/icons/battery/os_batterycharging_040.c +++ /dev/null @@ -1,56 +0,0 @@ -#include "lvgl/lvgl.h" - -#ifndef LV_ATTRIBUTE_MEM_ALIGN -#define LV_ATTRIBUTE_MEM_ALIGN -#endif - -#ifndef LV_ATTRIBUTE_IMG_CK_OS_BATTERYCHARGING_040 -#define LV_ATTRIBUTE_IMG_CK_OS_BATTERYCHARGING_040 -#endif - -const LV_ATTRIBUTE_MEM_ALIGN LV_ATTRIBUTE_IMG_CK_OS_BATTERYCHARGING_040 uint8_t ck_os_batterycharging_040_map[] = { - 0x6c, 0xfe, 0x6c, 0xff, /*Color of index 0*/ - 0xe4, 0xe6, 0xe4, 0xff, /*Color of index 1*/ - - 0x03, 0xff, 0xc0, 0x00, - 0x07, 0xff, 0xe0, 0x00, - 0x0f, 0xff, 0xf0, 0x00, - 0x0f, 0xff, 0xf0, 0x00, - 0xff, 0x00, 0xff, 0x00, - 0xff, 0x00, 0xff, 0x00, - 0xff, 0x00, 0xff, 0x00, - 0xff, 0x00, 0xff, 0x00, - 0xf0, 0x00, 0x0f, 0x00, - 0xf0, 0x00, 0x0f, 0x00, - 0xf0, 0x00, 0x0f, 0x00, - 0xf0, 0x00, 0x0f, 0x00, - 0xf0, 0x00, 0x0f, 0x00, - 0xf0, 0x00, 0x0f, 0x00, - 0xf0, 0x00, 0x00, 0x00, - 0xf0, 0x00, 0x00, 0x00, - 0xf0, 0x00, 0x07, 0x00, - 0xf0, 0x00, 0x0f, 0x00, - 0xf0, 0x00, 0x1f, 0x00, - 0xf0, 0x00, 0x3e, 0x00, - 0xf3, 0xf8, 0x7e, 0x00, - 0xf3, 0xf0, 0xfc, 0x00, - 0xf3, 0xf1, 0xff, 0xf0, - 0xf3, 0xf3, 0xff, 0xf0, - 0xf3, 0xf3, 0xff, 0xf0, - 0xf3, 0xf3, 0xff, 0xe0, - 0xf0, 0x00, 0x0f, 0xc0, - 0xf0, 0x00, 0x1f, 0x80, - 0xff, 0xff, 0x3f, 0x00, - 0xff, 0xff, 0x3e, 0x00, - 0xff, 0xff, 0x3c, 0x00, - 0xff, 0xff, 0x38, 0x00, -}; - -const lv_img_dsc_t ck_os_batterycharging_040 = { - .header.always_zero = 0, - .header.w = 28, - .header.h = 32, - .data_size = 136, - .header.cf = LV_IMG_CF_INDEXED_1BIT, - .data = ck_os_batterycharging_040_map, -}; diff --git a/src/displayapp/icons/battery/os_batterycharging_040.png b/src/displayapp/icons/battery/os_batterycharging_040.png deleted file mode 100644 index 5a42caf2..00000000 Binary files a/src/displayapp/icons/battery/os_batterycharging_040.png and /dev/null differ diff --git a/src/displayapp/icons/battery/os_batterycharging_050.c b/src/displayapp/icons/battery/os_batterycharging_050.c deleted file mode 100644 index d2eea829..00000000 --- a/src/displayapp/icons/battery/os_batterycharging_050.c +++ /dev/null @@ -1,56 +0,0 @@ -#include "lvgl/lvgl.h" - -#ifndef LV_ATTRIBUTE_MEM_ALIGN -#define LV_ATTRIBUTE_MEM_ALIGN -#endif - -#ifndef LV_ATTRIBUTE_IMG_CK_OS_BATTERYCHARGING_050 -#define LV_ATTRIBUTE_IMG_CK_OS_BATTERYCHARGING_050 -#endif - -const LV_ATTRIBUTE_MEM_ALIGN LV_ATTRIBUTE_IMG_CK_OS_BATTERYCHARGING_050 uint8_t ck_os_batterycharging_050_map[] = { - 0x6c, 0xfe, 0x6c, 0xff, /*Color of index 0*/ - 0xe4, 0xe6, 0xe4, 0xff, /*Color of index 1*/ - - 0x03, 0xff, 0xc0, 0x00, - 0x07, 0xff, 0xe0, 0x00, - 0x0f, 0xff, 0xf0, 0x00, - 0x0f, 0xff, 0xf0, 0x00, - 0xff, 0x00, 0xff, 0x00, - 0xff, 0x00, 0xff, 0x00, - 0xff, 0x00, 0xff, 0x00, - 0xff, 0x00, 0xff, 0x00, - 0xf0, 0x00, 0x0f, 0x00, - 0xf0, 0x00, 0x0f, 0x00, - 0xf0, 0x00, 0x0f, 0x00, - 0xf0, 0x00, 0x0f, 0x00, - 0xf0, 0x00, 0x0f, 0x00, - 0xf0, 0x00, 0x0f, 0x00, - 0xf0, 0x00, 0x00, 0x00, - 0xf0, 0x00, 0x00, 0x00, - 0xf0, 0x00, 0x07, 0x00, - 0xf0, 0x00, 0x0f, 0x00, - 0xf3, 0xfe, 0x1f, 0x00, - 0xf3, 0xfc, 0x3e, 0x00, - 0xf3, 0xf8, 0x7e, 0x00, - 0xf3, 0xf0, 0xfc, 0x00, - 0xf3, 0xf1, 0xff, 0xf0, - 0xf3, 0xf3, 0xff, 0xf0, - 0xf3, 0xf3, 0xff, 0xf0, - 0xf3, 0xf3, 0xff, 0xe0, - 0xf0, 0x00, 0x0f, 0xc0, - 0xf0, 0x00, 0x1f, 0x80, - 0xff, 0xff, 0x3f, 0x00, - 0xff, 0xff, 0x3e, 0x00, - 0xff, 0xff, 0x3c, 0x00, - 0xff, 0xff, 0x38, 0x00, -}; - -const lv_img_dsc_t ck_os_batterycharging_050 = { - .header.always_zero = 0, - .header.w = 28, - .header.h = 32, - .data_size = 136, - .header.cf = LV_IMG_CF_INDEXED_1BIT, - .data = ck_os_batterycharging_050_map, -}; diff --git a/src/displayapp/icons/battery/os_batterycharging_050.png b/src/displayapp/icons/battery/os_batterycharging_050.png deleted file mode 100644 index ca0e04dd..00000000 Binary files a/src/displayapp/icons/battery/os_batterycharging_050.png and /dev/null differ diff --git a/src/displayapp/icons/battery/os_batterycharging_060.c b/src/displayapp/icons/battery/os_batterycharging_060.c deleted file mode 100644 index 05f8b975..00000000 --- a/src/displayapp/icons/battery/os_batterycharging_060.c +++ /dev/null @@ -1,56 +0,0 @@ -#include "lvgl/lvgl.h" - -#ifndef LV_ATTRIBUTE_MEM_ALIGN -#define LV_ATTRIBUTE_MEM_ALIGN -#endif - -#ifndef LV_ATTRIBUTE_IMG_CK_OS_BATTERYCHARGING_060 -#define LV_ATTRIBUTE_IMG_CK_OS_BATTERYCHARGING_060 -#endif - -const LV_ATTRIBUTE_MEM_ALIGN LV_ATTRIBUTE_IMG_CK_OS_BATTERYCHARGING_060 uint8_t ck_os_batterycharging_060_map[] = { - 0x6c, 0xfe, 0x6c, 0xff, /*Color of index 0*/ - 0xe4, 0xe6, 0xe4, 0xff, /*Color of index 1*/ - - 0x03, 0xff, 0xc0, 0x00, - 0x07, 0xff, 0xe0, 0x00, - 0x0f, 0xff, 0xf0, 0x00, - 0x0f, 0xff, 0xf0, 0x00, - 0xff, 0x00, 0xff, 0x00, - 0xff, 0x00, 0xff, 0x00, - 0xff, 0x00, 0xff, 0x00, - 0xff, 0x00, 0xff, 0x00, - 0xf0, 0x00, 0x0f, 0x00, - 0xf0, 0x00, 0x0f, 0x00, - 0xf0, 0x00, 0x0f, 0x00, - 0xf0, 0x00, 0x0f, 0x00, - 0xf0, 0x00, 0x0f, 0x00, - 0xf0, 0x00, 0x0f, 0x00, - 0xf0, 0x00, 0x00, 0x00, - 0xf0, 0x00, 0x00, 0x00, - 0xf3, 0xff, 0x87, 0x00, - 0xf3, 0xff, 0x0f, 0x00, - 0xf3, 0xfe, 0x1f, 0x00, - 0xf3, 0xfc, 0x3e, 0x00, - 0xf3, 0xf8, 0x7e, 0x00, - 0xf3, 0xf0, 0xfc, 0x00, - 0xf3, 0xf1, 0xff, 0xf0, - 0xf3, 0xf3, 0xff, 0xf0, - 0xf3, 0xf3, 0xff, 0xf0, - 0xf3, 0xf3, 0xff, 0xe0, - 0xf0, 0x00, 0x0f, 0xc0, - 0xf0, 0x00, 0x1f, 0x80, - 0xff, 0xff, 0x3f, 0x00, - 0xff, 0xff, 0x3e, 0x00, - 0xff, 0xff, 0x3c, 0x00, - 0xff, 0xff, 0x38, 0x00, -}; - -const lv_img_dsc_t ck_os_batterycharging_060 = { - .header.always_zero = 0, - .header.w = 28, - .header.h = 32, - .data_size = 136, - .header.cf = LV_IMG_CF_INDEXED_1BIT, - .data = ck_os_batterycharging_060_map, -}; diff --git a/src/displayapp/icons/battery/os_batterycharging_060.png b/src/displayapp/icons/battery/os_batterycharging_060.png deleted file mode 100644 index 2930068a..00000000 Binary files a/src/displayapp/icons/battery/os_batterycharging_060.png and /dev/null differ diff --git a/src/displayapp/icons/battery/os_batterycharging_070.c b/src/displayapp/icons/battery/os_batterycharging_070.c deleted file mode 100644 index ac3e319c..00000000 --- a/src/displayapp/icons/battery/os_batterycharging_070.c +++ /dev/null @@ -1,56 +0,0 @@ -#include "lvgl/lvgl.h" - -#ifndef LV_ATTRIBUTE_MEM_ALIGN -#define LV_ATTRIBUTE_MEM_ALIGN -#endif - -#ifndef LV_ATTRIBUTE_IMG_CK_OS_BATTERYCHARGING_070 -#define LV_ATTRIBUTE_IMG_CK_OS_BATTERYCHARGING_070 -#endif - -const LV_ATTRIBUTE_MEM_ALIGN LV_ATTRIBUTE_IMG_CK_OS_BATTERYCHARGING_070 uint8_t ck_os_batterycharging_070_map[] = { - 0x6c, 0xfe, 0x6c, 0xff, /*Color of index 0*/ - 0xe4, 0xe6, 0xe4, 0xff, /*Color of index 1*/ - - 0x03, 0xff, 0xc0, 0x00, - 0x07, 0xff, 0xe0, 0x00, - 0x0f, 0xff, 0xf0, 0x00, - 0x0f, 0xff, 0xf0, 0x00, - 0xff, 0x00, 0xff, 0x00, - 0xff, 0x00, 0xff, 0x00, - 0xff, 0x00, 0xff, 0x00, - 0xff, 0x00, 0xff, 0x00, - 0xf0, 0x00, 0x0f, 0x00, - 0xf0, 0x00, 0x0f, 0x00, - 0xf0, 0x00, 0x0f, 0x00, - 0xf0, 0x00, 0x0f, 0x00, - 0xf0, 0x00, 0x0f, 0x00, - 0xf0, 0x00, 0x0f, 0x00, - 0xf3, 0xff, 0xc0, 0x00, - 0xf3, 0xff, 0xc0, 0x00, - 0xf3, 0xff, 0x87, 0x00, - 0xf3, 0xff, 0x0f, 0x00, - 0xf3, 0xfe, 0x1f, 0x00, - 0xf3, 0xfc, 0x3e, 0x00, - 0xf3, 0xf8, 0x7e, 0x00, - 0xf3, 0xf0, 0xfc, 0x00, - 0xf3, 0xf1, 0xff, 0xf0, - 0xf3, 0xf3, 0xff, 0xf0, - 0xf3, 0xf3, 0xff, 0xf0, - 0xf3, 0xf3, 0xff, 0xe0, - 0xf0, 0x00, 0x0f, 0xc0, - 0xf0, 0x00, 0x1f, 0x80, - 0xff, 0xff, 0x3f, 0x00, - 0xff, 0xff, 0x3e, 0x00, - 0xff, 0xff, 0x3c, 0x00, - 0xff, 0xff, 0x38, 0x00, -}; - -const lv_img_dsc_t ck_os_batterycharging_070 = { - .header.always_zero = 0, - .header.w = 28, - .header.h = 32, - .data_size = 136, - .header.cf = LV_IMG_CF_INDEXED_1BIT, - .data = ck_os_batterycharging_070_map, -}; diff --git a/src/displayapp/icons/battery/os_batterycharging_070.png b/src/displayapp/icons/battery/os_batterycharging_070.png deleted file mode 100644 index 7d5f55d7..00000000 Binary files a/src/displayapp/icons/battery/os_batterycharging_070.png and /dev/null differ diff --git a/src/displayapp/icons/battery/os_batterycharging_080.c b/src/displayapp/icons/battery/os_batterycharging_080.c deleted file mode 100644 index cc1c1d23..00000000 --- a/src/displayapp/icons/battery/os_batterycharging_080.c +++ /dev/null @@ -1,58 +0,0 @@ -#include "lvgl/lvgl.h" - -#ifndef LV_ATTRIBUTE_MEM_ALIGN -#define LV_ATTRIBUTE_MEM_ALIGN -#endif - -#ifndef LV_ATTRIBUTE_IMG_CK_OS_BATTERYCHARGING_080 -#define LV_ATTRIBUTE_IMG_CK_OS_BATTERYCHARGING_080 -#endif - -const LV_ATTRIBUTE_MEM_ALIGN LV_ATTRIBUTE_IMG_CK_OS_BATTERYCHARGING_080 uint8_t ck_os_batterycharging_080_map[] = { - 0x7c, 0xd2, 0x34, 0xff, /*Color of index 0*/ - 0xe4, 0xe6, 0xe4, 0xff, /*Color of index 1*/ - 0x6c, 0xfe, 0x6c, 0xff, /*Color of index 2*/ - 0xff, 0xff, 0xff, 0xff, /*Color of index 3*/ - - 0xaa, 0xa5, 0x55, 0x55, 0x5a, 0xaa, 0xaa, - 0xaa, 0x95, 0x55, 0x55, 0x56, 0xaa, 0xaa, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa, 0xaa, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa, 0xaa, - 0x55, 0x55, 0xaa, 0xaa, 0x55, 0x55, 0xaa, - 0x55, 0x55, 0xaa, 0xaa, 0x55, 0x55, 0xaa, - 0x55, 0x55, 0xaa, 0xaa, 0x55, 0x55, 0xaa, - 0x55, 0x55, 0xaa, 0xaa, 0x55, 0x55, 0xaa, - 0x55, 0xaa, 0xaa, 0xaa, 0xaa, 0x55, 0xaa, - 0x55, 0xaa, 0xaa, 0xaa, 0xaa, 0x55, 0xaa, - 0x55, 0xaa, 0xaa, 0xaa, 0xaa, 0x55, 0xaa, - 0x55, 0xaa, 0xaa, 0xaa, 0xaa, 0x55, 0xaa, - 0x55, 0xa0, 0x00, 0x00, 0x0a, 0x55, 0xaa, - 0x55, 0xa0, 0x00, 0x00, 0x0a, 0x55, 0xaa, - 0x55, 0xa0, 0x00, 0x00, 0x0a, 0xaa, 0xaa, - 0x55, 0xa0, 0x00, 0x00, 0x0a, 0xaa, 0xaa, - 0x55, 0xa0, 0x00, 0x00, 0x2a, 0x95, 0xaa, - 0x55, 0xa0, 0x00, 0x00, 0xaa, 0x55, 0xaa, - 0x55, 0xa0, 0x00, 0x02, 0xa9, 0x55, 0xaa, - 0x55, 0xa0, 0x00, 0x0a, 0xa5, 0x56, 0xaa, - 0x55, 0xa0, 0x00, 0x2a, 0x95, 0x56, 0xaa, - 0x55, 0xa0, 0x00, 0xaa, 0x55, 0x5a, 0xaa, - 0x55, 0xa0, 0x00, 0xa9, 0x55, 0x55, 0x55, - 0x55, 0xa0, 0x00, 0xa5, 0x55, 0x55, 0x55, - 0x55, 0xa0, 0x00, 0xa5, 0x55, 0x55, 0x55, - 0x55, 0xa0, 0x00, 0xa5, 0x55, 0x55, 0x56, - 0x55, 0xaa, 0xaa, 0xaa, 0xaa, 0x55, 0x5a, - 0x55, 0xaa, 0xaa, 0xaa, 0xa9, 0x55, 0x6a, - 0x55, 0x55, 0x55, 0x55, 0xa5, 0x55, 0xaa, - 0x55, 0x55, 0x55, 0x55, 0xa5, 0x56, 0xaa, - 0x55, 0x55, 0x55, 0x55, 0xa5, 0x5a, 0xaa, - 0x55, 0x55, 0x55, 0x55, 0xa5, 0x6a, 0xaa, -}; - -const lv_img_dsc_t ck_os_batterycharging_080 = { - .header.always_zero = 0, - .header.w = 28, - .header.h = 32, - .data_size = 240, - .header.cf = LV_IMG_CF_INDEXED_2BIT, - .data = ck_os_batterycharging_080_map, -}; diff --git a/src/displayapp/icons/battery/os_batterycharging_080.png b/src/displayapp/icons/battery/os_batterycharging_080.png deleted file mode 100644 index cce5052f..00000000 Binary files a/src/displayapp/icons/battery/os_batterycharging_080.png and /dev/null differ diff --git a/src/displayapp/icons/battery/os_batterycharging_090.c b/src/displayapp/icons/battery/os_batterycharging_090.c deleted file mode 100644 index 85e1c260..00000000 --- a/src/displayapp/icons/battery/os_batterycharging_090.c +++ /dev/null @@ -1,58 +0,0 @@ -#include "lvgl/lvgl.h" - -#ifndef LV_ATTRIBUTE_MEM_ALIGN -#define LV_ATTRIBUTE_MEM_ALIGN -#endif - -#ifndef LV_ATTRIBUTE_IMG_CK_OS_BATTERYCHARGING_090 -#define LV_ATTRIBUTE_IMG_CK_OS_BATTERYCHARGING_090 -#endif - -const LV_ATTRIBUTE_MEM_ALIGN LV_ATTRIBUTE_IMG_CK_OS_BATTERYCHARGING_090 uint8_t ck_os_batterycharging_090_map[] = { - 0x7c, 0xd2, 0x34, 0xff, /*Color of index 0*/ - 0xe4, 0xe6, 0xe4, 0xff, /*Color of index 1*/ - 0x6c, 0xfe, 0x6c, 0xff, /*Color of index 2*/ - 0xff, 0xff, 0xff, 0xff, /*Color of index 3*/ - - 0xaa, 0xa5, 0x55, 0x55, 0x5a, 0xaa, 0xaa, - 0xaa, 0x95, 0x55, 0x55, 0x56, 0xaa, 0xaa, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa, 0xaa, - 0xaa, 0x55, 0x55, 0x55, 0x55, 0xaa, 0xaa, - 0x55, 0x55, 0xaa, 0xaa, 0x55, 0x55, 0xaa, - 0x55, 0x55, 0xaa, 0xaa, 0x55, 0x55, 0xaa, - 0x55, 0x55, 0xaa, 0xaa, 0x55, 0x55, 0xaa, - 0x55, 0x55, 0xaa, 0xaa, 0x55, 0x55, 0xaa, - 0x55, 0xaa, 0xaa, 0xaa, 0xaa, 0x55, 0xaa, - 0x55, 0xaa, 0xaa, 0xaa, 0xaa, 0x55, 0xaa, - 0x55, 0xa0, 0x00, 0x00, 0x0a, 0x55, 0xaa, - 0x55, 0xa0, 0x00, 0x00, 0x0a, 0x55, 0xaa, - 0x55, 0xa0, 0x00, 0x00, 0x0a, 0x55, 0xaa, - 0x55, 0xa0, 0x00, 0x00, 0x0a, 0x55, 0xaa, - 0x55, 0xa0, 0x00, 0x00, 0x0a, 0xaa, 0xaa, - 0x55, 0xa0, 0x00, 0x00, 0x0a, 0xaa, 0xaa, - 0x55, 0xa0, 0x00, 0x00, 0x2a, 0x95, 0xaa, - 0x55, 0xa0, 0x00, 0x00, 0xaa, 0x55, 0xaa, - 0x55, 0xa0, 0x00, 0x02, 0xa9, 0x55, 0xaa, - 0x55, 0xa0, 0x00, 0x0a, 0xa5, 0x56, 0xaa, - 0x55, 0xa0, 0x00, 0x2a, 0x95, 0x56, 0xaa, - 0x55, 0xa0, 0x00, 0xaa, 0x55, 0x5a, 0xaa, - 0x55, 0xa0, 0x00, 0xa9, 0x55, 0x55, 0x55, - 0x55, 0xa0, 0x00, 0xa5, 0x55, 0x55, 0x55, - 0x55, 0xa0, 0x00, 0xa5, 0x55, 0x55, 0x55, - 0x55, 0xa0, 0x00, 0xa5, 0x55, 0x55, 0x56, - 0x55, 0xaa, 0xaa, 0xaa, 0xaa, 0x55, 0x5a, - 0x55, 0xaa, 0xaa, 0xaa, 0xa9, 0x55, 0x6a, - 0x55, 0x55, 0x55, 0x55, 0xa5, 0x55, 0xaa, - 0x55, 0x55, 0x55, 0x55, 0xa5, 0x56, 0xaa, - 0x55, 0x55, 0x55, 0x55, 0xa5, 0x5a, 0xaa, - 0x55, 0x55, 0x55, 0x55, 0xa5, 0x6a, 0xaa, -}; - -const lv_img_dsc_t ck_os_batterycharging_090 = { - .header.always_zero = 0, - .header.w = 28, - .header.h = 32, - .data_size = 240, - .header.cf = LV_IMG_CF_INDEXED_2BIT, - .data = ck_os_batterycharging_090_map, -}; diff --git a/src/displayapp/icons/battery/os_batterycharging_090.png b/src/displayapp/icons/battery/os_batterycharging_090.png deleted file mode 100644 index fc7b443d..00000000 Binary files a/src/displayapp/icons/battery/os_batterycharging_090.png and /dev/null differ diff --git a/src/displayapp/icons/battery/os_batterycharging_100.c b/src/displayapp/icons/battery/os_batterycharging_100.c deleted file mode 100644 index 8dec0cb5..00000000 --- a/src/displayapp/icons/battery/os_batterycharging_100.c +++ /dev/null @@ -1,56 +0,0 @@ -#include "lvgl/lvgl.h" - -#ifndef LV_ATTRIBUTE_MEM_ALIGN -#define LV_ATTRIBUTE_MEM_ALIGN -#endif - -#ifndef LV_ATTRIBUTE_IMG_CK_OS_BATTERYCHARGING_100 -#define LV_ATTRIBUTE_IMG_CK_OS_BATTERYCHARGING_100 -#endif - -const LV_ATTRIBUTE_MEM_ALIGN LV_ATTRIBUTE_IMG_CK_OS_BATTERYCHARGING_100 uint8_t ck_os_batterycharging_100_map[] = { - 0x6c, 0xfe, 0x6c, 0xff, /*Color of index 0*/ - 0xe4, 0xe6, 0xe4, 0xff, /*Color of index 1*/ - - 0x03, 0xff, 0xc0, - 0x07, 0xff, 0xe0, - 0x0f, 0xff, 0xf0, - 0x0f, 0xff, 0xf0, - 0xff, 0x00, 0xff, - 0xff, 0x00, 0xff, - 0xff, 0x00, 0xff, - 0xff, 0x00, 0xff, - 0xf0, 0x00, 0x0f, - 0xf0, 0x00, 0x0f, - 0xf0, 0x07, 0x0f, - 0xf0, 0x0f, 0x0f, - 0xf0, 0x1f, 0x0f, - 0xf0, 0x3e, 0x0f, - 0xf0, 0x7e, 0x0f, - 0xf0, 0xfc, 0x0f, - 0xf1, 0xff, 0xcf, - 0xf3, 0xff, 0xcf, - 0xf3, 0xff, 0xcf, - 0xf3, 0xff, 0x8f, - 0xf0, 0x3f, 0x0f, - 0xf0, 0x7e, 0x0f, - 0xf0, 0x7c, 0x0f, - 0xf0, 0xf8, 0x0f, - 0xf0, 0xf0, 0x0f, - 0xf0, 0xe0, 0x0f, - 0xf0, 0x00, 0x0f, - 0xf0, 0x00, 0x0f, - 0xff, 0xff, 0xff, - 0xff, 0xff, 0xff, - 0xff, 0xff, 0xff, - 0xff, 0xff, 0xff, -}; - -const lv_img_dsc_t ck_os_batterycharging_100 = { - .header.always_zero = 0, - .header.w = 24, - .header.h = 32, - .data_size = 104, - .header.cf = LV_IMG_CF_INDEXED_1BIT, - .data = ck_os_batterycharging_100_map, -}; diff --git a/src/displayapp/icons/battery/os_batterycharging_100.png b/src/displayapp/icons/battery/os_batterycharging_100.png deleted file mode 100644 index 7c8ce0c4..00000000 Binary files a/src/displayapp/icons/battery/os_batterycharging_100.png and /dev/null differ diff --git a/src/displayapp/screens/BatteryIcon.cpp b/src/displayapp/screens/BatteryIcon.cpp index 08aaab70..2fe7c251 100644 --- a/src/displayapp/screens/BatteryIcon.cpp +++ b/src/displayapp/screens/BatteryIcon.cpp @@ -1,23 +1,34 @@ #include "displayapp/screens/BatteryIcon.h" #include #include "displayapp/screens/Symbols.h" +#include "displayapp/icons/battery/batteryicon.c" using namespace Pinetime::Applications::Screens; -const char* BatteryIcon::GetBatteryIcon(uint8_t batteryPercent) { - if (batteryPercent > 87) - return Symbols::batteryFull; - if (batteryPercent > 62) - return Symbols::batteryThreeQuarter; - if (batteryPercent > 37) - return Symbols::batteryHalf; - if (batteryPercent > 12) - return Symbols::batteryOneQuarter; - return Symbols::batteryEmpty; +void BatteryIcon::Create(lv_obj_t* parent) { + batteryImg = lv_img_create(parent, nullptr); + lv_img_set_src(batteryImg, &batteryicon); + lv_obj_set_style_local_image_recolor(batteryImg, LV_IMG_PART_MAIN, LV_STATE_DEFAULT, LV_COLOR_BLACK); + + batteryJuice = lv_obj_create(batteryImg, nullptr); + lv_obj_set_width(batteryJuice, 8); + lv_obj_align(batteryJuice, nullptr, LV_ALIGN_IN_BOTTOM_RIGHT, -2, -2); + lv_obj_set_style_local_radius(batteryJuice, LV_OBJ_PART_MAIN, LV_STATE_DEFAULT, 0); } -const char* BatteryIcon::GetUnknownIcon() { - return Symbols::batteryEmpty; +lv_obj_t* BatteryIcon::GetObject() { + return batteryImg; +} + +void BatteryIcon::SetBatteryPercentage(uint8_t percentage) { + lv_obj_set_height(batteryJuice, percentage * 14 / 100); + lv_obj_realign(batteryJuice); +} + +void BatteryIcon::SetColor(lv_color_t color) { + lv_obj_set_style_local_image_recolor(batteryImg, LV_IMG_PART_MAIN, LV_STATE_DEFAULT, color); + lv_obj_set_style_local_image_recolor_opa(batteryImg, LV_IMG_PART_MAIN, LV_STATE_DEFAULT, LV_OPA_COVER); + lv_obj_set_style_local_bg_color(batteryJuice, LV_OBJ_PART_MAIN, LV_STATE_DEFAULT, color); } const char* BatteryIcon::GetPlugIcon(bool isCharging) { diff --git a/src/displayapp/screens/BatteryIcon.h b/src/displayapp/screens/BatteryIcon.h index bec2e4e0..81f94ac4 100644 --- a/src/displayapp/screens/BatteryIcon.h +++ b/src/displayapp/screens/BatteryIcon.h @@ -1,15 +1,24 @@ #pragma once #include +#include namespace Pinetime { namespace Applications { namespace Screens { class BatteryIcon { public: + void Create(lv_obj_t* parent); + + void SetColor(lv_color_t); + void SetBatteryPercentage(uint8_t percentage); + lv_obj_t* GetObject(); + static const char* GetUnknownIcon(); - static const char* GetBatteryIcon(uint8_t batteryPercent); static const char* GetPlugIcon(bool isCharging); + private: + lv_obj_t* batteryImg; + lv_obj_t* batteryJuice; }; } } -} \ No newline at end of file +} diff --git a/src/displayapp/screens/Tile.cpp b/src/displayapp/screens/Tile.cpp index cfbe44d3..0a113e3e 100644 --- a/src/displayapp/screens/Tile.cpp +++ b/src/displayapp/screens/Tile.cpp @@ -35,14 +35,12 @@ Tile::Tile(uint8_t screenID, // Time label_time = lv_label_create(lv_scr_act(), nullptr); - lv_label_set_text(label_time, dateTimeController.FormattedTime().c_str()); lv_label_set_align(label_time, LV_LABEL_ALIGN_CENTER); lv_obj_align(label_time, nullptr, LV_ALIGN_IN_TOP_LEFT, 0, 0); // Battery - batteryIcon = lv_label_create(lv_scr_act(), nullptr); - lv_label_set_text_static(batteryIcon, BatteryIcon::GetBatteryIcon(batteryController.PercentRemaining())); - lv_obj_align(batteryIcon, nullptr, LV_ALIGN_IN_TOP_RIGHT, -8, 0); + batteryIcon.Create(lv_scr_act()); + lv_obj_align(batteryIcon.GetObject(), nullptr, LV_ALIGN_IN_TOP_RIGHT, -8, 0); if (numScreens > 1) { pageIndicatorBasePoints[0].x = LV_HOR_RES - 1; @@ -113,6 +111,8 @@ Tile::Tile(uint8_t screenID, lv_label_set_text_static(backgroundLabel, ""); taskUpdate = lv_task_create(lv_update_task, 5000, LV_TASK_PRIO_MID, this); + + UpdateScreen(); } Tile::~Tile() { @@ -122,7 +122,7 @@ Tile::~Tile() { void Tile::UpdateScreen() { lv_label_set_text(label_time, dateTimeController.FormattedTime().c_str()); - lv_label_set_text_static(batteryIcon, BatteryIcon::GetBatteryIcon(batteryController.PercentRemaining())); + batteryIcon.SetBatteryPercentage(batteryController.PercentRemaining()); } void Tile::OnValueChangedEvent(lv_obj_t* obj, uint32_t buttonId) { diff --git a/src/displayapp/screens/Tile.h b/src/displayapp/screens/Tile.h index 4869fef9..48747144 100644 --- a/src/displayapp/screens/Tile.h +++ b/src/displayapp/screens/Tile.h @@ -9,6 +9,7 @@ #include "components/settings/Settings.h" #include "components/datetime/DateTimeController.h" #include "components/battery/BatteryController.h" +#include namespace Pinetime { namespace Applications { @@ -40,13 +41,14 @@ namespace Pinetime { lv_task_t* taskUpdate; lv_obj_t* label_time; - lv_obj_t* batteryIcon; lv_point_t pageIndicatorBasePoints[2]; lv_point_t pageIndicatorPoints[2]; lv_obj_t* pageIndicatorBase; lv_obj_t* pageIndicator; lv_obj_t* btnm1; + BatteryIcon batteryIcon; + const char* btnmMap[8]; Pinetime::Applications::Apps apps[6]; }; diff --git a/src/displayapp/screens/WatchFaceAnalog.cpp b/src/displayapp/screens/WatchFaceAnalog.cpp index 6f9dd1b6..dd5b2929 100644 --- a/src/displayapp/screens/WatchFaceAnalog.cpp +++ b/src/displayapp/screens/WatchFaceAnalog.cpp @@ -66,10 +66,13 @@ WatchFaceAnalog::WatchFaceAnalog(Pinetime::Applications::DisplayApp* app, lv_img_set_src(bg_clock_img, &bg_clock); lv_obj_align(bg_clock_img, NULL, LV_ALIGN_CENTER, 0, 0); - batteryIcon = lv_label_create(lv_scr_act(), nullptr); - lv_label_set_text_static(batteryIcon, Symbols::batteryHalf); - lv_obj_align(batteryIcon, NULL, LV_ALIGN_IN_TOP_RIGHT, 0, 0); - lv_obj_set_auto_realign(batteryIcon, true); + batteryIcon.Create(lv_scr_act()); + lv_obj_align(batteryIcon.GetObject(), nullptr, LV_ALIGN_IN_TOP_RIGHT, 0, 0); + + plugIcon = lv_label_create(lv_scr_act(), nullptr); + lv_label_set_text_static(plugIcon, Symbols::plug); + lv_obj_set_style_local_text_color(plugIcon, LV_LABEL_PART_MAIN, LV_STATE_DEFAULT, LV_COLOR_RED); + lv_obj_align(plugIcon, nullptr, LV_ALIGN_IN_TOP_RIGHT, 0, 0); notificationIcon = lv_label_create(lv_scr_act(), NULL); lv_obj_set_style_local_text_color(notificationIcon, LV_LABEL_PART_MAIN, LV_STATE_DEFAULT, lv_color_hex(0x00FF00)); @@ -121,7 +124,8 @@ WatchFaceAnalog::WatchFaceAnalog(Pinetime::Applications::DisplayApp* app, lv_obj_add_style(hour_body_trace, LV_LINE_PART_MAIN, &hour_line_style_trace); taskRefresh = lv_task_create(RefreshTaskCallback, LV_DISP_DEF_REFR_PERIOD, LV_TASK_PRIO_MID, this); - UpdateClock(); + + Refresh(); } WatchFaceAnalog::~WatchFaceAnalog() { @@ -180,21 +184,18 @@ void WatchFaceAnalog::UpdateClock() { void WatchFaceAnalog::SetBatteryIcon() { auto batteryPercent = batteryPercentRemaining.Get(); - if (batteryPercent == 100) { - lv_obj_set_style_local_text_color(batteryIcon, LV_LABEL_PART_MAIN, LV_STATE_DEFAULT, LV_COLOR_MAKE(0x0, 0xb0, 0x0)); - } else { - lv_obj_set_style_local_text_color(batteryIcon, LV_LABEL_PART_MAIN, LV_STATE_DEFAULT, LV_COLOR_WHITE); - } - lv_label_set_text_static(batteryIcon, BatteryIcon::GetBatteryIcon(batteryPercent)); + batteryIcon.SetBatteryPercentage(batteryPercent); } void WatchFaceAnalog::Refresh() { isCharging = batteryController.IsCharging(); if (isCharging.IsUpdated()) { if (isCharging.Get()) { - lv_obj_set_style_local_text_color(batteryIcon, LV_LABEL_PART_MAIN, LV_STATE_DEFAULT, LV_COLOR_RED); - lv_label_set_text_static(batteryIcon, Symbols::plug); + lv_obj_set_hidden(batteryIcon.GetObject(), true); + lv_obj_set_hidden(plugIcon, false); } else { + lv_obj_set_hidden(batteryIcon.GetObject(), false); + lv_obj_set_hidden(plugIcon, true); SetBatteryIcon(); } } diff --git a/src/displayapp/screens/WatchFaceAnalog.h b/src/displayapp/screens/WatchFaceAnalog.h index 4d76298a..04d9e711 100644 --- a/src/displayapp/screens/WatchFaceAnalog.h +++ b/src/displayapp/screens/WatchFaceAnalog.h @@ -9,6 +9,7 @@ #include "components/battery/BatteryController.h" #include "components/ble/BleController.h" #include "components/ble/NotificationManager.h" +#include namespace Pinetime { namespace Controllers { @@ -64,9 +65,11 @@ namespace Pinetime { lv_style_t second_line_style; lv_obj_t* label_date_day; - lv_obj_t* batteryIcon; + lv_obj_t* plugIcon; lv_obj_t* notificationIcon; + BatteryIcon batteryIcon; + const Controllers::DateTime& dateTimeController; Controllers::Battery& batteryController; Controllers::Ble& bleController; diff --git a/src/displayapp/screens/WatchFaceDigital.cpp b/src/displayapp/screens/WatchFaceDigital.cpp index 866e169e..8a620bd0 100644 --- a/src/displayapp/screens/WatchFaceDigital.cpp +++ b/src/displayapp/screens/WatchFaceDigital.cpp @@ -33,14 +33,13 @@ WatchFaceDigital::WatchFaceDigital(DisplayApp* app, heartRateController {heartRateController}, motionController {motionController} { - batteryIcon = lv_label_create(lv_scr_act(), nullptr); - lv_label_set_text_static(batteryIcon, Symbols::batteryFull); - lv_obj_align(batteryIcon, lv_scr_act(), LV_ALIGN_IN_TOP_RIGHT, 0, 0); + batteryIcon.Create(lv_scr_act()); + lv_obj_align(batteryIcon.GetObject(), lv_scr_act(), LV_ALIGN_IN_TOP_RIGHT, 0, 0); batteryPlug = lv_label_create(lv_scr_act(), nullptr); lv_obj_set_style_local_text_color(batteryPlug, LV_LABEL_PART_MAIN, LV_STATE_DEFAULT, lv_color_hex(0xFF0000)); lv_label_set_text_static(batteryPlug, Symbols::plug); - lv_obj_align(batteryPlug, batteryIcon, LV_ALIGN_OUT_LEFT_MID, -5, 0); + lv_obj_align(batteryPlug, batteryIcon.GetObject(), LV_ALIGN_OUT_LEFT_MID, -5, 0); bleIcon = lv_label_create(lv_scr_act(), nullptr); lv_obj_set_style_local_text_color(bleIcon, LV_LABEL_PART_MAIN, LV_STATE_DEFAULT, lv_color_hex(0x0082FC)); @@ -110,12 +109,7 @@ void WatchFaceDigital::Refresh() { batteryPercentRemaining = batteryController.PercentRemaining(); if (batteryPercentRemaining.IsUpdated()) { auto batteryPercent = batteryPercentRemaining.Get(); - if (batteryPercent == 100) { - lv_obj_set_style_local_text_color(batteryIcon, LV_LABEL_PART_MAIN, LV_STATE_DEFAULT, LV_COLOR_MAKE(0x0, 0xb0, 0x0)); - } else { - lv_obj_set_style_local_text_color(batteryIcon, LV_LABEL_PART_MAIN, LV_STATE_DEFAULT, LV_COLOR_WHITE); - } - lv_label_set_text_static(batteryIcon, BatteryIcon::GetBatteryIcon(batteryPercent)); + batteryIcon.SetBatteryPercentage(batteryPercent); } bleState = bleController.IsConnected(); @@ -123,7 +117,6 @@ void WatchFaceDigital::Refresh() { if (bleState.IsUpdated() || bleRadioEnabled.IsUpdated()) { lv_label_set_text_static(bleIcon, BleIcon::GetIcon(bleState.Get())); } - lv_obj_realign(batteryIcon); lv_obj_realign(batteryPlug); lv_obj_realign(bleIcon); diff --git a/src/displayapp/screens/WatchFaceDigital.h b/src/displayapp/screens/WatchFaceDigital.h index d33434c0..cd83689a 100644 --- a/src/displayapp/screens/WatchFaceDigital.h +++ b/src/displayapp/screens/WatchFaceDigital.h @@ -1,5 +1,6 @@ #pragma once +#include #include #include #include @@ -59,7 +60,6 @@ namespace Pinetime { lv_obj_t* label_time_ampm; lv_obj_t* label_date; lv_obj_t* backgroundLabel; - lv_obj_t* batteryIcon; lv_obj_t* bleIcon; lv_obj_t* batteryPlug; lv_obj_t* heartbeatIcon; @@ -68,6 +68,8 @@ namespace Pinetime { lv_obj_t* stepValue; lv_obj_t* notificationIcon; + BatteryIcon batteryIcon; + Controllers::DateTime& dateTimeController; Controllers::Battery& batteryController; Controllers::Ble& bleController; diff --git a/src/displayapp/screens/WatchFacePineTimeStyle.cpp b/src/displayapp/screens/WatchFacePineTimeStyle.cpp index 28e7a6a3..ae9f5815 100644 --- a/src/displayapp/screens/WatchFacePineTimeStyle.cpp +++ b/src/displayapp/screens/WatchFacePineTimeStyle.cpp @@ -101,11 +101,14 @@ WatchFacePineTimeStyle::WatchFacePineTimeStyle(DisplayApp* app, lv_obj_align(sidebar, lv_scr_act(), LV_ALIGN_IN_TOP_RIGHT, 0, 0); // Display icons - batteryIcon = lv_label_create(lv_scr_act(), nullptr); - lv_obj_set_style_local_text_color(batteryIcon, LV_LABEL_PART_MAIN, LV_STATE_DEFAULT, LV_COLOR_BLACK); - lv_label_set_text_static(batteryIcon, Symbols::batteryFull); - lv_obj_align(batteryIcon, sidebar, LV_ALIGN_IN_TOP_MID, 0, 2); - lv_obj_set_auto_realign(batteryIcon, true); + batteryIcon.Create(sidebar); + batteryIcon.SetColor(LV_COLOR_BLACK); + lv_obj_align(batteryIcon.GetObject(), nullptr, LV_ALIGN_IN_TOP_MID, 0, 2); + + plugIcon = lv_label_create(lv_scr_act(), nullptr); + lv_label_set_text_static(plugIcon, Symbols::plug); + lv_obj_set_style_local_text_color(plugIcon, LV_LABEL_PART_MAIN, LV_STATE_DEFAULT, LV_COLOR_BLACK); + lv_obj_align(plugIcon, sidebar, LV_ALIGN_IN_TOP_MID, 0, 2); bleIcon = lv_label_create(lv_scr_act(), nullptr); lv_obj_set_style_local_text_color(bleIcon, LV_LABEL_PART_MAIN, LV_STATE_DEFAULT, lv_color_hex(0x000000)); @@ -340,7 +343,7 @@ bool WatchFacePineTimeStyle::OnButtonPushed() { void WatchFacePineTimeStyle::SetBatteryIcon() { auto batteryPercent = batteryPercentRemaining.Get(); - lv_label_set_text_static(batteryIcon, BatteryIcon::GetBatteryIcon(batteryPercent)); + batteryIcon.SetBatteryPercentage(batteryPercent); } void WatchFacePineTimeStyle::AlignIcons() { @@ -358,8 +361,11 @@ void WatchFacePineTimeStyle::Refresh() { isCharging = batteryController.IsCharging(); if (isCharging.IsUpdated()) { if (isCharging.Get()) { - lv_label_set_text_static(batteryIcon, Symbols::plug); + lv_obj_set_hidden(batteryIcon.GetObject(), true); + lv_obj_set_hidden(plugIcon, false); } else { + lv_obj_set_hidden(batteryIcon.GetObject(), false); + lv_obj_set_hidden(plugIcon, true); SetBatteryIcon(); } } diff --git a/src/displayapp/screens/WatchFacePineTimeStyle.h b/src/displayapp/screens/WatchFacePineTimeStyle.h index 465aa705..e703d89c 100644 --- a/src/displayapp/screens/WatchFacePineTimeStyle.h +++ b/src/displayapp/screens/WatchFacePineTimeStyle.h @@ -8,6 +8,7 @@ #include "displayapp/Colors.h" #include "components/datetime/DateTimeController.h" #include "components/ble/BleController.h" +#include namespace Pinetime { namespace Controllers { @@ -79,7 +80,7 @@ namespace Pinetime { lv_obj_t* dateDay; lv_obj_t* dateMonth; lv_obj_t* backgroundLabel; - lv_obj_t* batteryIcon; + lv_obj_t* plugIcon; lv_obj_t* bleIcon; lv_obj_t* calendarOuter; lv_obj_t* calendarInner; @@ -93,6 +94,8 @@ namespace Pinetime { lv_obj_t* lbl_btnSet; lv_color_t needle_colors[1]; + BatteryIcon batteryIcon; + Controllers::DateTime& dateTimeController; Controllers::Battery& batteryController; Controllers::Ble& bleController; diff --git a/src/displayapp/screens/settings/QuickSettings.cpp b/src/displayapp/screens/settings/QuickSettings.cpp index aa7f17a3..6268531a 100644 --- a/src/displayapp/screens/settings/QuickSettings.cpp +++ b/src/displayapp/screens/settings/QuickSettings.cpp @@ -35,13 +35,11 @@ QuickSettings::QuickSettings(Pinetime::Applications::DisplayApp* app, // Time label_time = lv_label_create(lv_scr_act(), nullptr); - lv_label_set_text(label_time, dateTimeController.FormattedTime().c_str()); lv_label_set_align(label_time, LV_LABEL_ALIGN_CENTER); lv_obj_align(label_time, lv_scr_act(), LV_ALIGN_IN_TOP_LEFT, 0, 0); - batteryIcon = lv_label_create(lv_scr_act(), nullptr); - lv_label_set_text_static(batteryIcon, BatteryIcon::GetBatteryIcon(batteryController.PercentRemaining())); - lv_obj_align(batteryIcon, nullptr, LV_ALIGN_IN_TOP_RIGHT, 0, 0); + batteryIcon.Create(lv_scr_act()); + lv_obj_align(batteryIcon.GetObject(), nullptr, LV_ALIGN_IN_TOP_RIGHT, 0, 0); static constexpr uint8_t barHeight = 20 + innerDistance; static constexpr uint8_t buttonHeight = (LV_VER_RES_MAX - barHeight - innerDistance) / 2; @@ -113,6 +111,8 @@ QuickSettings::QuickSettings(Pinetime::Applications::DisplayApp* app, lv_label_set_text_static(backgroundLabel, ""); taskUpdate = lv_task_create(lv_update_task, 5000, LV_TASK_PRIO_MID, this); + + UpdateScreen(); } QuickSettings::~QuickSettings() { @@ -124,7 +124,7 @@ QuickSettings::~QuickSettings() { void QuickSettings::UpdateScreen() { lv_label_set_text(label_time, dateTimeController.FormattedTime().c_str()); - lv_label_set_text_static(batteryIcon, BatteryIcon::GetBatteryIcon(batteryController.PercentRemaining())); + batteryIcon.SetBatteryPercentage(batteryController.PercentRemaining()); } void QuickSettings::OnButtonEvent(lv_obj_t* object, lv_event_t event) { diff --git a/src/displayapp/screens/settings/QuickSettings.h b/src/displayapp/screens/settings/QuickSettings.h index 7913898d..40a2a2ef 100644 --- a/src/displayapp/screens/settings/QuickSettings.h +++ b/src/displayapp/screens/settings/QuickSettings.h @@ -8,6 +8,7 @@ #include "components/motor/MotorController.h" #include "components/settings/Settings.h" #include "components/battery/BatteryController.h" +#include namespace Pinetime { @@ -37,7 +38,6 @@ namespace Pinetime { Controllers::Settings& settingsController; lv_task_t* taskUpdate; - lv_obj_t* batteryIcon; lv_obj_t* label_time; lv_style_t btn_style; @@ -48,6 +48,8 @@ namespace Pinetime { lv_obj_t* btn3; lv_obj_t* btn3_lvl; lv_obj_t* btn4; + + BatteryIcon batteryIcon; }; } }