From 256bce0482b75e935f95907867c7b7309f4de8f8 Mon Sep 17 00:00:00 2001 From: Mark Jocas Date: Tue, 2 Jun 2026 08:45:45 +0200 Subject: [PATCH] Refines buzzer melody buffer comment Simplifies the explanation for using a static buffer for buzzer melodies. --- src/helpers/ui/buzzer.cpp | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/helpers/ui/buzzer.cpp b/src/helpers/ui/buzzer.cpp index ee5fc4ce8..a6c003f02 100644 --- a/src/helpers/ui/buzzer.cpp +++ b/src/helpers/ui/buzzer.cpp @@ -49,9 +49,7 @@ void genericBuzzer::playToggle(int count, bool enabled) { const int max_notes = (int)(sizeof(notes) / sizeof(notes[0])); if (count < 1) count = 1; if (count > max_notes) count = max_notes; - // NonBlockingRtttl stores only a pointer to the melody, so the backing - // buffer must outlive the call. A static buffer is fine here because the - // library can't play two melodies at once anyway. + A static buffer as the library can't play two melodies at once anyway. static char melody[64]; int n = snprintf(melody, sizeof(melody), "Tg:d=8,o=6,b=180:"); for (int i = 0; i < count && n < (int)sizeof(melody); i++) {