improved logging

This commit is contained in:
Ayzen
2026-06-06 00:52:52 +03:00
parent af6005d68f
commit aea49f6128
65 changed files with 1206 additions and 240 deletions
+7
View File
@@ -12,6 +12,7 @@ from python_app.models.run_config_model import RadarSweepModel, RunConfigModel
def _parse_args() -> argparse.Namespace:
"""Parse command-line options for the SN9000 VISA smoke test."""
parser = argparse.ArgumentParser(description="Acquire one SN9000 collection through VISA HiSLIP")
parser.add_argument(
"--host",
@@ -40,6 +41,7 @@ def _parse_args() -> argparse.Namespace:
def _validate_collection(collection: SweepCollection, expected_points: int) -> None:
"""Raise unless a SN9000 collection has the expected traces, combos, shapes, and finite values."""
expected_traces = (
RunConfigModel.MULTI_DEVICE_INPUT_POSITIONS * RunConfigModel.MULTI_DEVICE_OUTPUT_POSITIONS
)
@@ -82,6 +84,11 @@ def _validate_collection(collection: SweepCollection, expected_points: int) -> N
def main() -> int:
"""Acquire one SN9000 collection and validate it end to end.
Opens the VISA session, configures the sweep, validates the collection, checks the SCPI
error queue, and prints a summary; raises on any validation or SCPI failure.
"""
args = _parse_args()
sweep = RadarSweepModel(
start_hz=args.start_hz,