Setup / Initialization

Bases: PicoScopeBase, shared_ps6000a_psospa, shared_4000a_6000a

PicoScope 6000 (A) API specific functions

Methods:

Name Description
close_unit

Closes the PicoScope device and releases the hardware handle.

get_device_resolution

Return the currently configured resolution.

get_enumerated_units

Returns count, serials and serial string length of a specific PicoScope unit.

get_unit_info

Get specified information from unit. Use UNIT_INFO.XXXX or integer.

get_unit_serial

Get and return batch and serial of unit.

open_unit

Opens PicoScope unit.

open_unit_async

Open a unit without blocking the calling thread.

open_unit_progress

Check the progress of :meth:open_unit_async.

ping_unit

Check that the device is still connected.

set_device_resolution

Configure the ADC resolution using ps6000aSetDeviceResolution.

close_unit()

Closes the PicoScope device and releases the hardware handle.

This calls the PicoSDK CloseUnit function to properly disconnect from the device.

Returns:
  • None

    None

get_device_resolution()

Return the currently configured resolution. Returns: :class:RESOLUTION: Device resolution.

get_enumerated_units()

Returns count, serials and serial string length of a specific PicoScope unit.

Returns:
  • int

    Number of devices of this type

  • str

    Comma separated string of all serials

  • int

    Length of string

get_unit_info(unit_info)

Get specified information from unit. Use UNIT_INFO.XXXX or integer.

Parameters:
  • unit_info (UNIT_INFO) –

    Specify information from PicoScope unit i.e. UNIT_INFO.PICO_BATCH_AND_SERIAL.

Returns:
  • str( str ) –

    Returns data from device.

get_unit_serial()

Get and return batch and serial of unit.

Returns:
  • str( str ) –

    Returns serial, e.g., "JR628/0017".

open_unit(serial_number=None, resolution=0)

Opens PicoScope unit.

Parameters:
  • serial_number (int, default: None ) –

    Serial number of specific unit, e.g., JR628/0017.

  • resolution (RESOLUTION, default: 0 ) –

    Resolution of device.

open_unit_async(serial_number=None, resolution=0)

Open a unit without blocking the calling thread. Wraps ps6000aOpenUnitAsync which begins the open operation and returns immediately. Args: serial_number: Serial number of the device to open. resolution: Requested resolution for the device. Returns: int: Status flag from the driver (0 if the request was not started, 1 if the operation began successfully).

open_unit_progress()

Check the progress of :meth:open_unit_async. This wraps ps6000aOpenUnitProgress and should be called repeatedly until complete is non-zero. Returns: tuple[int, int, int]: (handle, progress_percent, complete).

ping_unit()

Check that the device is still connected. This wraps ps6000aPingUnit which verifies communication with the PicoScope. If the call succeeds the method returns True. Returns: bool: True if the unit responded.

set_device_resolution(resolution)

Configure the ADC resolution using ps6000aSetDeviceResolution. Args: resolution: Desired resolution as a :class:RESOLUTION value.