Solenoid not working

So, our piston is set to extend when button B (code in top function) is pressed, and to retract when button Y is pressed (code in bottom function). Button B works as normal, but when button Y is pressed, the solenoid starts leaking from one of the holes. I don’t have a picture of the specific hole right now, but I will upload one as soon as I can. The leaking itself only happens when button Y is pressed, so I am unsure if it is a code or build issue. This has happened with three separate solenoids, and we have triple-checked all connections. It also happened when the code was set to just set the solenoid to true or false (i.e. the code below, but with just the first line of each function). We have tried making adjustments to the code, and the current code (shown below) is what one of our sister teams is using successfully, but has not fixed our issue. I’m not sure what is happening, so I was wondering if one of you guys could help?
image

Not a code issue (there is no “make solenoid leak” command!).

Double check the plumbing between your air cylinder and solenoid. The only “leak” should be out the exhaust ports of the solenoid valve when your air cylinder extends or retracts.

7 Likes

Thanks for the clarification. We were unsure if the air was meant to be leaking from there or not. And we tried again today with a fourth solenoid, and its now working properly.

1 Like