Increases the serial response waiting time.
This commit is contained in:
0
format_serial_txt_to_csv.py
Normal file
0
format_serial_txt_to_csv.py
Normal file
@@ -23,7 +23,7 @@ GET_IPV4_SHELL_COMMAND = "ip a | grep {} | grep inet | cut -d' ' -f6 | cut -d'/'
|
|||||||
NR_CQI_COMMAND = b'AT+QNWCFG="nr5g_csi"\r\n'
|
NR_CQI_COMMAND = b'AT+QNWCFG="nr5g_csi"\r\n'
|
||||||
NR_SERVINGCELL_COMMAND = b'AT+QENG="servingcell"\r\n'
|
NR_SERVINGCELL_COMMAND = b'AT+QENG="servingcell"\r\n'
|
||||||
NR_EN_DC_STATUS_COMMAND = b"AT+QENDC\r\n"
|
NR_EN_DC_STATUS_COMMAND = b"AT+QENDC\r\n"
|
||||||
NR_SERIAL_RESPOND_TIME = 0.3 # s
|
NR_SERIAL_RESPOND_TIME = 0.5 # s
|
||||||
CMD_TIME_EPOCH = "date +%s"
|
CMD_TIME_EPOCH = "date +%s"
|
||||||
TIMEOUT_OFFSET = 10.0
|
TIMEOUT_OFFSET = 10.0
|
||||||
WAIT_AFTER_IPERF = 5.0
|
WAIT_AFTER_IPERF = 5.0
|
||||||
@@ -224,7 +224,7 @@ def monitor_serial(ser, output_file):
|
|||||||
)
|
)
|
||||||
for cmd in run_cmds:
|
for cmd in run_cmds:
|
||||||
ser.write(cmd)
|
ser.write(cmd)
|
||||||
sleep(0.3)
|
sleep(NR_SERIAL_RESPOND_TIME)
|
||||||
response += ser.read(ser.inWaiting()).decode("utf-8")
|
response += ser.read(ser.inWaiting()).decode("utf-8")
|
||||||
response = (
|
response = (
|
||||||
response.replace("\n", ";")
|
response.replace("\n", ";")
|
||||||
|
|||||||
Reference in New Issue
Block a user