LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

arduino and myRIO

Solved!
Go to solution

Hi everyone
i am wondering if there is any way to connect an arduino with myRIO.
i want to send sensors values from arduino to myrio
i tried to use UART in labview to receive the signals out from arduino to myRIO but myRio didn't read them.
is anyone could help me?

0 Kudos
Message 1 of 4
(2,348 Views)
Solution
Accepted by topic author OmarFTL

Have you tried just plugging the USB into it?  I don't have a myRIO but have other Linux RT devices and they enumerate most USB serial devices on start and it should show up as a VISA device.  You should then be able to communicate to it using normal VISA Read/Write operations like you would in Windows.  There is a Simple Serial example in Help >> Find Examples that shows some of the basics.  Otherwise UART should work but again I don't actually have the hardware to play with.

0 Kudos
Message 2 of 4
(2,338 Views)

i asked the same question on arduino community but also no one has the wanted answer

if i connect tx of myrio with rx of arduino and vice versa 
is there anything more i should do?
they told me i have to connect GND but i dont know which one in myrio i should connect

0 Kudos
Message 3 of 4
(2,293 Views)
Solution
Accepted by topic author OmarFTL

Which sensor and which Arduino?

 

My preferred solution is to try and connect the sensor directly to the myRIO and skip the microcontroller.

 

If you still prefer to use the Arduino, you can in fact just use the USB serial connection, unless you have a webcam or thumbdrive there already.  Just plug it in and look in the /dev/serial/by-id directory for you device.  If you have a sketch with prints to the serial port you can install the screen package 'opkg install screen' and then test it using 'screen /dev/serial/by-id/<serial id> <baud>'.  

 

You can also use SPI, I2C, or UART to connect the two.  Here you need to beware that the myRIO is a 3.3V device and many Arduinos are 5V.  You either need to use a level shifter or choose a 3.3V Arduino.  I like the SparkFun BlackBoard, it uses the FTDI USB chipset which I prefer and has a jumper to select 3.3V operation.  Of course your sensor may be a 5V device, in that case I'd just use a level shifter between the myRIO and Arduino.  Again, SparkFun makes a cheap 4-channel level shifter which I use a lot.

0 Kudos
Message 4 of 4
(2,283 Views)