CaptureConfig

Capture configuration

Attributes

NameTypeDescription
enabled_channelslist[ChannelConfig]
analog_settingsOptional[AnalogSettings]
capture_settingsOptional[CaptureSettings]

Methods

__init__(enabled_channels: list[ChannelConfig], analog_settings: Optional[AnalogSettings] = None, capture_settings: Optional[CaptureSettings] = None) -> None
validate_sample_buffer_and_timeout(mso_part_number: MsoPodPartNumber)

Validate the timeout on the capture is possible given the pre_trigger_ and post_trigger_seconds, and that the maximum sample buffer depth is not exceeded.

get_logic_analyzer_settings() -> Optional[json_types.LogicAnalyzerSettings]

Validate that the digital channels are configured correctly

Returns a json_types.LogicAnalyzerSettings object or None if no digital channels are enabled

get_analog_settings(part_number: MsoPodPartNumber) -> Optional[json_types.AnalogSettings]

Return the analog settings as a json_types.AnalogSettings object Return None if no analog channels are enabled

find_trigger_channel(trigger: EdgeTrigger) -> ChannelConfig

Return the ChannelConfig from enabled_channels that matches the given trigger

validate_enabled_channels() -> list[Dict[str, Any]]

Validate enabled_channels and convert them to dictionaries

to_dict(output_dir: Path, mso_part_number: MsoPodPartNumber) -> Dict[str, Any]

Convert the configuration to a dictionary format expected by the MSO

to_config_dict() -> dict[Any, Any]

Emit this configuration as a dictionary

classmethod from_config_dict(dict_version: dict[Any, Any]) -> CaptureConfig

Convert a dictionary version of this configuration to a CaptureConfig

to_dir(output_dir: Path, mso_part_number: MsoPodPartNumber) -> Path

Save this configuration as a directory of files and return the path of the record options file

classmethod from_dir(dir_path: Path) -> CaptureConfig

Load a CaptureConfig from a directory of files

AI/LLM users: see llms-mso-api.txt for machine-readable documentation.