Pneumatic Actuators translate the force of compressed air into fast and powerful motion. In the VEX Robotics System, all pneumatic actuators create linear (in-and-out) motion, although rotary actuators do exist. The compressed air that powers the actuators is stored in a reservoir tank; differences in air pressure between the actuators and tank cause the actuators to move in and out.
The flow of air between the tank and the actuators (directly related to the differences in air pressure) is controlled by a small switch, called an electromagnetic solenoid, which connects to the VEX PIC or Cortex using a standard 3-pin wire. It’s a common misconception that, since the solenoid enables motion, its 3-pin wire should plug into one of the MOTOR ports on the microcontroller. Actually, a solenoid is what’s considered a “Digital Output”, and should be plugged into one of the DIGITAL ports on the Cortex, or ANALOG/DIGITAL ports on the PIC.
Then, in ROBOTC, when you want to activate the pneumatic actuator controlled by the solenoid, you set its value equal to “1”. To deactivate it, set its value equal to “0”. In the sample code below, the remote control buttons are used to activate and deactivate the pneumatic actuator.
#pragma config(Sensor, dgtl7, solenoid, sensorDigitalOut)
//*!!Code automatically generated by ‘ROBOTC’ configuration wizard !!*//
while(true) // Loop Forever
if(vexRT[Btn6U] == 1) // If button 6U (upper right shoulder button) is pressed:
SensorValue[solenoid] = 1; // …activate the solenoid.
else // If button 6U (upper right shoulder button) is NOT pressed:
SensorValue[solenoid] = 0; // ..deactivate the solenoid.
For more information on using pneumatic actuators, check out our Pneumatics lesson from the VEX 2.0 Curriculum.