From 01d57e926e69590fe0969ed4602fad51d7d27eec Mon Sep 17 00:00:00 2001 From: tototo31 Date: Sun, 26 Oct 2025 11:32:17 -0500 Subject: [PATCH 1/2] fix up arrow changing rgb backlight color --- nightstand_clock/clock_app.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/nightstand_clock/clock_app.c b/nightstand_clock/clock_app.c index 20e4fe518f..ea5805e067 100644 --- a/nightstand_clock/clock_app.c +++ b/nightstand_clock/clock_app.c @@ -52,7 +52,7 @@ static const NotificationSequence led_reset = { void set_backlight_brightness(float brightness) { notif->settings.display_brightness = brightness; - notification_message(notif, &sequence_display_backlight_on); + furi_hal_light_set(LightBacklight, brightness * 0xFF); } void handle_up() { @@ -315,7 +315,6 @@ int32_t clock_app(void* p) { float tmpBrightness = notif->settings.display_brightness; brightness = tmpBrightness * 100; // Keep current brightness by default - notification_message(notif, &sequence_display_backlight_enforce_on); notification_message(notif, &led_off); // Set system callbacks @@ -395,7 +394,6 @@ int32_t clock_app(void* p) { free(plugin_state); set_backlight_brightness(tmpBrightness); - notification_message(notif, &sequence_display_backlight_enforce_auto); notification_message(notif, &led_reset); return 0; From 2551c5dc73cd52fd366aa5ee677407c16f3973ba Mon Sep 17 00:00:00 2001 From: tototo31 Date: Sun, 26 Oct 2025 12:41:11 -0500 Subject: [PATCH 2/2] fix backlight color not being set correctly when backing out of app --- nightstand_clock/clock_app.c | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/nightstand_clock/clock_app.c b/nightstand_clock/clock_app.c index ea5805e067..86f4a123ee 100644 --- a/nightstand_clock/clock_app.c +++ b/nightstand_clock/clock_app.c @@ -396,5 +396,16 @@ int32_t clock_app(void* p) { set_backlight_brightness(tmpBrightness); notification_message(notif, &led_reset); + // Force RGB backlight update to restore original color settings + // by temporarily changing brightness and restoring it + if(momentum_settings.rgb_backlight) { + uint8_t current_brightness = tmpBrightness * 0xFF; + // Temporarily set brightness to 0 to force update + furi_hal_light_set(LightBacklight, 0); + furi_delay_ms(10); // Small delay to ensure the change takes effect + // Restore original brightness + furi_hal_light_set(LightBacklight, current_brightness); + } + return 0; }