LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Separating data

Hello everyone

 

Iam not experienced labview user and i wanna know if there is a way to separate incoming data from microcontroller. Iam using sensor MPU6050 and i view the raw data using read buffer (https://imgur.com/a/UGcodJF) and i wanna know if there is some way to separate them one by one (for example Ax=20) and then use that separated data to make a chart/graph because as u can see using read buffer only show all of them together. Thanks in advance.

 

0 Kudos
Message 1 of 9
(1,119 Views)

I don't know what your data forma is (I can't open your link because my company blocks access to image sharing sites) 

 

But...

 

Most of the time data is separated by a comma or some other character.

 

Try using "spreadsheet string to array" and use that character as the delimiter.

========================
=== Engineer Ambiguously ===
========================
0 Kudos
Message 2 of 9
(1,090 Views)

I dont have data saved in spreadsheet, they are just being sent through serial port every second and what i want is to be able to acces them separately. So lets say i want to use acceleration data to create one chart and gyroscopic data as second chart and for that i need to tell which axis is which if u understand me.

0 Kudos
Message 3 of 9
(1,035 Views)

The image is useless for helping you.

 

The vi contains no typical data and is also useless. 

 

However, if you right-click the Read Data String indicator and select "Show Display format" you can easily change it to show the typical data in hex format or even in escape code Display.  This might give us a clue about how your device is sending data.  (Alternately, you could Read The F*ing Manual!)


"Should be" isn't "Is" -Jay
0 Kudos
Message 4 of 9
(1,028 Views)

@enjoyer_1 wrote:

I dont have data saved in spreadsheet, they are just being sent through serial port every second and what i want is to be able to acces them separately. So lets say i want to use acceleration data to create one chart and gyroscopic data as second chart and for that i need to tell which axis is which if u understand me.


Since you are hung up on the word "spreadsheet " you obviously don't understand what "spreadsheet string to array" does.

 

Read the spreadsheet string to array help

 

And consider this... Lets say your device sends four values separated by commas.

SS2ACapture.PNG

========================
=== Engineer Ambiguously ===
========================
0 Kudos
Message 5 of 9
(999 Views)

And when i want to add title to each number so i know what that number means? Because  now i have several numbers that are changing but "i dont know" what they stand for and is there a way i can add output to array so i can use the values to create multiple charts?

0 Kudos
Message 6 of 9
(937 Views)

Hi enjoyer,

 


@enjoyer_1 wrote:

And when i want to add title to each number so i know what that number means? Because  now i have several numbers that are changing but "i dont know" what they stand for and is there a way i can add output to array so i can use the values to create multiple charts?


Yes, you can do that…

 

When your message is always formatted in the same way you can put the numbers into a (typedefined) cluster.

When your message can vary you need to parse not just the numeric values, but also the string labels. Then use the label to set the correct value in your cluster…

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 7 of 9
(931 Views)

@enjoyer_1 wrote:

And when i want to add title to each number so i know what that number means? Because  now i have several numbers that are changing but "i dont know" what they stand for 


You question makes my think that you need to take some of the free training linked at the top of this forum because indexing an array not to mention labeling an indicator is pretty basic LabVIEW stuff.

 

BTW: You do know what data your device is sending you and what order it is being sent in don't you?

 


@enjoyer_1 wrote:

 and is there a way i can add output to array so i can use the values to create multiple charts?


I don't know what you mean by "add output to array".

========================
=== Engineer Ambiguously ===
========================
0 Kudos
Message 8 of 9
(922 Views)

Alright,  let's get some things straight before you waste any more of everyone's time here.

 

The MCU 6050 is a MEMS sensor that outputs 7 parameters.  3 Scaled accelerations with signed 16 bit resolution at 2,4,8 or 16 g full scale. 3 scaled signed 16 bit rotation values at 250, 500, 1000 or 2000 deg/s and a signed 16 bit value for temperature M=degC/340 B=35degC over an i2c bus.

 

You are using something like a ųProcessor to control gains, convert i2c to serial etc...and we don't know what it is, how it is programmed, whether it scales the outputs or even reformats them!

 

You have not yet shown us typical data received from your serial read nor discussed what ranges are selected on the MCU 6050.

 

Now, I seam to have a lot of good information about what you see and what questions need to be resolved to help you succeed in your development.   I used Google and RTFM for the MCU 60x0 MEMS chip.


"Should be" isn't "Is" -Jay
0 Kudos
Message 9 of 9
(911 Views)