Chief Delphi

Chief Delphi (http://www.chiefdelphi.com/forums/index.php)
-   NI LabVIEW (http://www.chiefdelphi.com/forums/forumdisplay.php?f=182)
-   -   initializing multiple joysticks (http://www.chiefdelphi.com/forums/showthread.php?t=100008)

tilky 13-01-2012 07:54

initializing multiple joysticks
 
i have always been programming two joysticks (or more) my opening them on the teleop block diagram, and then setting which usb right there. However, i recently found out that you are supposed to initialize them in the begin vi. However, i'm not sure if you can initialize different ones, with RefNames as Joystick 1, Joystick 2...and then refer to the in the teleop with the same name. We've been having some difficulties with our robot and there is no way to know if this is the proper way.

Greg McKaskle 13-01-2012 08:47

Re: initializing multiple joysticks
 
The framework code does it the recommended way. It opens a joystick in begin, stores it with a name, and then teleop and other location can do a name lookup. This was introduced a few years ago and is used extensively to cut down on the number of parameters that need to be added. I'd recommend going through the sample code and adding your second joystick and getting that to work.

Greg Mckaskle


All times are GMT -5. The time now is 09:31.

Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi