Closed Benmw99 closed 8 years ago
You should create an instance of the class from within robot map: https://github.com/Team2168/2015_Main_Robot/pull/106/files#diff-6526467aa4534dd94ac9e3313ee14841R124
The methods within RCFingers which allow the fingers to be actuated independantly won't work. It looks like you modeled your class after the ARCB class which apparenly was designed to drive one solenoid valve per arm. So in hardware it controller two separate valves through a single relay. In the case of the fingers there is only one solenoid valve controller through the relay channel. When the relay is set to kOff the fingers are open/disengaged. When the relay is set to kForward the solenoid valve is energized and the fingers close/engage. See the https://github.com/Team2168/2015_Main_Robot/blob/master/src/org/team2168/subsystems/BinRetainer.java class as suggested originally. That subsystem is quite similar at the hardware level.
After updating the RCFingers subsystem, modify the commands to use the revised methods for actuation and you should be good to go.
Everything else looks good to me. Nice work. If you want to go over why the way you wrote the code wont work for this particular pneumatic setup, I can go through the hardware with you in person. It's not immediately obvious how the Relay should be driven unless you can see the wiring/plumbing.
I added the subsystem, commands, and hooked them up to the buttons. I followed the style of the ARCB because it is hooked up to a relay. There were no more solenoid ports open so I did it using just the relay.