My i’m trying to wire up a spike relay to a digital in and out, but it happens to only go in one direction (remember digital is only a 1 or a 0), im thinking i should split a PWM cable and set the black as a shared ground between two digital i/o, and the red going to one digital i/o and the white going to another digital i/o. Is this right?
Whats your opinion? Or if i’m totally wrong, whats the correct method to wiring a spike relay to a digital i/o?
The Spikes aren’t PWMs, they just use a PWM cable. You can figure it out looking at the program aliases. At any rate, on the relay’s PWM cable, black is black/ground, red is reverse, white is forward. So you’d connect the red cable to the white pin of a second digital IO.
Your assumption is correct on how to wire it, but might not necessarily work. I have had problems with vex controllers driving spikes before (but only certain spikes - the old style blue’s IIRC), where the digital IO wasn’t able to source enough current, so you might need to try the solenoid outputs if it doesn’t work. Double check that the output of the Darlington pair on the solenoid outputs is 5V though, and not 7.2.
Edit: after thinking about it, if you can get it to go one direction, then you likely won’t have the probelm I was having, and wireing it the way you said should work. Too much time at work and then in the robot lab tonight for me.
Dont worry about that 7.2v part, i have a breaker panel wired up to a 12 volt battery. The EDU-RC will be powered using the 7.2 battery.
I think splitting the PWM into two parts would work… About that shared ground… Should i just stick a wire in to the pwm connector (on the black female pin) and solder it, then do the same to the 2nd pwm connect? I’m afraid i might short something :-/
Ground is ground is ground is ground. All those little black pins go to the exact same place and have the (nearly) exact same potential, barring odd very small resistance and capacitive effects, I suppose. So you shuldn’t really have to worry about splitting the ground and sending it somewhere else.
Hmm. Do you know if it’s the red wire that’s not working or is it the white wire that’s not working? That is, make the white wire IO = 1, and the other = 0 and see if it still works in that direction. If it doesn’t then your wiring might be faulty somewhere. If it works in that direction but not the other, then your wiring of the red wire might be bad.