Added thread safety to USB TX, servo control thread, primitive ADC thread, python test codes

This commit is contained in:
Your Name
2026-09-22 13:01:31 +03:00
parent 1d1416d5d8
commit dd7e6d9456
16 changed files with 944 additions and 40 deletions
+5 -2
View File
@@ -12,7 +12,10 @@ COMMAND_PREFIX = 0x69
COMMAND_ACK = 0
COMMAND_NACK = 1
LED = 2
LED_TOGGLE = 2
LED_SET = 3
SERVO_SET = 4
SERVO_SET_ALL = 5
DEVICE_ID = 0
@@ -112,7 +115,7 @@ def main():
for i in range(10):
print(f"--> Sending LED command {i + 1}")
ser.write(make_packet(LED))
ser.write(make_packet(LED_TOGGLE))
time.sleep(0.5)
print("Done.")