bdk: display: return duty for oled panel properly

For display_get_backlight_brightness.
This commit is contained in:
CTCaer 2024-06-02 08:23:58 +03:00
parent c5f6837c35
commit 320b91a767

View file

@ -690,7 +690,10 @@ void display_backlight_brightness(u32 brightness, u32 step_delay)
u32 display_get_backlight_brightness() u32 display_get_backlight_brightness()
{ {
if (_display_id != PANEL_SAM_AMS699VC01)
return ((PWM(PWM_CONTROLLER_PWM_CSR_0) >> 16) & 0xFF); return ((PWM(PWM_CONTROLLER_PWM_CSR_0) >> 16) & 0xFF);
else
return _dsi_bl;
} }
static void _display_panel_and_hw_end(bool no_panel_deinit) static void _display_panel_and_hw_end(bool no_panel_deinit)