LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How to trigger a signal generator to start outputting signals from labview

Hello,

I have a setup with a BNC-2090/PCI-6143 currently hooked up to a Rigol DG972 signal generator from the PFI0/TRIG 1 port on the 2090. I have been trying to use labview to send a signal to the signal generator to trigger it to start generating a signal so that I can synchronize the start of the signal with the start of measurements for several other devices I have connected to the BNC-2090's analog input ports. However, I am very new to labview and do not know how to accomplish this task within the program or even which port I need to connect the signal generator to. Is doing this even possible, and if so, what is the way I would do this?

-Stongduke

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

Well I could not find a prebuilt LabVIEW "driver" for that device, so you are going to have to make your own.

 

FYI: Most LabVIEW drivers are simply a set of VIs the manufacture made that use SCPI commands and VISA. That's what you are going to have to do using the SCPI commands in the DG900 Programming Guide

 

I just skimmed the programming guide and there is a (rather poor) LabVIEW programming example in Chapter 4.

 

Study the programming guide and try a few things. If you still are having problems come back and show us what you tried and what didn't work.

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

Hi RTSLVU,

Do you think the example to create drivers in this guide you shared can be used for any NI device?

 

https://beyondmeasure.rigoltech.com/acton/attachment/1579/f-08aa/0/-/-/-/-/DG900_ProgrammingGuide_EN...

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

@GRCK5000 wrote:

Hi RTSLVU,

Do you think the example to create drivers in this guide you shared can be used for any NI device?

By NI device do you mean LabVIEW version? The example is for LabVIEW 2009, but it's pretty basic (you are just sending text [SCPI commands] using VISA) so the example should work for any LabVIEW version.

 

 

========================
=== Engineer Ambiguously ===
========================
0 Kudos
Message 4 of 9
(1,760 Views)

Not labview version.I meant NI device like cdaq 97xx, etc...

0 Kudos
Message 5 of 9
(1,723 Views)

@GRCK5000 wrote:

Not labview version.I meant NI device like cdaq 97xx, etc...


All NI Instruments use proprietary driver APIs and do not use VISA or SCPI commands such as the third-part bench instruments. You need to familiarize yourself with the appropriate driver for that instrument in order to use it, for example, for the cDAQ stuff you need to use the DAQmx driver APIs to control.

Santhosh
Soliton Technologies

New to the forum? Please read community guidelines and how to ask smart questions

Only two ways to appreciate someone who spent their free time to reply/answer your question - give them Kudos or mark their reply as the answer/solution
0 Kudos
Message 6 of 9
(1,720 Views)

Thanks Santos! This answered my question. I want to know  if from the link you shared, section 4-9 to 4-15. Can I follow this example to build a driver for a third party instrument?

 https://beyondmeasure.rigoltech.com/acton/attachment/1579/f-08aa/0/-/-/-/-/DG900_ProgrammingGuide_EN...

0 Kudos
Message 7 of 9
(1,697 Views)

@GRCK5000 wrote:

Thanks Santos! This answered my question. I want to know  if from the link you shared, section 4-9 to 4-15. Can I follow this example to build a driver for a third party instrument?

 https://beyondmeasure.rigoltech.com/acton/attachment/1579/f-08aa/0/-/-/-/-/DG900_ProgrammingGuide_EN...


I cannot generalize it as just any third-party instrument, most leading instrument manufacturers adhere to the SCPI syntax which can be implemented using VISA, and some manufactures provide a proprietary dll to communicate with the instrument.

 

In sections 4-9 to 4-15, the implementation looks like a simple UI event handler, I don't see a value compared to the Interactive VISA debug screen.

In addition, I would always recommend watching this tutorial - https://labviewwiki.org/wiki/VIWeek_2020/Proper_way_to_communicate_over_serial

 

Santhosh
Soliton Technologies

New to the forum? Please read community guidelines and how to ask smart questions

Only two ways to appreciate someone who spent their free time to reply/answer your question - give them Kudos or mark their reply as the answer/solution
0 Kudos
Message 8 of 9
(1,692 Views)

SCPI was an attempt to standardize instrument communications.

 

So in theory SCPI commands for one manufacturers sig-gen should work on another manufacturers sig-gen.

 

But it is a voluntary standard so don't count on it always being so.

 

Specially when you get into advanced commands and options that one device may have that the other doesn't...

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