nibcq.measurement.SwitchingSupport

class nibcq.measurement.SwitchingSupport

Bases: abc.ABC, nibcq.switch.SwitchAware

Mixin for measurements that support switching functionality.

abstractmethod run_with_switching()

Run measurement with automatic switching between DUT channels.

This method must be implemented by each measurement subclass to provide switching functionality. It should use the SwitchAware mixin capabilities to iterate through configured channels and perform measurements.

Returns:

List of measurement results for each DUT channel.

Return type:

list

Raises:

RuntimeError – If switching not enabled or no channels configured.

property has_switch_capability: bool

Check if the device has switch capability.

Returns:

True if switch capability is available, False otherwise

Return type:

bool

connect_channel(channel: SMUCellData) None

Connect to a specific DUT channel using the device’s switch capability.

Parameters:

channel (SMUCellData) – SwitchChannel containing connection information

Raises:

RuntimeError – If no switch capability is available

Return type:

None

disconnect_all() None

Disconnect all channels using the device’s switch capability.

Raises:

RuntimeError – If no switch capability is available

Return type:

None

wait_for_debounce() None

Wait for switch relays to settle using the device’s switch capability.

Raises:

RuntimeError – If no switch capability is available

Return type:

None

property switch_cells: List[str] | List[SMUCellData]

Get the configured switch cells from the device.

Returns:

DUT channel names or SMUCellData objects, which contain the DUT and switch channel information.

Return type:

list[str] | list[SMUCellData]