View Single Post
  #2   Spotlight this post!  
Unread 23-06-2002, 23:58
archiver archiver is offline
Forum Archival System
#0047 (ChiefDelphi)
 
Join Date: May 2001
Location: Pontiac, MI
Posts: 21,214
archiver has a reputation beyond reputearchiver has a reputation beyond reputearchiver has a reputation beyond reputearchiver has a reputation beyond reputearchiver has a reputation beyond reputearchiver has a reputation beyond reputearchiver has a reputation beyond reputearchiver has a reputation beyond reputearchiver has a reputation beyond reputearchiver has a reputation beyond reputearchiver has a reputation beyond repute
Re: Programming PBASIC for pneumatics

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.
__________________
This message was archived from an earlier forum system. Some information may have been left out. Start new discussion in the current forums, and refer back to these threads when necessary.