View Single Post
  #3   Spotlight this post!  
Unread 02-25-2016, 12:52 PM
FRC3220 FRC3220 is offline
Registered User
no team
 
Join Date: Feb 2016
Location: Spangle
Posts: 11
FRC3220 is an unknown quantity at this point
Re: Controlling motors with spike relays

I tried that, and it still didn't work. I have a solenoid mapped to the y-axis of the same joystick. Our builders built an excavator-like arm, and they want to be able to pick it up with the y-axis of the joystick, and rotate it with the x. The solenoid works, but the relay still doesn't. Is there any way that one is interfering with the other? Here's my TeleOp Periodic Code for the rotation motor:
Code:
 
     double joystick2X;
     joystick2X = stick2.GetX();
     if (joystick2X > 0.1)
        {arm_rotator.Set(Relay::kForward); }
     else if (joystick2X < -0.1)
        {arm_rotator.Set(Relay::kReverse); }
Reply With Quote