summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorhathach <[email protected]>2023-11-29 18:11:50 +0700
committerhathach <[email protected]>2023-11-29 18:11:50 +0700
commitc1dbeb55b4eaa3e0af07eb594147caed5e85f503 (patch)
tree4906e0872868af055028491fd8d0f5ec98b8c2b4 /test
parent83840041a86d3893dc66e9a39cdace78158da011 (diff)
increase intial sleep for port check, otherwise it ccould fail on pi4
Diffstat (limited to 'test')
-rw-r--r--test/hil/hil_test.py7
1 files changed, 4 insertions, 3 deletions
diff --git a/test/hil/hil_test.py b/test/hil/hil_test.py
index c90cf363c..b307a45f6 100644
--- a/test/hil/hil_test.py
+++ b/test/hil/hil_test.py
@@ -65,13 +65,14 @@ def open_serial_dev(port):
if os.path.exists(port):
try:
# slight delay since kernel may occupy the port briefly
- time.sleep(0.2)
+ time.sleep(0.5)
+ timeout = timeout - 0.5
ser = serial.Serial(port, timeout=1)
break
except serial.SerialException:
pass
- time.sleep(0.8)
- timeout = timeout - 1
+ time.sleep(0.5)
+ timeout = timeout - 0.5
assert timeout, 'Device not available or Cannot open port'
return ser