mirror of
https://github.com/78/xiaozhi-esp32.git
synced 2026-02-16 08:58:08 +00:00
M5Stack Tab5's backlight doesn't need PWM inversion - the official demo uses direct duty cycle without any inversion flag. (#1764)
uint32_t duty_cycle = (4095 * brightness_percent) / 100; ledc_set_duty(LEDC_LOW_SPEED_MODE, LCD_LEDC_CH, duty_cycle); https://github.com/m5stack/M5Tab5-UserDemo/blob/main/platforms/tab5/components/m5stack_tab5/m5stack_tab5.c#L1088 Tested on M5Stack Tab5, the screen brightness is working correctly now, previously it's reversed.
This commit is contained in:
@@ -45,7 +45,7 @@
|
||||
#define DISPLAY_OFFSET_Y 0
|
||||
|
||||
#define DISPLAY_BACKLIGHT_PIN GPIO_NUM_22
|
||||
#define DISPLAY_BACKLIGHT_OUTPUT_INVERT true
|
||||
#define DISPLAY_BACKLIGHT_OUTPUT_INVERT false
|
||||
|
||||
#define TOUCH_INT_GPIO GPIO_NUM_23 // 触摸中断
|
||||
|
||||
|
||||
Reference in New Issue
Block a user