led check
This commit is contained in:
@@ -6,6 +6,7 @@ import math
|
|||||||
from tqdm import tqdm
|
from tqdm import tqdm
|
||||||
import re
|
import re
|
||||||
import sys
|
import sys
|
||||||
|
import time
|
||||||
|
|
||||||
class Device:
|
class Device:
|
||||||
def __init__(self, accuracy, precision, port, baud_rate):
|
def __init__(self, accuracy, precision, port, baud_rate):
|
||||||
@@ -26,6 +27,9 @@ def perform_hpos_test(repeat_no, solution, df):
|
|||||||
raise FileNotFoundError(f"Port {port} not found.")
|
raise FileNotFoundError(f"Port {port} not found.")
|
||||||
|
|
||||||
with serial.Serial(port, baud_rate, timeout=1, parity=serial.PARITY_NONE) as ser:
|
with serial.Serial(port, baud_rate, timeout=1, parity=serial.PARITY_NONE) as ser:
|
||||||
|
x = ser.read()
|
||||||
|
s = ser.read(10)
|
||||||
|
line = ser.readline()
|
||||||
|
|
||||||
ser.write(b'B')
|
ser.write(b'B')
|
||||||
while True:
|
while True:
|
||||||
|
|||||||
Reference in New Issue
Block a user