|
|
|
![]() |
|
|||||||
|
||||||||
![]() |
|
|
Thread Tools | Rate Thread | Display Modes |
|
|
|
#1
|
||||
|
||||
|
Relay Signal not working
We are having problems with our relays. We used to having our relays working, but they have all suddenly stopped working, on both different robots.
The spike is getting power, as there is the LED indicator is orange. The brand new VEX Pro spike is connected to our compressor, with the PWM Cable running to Relay 3 on the digital sidecar. We have the ribbon cable running form the digital sidecar to the module in slot 2 on the cRio, with the terminal screws in. The code on for the spike is as follows. The code below is only for the spike and the joystick. Code:
class RobotDemo : public IterativeRobot
{
Relay *manualCompressor;
Joystick *primaryController;
public:
RobotDemo(){
manualCompressor = new Relay(3);
primaryController = new Joystick(1);
}
void RobotDemo::TeleOpPeriodic(){
if(primaryController->GetRawButton(6)){
manualCompressor->Set(Relay::kForward);
}
else if(primaryController->GetRawButton(5)){
manualCompressor->Set(Relay::kReverse);
}
else{
manualCompressor->Set(Relay::kOff);
}
}
We have no idea what is wrong with our relays, and would really appreciate some help and ideas. Thanks, |
|
#2
|
|||||
|
|||||
|
Re: Relay Signal not working
Is some other part of your code trying to control Relay 3 at the same time?
|
|
#3
|
|||
|
|||
|
Re: Relay Signal not working
I'd say that it's probably some slip of the mind of your electrical guy (I have many.) Just make sure that 1. Your cable is connected to relay three counting up from 1 (parallax makes it hard to be sure) 2. Your signal is in the correct direction (check with a voltmeter) 3. Your cable has continuity for each of the respective pins (check with an ohmmeter or with a known good PWM cable) 4. Your cable is wired correctly, make sure the connector isn't flipped (simple mistake but easy fix.)
Good luck |
|
#4
|
|||
|
|||
|
Re: Relay Signal not working
Quote:
Quote:
|
|
#5
|
|||||
|
|||||
|
Re: Relay Signal not working
What lights are lit on the Digital Sidecar when you're trying to set the relay Forward? When you're trying to set the relay Reverse?
What is the big orange Robot Signal Light doing throughout the process? |
![]() |
| Thread Tools | |
| Display Modes | Rate This Thread |
|
|