fix(mic): исправлен таймер на TIM3

This commit is contained in:
2025-12-25 23:17:39 +03:00
parent 3306b8083b
commit 063cced2a5
7 changed files with 223 additions and 213 deletions

19
client/src/test_usb.py Normal file
View File

@@ -0,0 +1,19 @@
#!/usr/bin/env python3
import serial
import time
port = serial.Serial("/dev/ttyACM0", 115200, timeout=1)
print(f"Connected to {port.name}")
port.write(b"test\n")
time.sleep(0.1)
# Читаем 5 секунд
start = time.time()
while time.time() - start < 5:
if port.in_waiting:
data = port.read(port.in_waiting)
print(f"RX: {data.decode('utf-8', errors='replace')}", end="")
time.sleep(0.1)
port.close()