Compare commits

...

2 Commits

Author SHA1 Message Date
Ludovic BOUÉ
ffb497b667
Enable AXP192 2024-11-12 18:51:01 +01:00
Ludovic BOUÉ
aa27453af7
Remove TFT_BL 2024-11-12 16:20:51 +01:00
2 changed files with 4 additions and 9 deletions

View File

@ -1581,10 +1581,6 @@ void Screen::handleSetOn(bool on, FrameCallback einkScreensaver)
digitalWrite(VTFT_LEDA, TFT_BACKLIGHT_ON); digitalWrite(VTFT_LEDA, TFT_BACKLIGHT_ON);
#endif #endif
#endif #endif
#ifdef TFT_BL
pinMode(TFT_BL, OUTPUT);
digitalWrite(TFT_BL, HIGH);
#endif
#if defined(M5STACK_CORE2) #if defined(M5STACK_CORE2)
M5.Power.Axp192.setDCDC3(1000); M5.Power.Axp192.setDCDC3(1000);
M5.Display.setBrightness(130); M5.Display.setBrightness(130);
@ -1600,10 +1596,6 @@ void Screen::handleSetOn(bool on, FrameCallback einkScreensaver)
#endif #endif
LOG_INFO("Turn off screen"); LOG_INFO("Turn off screen");
dispdev->displayOff(); dispdev->displayOff();
#ifdef TFT_BL
pinMode(TFT_BL, OUTPUT);
digitalWrite(TFT_BL, LOW);
#endif
#if defined(M5STACK_CORE2) #if defined(M5STACK_CORE2)
M5.Power.Axp192.setDCDC3(0); M5.Power.Axp192.setDCDC3(0);
#endif #endif
@ -2771,4 +2763,4 @@ int Screen::handleAdminMessage(const meshtastic_AdminMessage *arg)
} // namespace graphics } // namespace graphics
#else #else
graphics::Screen::Screen(ScanI2C::DeviceAddress, meshtastic_Config_DisplayConfig_OledType, OLEDDISPLAY_GEOMETRY) {} graphics::Screen::Screen(ScanI2C::DeviceAddress, meshtastic_Config_DisplayConfig_OledType, OLEDDISPLAY_GEOMETRY) {}
#endif // HAS_SCREEN #endif // HAS_SCREEN

View File

@ -1,4 +1,7 @@
#define BUTTON_NEED_PULLUP #define BUTTON_NEED_PULLUP
#define HAS_AXP192
#define I2C_SDA 21 // For AXP192
#define I2C_SCL 22 // For AXP192
#undef LORA_SCK #undef LORA_SCK
#undef LORA_MISO #undef LORA_MISO