Skip to content

Commit c1dbeb5

Browse files
committed
increase intial sleep for port check, otherwise it ccould fail on pi4
1 parent 8384004 commit c1dbeb5

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

test/hil/hil_test.py

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -65,13 +65,14 @@ def open_serial_dev(port):
6565
if os.path.exists(port):
6666
try:
6767
# slight delay since kernel may occupy the port briefly
68-
time.sleep(0.2)
68+
time.sleep(0.5)
69+
timeout = timeout - 0.5
6970
ser = serial.Serial(port, timeout=1)
7071
break
7172
except serial.SerialException:
7273
pass
73-
time.sleep(0.8)
74-
timeout = timeout - 1
74+
time.sleep(0.5)
75+
timeout = timeout - 0.5
7576
assert timeout, 'Device not available or Cannot open port'
7677
return ser
7778

0 commit comments

Comments
 (0)