Thread: Relay Trouble
View Single Post
  #3   Spotlight this post!  
Unread 20-01-2011, 08:19
Steve Warner Steve Warner is offline
Controls / Programming
FRC #0234 (Cyber Blue)
Team Role: Mentor
 
Join Date: Feb 2006
Rookie Year: 2006
Location: Indiana
Posts: 41
Steve Warner is an unknown quantity at this point
Re: Relay Trouble

Right now the code to define a relay looks like this:

Relay *abcRelay;

abcRelay = new Relay(3);

The first line is globally defined and the second line is in a function called Init_Controls which is called from IRobot which is the constructor for the IterativeRobot class. Until I just checked the code, I was thinking that Init_Controls was called from RobotInit so this might be part of the problem but digital_inputs and solenoids are defined in the same function and work fine. It is the addition of the second line that kills the code.
Reply With Quote