Thread: Bs2
View Single Post
  #8   Spotlight this post!  
Unread 08-07-2002, 23:12
rbayer's Avatar Unsung FIRST Hero
rbayer rbayer is offline
Blood, Sweat, and Code
no team (Teamless Orphan)
 
Join Date: Mar 2002
Rookie Year: 2001
Location: Minnetonka, MN
Posts: 1,087
rbayer is a glorious beacon of lightrbayer is a glorious beacon of lightrbayer is a glorious beacon of lightrbayer is a glorious beacon of lightrbayer is a glorious beacon of light
Send a message via AIM to rbayer
that is correct, you only need to declare the Input and Output once. As far as I can tell, the code looks right to me. If I understand it right, as soon as the pressure falls below the minimum, the pump will turn on and stay on until it reaches maximum. At that point, it will stay off until it drops below the minimum again. Correct? The only thing you might want to do is initialize all your variables (including out2) before starting the main loop.
__________________
New C-based RoboEmu2 (code simulator) available at: http://www.robbayer.com/software.php