mirror of
https://github.com/meshtastic/firmware.git
synced 2025-04-25 09:42:35 +00:00
Bug fixed in ExternalNotificationModule (#5375)
While `nagging` setExternalState wasn't written to Buzzer & Vibra so output was never toggled. Possible fix for #5348
This commit is contained in:
parent
37b29f6899
commit
a174ec7cf9
@ -119,12 +119,13 @@ int32_t ExternalNotificationModule::runOnce()
|
|||||||
if (externalTurnedOn[1] + (moduleConfig.external_notification.output_ms ? moduleConfig.external_notification.output_ms
|
if (externalTurnedOn[1] + (moduleConfig.external_notification.output_ms ? moduleConfig.external_notification.output_ms
|
||||||
: EXT_NOTIFICATION_MODULE_OUTPUT_MS) <
|
: EXT_NOTIFICATION_MODULE_OUTPUT_MS) <
|
||||||
millis()) {
|
millis()) {
|
||||||
setExternalState(0, !getExternal(1));
|
setExternalState(1, !getExternal(1));
|
||||||
}
|
}
|
||||||
if (externalTurnedOn[2] + (moduleConfig.external_notification.output_ms ? moduleConfig.external_notification.output_ms
|
if (externalTurnedOn[2] + (moduleConfig.external_notification.output_ms ? moduleConfig.external_notification.output_ms
|
||||||
: EXT_NOTIFICATION_MODULE_OUTPUT_MS) <
|
: EXT_NOTIFICATION_MODULE_OUTPUT_MS) <
|
||||||
millis()) {
|
millis()) {
|
||||||
setExternalState(0, !getExternal(2));
|
LOG_DEBUG("EXTERNAL 2 %d compared to %d", externalTurnedOn[2]+moduleConfig.external_notification.output_ms, millis());
|
||||||
|
setExternalState(2, !getExternal(2));
|
||||||
}
|
}
|
||||||
#if defined(HAS_NCP5623) || defined(RGBLED_RED) || defined(HAS_NEOPIXEL) || defined(UNPHONE)
|
#if defined(HAS_NCP5623) || defined(RGBLED_RED) || defined(HAS_NEOPIXEL) || defined(UNPHONE)
|
||||||
red = (colorState & 4) ? brightnessValues[brightnessIndex] : 0; // Red enabled on colorState = 4,5,6,7
|
red = (colorState & 4) ? brightnessValues[brightnessIndex] : 0; // Red enabled on colorState = 4,5,6,7
|
||||||
|
Loading…
Reference in New Issue
Block a user