@@ -199,7 +199,7 @@ class dispDrvSt7789 : public dispDrvBase {
199199 // Clear and draw the new cloud icon, based on MQTT connection status
200200 _display->fillRect (cloudX, iconY, _status_bar_icon_sz, _status_bar_icon_sz,
201201 ST77XX_WHITE);
202- if (mqtt_status == 21 ) {
202+ if (mqtt_status) {
203203 _display->drawBitmap (cloudX, iconY, epd_bmp_cloud_online,
204204 _status_bar_icon_sz, _status_bar_icon_sz, ST77XX_BLACK);
205205 } else {
@@ -243,13 +243,15 @@ class dispDrvSt7789 : public dispDrvBase {
243243 _display->fillRect (0 , _status_bar_height, _width,
244244 _height - _status_bar_height, ST77XX_BLACK);
245245 int16_t y_idx = _status_bar_height;
246- _display->setCursor (0 , y_idx);
247246
248247 // Calculate the line height based on the text size (NOTE: base height is
249248 // 8px)
250249 int16_t line_height = 8 * _text_sz;
251250 uint16_t c_idx = 0 ;
252251 size_t msg_size = strlen (message);
252+ // Begin with a small offset from status bar
253+ y_idx += 5 ;
254+ _display->setCursor (0 , y_idx);
253255 for (size_t i = 0 ; i < msg_size && c_idx < msg_size; i++) {
254256 if (y_idx + line_height > _height)
255257 break ;
0 commit comments