added s11!
This commit is contained in:
@@ -4,9 +4,8 @@ from __future__ import annotations
|
||||
|
||||
from dataclasses import dataclass, field
|
||||
|
||||
import numpy as np
|
||||
|
||||
from python_app.hardware_full.librevna_backends import LibreVnaBackend, MockLibreVnaBackend, NativeLibreVnaBackend
|
||||
from python_app.hardware_full.librevna_driver.models import SweepResult
|
||||
from python_app.models.run_config_model import RadarSweepModel
|
||||
|
||||
|
||||
@@ -89,10 +88,10 @@ class LibreVnaService:
|
||||
if opened_here:
|
||||
self.close()
|
||||
|
||||
def acquire_s21(self) -> tuple[np.ndarray, np.ndarray]:
|
||||
"""Acquire one S21 trace from currently selected backend."""
|
||||
def acquire(self) -> SweepResult:
|
||||
"""Acquire one sweep with all available traces from active backend."""
|
||||
if self._backend is None:
|
||||
raise RuntimeError("LibreVNA backend is not initialized")
|
||||
if self._using_mock_backend and not self._driver_available and self.backend_mode != "mock":
|
||||
raise RuntimeError("Device not found")
|
||||
return self._backend.acquire_s21()
|
||||
return self._backend.acquire()
|
||||
|
||||
Reference in New Issue
Block a user