LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Get continuous data in excel file from Instrument device using USB-RS232

Hi Intern,

 


@InternlABVIEW wrote:

I was thinking of getting 8 data rows for 8 different channels which will runs with 8 specific command 😅


Read the manual of your device!

When it only offers the WF8readall command then you need to use exactly that command.

When it offers a command to read specific channels then you should use that…

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 11 of 54
(1,939 Views)

Yes I know that.  But how do I arrange or which function do I use in labview to do that 8 rows or send specific command to do that 8 rows? I think, I can’t just use just 1 visa write function to write 8 different commands  to 8 different row. And which function to use to make 8 rows and send 8 different commands continuously. 

0 Kudos
Message 12 of 54
(1,931 Views)

Hi Intern,

 


@InternlABVIEW wrote:

I think, I can’t just use just 1 visa write function to write 8 different commands  to 8 different row. And which function to use to make 8 rows and send 8 different commands continuously. 


Sure you can use just one VISAWrite to send different commands! Just use a loop to iterate over an array of commands!

Additionally your loop will also create an array of responses just by employing autoindexing!

 

This is very basic LabVIEW stuff: it seems you should take those "Training resources" offered at the top of the LabVIEW board!

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 13 of 54
(1,929 Views)

Ok thanks. I will check and let’s see how does it go. I am currently stuck in sending ASCII to the device but the device is not responding. I tried send command using visa write. But no response from the device. Am I doing something wrong?

0 Kudos
Message 14 of 54
(1,908 Views)

Hi Intern,

 


@InternlABVIEW wrote:

I am currently stuck in sending ASCII to the device but the device is not responding. I tried send command using visa write. But no response from the device. Am I doing something wrong?


The answer is "Probably yes!"…

As you didn't show your VI we cannot tell you, if and where you went wrong!

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 15 of 54
(1,899 Views)

I am currently using this VI to check those command to device but no luck so far. It is one of the example from Labview.

0 Kudos
Message 16 of 54
(1,917 Views)

Hi Intern,

 

have you tried to change the TermChar, maybe to 0xD (aka CR aka \r)?

Which commands to you try to send?

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
Message 17 of 54
(1,901 Views)

I tried to send command in normal window and Hexa and \n. In the manual it’s says I have to send ASCII uncoded command into to string format. 

0 Kudos
Message 18 of 54
(1,889 Views)

Any modifications  need to do in Visa Write to send command to device which need to be ASCII encoded command in string format to the device.

0 Kudos
Message 19 of 54
(1,832 Views)

Hi,

 

I am currently using USB-RS232 to get data from the instrument device. However all the data are coming as a

 

26/07/2021 2:43 PM CH2,RTD,-1809.400

26/07/2021 2:43 PM CH3,RTD,-1809.400

26/07/2021 2:43 PM CH4,RTD,-1809.400

26/07/2021 2:43 PM CH5,pH_,0.000

26/07/2021 2:43 PM CH6,pH_,0.000

26/07/2021 2:43 PM CH7,pH_,0.000

26/07/2021 2:43 PM CH8,pH_,0.000

 

How do I put those data according to the channel number every time in different rows. For example, 8 channel data in 8 different rows every time.

The code, I am currently using as follows.

0 Kudos
Message 20 of 54
(1,822 Views)