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.

LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

Define ACQUISITION_START_TIME to Tektronix DPO3034

Solved!
Go to solution
Hello,

I'm trying to define ACQUISITION_START_TIME to Tektronix DPO3034 through USB interface with CVI.
I managed to install the driver and can communicate with the oscilloscope.
When I write the delay value (3.5334E-005) this is what i get from the Spy:

1. IviScope_SetAttributeViReal64 (DPOScope, NULL, ACQUISITION_START_TIME, 3.5334E-005)
Process ID: 0x00001534 Thread ID: 0x00000874
Start Time: 17:29:42.456 Call Duration 00:00:00.015
Status: 0 (VI_SUCCESS)

That means that the right command was passed.
But... the delay in the scope comes with 0.4us resolution. That means that i can get ACQUISITION_START_TIME values of only 3.56E-005, 3.6E-005 etc.
This is what I get in the spy with GetAttribute command imeddiatley after the above SetAttribute command:

4. IviScope_GetAttributeViReal64 (DPOScope, NULL, ACQUISITION_START_TIME, 3.56E-005)
Process ID: 0x00001534 Thread ID: 0x00000874
Start Time: 17:34:11.995 Call Duration 00:00:00.016
Status: 0 (VI_SUCCESS)
(The actual delay on the scope screen is also 3.56E-005...)

Thank you for your assistent!
0 Kudos
Message 1 of 7
(5,130 Views)

Hello,

 

This seems to me like expected operation.  The scope is rounding the desired value to the nearest allowed value and telling you that that is what it's set as.

 

What is the problem?

-Jim B
Applications Engineer, National Instruments
CLD, CTD
0 Kudos
Message 2 of 7
(5,112 Views)

Hi Jim,

 

The problem is that I need a much better delay resolution than the 0.4us I get with CVI.

I know that with Labview at the same exact setting I can get resolution of 0.01us.

Also by running the same CVI code on other scopes (with same specs and setting) gives me the resolution I need.

 

Any idea how can I debug it?

0 Kudos
Message 3 of 7
(5,097 Views)

What value is really sent to the scope ? You should see a VISA write with the lowlevel SCPI command string for that setting in SPY.

If this is allready the rounded value, you could look into the driver source code for the conditions for the rounding step width. To debug, you can use the Instrument-> Edit->Attach and edit source menu option. Then you can single step into the driver source. 

If this is the unmodified value, you have to check the scopes manuals, why it is rounding.

In any case there may be another setting ( maybe the general time resolution), which influences the time resolution for that setting. 

0 Kudos
Message 4 of 7
(5,088 Views)

I found the reason...

The driver source code says:

   /**************************************************************************************
     * The resolution in old firmware version is 4ns, but 400ns in new
     * firmware. So remove the old resolution from the driver source code.
 
 checkErr( tkdpo4k_CoerceToResolution (vi, value, 4.0e-9, comparePrecision, &newValue));
    ***************************************************************************************/
   
    checkErr( tkdpo4k_CoerceToResolution (vi, value, 400.0e-9, comparePrecision, &newValue));

 

Tektronix claim that this is not valid for my firmware...

Can someone help to complie new dll driver which is not limiting the resolution?

 

The source files and the original dll are attched.

Download All
0 Kudos
Message 5 of 7
(5,029 Views)
Solution
Accepted by topic author GE-HCS
I fixed the driver...
0 Kudos
Message 6 of 7
(5,016 Views)

Hi.  I am using Tektronix MDO3014 scope and I have similar problem. When I am setting start time to 0 it is fine, but then it has resolution of 0.4us. So I can get values of 0 0.4us 0.8us and so on. The scope sampling frequency is 2.5 GS/s and it allows to move cursor with 40ns resolution. It has problem with resolution even if I am using tkdpo4k Example- Acq Wfm Edge Triggered. vi. How did you fix the driver?

0 Kudos
Message 7 of 7
(4,150 Views)