为编程爱好者分享易语言教程源码的资源网
好用的代理IP,游戏必备 ____广告位招租____ 服务器99/年 ____广告位招租____ ____广告位招租____ 挂机,建站服务器
好用的代理IP,游戏必备 ____广告位招租____ 服务器低至38/年 ____广告位招租____ ____广告位招租____ 挂机,建站服务器

网站首页 > 脚本专栏 > 按键精灵相关 > 按键精灵Q语言 正文

按键精灵自动烧写测试脚本源码

三叶资源网 2018-10-31 22:37:15 按键精灵Q语言 1852 ℃ 0 评论

【功能说明】 

<51单片机烧写测试流程自动控制> 

【使用说明】 

<启动时要非烧写软件窗口,烧写软件要先设置好芯片和要下载的文件,先运行测试软件,设置循环延时为0秒,设置安全删除硬件为总是显示>

@[email protected] 

脚本附件:en_open.bmp, flip.bmp, insert.bmp, run.bmp, run_end.bmp, USB_TEST.bmp

运行环境:分辨率:1024x768 色深:32位 操作系统:Windows XP 按键精灵版本:7.02.4325

//UserVar Var1=0 设置内容  
PutAttachment *.bmp  
dim now  
//打开USB口  
VBSCall FindPic(140,740,1024,768,"Attachment:\flip.bmp",0.9,intX,intY)  
If intX<1  
    MessageBox "烧写软件未运行"  
Return   
EndIf   
MoveTo intX,intY  
LeftClick 1  
KeyDown 18,1  
Delay 200  
KeyPress 83,1  
Delay 200  
KeyPress 67,1  
Delay 200  
KeyPress 85,1  
Delay 200  
KeyUp 18,1  
VBSCall FindPic(0,0,1024,768,"Attachment:\en_open.bmp",0.8,intX,intY)  
MoveTo intX,intY  
LeftClick 1  
Delay 1000  
//开始烧写  
VBSCall FindPic(0,0,1024,768,"Attachment:\run.bmp",1.0,intX,intY)  
If intX<1  
Return   
EndIf   
MoveTo intX,intY  
Delay 200  
LeftClick 1  
Delay 15000  
//烧写是否完成完成  
now=0  
VBSCall FindPic(0,0,1024,768,"Attachment:\run_end.bmp",1.0,intX,intY)  
While intX<1  
    Delay 800  
    VBSCall FindPic(0,0,1024,768,"Attachment:\run_end.bmp",1.0,intX,intY)  
    now=now+1  
    If now>10  
        MessageBox "烧写失败"  
    Return   
EndIf   
//    MoveTo intX,intY  
EndFor   
//MessageBox "拔除跳线"  
//启动应用程序  
VBSCall FindColor(0,0,1024,768,"0000FF",intX,intY)  
MoveTo intX+5,intY+5  
LeftClick 1  
Delay 200  
//检测USB是否已经被识别  
VBSCall FindPic(850,730,1024,768,"Attachment:\insert.bmp",0.8,intX,intY)  
While intX<1  
    Delay 800  
    VBSCall FindPic(850,730,1024,768,"Attachment:\insert.bmp",0.8,intX,intY)  
    //    MoveTo intX,intY  
EndFor   
//开始测试  
MessageBox "请插卡"  
VBSCall FindPic(0,0,1024,768,"Attachment:\USB_TEST.bmp",0.9,intX,intY)  
MoveTo intX,intY  
LeftClick 1  
Delay 200  
KeyDown 18,1  
Delay 200  
KeyPress 84,1  
Delay 200  
KeyUp 18,1  
Delay 200  
//判断是否测试完成  
VBSCall GetColor=GetPixelColor(356,482)  
While GetColor="995E41"  
    Delay 800  
    VBSCall GetColor=GetPixelColor(356,482)  
    //    MoveTo intX,intY  
EndFor   
//回车结束一次烧写测试  
Delay 10000  
KeyPress 13,1  
Return


文件下载


来源:三叶资源网,欢迎分享,公众号:iisanye,(三叶资源网⑤群:21414575

本文暂时没有评论,来添加一个吧(●'◡'●)

欢迎 发表评论:

百度站内搜索
关注微信公众号
三叶资源网⑤群:三叶资源网⑤群

网站分类
随机tag
QQ邮箱扫码登录高级输入框数据结构vue滑动验证码手动记牌文字识别纯组件实现圆形头像自动循环显示列表项目贴吧采集信息框贪玩蓝月键值排序数据库今日头条聊呗协议标签浏览器益友会黑猫论坛IMAP收信
最新评论