View Single Post
  #7   Spotlight this post!  
Unread 11-02-2008, 12:04
Kingofl337's Avatar
Kingofl337 Kingofl337 is offline
You didn't see anything....
AKA: Adam
FRC #0501 (Power Knights)
Team Role: Mentor
 
Join Date: Feb 2005
Rookie Year: 1998
Location: Manchester, NH
Posts: 861
Kingofl337 has a reputation beyond reputeKingofl337 has a reputation beyond reputeKingofl337 has a reputation beyond reputeKingofl337 has a reputation beyond reputeKingofl337 has a reputation beyond reputeKingofl337 has a reputation beyond reputeKingofl337 has a reputation beyond reputeKingofl337 has a reputation beyond reputeKingofl337 has a reputation beyond reputeKingofl337 has a reputation beyond reputeKingofl337 has a reputation beyond repute
Send a message via Yahoo to Kingofl337
Re: Automated Air Compressor code

From the help file....

Use the Pressure Switch block to automatically regulate a compressor in a pneumatic system.

The Pressure Switch function should be called a single time prior to your use of the compressor in a pneumatic system. The best place to use this block may be in 'Initialize'. The function will automatically monitor the state of the pressure switch (every 500ms), and will activate the spike to power the compressor whenever the pressure switch closes (at about 95 psi). The compressor will stop when it reaches it's maximum pressure of 115 psi.

edit: Also Alan if you read my earlier post

Quote:
You don't need both, you only need to call InitPressureSwitch(psInput, psRelay); in the Initialize function.

It will take care of everything after that.
My post you quoted made more sence.
__________________
FIRST Team 501 PowerKnights - Mentor
FIRST Team 40 Checkmate - Mentor Alum
FIRST Team 146 Blue Lightning - Alumni

Last edited by Kingofl337 : 11-02-2008 at 13:11.