LabVIEW Interface for Arduino Discussions

cancel
Showing results for 
Search instead for 
Did you mean: 

Arduino control threw wifi

im working on a side project for my current FIRST Robotics Team. 3146.

we are a reletivly new team, and i am new to this team. but right now we are using an RC controller to prototype without the crio, i know there is the openrobot controller out there but i am looking for something that is quick and easy to change between labview for crio and the arduino.

I have a wifi dongle for the arduino and i have been working with it for a while, the RN-XV. looks like a zigbee but its wifi. i was wondering if i could get Labivew to communicat threw the dongle rather than the usb port?

to be compleatly honnest i havent put much thought into this yet, but i would like some help its one of thoes last minute ideas.

To break it down, how would i go about running the labview interface for arduino threw wifi?

and how can i program in an "E-stop" condition.. EX loss of signal stop all motors. insted of with RC controllers it just sends a bad signal and it can do whatever it wants.

0 Kudos
Message 1 of 3
(4,838 Views)

Hey jchalo99,

I don't think this is a great use case for LIFA - at least without some major changes. The latency between the Arduino and the computer is prohibitive for high speed control applications- since you have to send a command and then wait for a response. You would want to make it so that a lot more of the control was done on the Arduino side- which would require some major changes to the framework. I also don't think you are going to gain the benefits you are looking for - since the LabVIEW Code you would write to use with LIFA is not going to work in the FRC framework.  Post back if you have questions.

Kevin Fort
Principal Software Engineer
NI
0 Kudos
Message 2 of 3
(2,802 Views)

Our robotics group are in the process of developing a teleoperation method to control our robot. Our constraint for communication is to ONLY use the 802.11 b/g standard. NO bluetooth or RF signals like (900MHz).

SO, we initially interfaced our arduino with LabView using LIFA, and also our Logitech Gamepad F310. Using the "winmm.dll" we made a call to the winmm.dll library using the "Call Library Function Node" block in LabView. Modifying the example VI "Arduino Servo.vi", we converted the analog joystick (thumbsticks left and right) values to the correct angles and wired them to our arduino "Servo Write Angle" function blocks in LabView. Now that our teleop code is practically done, we now need to communicate wirelessly to our arduino.

Our idea was to use the "server.vi" and "client.vi", server being the arduno and the client being our computer to send packets via Wifi to the arduino (servo number, server angle, etc). I read Kevin_F's post above and seen that this would be insufficient if we want fast data transmission, i believe on the website we can use the Xbee Wifi transmitter (cannot use bluetooth) which has a transmit loop rate of 25Hz to tether our arduino wirelessly to LabView. We are very sad if we cannot use LabView because now we have to delv into our cprogramming skills and code all of our sensors and what not with Arduno's environment.

I am now thinking we need to totally eliminate LabView and set up two routers with DD-WRT, import the pygame library which will allow for us to not only map our Logitech Gamepad F310 but also send packets to a router with corresponding servo number, angle to write and identification ID. (example: http://principialabs.com/joystick-control-of-a-servo/)

Without the pygame library, I haven't found anywhere on how to include the winmm.dll library to map out our logitech gamepad connected via USB with c programming language. I have seen examples in C++ and C# but none of just C.

Please tell me i am misunderstanding something, because i would really like to develop our project with LabView.

0 Kudos
Message 3 of 3
(2,802 Views)