LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Separate serial string byte by byte

Solved!
Go to solution

Hi,

 

This is my first post and only started using labview yesterday so please excuse if it sound a little dumb. I have connected an arduino through labview and sent data to it and had data sent back. I can get it to plot it to a a waveform chart of this data. However I am making the arduino send sensor data iteratively. I have 8 sensors so each byte that comes through will be the data for a new sensor, after the eighth sensor it will again start at sensor one and repeat the process. I need to separate this data and put it into eight different arrays but am not sure how to do this correctly.

 

Any help is greatly appreciated.

 

Thanks

 

 

0 Kudos
Message 1 of 3
(3,256 Views)
Solution
Accepted by Canalian

Hi Canalian,

 

convert your string from VISARead to an U8 array and decimate that array into 8 subarrays:

check.png

Now you have each sensors data seperated in its own array and you can do with it whatever you want.

Well, you could also use StringSubset to get each byte for it's own...

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
Message 2 of 3
(3,234 Views)

Hi GerdW,

 

Thanks heaps for the help

 

really appreciated.

 

 

0 Kudos
Message 3 of 3
(3,206 Views)