mirror of
https://github.com/meshtastic/firmware.git
synced 2025-08-28 07:30:16 +00:00
Fix build warning and trunk format
This commit is contained in:
parent
2703fc1f18
commit
8f20bb19ba
@ -436,6 +436,8 @@ class AnalogBatteryLevel : public HasBatteryLevel
|
|||||||
return isBatteryConnect() && isVbusIn();
|
return isBatteryConnect() && isVbusIn();
|
||||||
#endif
|
#endif
|
||||||
#endif
|
#endif
|
||||||
|
// by default, we check the battery voltage only
|
||||||
|
return isVbusIn();
|
||||||
}
|
}
|
||||||
|
|
||||||
private:
|
private:
|
||||||
|
@ -65,8 +65,8 @@
|
|||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if (defined(USE_EINK) || defined(ILI9341_DRIVER) || defined(ILI9342_DRIVER) || defined(ST7701_CS) || defined(ST7735_CS) || \
|
#if (defined(USE_EINK) || defined(ILI9341_DRIVER) || defined(ILI9342_DRIVER) || defined(ST7701_CS) || defined(ST7735_CS) || \
|
||||||
defined(ST7789_CS) || defined(USE_ST7789) || defined(HX8357_CS)) || defined(ILI9488_CS) && \
|
defined(ST7789_CS) || defined(USE_ST7789) || defined(HX8357_CS)) || \
|
||||||
!defined(DISPLAY_FORCE_SMALL_FONTS)
|
defined(ILI9488_CS) && !defined(DISPLAY_FORCE_SMALL_FONTS)
|
||||||
// The screen is bigger so use bigger fonts
|
// The screen is bigger so use bigger fonts
|
||||||
#define FONT_SMALL FONT_MEDIUM_LOCAL // Height: 19
|
#define FONT_SMALL FONT_MEDIUM_LOCAL // Height: 19
|
||||||
#define FONT_MEDIUM FONT_LARGE_LOCAL // Height: 28
|
#define FONT_MEDIUM FONT_LARGE_LOCAL // Height: 28
|
||||||
|
@ -319,9 +319,11 @@ void setup()
|
|||||||
SPISettings spiSettings(4000000, MSBFIRST, SPI_MODE0);
|
SPISettings spiSettings(4000000, MSBFIRST, SPI_MODE0);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#if !HAS_TFT
|
||||||
meshtastic_Config_DisplayConfig_OledType screen_model =
|
meshtastic_Config_DisplayConfig_OledType screen_model =
|
||||||
meshtastic_Config_DisplayConfig_OledType::meshtastic_Config_DisplayConfig_OledType_OLED_AUTO;
|
meshtastic_Config_DisplayConfig_OledType::meshtastic_Config_DisplayConfig_OledType_OLED_AUTO;
|
||||||
OLEDDISPLAY_GEOMETRY screen_geometry = GEOMETRY_128_64;
|
OLEDDISPLAY_GEOMETRY screen_geometry = GEOMETRY_128_64;
|
||||||
|
#endif
|
||||||
|
|
||||||
#ifdef USE_SEGGER
|
#ifdef USE_SEGGER
|
||||||
auto mode = false ? SEGGER_RTT_MODE_BLOCK_IF_FIFO_FULL : SEGGER_RTT_MODE_NO_BLOCK_TRIM;
|
auto mode = false ? SEGGER_RTT_MODE_BLOCK_IF_FIFO_FULL : SEGGER_RTT_MODE_NO_BLOCK_TRIM;
|
||||||
@ -545,6 +547,7 @@ void setup()
|
|||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#if !HAS_TFT
|
||||||
auto screenInfo = i2cScanner->firstScreen();
|
auto screenInfo = i2cScanner->firstScreen();
|
||||||
screen_found = screenInfo.type != ScanI2C::DeviceType::NONE ? screenInfo.address : ScanI2C::ADDRESS_NONE;
|
screen_found = screenInfo.type != ScanI2C::DeviceType::NONE ? screenInfo.address : ScanI2C::ADDRESS_NONE;
|
||||||
|
|
||||||
@ -562,6 +565,7 @@ void setup()
|
|||||||
screen_model = meshtastic_Config_DisplayConfig_OledType::meshtastic_Config_DisplayConfig_OledType_OLED_AUTO;
|
screen_model = meshtastic_Config_DisplayConfig_OledType::meshtastic_Config_DisplayConfig_OledType_OLED_AUTO;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
#define UPDATE_FROM_SCANNER(FIND_FN)
|
#define UPDATE_FROM_SCANNER(FIND_FN)
|
||||||
|
|
||||||
@ -725,9 +729,11 @@ void setup()
|
|||||||
else
|
else
|
||||||
playStartMelody();
|
playStartMelody();
|
||||||
|
|
||||||
|
#if !HAS_TFT
|
||||||
// fixed screen override?
|
// fixed screen override?
|
||||||
if (config.display.oled != meshtastic_Config_DisplayConfig_OledType_OLED_AUTO)
|
if (config.display.oled != meshtastic_Config_DisplayConfig_OledType_OLED_AUTO)
|
||||||
screen_model = config.display.oled;
|
screen_model = config.display.oled;
|
||||||
|
#endif
|
||||||
|
|
||||||
#if defined(USE_SH1107)
|
#if defined(USE_SH1107)
|
||||||
screen_model = meshtastic_Config_DisplayConfig_OledType_OLED_SH1107; // set dimension of 128x128
|
screen_model = meshtastic_Config_DisplayConfig_OledType_OLED_SH1107; // set dimension of 128x128
|
||||||
|
Loading…
Reference in New Issue
Block a user