From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Timing on Oscilliscope

Hi Folks.

 

I am having a timing issue with my oscilliscope (Rigol DS1052E) being programmed with Labview. In the "Automated Function Generator" VI everything works fine. The commands are sent to the function generator (TTi TG2000) and I can view the waveform changes smoothly on the oscilliscope. When I add the functionality to read the Oscilliscope into Labview the problem occurs. The signal appears and dissapears instead of being constant. The waveform graph on the front panel is consistant, but it is only representing the data that is displayed momentarily on the scope. Why am I getting the blank screen and how can I make the signal appear consistant. Is this an issue with my coding or is there any known issues with Rigol data aquisition??

 

Thanks,

 

Mark.

0 Kudos
Message 1 of 8
(3,111 Views)

Your problem is likely that Autosetup call that you are doing each loop iteration.  Especially with instrument communications, you should do all of your setup once, before the loop.  Also, you should do the cleanup (closing) once after the loop.  So move all of your initialization code to be before your loop and all of the closing to be after the loop.  So all you should have inside of your loop is the VISA Write and the Read Single Waveform.

 

A couple of additional notes:

1. There is no real point to the FOR loop.  You should just get rid of it.

2. You really should stop your loop when there is an error.

3.  Make sure you are closing all of your VISA references.


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 2 of 8
(3,101 Views)

I made all the changes you recommended (in attachment) but I still have the same problem. I can frequency changing then the signal disappears for about 2 seconds. This all happens within the loop. I have tried adding a few delays but this just exaggerates the problem.

0 Kudos
Message 3 of 8
(3,090 Views)

I do not have those Rigol drivers, but it is sounding like that function is doing something with the screen.


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 4 of 8
(3,074 Views)

I viewed a demo online which shows the oscilliscope to. It also was jumping. It must be something to do internally when it recieves a command. Annoying but I will get by.

0 Kudos
Message 5 of 8
(3,064 Views)

Maybe it's set up to accomplish "continuous" by doing continuous single triggers?

Bill
CLD
(Mid-Level minion.)
My support system ensures that I don't look totally incompetent.
Proud to say that I've progressed beyond knowing just enough to be dangerous. I now know enough to know that I have no clue about anything at all.
Humble author of the CLAD Nugget.
0 Kudos
Message 6 of 8
(3,060 Views)

Just downloaded the drivers and did a little digging.  The Read.vi calls an Initialte and then waits 2 seconds before getting the waveform.  I'm willing to bet that this is what is causing your screen to go away.  You should be able to call the Low Level->Fetch Waveform.vi on its own as long as the scope is set to continuously acquire.


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
Message 7 of 8
(3,057 Views)

I was thinking that myself. For the moment I am just going to wait until the signal stabalises but if things are running too slow I might change this.

 

Thanks for the advise.

0 Kudos
Message 8 of 8
(3,047 Views)