Open NickNunno opened 4 years ago
Hey @NickNunno! I'm also looking to add to Rover's E-stop functionality. Here's a description of my desired functionality:
I'm new to ArduPilot development, but I'm moderately familiar with the codebase. I was planning on adding a new sensor library AP_EmergencyStop to handle multiple E-stop buttons, basing it on the analog implementation from AP_RangeFinder. In fact, I have an existing solution which hi-jacks the the AP_RangeFinder analog implementation, but it's more of a hack than a solution and doesn't give feedback to the GCS.
What are your thoughts on the features listed above and general approach to implementing them? Do you think our interests are aligned, or should these be two separate feature requests?
can we put this logic in a script, with access to AP_Button?
1. I/O processor monitors two pins
which pins?
5\. When in safety state, FMU can not reset I/O processor state.
this is very hard to guarantee, as for example FMU needs to be able to reset the IOMCU to load a new firmware
I think there are three actions:
More discussion on this from the Partners meeting:
Hello Gents!
I was able to do some testing today to ensure we can reasonably expect the hardware side to work with the PWM method.
At 12.5' of 16awg I see zero signal distortion. (Did not check between these lengths)
In an attempt to introduce some noise on the wire, I ran the 12.5' length through a coil being fed +/-5v sine wave and ran it up/down the full frequency range. I was unable to produce any noise to speak of, let alone noise that would cause issue's with the proposed state sensing logic.
@rmackay9 @tridge what do you guys think?
Hey guys! I commented earlier about a different approach I was taking toward Rover E-stop, and then I made a separate issue #14087 for it. I didn't hear back from anyone so I went ahead and implemented my version. The functionality might be slightly different than what's being discussed here, but it seems to achieve the same effect.
My implementation involves a new library AP_EmeregencyStop, which could support up to 8 E-stop buttons (9 if you include the RC function). It currently only has one driver: AP_EmergencyStop_GPIO, which uses the FMU pins in a NO/NC configuration. More drivers could be developed for other types of E-stops though (i.e. a remote e-stop located at the GCS).
Would you guys like me to make a PR so you can consider my implementation? I'm just trying to avoid unnecessary development of a feature that I already have implemented!
Accommodates up to 10 E-stops in the system - could include remote E-stops
wow! can you explain a bit more about the hw you're on?
@nlgilbert sounds interesting!
Would be great to find out more info or see a PR, whether here or on your ticket.
I do feel its extremely important for this to be a digital signal rather than analog NO/NC as its far too easy to have an electrical failure.
After a discussion with my boss and project manager, I've been informed that anything developed for the project I'm working on is considered intellectual property. Unfortunately that means I will not be able to contribute any code (at least not until our legal team figures out how to handle working with open source). Sorry to leave you guys hanging, but I wish you the best of luck in getting an E-stop that works for you!
@tridge @rmackay9 do either of you have time to take a crack at this?
Feature request
Problem AP safety button logic was primary designed around copters which have many specific caveats.
Unlike copters, rover should have a means to support inexpensive, industry std Emergency-Stop buttons. These switches are purpose built and typically come with two individual circuit breakers that can be setup NO/NC. When pressed, they lock in position and must be axially turned in order to safely resume the default state. (Available with/without keyed locks)
Describe the solution you'd like Modify safety code so that:
Describe alternatives you've considered
Platform [ ] All [ ] AntennaTracker [ ] Copter [ ] Plane [x] Rover [ ] Submarine
Failure Modes The proposed solution is not perfect but I believe it to be a substantial improvement to the current scheme which really isn't useful for ground vehicles.
The first failure mode would be the E-Stop wiring/button. This is inherent in all systems. high/low sync should mitigate most physical issues.
Second failure mode would be the I/O Processor which kills pin output. If this fails, we have a problem but I think its reasonable to trust?
Third failure mode would be I/O processor failing to communicate with FMU about the current state or FMU lock up. This scenario would be nothing but a fallback to where we are today where an eventual crash check will change modes.