Skip to content

LeCroyWaverunnerLT#

Controls a LeCroy WaveRunner LT oscilloscope (4 channels) from Python. Some functions are not implemented for this device and raise a NotImplementedException . This class inherits from MeasmaticDevice.


method check_errors()#

Checks the oscilloscope for errors. Currently the device performs no check (status register evaluation is not implemented).

Example#

osci = measmatic.get_device('device-osci')
osci.check_errors()

method enable_channel(osciChannel: Any, enabled: bool)#

Switches the trace of a channel on or off.

Parameters#

Name Description
osciChannel The channel of type Atv.Framework.Devices.Contracts.OsciChannel .
enabled True to enable the trace, False to disable it.

Example#

from Atv.Framework.Devices.Contracts import OsciChannel
osci = measmatic.get_device('device-osci')
osci.enable_channel(OsciChannel.Channel1, True)

method fetch_data(osciChannel: Any, time: Any, voltage: Any)#

Reads the recorded waveform of a channel. Not implemented for this device; the call always raises a NotImplementedException .

Parameters#

Name Description
osciChannel The channel of type Atv.Framework.Devices.Contracts.OsciChannel .
time Out parameter, returned as part of the result tuple. The sample times in seconds.
voltage Out parameter, returned as part of the result tuple. The sample voltages in volts.

Returns#

Type Description
float The sample times in seconds.
float The sample voltages in volts.

Example#

from Atv.Framework.Devices.Contracts import OsciChannel
osci = measmatic.get_device('device-osci')
time, voltage = osci.fetch_data(OsciChannel.Channel1)

method get_number_of_channels()#

Gets the number of analog channels of the oscilloscope.

Returns#

Type Description
int The number of channels (4 for this device).

Example#

osci = measmatic.get_device('device-osci')
count = osci.get_number_of_channels()

method is_busy()#

Checks whether the oscilloscope is busy. Not implemented for this device; the call always raises a NotImplementedException .

Returns#

Type Description
bool True if the oscilloscope is busy, otherwise False .

Example#

osci = measmatic.get_device('device-osci')
busy = osci.is_busy()

method is_ready_for_acquisition()#

Checks whether the oscilloscope is armed and ready for an acquisition. Not implemented for this device; the call always raises a NotImplementedException .

Returns#

Type Description
bool True if the oscilloscope is ready for an acquisition, otherwise False .

Example#

osci = measmatic.get_device('device-osci')
ready = osci.is_ready_for_acquisition()

method probe_calibrate(osciChannel: Any)#

Calibrates the probe connected to a channel. This device performs no action.

Parameters#

Name Description
osciChannel The channel of type Atv.Framework.Devices.Contracts.OsciChannel .

Example#

from Atv.Framework.Devices.Contracts import OsciChannel
osci = measmatic.get_device('device-osci')
osci.probe_calibrate(OsciChannel.Channel1)

method probe_degauss(osciChannel: Any)#

Degausses the current probe connected to a channel. This device performs no action.

Parameters#

Name Description
osciChannel The channel of type Atv.Framework.Devices.Contracts.OsciChannel .

Example#

from Atv.Framework.Devices.Contracts import OsciChannel
osci = measmatic.get_device('device-osci')
osci.probe_degauss(OsciChannel.Channel1)

method reset()#

Resets the oscilloscope to its default state ( *RST ).

Example#

osci = measmatic.get_device('device-osci')
osci.reset()

method set_coupling(osciChannel: Any, coupling: Any)#

Sets the input coupling and termination of a channel.

Parameters#

Name Description
osciChannel The channel of type Atv.Framework.Devices.Contracts.OsciChannel .
coupling The coupling of type Atv.Framework.Devices.Contracts.OsciCoupling

Example#

from Atv.Framework.Devices.Contracts import OsciChannel, OsciCoupling
osci = measmatic.get_device('device-osci')
osci.set_coupling(OsciChannel.Channel1, OsciCoupling.Dc50)

method set_record_length(recordLength: int)#

Sets the record length (memory size, number of samples per acquisition).

Parameters#

Name Description
recordLength The record length in samples.

Example#

osci = measmatic.get_device('device-osci')
osci.set_record_length(10000)

method set_time_range_and_offset(timeRange: float, timeOffset: float)#

Sets the horizontal (time) range and the trigger delay offset.

Parameters#

Name Description
timeRange The full horizontal range in seconds (the time per division is derived from it).
timeOffset The horizontal delay time in seconds.

Example#

osci = measmatic.get_device('device-osci')
osci.set_time_range_and_offset(1e-6, 0.0)

method set_trigger(osciChannel: Any, level: float, coupling: Any = ...)#

Configures the edge trigger source channel, trigger level and trigger coupling.

Parameters#

Name Description
osciChannel The trigger source channel of type Atv.Framework.Devices.Contracts.OsciChannel .
level The trigger level in volts.
coupling The trigger coupling of type Atv.Framework.Devices.Contracts.OsciTriggerCoupling Default: ...

Example#

from Atv.Framework.Devices.Contracts import OsciChannel
osci = measmatic.get_device('device-osci')
osci.set_trigger(OsciChannel.Channel1, 1.5)

method set_trigger_edge_slope(slope: Any)#

Sets the slope of the edge trigger.

Parameters#

Name Description
slope The slope of type Atv.Framework.Devices.Contracts.OsciTriggerSlope

Example#

from Atv.Framework.Devices.Contracts import OsciTriggerSlope
osci = measmatic.get_device('device-osci')
osci.set_trigger_edge_slope(OsciTriggerSlope.Pos)

method set_trigger_mode(mode: Any)#

Sets the trigger mode.

Parameters#

Name Description
mode The mode of type Atv.Framework.Devices.Contracts.OsciTriggerMode

Example#

from Atv.Framework.Devices.Contracts import OsciTriggerMode
osci = measmatic.get_device('device-osci')
osci.set_trigger_mode(OsciTriggerMode.Normal)

method set_trigger_type_edge()#

Selects the edge trigger type.

Example#

osci = measmatic.get_device('device-osci')
osci.set_trigger_type_edge()

method set_voltage_range_and_offset(osciChannel: Any, voltRange: float, voltOffset: float)#

Sets the vertical (voltage) range and offset of a channel.

Parameters#

Name Description
osciChannel The channel of type Atv.Framework.Devices.Contracts.OsciChannel .
voltRange The full vertical range in volts (the volts per division are derived from it).
voltOffset The vertical offset in volts.

Example#

from Atv.Framework.Devices.Contracts import OsciChannel
osci = measmatic.get_device('device-osci')
osci.set_voltage_range_and_offset(OsciChannel.Channel1, 10.0, 0.0)

method start_continually_acquisition()#

Starts a continuous acquisition. Not implemented for this device; the call always raises a NotImplementedException .

Example#

osci = measmatic.get_device('device-osci')
osci.start_continually_acquisition()

method start_single_acquisition()#

Arms the oscilloscope for a single acquisition and waits until the device has finished any required calibration.

Example#

osci = measmatic.get_device('device-osci')
osci.start_single_acquisition()

method stop_acquisition()#

Stops the acquisition.

Example#

osci = measmatic.get_device('device-osci')
osci.stop_acquisition()

method trigger()#

Stops, arms and re-arms the oscilloscope in single mode ( ARM ), which triggers a single acquisition. The call blocks for about one second.

Example#

osci = measmatic.get_device('device-osci')
osci.trigger()

method wait_completed()#

Waits until the oscilloscope has completed all pending operations ( *OPC? ) and raises an error otherwise.

Example#

osci = measmatic.get_device('device-osci')
osci.wait_completed()