From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Sending data from Arduino Mega to NI MyRIO 1900

Hi friends,

 

I am working on a project where I need to send data collected via sensors from Arduino Mega and send the data to Ni MyRIO 1900.

 

How can I communicate between Arduino Mega and NI MyRIO 1900?

 

I have not tried it as I am new to MyRIO, so I do not have any code right now.

 

Kindly help me in this issue.

 

Thanks in advance.

0 Kudos
Message 1 of 4
(775 Views)

@Prashanthrkubasad wrote:

I have not tried it as I am new to MyRIO, so I do not have any code right now.

Hello, Prashan (forgive me for shortening your name).

 

The myRIO is a LabVIEW Real-Time device, running NI Real-Time Linux OS, and designed to be the Real-Time component of a LabVIEW Real-Time Project.  You can program it in LabVIEW, but you need to be doing the code development using LabVIEW Project.  You develop the LabVIEW code to be run on the myRIO using your PC running LabVIEW, with the Real-Time Module installed and with the myRIO Software Bundle also installed (you don't absolutely need to have this, but it has a lot of "simplifying" Express VIs for students and other newcomers to LabVIEW).

 

Do you have a mentor who has experience with the LabVIEW Real-Time Module and can help you get the software installed and the myRIO configured properly?  Has your myRIO been set up to work with your version of LabVIEW?

 

Which brings up a very important question -- what version of LabVIEW are you running?  You should be running the 32-bit version of LabVIEW in order to install the myRIO Software Bundle.  The Bundle also does not work with all versions of LabVIEW -- there is a Bundle that works (and is fairly easy to install) with LabVIEW 2019, and another bundle that works (and can be extremely difficult to install) with LabVIEW 2021, but none of the Bundles are compatible with LabVIEW 2020 or 2022.  

 

Bob Schor

0 Kudos
Message 2 of 4
(737 Views)

Hi Bob_Schor,

 

Thank you for your answer.

 

I am currently using LabVIEW version 2015, and I have installed the MyRIO bundle and I have done some basic coding by following the MyRIO project guide.

 

For my project, I am collecting both analogue and digital signals from 3 sensors using Arduino, and I have to connect the Arduino with MyRIO to send these signals. I have heard about UART connections. But I do not know how to do the connections.

 

I need assistance on connection and coding on both sides to send and read data.

0 Kudos
Message 3 of 4
(722 Views)

I hope you have a mentor who knows LabVIEW and some communication basics.  Try doing a Web Search for "Arduino Mega serial communication".  If that proves useful, also do one for "myRIO serial communication".  Do you know about UARTs?  I think you can make both the Mega and the myRIO function as a UART using 2 or 3 pins, so sending ASCII (strings) back and forth should be fairly simple.  I've been doing this long enough that I know about BAUD rate, Parity, 7- or 8-bit data, and # Stop bits (here's a hint -- N-8-1), and even remember when 57600 baud was considered really fast ...

 

Bob Schor

0 Kudos
Message 4 of 4
(706 Views)