|
NEED HELP with Delay loop for compressor relay switch
Posted by Erik at 03/12/2001 11:54 AM EST
Engineer on team #381, Trenton Tornados, from Trenton High School and Princeton University.
I am trying to write a delay loop in the default program for the robot controller, and I would like to know if anyone can help me understand how to turn off the relay switch by setting it to 1 or 0. what I really want to know is how to put in a delay using a conditional statement I suppose. Code snippets would be much appreciated. I think I have the idea but here is my pseudocode:
delay VAR word
delay = 0;
mainloop{
when switch opens up then{
delay = delay + 1;
if delay
__________________
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.
|