Ok so i have looked at the threads and i found everyone of them to be similar to what i am asking and if it was what i was asking they didn't help much. So i am going to explain thoroughly. I want to have the 2 Triggers on the 2 joysticks controlling 1 relay to go forward when Button 1 of joystick 1 is pressed and reverse when Button 1 of joystick 2 is pressed and Neutral when none are pressed.

What i have done was unbundle both joystick buttons. Wired both button 1 of both Joysticks to their Seperate "select" function(T/F). Created a forward constand and wired it to the True statement of the select function and off for the false statement for the joystick 1. I did the same for joystick 2 but instead of forward i did reverse. i wired the right ends of both of the "Select" functions to a "or" Statement and wired them to the Relay set box.

I thought this would work but the relay doesn't reverse. it only goes in 1 direction.
Can anyone tell me why?

<added info>
I also looked at the digital sidecar and the relay light turns red when i push 1 trigger and the relay turns green when the other is pushed but the relay does not turn green just red

a3aperez

01-29-2009, 08:18 PM

Make sure you are using the right constants.

From the Set Relay help:

RelayValue specifies whether the relay is configured to move the motor in a forward or reverse direction.

Off (0) (Default) Specifies that the motors are off.

On (1) Specifies that the motors are on.

Forward (2) Specifies that the relay moves the motors in a forward direction.

Reverse (3) Specifies that the relay moves the motors in a reverse direction.

Burmeister #279

01-29-2009, 09:06 PM

i'm not sure if this is the actual problem, and as i don't have labview on this computer, i have no screen shots, however, there might be a problem if it's confusing itself due to both being pressed. if you have a case structure around the entire area where you deal with the buttons, and then wire an XOR gate [Boolean pallet] into the case selector, and both buttons into the XOR. this will eliminate any problems with both buttons being pressed. after that, in the true portion of the case, have a second case structure to find the state of the first button. if it's true, then set the value of the relay you are changing, if it is false, use another case structure inside of the false case of the previous one to check for the second button.

AIM: Burmeister 279

I changed my mind and my computer and here's my example of what to do. the XOR is a special logic gate that makes only lets it work if one and ONLY one input is true.

need any more help : burmeister.twosevennine@gmail.com subject: programming help

starsROBOTICS

01-29-2009, 10:05 PM

i'm not sure if this is the actual problem, and as i don't have labview on this computer, i have no screen shots, however, there might be a problem if it's confusing itself due to both being pressed. if you have a case structure around the entire area where you deal with the buttons, and then wire an XOR gate [Boolean pallet] into the case selector, and both buttons into the XOR. this will eliminate any problems with both buttons being pressed. after that, in the true portion of the case, have a second case structure to find the state of the first button. if it's true, then set the value of the relay you are changing, if it is false, use another case structure inside of the false case of the previous one to check for the second button.

AIM: Burmeister 279

I changed my mind and my computer and here's my example of what to do. the XOR is a special logic gate that makes only lets it work if one and ONLY one input is true.

need any more help : burmeister.twosevennine@gmail.com subject: programming help

Dude not to be rude but you need to better explain things. That was the most confusing thing i read all day.

starsROBOTICS

01-29-2009, 10:12 PM

Make sure you are using the right constants.

From the Set Relay help:

RelayValue specifies whether the relay is configured to move the motor in a forward or reverse direction.

Off (0) (Default) Specifies that the motors are off.

On (1) Specifies that the motors are on.

Forward (2) Specifies that the relay moves the motors in a forward direction.

Reverse (3) Specifies that the relay moves the motors in a reverse direction.

Ok instead of specifying 1,0,2, or 3 i right clicked the left side of the relay terminal and created a constant. I put the constant to the left of the select and wired it to the true statement. Would that be okay or does it have to be a numeric value as in 1,2,3, or 0?

a3aperez

01-30-2009, 12:21 AM

Ok instead of specifying 1,0,2, or 3 i right clicked the left side of the relay terminal and created a constant. I put the constant to the left of the select and wired it to the true statement. Would that be okay or does it have to be a numeric value as in 1,2,3, or 0?

Here's a VI with what I understood you wanted to do.
http://www.filedropper.com/tworelaytwojoysticksforwardreverse