|
|
|
![]() |
|
|||||||
|
||||||||
![]() |
| Thread Tools | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
Multiple Joystick Help
I am trying to figure out tank drive for our robot and whenever I try to open a new joystick on Begin.vi it changes the USB port on the 1st joystick as well. I have tried changing the name of the joystick, but it changes both of them when I do. Please help me!
|
|
#2
|
||||
|
||||
|
Re: Multiple Joystick Help
what you have to do is open two under begin vi, with a different name for each. Under teleop, you use two get refnames (one for each).
|
|
#3
|
||||||
|
||||||
|
Re: Multiple Joystick Help
It sounds like you are changing the the values on the front panel of the joystick open vi, rather then wiring a constant into the joystick open input in begin.vi.
|
|
#4
|
|||
|
|||
|
Re: Multiple Joystick Help
All you need to do to configure tank drive is open teleop.vi, change out the Arcade drive block for Tank drive (WPI Library>Robot>Tank Drive), and wire in the second joystick.
|
|
#5
|
|||
|
|||
|
Re: Multiple Joystick Help
DominckC,
So, for a total noob with NO programming experience, I'm the mechanical coach, what would the diagrams look like? I found the Tank Drive block. |
|
#6
|
|||
|
|||
|
Re: Multiple Joystick Help
Anyone awake?
![]() |
|
#8
|
|||
|
|||
|
Re: Multiple Joystick Help
Thanks Mark,
If we get snowed in tomorrow I'll give it a try then. |
|
#9
|
||||
|
||||
|
Re: Multiple Joystick Help
Quote:
Mark, your section for the Begin VI is missing a pair of joystick open and set joystick reference VIs. |
|
#10
|
|||||
|
|||||
|
Re: Multiple Joystick Help
Quote:
I use the series for teaching and the students are expected to learn to apply prior examples in building block fashion to subsequent examples. Also, for brevity's sake subsequent examples don't repeat all the prior examples. Otherwise it gets very unwieldy in later compound examples and loses the independent point each is trying to make. It's a teaching style choice. Last edited by Mark McLeod : 17-01-2012 at 08:43. |
|
#11
|
|||
|
|||
|
Re: Multiple Joystick Help
My problem is in the begin.vi. When I open them the refnames change simultaneously, so that when I change one the other changes as well.
|
|
#12
|
|||||
|
|||||
|
Re: Multiple Joystick Help
Did you create the new joystick from scratch or copy it somehow?
Do you know how to get the wirespool cursor when you hover over the name node, right-click and choose Create -> Constant? |
|
#13
|
|||
|
|||
|
Re: Multiple Joystick Help
At first I was trying to copy and paste, but then once I created it from scratch they still seemed to be linked. I have tried Create -> Constant as well.
|
|
#14
|
|||||
|
|||||
|
Re: Multiple Joystick Help
What exactly do you mean by "open them"? It might help to show us your code.
|
![]() |
| Thread Tools | |
| Display Modes | Rate This Thread |
|
|