-
Notifications
You must be signed in to change notification settings - Fork 17k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
AP_Notify: Eliminated need for Solo specific tones, added power off tone to px4 tones #6218
Conversation
Evaluated solo specific tones file vs standard px4 tones files. The only thing the Solo had that standard ArduPilot does not have is the GPS unplugged tone and the power off tone. This PR is needed to get Solo onto Master. Please backport into 3.5 if approved. * GPS unplugged tone abandoned. Determined to be unnecessary. * Power off tone merged into standard px4 tones file. Smart battery signalling a power off will make use of this tone. Has application for any smart battery equipped vehicle, not just Solo. * Removed all references and dependencies to ToneAlarm_PX4_Solo.cpp and ToneAlarm_PX4_Solo.h * Deleted ToneAlarm_PX4_Solo.cpp and ToneAlarm_PX4_Solo.h since they're no longer needed.
@khancyr I think this one worked :) |
Yep, seem good to go. |
I haven't give it a detailed review yet, but a few points:
|
@OXINARF Less messing around.. |
@proficnc Great, love it! |
if (!flags.powering_off) { | ||
play_tone(AP_NOTIFY_PX4_TONE_QUIET_SHUTDOWN); | ||
} | ||
flags.powering_off = AP_Notify::flags.powering_off; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This line will always be true. Might as well just set it to true for clarity.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure what you mean? The AP_Notify::flags.powering_off
flag will be false unless the user pushes the power button fox 2 seconds, at which point it goes true. The flags internal to the tone file are just to keep it from repeating once it's fired once. Otherwise it be playing the tone at 50hz.
Disregard. I included this in a larger PR #6340 |
Evaluated solo specific tones file vs standard px4 tones files. The only thing the Solo had that standard ArduPilot does not have is the GPS unplugged tone and the power off tone. This PR is needed to get Solo onto Master. Please backport into 3.5 if approved.
ToneAlarm_PX4_Solo.cpp
andToneAlarm_PX4_Solo.h
ToneAlarm_PX4_Solo.cpp
andToneAlarm_PX4_Solo.h
since they're no longer needed.