From 8efe664b0a498028a414791bd66eae51d5f21bf7 Mon Sep 17 00:00:00 2001 From: Maska989 Date: Fri, 4 Oct 2024 10:29:14 +0200 Subject: [PATCH] trunner: change passed vid/pid from string to list JIRA: CI-500 --- trunner/target/armv7a7.py | 2 +- trunner/target/armv7a9.py | 2 +- trunner/target/armv7m4.py | 2 +- trunner/target/armv7m7.py | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/trunner/target/armv7a7.py b/trunner/target/armv7a7.py index 7c1655e9a..4bb730840 100644 --- a/trunner/target/armv7a7.py +++ b/trunner/target/armv7a7.py @@ -103,6 +103,6 @@ class IMX6ULLEvkTarget(ARMv7A7Target): def __init__(self, host: Host, port: Optional[str] = None, baudrate: int = 115200): if not port: - port = find_port("10c4:ea60") # vid:pid Product=CP2102 USB to UART Bridge Controller for imx6ull-evk + port = find_port(["10c4:ea60"]) # vid:pid Product=CP2102 USB to UART Bridge Controller for imx6ull-evk super().__init__(host, port, baudrate) diff --git a/trunner/target/armv7a9.py b/trunner/target/armv7a9.py index 0ea5f9294..fef9cbc24 100644 --- a/trunner/target/armv7a9.py +++ b/trunner/target/armv7a9.py @@ -132,7 +132,7 @@ class Zynq7000ZedboardTarget(ARMv7A9Target): def __init__(self, host: Host, port: Optional[str] = None, baudrate: int = 115200): if port is None: - port = find_port("04b4:0008") + port = find_port(["04b4:0008"]) super().__init__(host, port, baudrate) diff --git a/trunner/target/armv7m4.py b/trunner/target/armv7m4.py index a49b47c42..bc4002ab3 100644 --- a/trunner/target/armv7m4.py +++ b/trunner/target/armv7m4.py @@ -111,7 +111,7 @@ class STM32L4x6Target(TargetBase): def __init__(self, host: Host, port: Optional[str] = None, baudrate: int = 115200): if port is None: # Try to find USB-Serial controller - port = find_port("USB-Serial|UART") + port = find_port(["067b:2303", "10c4:ea60"]) self.dut = SerialDut(port, baudrate, encoding="utf-8", codec_errors="ignore") self.rebooter = ARMv7M4Rebooter(host, self.dut) diff --git a/trunner/target/armv7m7.py b/trunner/target/armv7m7.py index f4162ea3a..bb89f4f67 100644 --- a/trunner/target/armv7m7.py +++ b/trunner/target/armv7m7.py @@ -89,7 +89,7 @@ def build_test(self, test: TestOptions) -> Callable[[TestResult], TestResult]: class IMXTarget(ARMv7M7Target): def __init__(self, host: Host, port: Optional[str] = None, baudrate: int = 115200): if not port: - port = find_port("0D28:0204") # vid:pid + port = find_port(["1fc9:0143", "0D28:0204"]) # possible vid:pid list super().__init__(host, port, baudrate)