Constants/Enums

pypicosdk.constants

Copyright (C) 2025-2025 Pico Technology Ltd. See LICENSE file for terms.

Classes:

Name Description
ACTION

Action codes used to manage and clear data buffers.

AUXIO_MODE

Operating modes for the AUX IO connector.

BANDWIDTH_CH

Class for different bandwidth configurations.

CHANNEL

Constants representing PicoScope trigger and input channels.

COUPLING

Enum class representing different types of coupling used in signal processing.

DATA_TYPE

Class for different data types.

DIGITAL_CHANNEL

Digital channel identifiers.

DIGITAL_CHANNEL_DIRECTIONS

Structure describing a digital channel direction.

DIGITAL_DIRECTION

Digital trigger direction settings.

DIGITAL_PORT

Digital port identifiers for the 6000A series.

DIGITAL_PORT_HYSTERESIS

Hysteresis options for digital ports.

PICO_CHANNEL_FLAGS

Bit flags for enabled channels used by ps6000aChannelCombinationsStateless.

PICO_CHANNEL_OVERVOLTAGE_TRIPPED

Status flag indicating whether a channel's input protection tripped.

PICO_CONDITION

Trigger condition used by SetTriggerChannelConditions.

PICO_CONNECT_PROBE_RANGE

Input range identifiers for get_analogue_offset_limits.

PICO_DIRECTION

Direction descriptor for SetTriggerChannelDirections.

PICO_FIRMWARE_INFO

Information describing firmware versions and updates.

PICO_LED_COLOUR_PROPERTIES

This structure is used with psospaSetLedColours() to define

PICO_LED_STATE_PROPERTIES

This structure is used with set_led_states() to define the

PICO_PORT_DIGITAL_CHANNEL

Digital channel identifiers within a port.

PICO_PROBE_RANGE_INFO

Probe attenuation identifiers for get_scaling_values.

PICO_SCALING_FACTORS_FOR_RANGE_TYPES_VALUES

Scaling factors for a probe range type.

PICO_SCALING_FACTORS_VALUES

Scaling factors for a channel and range.

PICO_SIGGEN_TRIG_SOURCE

Signal generator trigger source options.

PICO_SIGGEN_TRIG_TYPE

Trigger type for the signal generator.

PICO_STREAMING_DATA_INFO

Structure describing streaming data buffer information.

PICO_STREAMING_DATA_TRIGGER_INFO

Structure describing trigger information for streaming.

PICO_TRIGGER_CHANNEL_PROPERTIES

Trigger threshold configuration for a single channel.

PICO_TRIGGER_INFO

Structure describing trigger timing information.

PICO_USB_POWER_DELIVERY

Structure representing USB Power Delivery status information for a single USB port.

PICO_USB_POWER_DETAILS

Structure describing USB power details for a PicoScope device.

PICO_VERSION

Firmware or driver version information.

POWER_SOURCE

Defines different power source connection statuses.

PULSE_WIDTH_TYPE

Pulse width qualifier comparison types.

RANGE

Enum class representing different voltage ranges used in signal processing.

RATIO_MODE

Defines various ratio modes for signal processing.

RESOLUTION

Resolution constants for PicoScope devices.

SIGGEN_FILTER_STATE

Output filter state for the signal generator.

SIGGEN_PARAMETER

Parameters that can be queried with :func:siggen_limits.

SWEEP_TYPE

Sweep direction for signal generator.

THRESHOLD_DIRECTION

Enumerates trigger threshold directions used with :class:PICO_DIRECTION.

THRESHOLD_MODE

Threshold operation mode values used in :class:PICO_DIRECTION.

TRIGGER_DIR

Trigger direction constants for configuring PicoScope triggers.

TRIGGER_STATE

Trigger state values used in :class:PICO_CONDITION.

TRIGGER_WITHIN_PRE_TRIGGER

Control for :func:trigger_within_pre_trigger_samples.

UNIT_INFO

Unit information identifiers for querying PicoScope device details.

WAVEFORM

Waveform type constants for PicoScope signal generator configuration.

Attributes:
  • TIMESTAMP_COUNTER_MASK (int) –

    Mask for the 56-bit timeStampCounter field.

TIMESTAMP_COUNTER_MASK = (1 << 56) - 1 module-attribute

Mask for the 56-bit timeStampCounter field.

ACTION

Action codes used to manage and clear data buffers.

These action codes are used with functions like setDataBuffer to specify the type of operation to perform on data buffers.

Attributes:
  • CLEAR_ALL –

    Clears all data buffers.

  • ADD –

    Adds data to the buffer.

  • CLEAR_THIS_DATA_BUFFER –

    Clears the current data buffer.

  • CLEAR_WAVEFORM_DATA_BUFFERS –

    Clears all waveform data buffers.

  • CLEAR_WAVEFORM_READ_DATA_BUFFERS –

    Clears the waveform read data buffers.

AUXIO_MODE

Operating modes for the AUX IO connector.

AWG_INDEX_MODE

Index mode for the AWG.

Attributes:
  • SINGLE –

    Single index mode.

  • DOUBLE –

    Double index mode.

  • QUAD –

    Quad index mode.

  • MAX_INDEX_MODES –

    Maximum index mode.

BANDWIDTH_CH

Class for different bandwidth configurations.

Attributes:
  • BW_FULL –

    Full bandwidth configuration.

  • BW_100KHZ –

    Bandwidth of 100 kHz.

  • BW_20KHZ –

    Bandwidth of 20 kHz.

  • BW_1MHZ –

    Bandwidth of 1 MHz.

  • BW_20MHZ –

    Bandwidth of 20 MHz.

  • BW_25MHZ –

    Bandwidth of 25 MHz.

  • BW_50MHZ –

    Bandwidth of 50 MHz.

  • BW_60MHZ –

    Bandwidth of 60 MHz.

  • BW_100MHZ –

    Bandwidth of 100 MHz.

  • BW_200MHZ –

    Bandwidth of 200 MHz.

  • BW_250MHZ –

    Bandwidth of 250 MHz.

  • BW_300MHZ –

    Bandwidth of 300 MHz.

  • BW_350MHZ –

    Bandwidth of 350 MHz.

  • BW_500MHZ –

    Bandwidth of 500 MHz.

CHANNEL

Constants representing PicoScope trigger and input channels.

Attributes:
  • A –

    Channel A

  • B –

    Channel B

  • C –

    Channel C

  • D –

    Channel D

  • E –

    Channel E

  • F –

    Channel F

  • G –

    Channel G

  • H –

    Channel H

  • TRIGGER_AUX –

    Dedicated auxiliary trigger input

COUPLING

Enum class representing different types of coupling used in signal processing.

Attributes:
  • AC –

    Represents AC coupling.

  • DC –

    Represents DC coupling.

  • DC_50OHM –

    Represents 50 Ohm DC coupling.

DATA_TYPE

Class for different data types.

Attributes:
  • INT8_T –

    8-bit signed integer.

  • INT16_T –

    16-bit signed integer.

  • INT32_T –

    32-bit signed integer.

  • UINT32_T –

    32-bit unsigned integer.

  • INT64_T –

    64-bit signed integer.

DIGITAL_CHANNEL

Digital channel identifiers.

DIGITAL_CHANNEL_DIRECTIONS

Structure describing a digital channel direction.

DIGITAL_DIRECTION

Digital trigger direction settings.

DIGITAL_PORT

Digital port identifiers for the 6000A series.

DIGITAL_PORT_HYSTERESIS

Hysteresis options for digital ports.

ETS_MODE

Class for different ETS modes. Attributes: OFF: ETS is disabled. FAST: ETS is enabled in fast mode. SLOW: ETS is enabled in slow mode. MODES_MAX: Maximum number of ETS modes.

PICO_CHANNEL_FLAGS

Bit flags for enabled channels used by ps6000aChannelCombinationsStateless.

PICO_CHANNEL_OVERVOLTAGE_TRIPPED

Status flag indicating whether a channel's input protection tripped. Attributes: channel_: Channel identifier as a :class:CHANNEL value. tripped_: 1 if the channel has tripped due to overvoltage.

PICO_CONDITION

Trigger condition used by SetTriggerChannelConditions.

Each instance defines the state that a particular input source must meet for the overall trigger to occur.

Attributes:
  • source_ –

    Channel being monitored as a :class:CHANNEL value.

  • condition_ –

    Desired state from :class:PICO_TRIGGER_STATE.

PICO_CONNECT_PROBE_RANGE

Input range identifiers for get_analogue_offset_limits.

PICO_DIRECTION

Direction descriptor for SetTriggerChannelDirections.

Attributes:
  • channel_ –

    Channel index as a :class:CHANNEL value.

  • direction_ –

    Direction from :class:PICO_THRESHOLD_DIRECTION.

  • thresholdMode_ –

    Threshold mode from :class:PICO_THRESHOLD_MODE.

PICO_FIRMWARE_INFO

Information describing firmware versions and updates. Attributes: firmwareType_: Firmware identifier as a :class:UNIT_INFO value. currentVersion_: Currently installed :class:PICO_VERSION. updateVersion_: Available update :class:PICO_VERSION. updateRequired_: 1 if an update is required, otherwise 0.

PICO_LED_COLOUR_PROPERTIES

This structure is used with psospaSetLedColours() to define the color for one LED using hue and saturation (HSV) values for the color.

PICO_LED_STATE_PROPERTIES

This structure is used with set_led_states() to define the state for one LED.

PICO_PORT_DIGITAL_CHANNEL

Digital channel identifiers within a port.

PICO_PROBE_RANGE_INFO

Probe attenuation identifiers for get_scaling_values.

PICO_SCALING_FACTORS_FOR_RANGE_TYPES_VALUES

Scaling factors for a probe range type.

PICO_SCALING_FACTORS_VALUES

Scaling factors for a channel and range.

PICO_SIGGEN_TRIG_SOURCE

Signal generator trigger source options.

PICO_SIGGEN_TRIG_TYPE

Trigger type for the signal generator.

PICO_STREAMING_DATA_INFO

Structure describing streaming data buffer information.

PICO_STREAMING_DATA_TRIGGER_INFO

Structure describing trigger information for streaming.

All field names in this structure are defined with a trailing underscore so they match the C structure exactly.

PICO_TRIGGER_CHANNEL_PROPERTIES

Trigger threshold configuration for a single channel.

The fields of this structure mirror the PICO_TRIGGER_CHANNEL_PROPERTIES definition in the PicoSDK headers. Each attribute name ends with an underscore so that the names match the underlying C struct when accessed from Python.

Attributes:
  • thresholdUpper_ –

    ADC counts for the upper trigger threshold.

  • thresholdUpperHysteresis_ –

    Hysteresis applied to thresholdUpper_ in ADC counts.

  • thresholdLower_ –

    ADC counts for the lower trigger threshold.

  • thresholdLowerHysteresis_ –

    Hysteresis applied to thresholdLower_ in ADC counts.

  • channel_ –

    Input channel that these properties apply to as a :class:CHANNEL value.

PICO_TRIGGER_INFO

Structure describing trigger timing information.

All fields of this ctypes structure include a trailing underscore in their names. When you receive a :class:PICO_TRIGGER_INFO instance from :meth:~pypicosdk.pypicosdk.PicoScopeBase.get_trigger_info or other functions, access the attributes using these exact names, for example info.triggerTime_.

Attributes:
  • status_ –

    :class:PICO_STATUS value describing the trigger state. This may be a bitwise OR of multiple status flags such as PICO_DEVICE_TIME_STAMP_RESET or PICO_TRIGGER_TIME_NOT_REQUESTED.

  • segmentIndex_ –

    Memory segment index from which the information was captured.

  • triggerIndex_ –

    Sample index at which the trigger occurred.

  • triggerTime_ –

    Time of the trigger event calculated with sub-sample resolution.

  • timeUnits_ –

    Units for triggerTime_ as a :class:PICO_TIME_UNIT value.

  • missedTriggers_ –

    Number of trigger events that occurred between this capture and the previous one.

  • timeStampCounter_ –

    Timestamp in samples from the first capture.

PICO_TRIGGER_INFO_PS5000A

Structure describing trigger information for PS5000A.

PICO_USB_POWER_DELIVERY

Structure representing USB Power Delivery status information for a single USB port.

This structure provides detailed information about the USB Power Delivery contract and status for a USB port, including voltage, current limits, connection state, and attached device type.

Attributes:
  • valid_ (c_uint8) –

    Indicates whether the power delivery data is valid (non-zero if valid).

  • busVoltagemV_ (c_uint32) –

    The bus voltage in millivolts.

  • rpCurrentLimitmA_ (c_uint32) –

    The current limit for the Rp resistor in milliamps.

  • partnerConnected_ (c_uint8) –

    Indicates if a partner device is connected (non-zero if connected).

  • ccPolarity_ (c_uint8) –

    The polarity of the CC (Configuration Channel) line.

  • attachedDevice_ (c_uint32) –

    The type of device attached (PICO_USB_POWER_DELIVERY_DEVICE_TYPE, a 4-byte enum).

  • contractExists_ (c_uint8) –

    Indicates whether a power contract exists (non-zero if yes).

  • currentPdo_ (c_uint32) –

    The current Power Data Object (PDO) index.

  • currentRdo_ (c_uint32) –

    The current Request Data Object (RDO) index.

PICO_USB_POWER_DETAILS

Structure describing USB power details for a PicoScope device.

Attributes:
  • powerErrorLikely_ (c_uint8) –

    Non-zero if the driver considers a USB power problem likely.

  • dataPort_ (PICO_USB_POWER_DELIVERY) –

    USB power delivery details related to the device's data port.

  • powerPort_ (PICO_USB_POWER_DELIVERY) –

    USB power delivery details related to the device's power port.

PICO_VERSION

Firmware or driver version information. Attributes: major_: Major version number. minor_: Minor version number. revision_: Revision number. build_: Build number.

POWER_SOURCE

Defines different power source connection statuses.

These values represent the connection status of a power supply or USB device.

Attributes:
  • SUPPLY_CONNECTED –

    Power supply is connected.

  • SUPPLY_NOT_CONNECTED –

    Power supply is not connected.

  • USB3_0_DEVICE_NON_USB3_0_PORT –

    USB 3.0 device is connected to a non-USB 3.0 port.

PULSE_WIDTH_TYPE

Pulse width qualifier comparison types.

RANGE

Enum class representing different voltage ranges used in signal processing.

Attributes:
  • mV10 –

    Voltage range of ±10 mV.

  • mV20 –

    Voltage range of ±20 mV.

  • mV50 –

    Voltage range of ±50 mV.

  • mV100 –

    Voltage range of ±100 mV.

  • mV200 –

    Voltage range of ±200 mV.

  • mV500 –

    Voltage range of ±500 mV.

  • V1 –

    Voltage range of ±1 V.

  • V2 –

    Voltage range of ±2 V.

  • V5 –

    Voltage range of ±5 V.

  • V10 –

    Voltage range of ±10 V.

  • V20 –

    Voltage range of ±20 V.

  • V50 –

    Voltage range of ±50 V.

RATIO_MODE

Defines various ratio modes for signal processing.

Attributes:
  • AGGREGATE –

    Aggregate mode for data processing.

  • DECIMATE –

    Decimation mode for reducing data resolution.

  • AVERAGE –

    Averaging mode for smoothing data.

  • DISTRIBUTION –

    Mode for calculating distribution statistics.

  • SUM –

    Mode for summing data.

  • TRIGGER_DATA_FOR_TIME_CALCULATION –

    Mode for calculating trigger data for time-based calculations.

  • SEGMENT_HEADER –

    Mode for segment header data processing.

  • TRIGGER –

    Trigger mode for event-based data. If manually setting buffers, TRIGGER will need its own buffer set.

  • RAW –

    Raw data mode, without any processing.

RESOLUTION

Resolution constants for PicoScope devices.

WARNING: Not all devices support all resolutions.

Attributes:
  • _8BIT –

    8-bit resolution.

  • _10BIT –

    10-bit resolution.

  • _12BIT –

    12-bit resolution.

  • _14BIT –

    14-bit resolution.

  • _15BIT –

    15-bit resolution.

  • _16BIT –

    16-bit resolution.

Examples:

>>> scope.open_unit(resolution=RESOLUTION._16BIT)

SCOPE_STATE

Class for different scope states. Attributes: IDLE: The scope is idle. PRE_TRIGGER: The scope is in pre-trigger mode. WAITING_FOR_TRIGGER: The scope is waiting for a trigger. CAPTURING: The scope is capturing data.

SIGGEN_FILTER_STATE

Output filter state for the signal generator.

SIGGEN_PARAMETER

Parameters that can be queried with :func:siggen_limits.

Attributes:
  • OUTPUT_VOLTS –

    0

  • SAMPLE –

    1

  • BUFFER_LENGTH –

    2

SWEEP_TYPE

Sweep direction for signal generator.

THRESHOLD_DIRECTION

Enumerates trigger threshold directions used with :class:PICO_DIRECTION.

THRESHOLD_MODE

Threshold operation mode values used in :class:PICO_DIRECTION.

TRIGGER_DIR

Trigger direction constants for configuring PicoScope triggers.

Attributes:
  • ABOVE –

    Trigger when the signal goes above the threshold.

  • BELOW –

    Trigger when the signal goes below the threshold.

  • RISING –

    Trigger on rising edge.

  • FALLING –

    Trigger on falling edge.

  • RISING_OR_FALLING –

    Trigger on either rising or falling edge.

TRIGGER_STATE

Trigger state values used in :class:PICO_CONDITION.

TRIGGER_WITHIN_PRE_TRIGGER

Control for :func:trigger_within_pre_trigger_samples.

UNIT_INFO

Unit information identifiers for querying PicoScope device details.

Attributes:
  • PICO_DRIVER_VERSION –

    PicoSDK driver version.

  • PICO_USB_VERSION –

    USB version (e.g., USB 2.0 or USB 3.0).

  • PICO_HARDWARE_VERSION –

    Hardware version of the PicoScope.

  • PICO_VARIANT_INFO –

    Device model or variant identifier.

  • PICO_BATCH_AND_SERIAL –

    Batch and serial number of the device.

  • PICO_CAL_DATE –

    Device calibration date.

  • PICO_KERNEL_VERSION –

    Kernel driver version.

  • PICO_DIGITAL_HARDWARE_VERSION –

    Digital board hardware version.

  • PICO_ANALOGUE_HARDWARE_VERSION –

    Analogue board hardware version.

  • PICO_FIRMWARE_VERSION_1 –

    First part of the firmware version.

  • PICO_FIRMWARE_VERSION_2 –

    Second part of the firmware version.

Examples:

>>> scope.get_unit_info(picosdk.UNIT_INFO.PICO_BATCH_AND_SERIAL)
"JM115/0007"

WAVEFORM

Waveform type constants for PicoScope signal generator configuration.

Attributes:
  • SINE –

    Sine wave.

  • SQUARE –

    Square wave.

  • TRIANGLE –

    Triangle wave.

  • RAMP_UP –

    Rising ramp waveform.

  • RAMP_DOWN –

    Falling ramp waveform.

  • SINC –

    Sinc function waveform.

  • GAUSSIAN –

    Gaussian waveform.

  • HALF_SINE –

    Half sine waveform.

  • DC_VOLTAGE –

    Constant DC voltage output.

  • PWM –

    Pulse-width modulation waveform.

  • WHITENOISE –

    White noise output.

  • PRBS –

    Pseudo-random binary sequence.

  • ARBITRARY –

    Arbitrary user-defined waveform.