Skip to content

Commit

Permalink
try-fix crash
Browse files Browse the repository at this point in the history
  • Loading branch information
mverch67 authored and jp-bennett committed Oct 28, 2024
1 parent c5173fb commit 28ba47f
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/modules/ExternalNotificationModule.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -184,7 +184,7 @@ int32_t ExternalNotificationModule::runOnce()
}
#endif
// now let the PWM buzzer play
if (moduleConfig.external_notification.use_pwm) {
if (moduleConfig.external_notification.use_pwm && config.device.buzzer_gpio) {
if (rtttl::isPlaying()) {
rtttl::play();
} else if (isNagging && (nagCycleCutoff >= millis())) {
Expand Down
2 changes: 1 addition & 1 deletion src/modules/ExternalNotificationModule.h
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ class ExternalNotificationModule : public SinglePortModule, private concurrency:
public:
ExternalNotificationModule();

uint32_t nagCycleCutoff = UINT32_MAX;
uint32_t nagCycleCutoff = 1;

void setExternalOn(uint8_t index = 0);
void setExternalOff(uint8_t index = 0);
Expand Down

0 comments on commit 28ba47f

Please sign in to comment.