From a0e69dd708b1cf7cb755e5d873c952edac3075fa Mon Sep 17 00:00:00 2001 From: Simon Alibert Date: Thu, 8 May 2025 12:52:16 +0200 Subject: [PATCH] Rename find_port --- lerobot/{scripts/find_motors_bus_port.py => find_port.py} | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) rename lerobot/{scripts/find_motors_bus_port.py => find_port.py} (96%) diff --git a/lerobot/scripts/find_motors_bus_port.py b/lerobot/find_port.py similarity index 96% rename from lerobot/scripts/find_motors_bus_port.py rename to lerobot/find_port.py index 68f2315d..47c2dfea 100644 --- a/lerobot/scripts/find_motors_bus_port.py +++ b/lerobot/find_port.py @@ -15,10 +15,10 @@ import os import time from pathlib import Path -from serial.tools import list_ports # Part of pyserial library - def find_available_ports(): + from serial.tools import list_ports # Part of pyserial library + if os.name == "nt": # Windows # List COM ports using pyserial ports = [port.device for port in list_ports.comports()]