LabVIEW Interface for Arduino Discussions

cancel
Showing results for 
Search instead for 
Did you mean: 

Bluetooth Serial Comm with Arduino Due

Hi,

I am trying to read data from my Arduino Due with Labview.

I am sending an array of bytes (size = 2) to labview.

Although, when reconstructing the bytes (using the Join Numbers VI) to the real value sometimes the order of the bytes is incorrect causeing an incorrect value. This is random.

What would be a simple say to make a handshake-like procedure in labview to so the proper order of the bytes is always received.

Please see my VI and Sketch.

J

Download All
0 Kudos
Message 1 of 4
(3,940 Views)

Look at how LIFA works.  It does exactly this (the command/response architecture).

0 Kudos
Message 2 of 4
(3,048 Views)

Thanks Nathan_B.

I have looked around LIFA a bit.

Would be able to point me directly to the VI that handles this, and does this command/response architecture require a specific sketch.

Thanks,
J

0 Kudos
Message 3 of 4
(3,049 Views)

The command/response architecture is simply a concept.  You send a command from LabVIEW to Arduino.  Arduino sends a response back to LabVIEW.

In a simple implementation of this architecture, you need to always know ahead of time exactly how many bytes the Arduino will send back so you can simply wait for that number of bytes to appear in the serial buffer.

You'll have to look at the firmware to understand it completely but the workhorse on the LabVIEW side is the Send Receive VI (IIRC).

0 Kudos
Message 4 of 4
(3,049 Views)