添加web
This commit is contained in:
38
web/layui/plugin/jw3524test.js
Normal file
38
web/layui/plugin/jw3524test.js
Normal file
@@ -0,0 +1,38 @@
|
||||
function jw3524test()
|
||||
{
|
||||
var obj = $('#Oper_View');
|
||||
var content_str = '<div class="layui-row" style="line-height: 1.8rem; padding-top: 2px;">';
|
||||
content_str += '<div class="layui-col-xs2">';
|
||||
content_str += ' <button type="button" class="layui-btn layui-btn-normal " style="height: 1.8rem; line-height: 1.8rem;width: 90%; padding: 0 3px;" onclick="JW3425Test_Run()">测试</button>'
|
||||
content_str += '</div></div>';
|
||||
obj.append(content_str);
|
||||
ShowCommMes("插件加载成功", MesgType.MESG_TYPE_INFO);
|
||||
|
||||
}
|
||||
|
||||
async function JW3425Test_Run()
|
||||
{
|
||||
epro2_oper.cmd = 1;
|
||||
await Ep2_Charge();
|
||||
ShowCommMes("充电等待 20S", MesgType.MESG_TYPE_INFO);
|
||||
for(var i= 0 ; i < 20; i++)
|
||||
{
|
||||
await TransSleep(1000);
|
||||
}
|
||||
epro2_oper.commaddr = 1;
|
||||
epro2_oper.pwd = "20191029";
|
||||
epro2_oper.cmd = 19;
|
||||
await Ep2_VerifiPwdCmd(epro2_oper.commaddr,epro2_oper.pwd);
|
||||
await TransSleep(100);
|
||||
epro2_oper.cmd = 32;
|
||||
epro2_oper.delayfire = 0;
|
||||
epro2_oper.commaddr = 1;
|
||||
await Ep2_WriteDelay();
|
||||
await TransSleep(100);
|
||||
epro2_oper.cmd = 7;
|
||||
await Ep2_ClkAmend(1,500);
|
||||
await TransSleep(100);
|
||||
epro2_oper.cmd = 12;
|
||||
await Ep2_Blast();
|
||||
|
||||
}
|
Reference in New Issue
Block a user