Overview
Use the scope module to control oscilloscopes for analog signal capture, triggering on specific events, and automated measurements.Import
Usage
Methods
Channel Control
enable()
Enable the oscilloscope channel.
disable()
Disable the oscilloscope channel.
Capture Control
start_capture()
Start continuous waveform capture.
start_single_capture()
Start single-shot capture (captures one triggered event).
stop_capture()
Stop waveform capture.
Measurements
Access comprehensive measurements through themeasurement attribute:
Voltage Measurements
Timing Measurements
Counting Measurements
Area Measurements
Statistical Measurements
Delay and Phase Measurements
Measurement Options
Most measurements accept optional parameters:Streaming (PicoScope)
For PicoScope devices, streaming capabilities are available:stream_start(channel, volts_per_div, time_per_div, trigger_level, trigger_slope, capture_mode, coupling)
Start streaming acquisition.
Parameters:
channel(str): Channel to enable -"A","B","1","2"volts_per_div(float): Vertical scaletime_per_div(float): Horizontal scale in secondstrigger_level(float): Trigger level in voltstrigger_slope(str):"rising","falling","either"capture_mode(str):"auto","normal","single"coupling(str):"dc","ac"
stream_stop()
Stop streaming acquisition.
stream_capture(output, duration, samples)
Capture data to file.
Parameters:
output(str): Output file pathduration(float): Capture duration in secondssamples(int): Number of samples (optional)
Complete Example
Trace Settings
Configure vertical and horizontal scale throughtrace_settings:
Advanced Trigger Settings
Access advanced trigger configuration throughtrigger_settings:
Cursor Control
Access cursor functions through thecursor attribute:
Supported Hardware
| Manufacturer | Model Series | Features |
|---|---|---|
| Rigol | MSO5000 | Multi-channel, mixed-signal, protocol decode |
| PicoScope | Various | Streaming support |
Notes
- Use
NetType.Analogfor oscilloscope channels (1-4) - Use
NetType.Logicfor digital channels (D0-D15) on MSO scopes - Streaming features are only available on PicoScope devices
- Configure trigger before starting capture for reliable measurements
- Measurements return
Noneif the measurement cannot be performed - For protocol triggering (UART, I2C, SPI, CAN), see the Logic Analyzer documentation
- Typo Note: The method
positve_pulse_count()is intentionally documented with this spelling to match the underlying API

