Closed robertlong13 closed 2 months ago
What about multi vehicle configurations ? Speech is the only feedback for changes on a non selected vehicle and this disables it as well...
I was thinking about this in the context of multi vehicle applications too. "Mode changed to X", "Heading to Waypoint X", without any indication of which vehicle it came from, is, at best, unhelpful. At worst, it's overwhelming vocal spam. Especially if you have a large swarm.
If that's not convincing, then I can reduce this PR to just making CurrentState honor the speechenable flag. That way plugins have the ability to control it, and we can add options for the stock behavior in the future.
@EosBandi and @meee1, thoughts on this? If you think it's best to default it so that all connections speak normally, I can reduce this PR to just fix it so that speechenable
works correctly.
@meee1, I have decided to limit the scope of this PR to just the bugfix. I can handle silencing/unsilencing in a plugin.
@meee1 @EosBandi, any issues with this now that it's just a 2-line bugfix?
I'm okay with it, but the decision to merge is ultimately up to Michael.
Some speech events, like mode changes, fire off on all connected com ports, not just the primary. Additionally,
CurrentState
ignores thespeechenable
flag of theMAVLinkInterface
that it's attached to, causing it to go off even for interfaces that are supposed to be silent.This PR makes
CurrentState
honor thespeechenable
flag. Additionally, it setsspeechenable
on an interface whenMainV2.comPort
is set to that interface, and clearsspeechenable
on the old interface thatMainV2.comPort
was pointing to.