HilPlotting

class mtf.test_utilities.new_hil_plotting.HilPlotting

Class for managing HIL plotting.

This class handles the configuration, starting, stopping, and cleanup of frame and signal listeners, as well as generating various types of plots based on the HIL data.

__init__() None
configure(topology_path: str, log_path: str) bool

Configures the HIL plotting.

Reads and parses the topology file, and sets up necessary paths.

Args:

topology_path (str): Path to the topology file. log_path (str): Path to the log file.

Returns:

bool: True if configuration is successful, False otherwise.

start_recording() bool

Starts recording for all frames and signals.

Returns:

bool: True if all listeners are started successfully, False otherwise.

stop_recording() bool

Stops recording for all frames and signals.

Returns:

bool: True if all listeners are stopped successfully, False otherwise.

generate_plots(html_logger: HtmlLogger) list[str]

Generates plots for reception events, time differences, and signal variations. Args:

html_logger (HtmlLogger): HTML logger instance for logging plot generation.

Returns:

list[str]: Paths to the generated plots.

cleanup()

Cleans up the HIL plotting setup.

Resets all configurations and clears internal data.

property is_configured: bool

Checks if the HIL plotting is configured.

Returns:

bool: True if configured, False otherwise.

property is_configured_diag: bool

Checks if the HIL plotting is configured for diag.

Returns:

bool: True if configured, False otherwise.

set_all_responses(responses)
export_to_csv() str

Export data to a CSV file.

Returns:

str: The filename of the exported CSV file.

Raises:

Exception: If an error occurs during CSV export.