LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

how can i control my sb-rio with scpi command

Good morning,

 

I expose to the usual situation: normally, it uses labview in order to program instruments, suppose that our instrument is an osculloscope, the usually thing, is that we use LabVIEW to control throught SCPI commands said oscilloscope. do not?

 

But now, if I have a sb-RIO with a FPGA where I have deployed a .vi cretated in labVIEW. Now our instrument is the sb-rio, ergo, our instrument is Labview already.

 

How could we control through an instrument through the putty or VISA.

 

Is there a way for LabVIEW to send the answer to a scpi command question?

 

i don't know if I explained well.

 

Thanks you.

0 Kudos
Message 1 of 10
(3,251 Views)

Hi cristina,

 

you could write your own SCPI parser in LabVIEW and have your sbRIO handle such SCPI requests as needed…

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 2 of 10
(3,246 Views)

How Can I do this?

 

Is there any docummetion of this?

 

 

Thanks.

0 Kudos
Message 3 of 10
(3,243 Views)

Hi cristina,

 

using Google you surely will find a lot of SCPI documentations…

 

But why do you insist on using SCPI?

You could use any kind of network communication between your sbRIO and a LabVIEW host program running on a usual PC! And LabVIEW comes with a lot of example VIs and projects explaining how to do such communication…

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 4 of 10
(3,225 Views)

I don't find in google how to do my own parser SCPI in Labview, I find how to do in C for example, but not in Labview.

 

 

0 Kudos
Message 5 of 10
(3,223 Views)

Hi cristina,

 

so you have an example written in C: all you need to do is to recreate that in LabVIEW…

It's a nice task, you will surely learn/improve your LabVIEW skills! 😄

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 6 of 10
(3,214 Views)

Ok....

 

 

But my doubt is how i can recreate that in LabVIEW .....

😉

0 Kudos
Message 7 of 10
(3,211 Views)

1. Setup a TCP/IP listener loop on the SB RIO.

2. Learn how to receive commands from the TCP/IP Read, preferably using the CRLF ending option.

3. Learn the functions in the String palette.  You might want to really look at Scan From String and Search/Split String.

 

Once you have the data, it is all in how you parse it.  You can even test that offline.


GCentral
There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5
0 Kudos
Message 8 of 10
(3,202 Views)

I want to do the communication with serial port, no with TCP/IP

 

Could i do the same with serial port communication?

 

 

Thanks.

0 Kudos
Message 9 of 10
(3,199 Views)

@cristina.lopez wrote:

I want to do the communication with serial port, no with TCP/IP

 

Could i do the same with serial port communication?


That can work just as well.  Learn to use the VISA functions and properly use the termination character.


GCentral
There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5
0 Kudos
Message 10 of 10
(3,195 Views)