Fix statusupdate and page styles

This commit is contained in:
fvanroie 2020-03-30 16:44:39 +02:00
parent f47cd7b6a0
commit c2a954bbe8
2 changed files with 7 additions and 9 deletions

View File

@ -584,14 +584,6 @@ void haspSetup(JsonObject settings)
{ {
guiSetDim(haspStartDim); guiSetDim(haspStartDim);
/* Create all screens */
for(uint8_t i = 0; i < (sizeof pages / sizeof *pages); i++) {
pages[i] = lv_obj_create(NULL, NULL);
// lv_obj_set_size(pages[0], hres, vres);
}
// haspSetConfig(settings);
/* /*
#ifdef LV_HASP_HOR_RES_MAX #ifdef LV_HASP_HOR_RES_MAX
lv_coord_t hres = LV_HASP_HOR_RES_MAX; lv_coord_t hres = LV_HASP_HOR_RES_MAX;
@ -684,6 +676,12 @@ void haspSetup(JsonObject settings)
} }
// lv_theme_set_current(th); // lv_theme_set_current(th);
/* Create all screens using the theme */
for(uint8_t i = 0; i < (sizeof pages / sizeof *pages); i++) {
pages[i] = lv_obj_create(NULL, NULL);
// lv_obj_set_size(pages[0], hres, vres);
}
haspDisconnect(); haspDisconnect();
haspLoadPage(haspPagesPath); haspLoadPage(haspPagesPath);
haspSetPage(haspStartPage); haspSetPage(haspStartPage);

View File

@ -208,7 +208,7 @@ void mqtt_send_statusupdate()
doc[F("heapFrag")] = halGetHeapFragmentation(); doc[F("heapFrag")] = halGetHeapFragmentation();
doc[F("espCanUpdate")] = false; doc[F("espCanUpdate")] = false;
doc[F("espCore")] = halGetCoreVersion().c_str(); doc[F("espCore")] = halGetCoreVersion().c_str();
doc[F("tftDriver")] = tftDriverName(); doc[F("tftDriver")] = tftDriverName().c_str();
#if defined(ARDUINO_ARCH_ESP8266) #if defined(ARDUINO_ARCH_ESP8266)
doc[F("espVcc")] = (float)ESP.getVcc() / 1000; doc[F("espVcc")] = (float)ESP.getVcc() / 1000;