betaflight
betaflight copied to clipboard
Refactor beeper
Comments are in individual commits
Do you want to test this code? You can flash it directly from Betaflight Configurator:
- Simply put
#13492
(this pull request number) in theSelect commit
field of the Configurator firmware flasher tab (you need toEnable expert mode
,Show release candidates
andDevelopment
).
WARNING: It may be unstable. Use only for testing!
There are some open problems with beeper:
-
beeper_off_flags & BEEPER_USB
When set, all beeps are disabled, including OSD, onboard LED, LedStrip and DSHOT. Is that intentional? Keeping warning led function seems very reasonable, ledstrip is probably OK. -
beeper_off_flags & <FLAG>
Old code did turnwarningLedEnable()
on. Visual beeper and ledstrip was off (https://github.com/betaflight/betaflight/pull/6947, this PR did break led blinking). New code blinks LED only. -
BEEPER_ARMED vas IMO almost continuous beep instead of
- . Nobody cared for 7 years, so long beep is maybe expected now?
As far as I can tell, motors only beep for Rx loss and Rx set. For Mag Cal, adding audio beeper is a big improvement. However without audio beeper, it is useful to have some other non-visual feedback. Would it be practical to provide a motor beep option that made a brief single 'motor beep' whenever any audio beep would be generated by the audio beeper?
4.5 or 4.6?
If there is nothing to fix - this would be 4.6
@ledvinap please rebase
Merged upstream