Programming Pneumatics

My team is in desperate need of programming help with pneumatics. We have the main concept of what we need, but don’t know where to start.

It would be helpful to know what programming language you’re using.

If you’re using Java or C++, you can find examples for pneumatics and just about everything else on screenstepslive. If LabVIEW, there are pneumatcs examples in the FRC folder of the LabVIEW Example Finder.

Sorry about that, we’re using Java.

The WPILib docs for Pneumatics as illustrated on Screensteps are super explanatory. Unless you’re trying to manually control the compressor, you don’t even need to drive it manually. You instantiate the solenoid(s) on the channels you’re using (on the PCM you’re using if you have more than one) and set the state (true/false for single, forward / reverse / off for double)

@AriMB’s link to the specific section should serve as a good starting point, with the actual Java sourcecode / Javadocs serving as additional material.

Thank you, all of this was very helpful.

If you’re using Java/C++:
Most of what you need to know about programming pneumatics is to operate pneumatic cylinder using Solenoids.
https://wpilib.screenstepslive.com/s/currentCS/m/java/l/599708-operating-pneumatic-cylinders-solenoids
Good Luck!

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.