feat: get_tyy_data优化2

This commit is contained in:
caoqianming 2025-05-16 11:12:07 +08:00
parent 1d7c2ebb35
commit 518379ea35
1 changed files with 1 additions and 1 deletions

View File

@ -17,7 +17,7 @@ def get_tyy_data(*args):
resp = sc.recv(1024)
if not resp:
raise ParseError("采集器返回空数据")
if len(resp) < 8:
elif len(resp) < 8:
raise ParseError("设备未启动")
json_data = resp[5:-4]
json_str = json_data.decode('utf-8')