Tektronix Technical Forums are maintained by community involvement. Feel free to post questions or respond to questions by other members. Should you require a time-sensitive answer, please contact your local Tektronix support center here.

MSO54LP Changes Record Length Automatically

Programming examples for remote communication with instruments
C/C++, C#, Python, Matlab, LabVIEW
Post Reply
mjcawford2
Posts: 1
Joined: June 17th, 2019, 3:02 pm
Country: United States

MSO54LP Changes Record Length Automatically

Post by mjcawford2 » June 18th, 2019, 6:26 am

When I set remote SCPI commands to the MSO54LP to set the record length to 1000 and the scale to 2e-008, wne I query the record length it comes back as 1250. How do I disable features that allow me to configure the scope to what I want, not the scope readjusting to keep a specific sample rate or changing the record length for a specific time period. Here are the commands I send relevant to this:
hor:mode manual
hor:mode:manual:configure recordlength
dat:start 1
dat:stop 1000
hor:reco 1000
hor:mode:reco 1000
hor:mode:scale 2e-008
hor:samplerate 5e+009
and when querying:
hor:reco? returns: 1250
hor:mode:sca? returns: 20.0000E-9.
hor:samplerate? returns: 6.2500E+9

No other Tek scopes I have interfaced have ever done this.
What settings do I need to enable/disable to allow me to do this?
Attachments
MSO54LPCapture.txt
(21.49 KiB) Downloaded 77 times

Jeffrey M
Tektronix Applications
Tektronix Applications
Posts: 24
Joined: August 3rd, 2016, 10:21 am
Country: United States

Re: MSO54LP Changes Record Length Automatically

Post by Jeffrey M » June 19th, 2019, 10:40 am

There are a couple of things at play here. First, as you probably know, record length, sampling rate, and time scale are arithmetically related by this formula:

sampling rate = (record length)/(time scale)

Inversely:

record length = (time scale)*(sampling rate)

In this horizontal system, sampling rate is always the dominant term. That is, we assume that the sampling rate is set to the intended value when other settings are changed. When you send the :hor:mode:scale 2e-008 command, the total time scale is set to 200 ns (20e-009 s/division). At this point in the sequence, the sampling rate is 6.25 GS/s, so the record length becomes (200 ns)*(6.25 GS/s) = 1250.

The other important behavior is that the sampling rate can only be set to an integer divisor of the maximum sampling rate. The max sample rate on this scope is 6.25 GS/s, so it can only be set to 3.125, 1.25, etc. GS/s. Attempting to set another value will cause the scope to choose the closest settable value. This is true for all Tek scopes.

Post Reply

Return to “Remote Instrument Communication (Programming) Examples”

Who is online

Users browsing this forum: No registered users and 1 guest