View Single Post
  #6   Spotlight this post!  
Unread 16-01-2007, 19:12
Eric Finn's Avatar
Eric Finn Eric Finn is offline
Registered User
FRC #0166 (Chop Shop)
Team Role: College Student
 
Join Date: May 2006
Rookie Year: 2005
Location: Merrimack, NH
Posts: 101
Eric Finn has a spectacular aura aboutEric Finn has a spectacular aura about
Send a message via AIM to Eric Finn
Re: Need Help With General Pneumatics

You don't even need an if statement, it can be done in a single line:

COMPRESSOR = 1 - PRESSURE_SENSOR;
where COMPRESSOR is the compressor's output, and PRESSURE_SENSOR is the pressure sensor input.
__________________
It always takes longer than you expect, even when you take into account Hofstadter's Law.
--Hofstadter's Law