README中增加整机自动化测试前需要调整速度滑块的提醒,完善current数据预处理的逻辑

This commit is contained in:
gitea 2024-08-16 16:05:31 +08:00
parent 8f342832b2
commit 62e5e6ab50
2 changed files with 4 additions and 3 deletions

View File

@ -146,6 +146,7 @@ pyinstaller --noconfirm --onedir --windowed --optimize 2 --contents-directory .
10. 由于xCore系统问题运行过程中可能会出现机器人宕机问题如果遇到可以手动重启控制柜重新运行
11. 务必正确填写configs.xlsx中的Target页面A1单元格可以选择正负方向急停
12. 工程文件可以手动重命名,按照机型存档,或者导出用于自动化测试
13. 自动化测试前需要将HMI程序速度设置为100%并同步至控制器,也即左下方速度滑条滑动至最大
#### 6) 电机电流自动化测试

View File

@ -28,16 +28,16 @@ def initialization(path, sub, w2t):
filename = data_file.split('\\')[-1]
if data_file.endswith('configs.xlsx'):
count += 1
elif sub == 'cycle' and data_file.endswith('.xlsx'):
elif sub == 'cycle' and data_file.endswith('T_电机电流.xlsx'):
count += 1
else:
if not (match('j[1-7].*\\.data', filename) or match('j[1-7].*\\.csv', filename)):
msg = f"不合规 {data_file}\n"
msg += f"所有文件必须以 jx_ 开头,以 .data/csv 结尾x取值1-7请检查后重新运行。"
msg += f"所有数据文件必须以 jx_ 开头,以 .data/csv 结尾x取值1-7,配置文件需要命名为\"configs.xlsx\",结果文件需要命名为\"T_电机电流.xlsx\",请检查后重新运行。"
w2t(msg, 0, 6, 'red')
if not ((sub == 'cycle' and count == 2) or (sub != 'cycle' and count == 1)):
w2t("使用max/avg功能时需要有配置文件表格使用cycle功能时需要有电机电流数据处理和配置文件两个表格确认后重新运行", 0, 5, 'red')
w2t("使用max/avg功能时需要有配置文件表格\"configs.xlsx\"使用cycle功能时需要有电机电流数据处理\"T_电机电流.xlsx\"和配置文件\"configs.xlsx\"两个表格,确认后重新运行!", 0, 5, 'red')
return data_files