Log in

View Full Version : Programming PBASIC for pneumatics


archiver
23-06-2002, 23:58
Posted by Will Korinek at 2/1/2001 9:44 AM EST


Student on team #646, Mechanical Animals, from Sayville High School and Computer Associates.



OKAY this may get complicated, for our robots arm, we chose to use pneumatics. We want to know if anyone has any idea what to include in our PBASIC code that will allow the air compressor to turn off when it reaches the specified PSI on the relay. And also turn it on when the PSI drops. Any help is much appreciated...we know that the code is dealing with the digital inputs and outputs, we just need to make some sense of the pbasic..

Thanks,
Will Korinek
Team 646 Sayville Mechanical Animals
Sayville High School
Sayville New York

archiver
23-06-2002, 23:58
Posted by Josh Vetter at 2/1/2001 9:59 AM EST


Student on team #548, Robostangs, from Northville High School and BOSCH.


In Reply to: Programming PBASIC for pneumatics
Posted by Will Korinek on 2/1/2001 9:44 AM EST:



Check out the white pages, there is one about wiring and programming pneumatics. But if you don't want to read all of that, here is what it says about programming it:

In this example, the pump is controlled by the spike relay 5 output, and the pressure switch is on robot controller digital input 1 (input – pin 1 and ground pin 3). This code is inserted in the main loop of the robot controller program.

' Test the state of the pressure switch
if rc_sw1 = 1 then pump_on ' jump if under the pressure limit

' 110 psi pressure limit has been reached
' turn pump off
pump_off:
relay5_fwd = 0
relay5_rev = 0
goto nextaction:

' turn pump on
pump_on:
relay5_fwd = 1
relay5_rev = 0

nextaction:

Josh Vetter
P.s. you may want to add a delay before the pump turns off so that the pump doesn't cycle.

archiver
23-06-2002, 23:58
Posted by Joe at 2/1/2001 9:28 PM EST


Student on team #506 from St. Anthony's HS.


In Reply to: Programming PBASIC for pneumatics
Posted by Will Korinek on 2/1/2001 9:44 AM EST:



I posted a question below about this. You may wish to take a look at it. The answers I recieved helped me alot. I'm sure they could help you too.