已阅读5页,还剩9页未读, 继续免费阅读
版权说明:本文档由用户提供并上传,收益归属内容提供方,若内容存在侵权,请进行举报或认领
文档简介
JITIN EQU P0.0 SZDAN EQU P0.1 KUAIJN EQU P0.2 ZHZHAN EQU P0.3 KUAITUI EQU P0.4 ZHZHSRU EQU P0.5 GJFSXZ EQU P0.6 YANSHIR EQU P0.7 YDWEI EQU P3.2 GONGJIN1 EQU P3.3 GONGJIN2 EQU P3.4 JIESHUWEI EQU P3.5 ZZSHUC_Y0 EQU P1.0 KJSHUC_Y1 EQU P1.1 KTSHUC_Y2 EQU P1.2 YSSHUC_Y3 EQU P1.3 GJSHUC_Y4 EQU P1.4 WDT_CONTR EQU 0E1H ; 开看门狗 WDT_CONTR_1 EQU 00111010B ; 开看门狗;-;初始化;- ORG 0000H LJMP MAIN ORG 000BH AJMP TIME0 ORG 0030H;-;初始化设置;-MAIN: CALL YS20MS MOV P0,#0FFH MOV P1,#0FFH MOV P2,#0FFH MOV P3,#0FFH MOV SP,#50H MOV SP,#50H MOV TMOD,#00000001B MOV TH0,#00H MOV TL0,#10H SETB EA SETB ET0 SETB TR0 CALL YS20MS MOV P0,#0FFH MOV P1,#0FFH MOV P2,#0FFH MOV P3,#0FFH MOV SP,#50H MOV TMOD,#00000001B MOV TH0,#00H MOV TL0,#10H SETB EA SETB ET0 SETB TR0 MOV WDT_CONTR,#WDT_CONTR_1 ;开看门狗,290ms,;-;按键检测;-LOOP0: JB JITIN,LOOP1 NOPLOOP1: JB JITIN,LOOP2 CALL YS20MS JB JITIN,LOOP2 MOV P1,#0FFH NOP MOV P1,#0FFH AJMP LOOP0 NOP AJMP LOOP0LOOP2: NOP JB SZDAN,LOOP5 CALL YS20MS JB SZDAN,LOOP5 AJMP START10 NOP AJMP START10 NOPLOOP5: AJMP START50 NOP AJMP START50;-;自动运行;-START10: NOP JB JITIN,START11 CALL YS20MS JB JITIN,START11 AJMP LOOP0 NOP AJMP LOOP0START11: NOP JB SZDAN,START14 CALL YS20MS JB SZDAN,START14START12: NOP JB GJFSXZ,START13 START13: CALL YS20MS JB GJFSXZ,START15 CALL YS20MS JB GJFSXZ,START15 AJMP START30 NOP AJMP START30START14: NOP MOV P1,#0FFH NOP MOV P1,#0FFH AJMP LOOP0 NOP AJMP LOOP0;-;-;-START15: NOP JB ZHZHAN,START10 CALL YS20MS JB ZHZHAN,START10 NOP JB YDWEI,START10 CALL YS20MS JB YDWEI,START10 JNB JITIN,START10 CALL YS20MS JNB JITIN,START10 CLR ZZSHUC_Y0 NOP CLR ZZSHUC_Y0 CALL YS1S ;-;-START16: NOP JNB GONGJIN1,START19 CALL YS20MS JNB GONGJIN1,START19START17: NOP JB ZHZHSRU,START180 CALL YS20MS JB ZHZHSRU,START180START18: NOP JNB JITIN,START180 CALL YS20MS JNB JITIN,START180 JNB KTSHUC_Y2,START180 CALL YS20MS JNB KTSHUC_Y2,START180 CLR KJSHUC_Y1 NOP CLR KJSHUC_Y1 NOP AJMP START16 , NOP AJMP START16START180: AJMP START25 NOP AJMP START25;-;-START19: NOP SETB KJSHUC_Y1 NOP SETB KJSHUC_Y1START20: NOP JNB JIESHUWEI,START23 CALL YS20MS JNB JIESHUWEI,START23START21: NOP JB ZHZHSRU,START25 CALL YS20MS JB ZHZHSRU,START25START22: NOP JNB JITIN,START25 CALL YS20MS JNB JITIN,START25 CALL START220 AJMP START20 NOP AJMP START20;-;-START23: JNB YDWEI,START25 CALL YS20MS JNB YDWEI,START25 JNB KJSHUC_Y1,START25 CALL YS20MS JNB KJSHUC_Y1,START25 CLR KTSHUC_Y2 NOP CLR KTSHUC_Y2START24: JNB JITIN,START25 CALL YS20MS JNB JITIN,START25 NOP AJMP START23 NOP AJMP START23START25: MOV P1,#0FFH NOP MOV P1,#0FFH AJMP START10 NOP AJMP START10;-;-;- START30: NOP JB ZHZHAN,START25 CALL YS20MS JB ZHZHAN,START25 NOP JB YDWEI,START25 CALL YS20MS JB YDWEI,START25 JNB JITIN,START25 CALL YS20MS JNB JITIN,START25 CLR ZZSHUC_Y0 NOP CLR ZZSHUC_Y0 CALL YS1S ;-;-START31: NOP JNB GONGJIN1,START34 CALL YS20MS JNB GONGJIN1,START34START32: NOP JB ZHZHSRU,START25 CALL YS20MS JB ZHZHSRU,START25 NOP JNB JITIN,START25 CALL YS20MS JNB JITIN,START25 JNB KTSHUC_Y2,START25 CALL YS20MS JNB KTSHUC_Y2,START25 CLR KJSHUC_Y1 NOP CLR KJSHUC_Y1 NOP AJMP START31 NOP AJMP START31;-;-START34: NOP SETB KJSHUC_Y1 NOP SETB KJSHUC_Y1;-START35: JNB GONGJIN2,START36 CALL YS20MS JNB GONGJIN2,START36 NOP JNB JIESHUWEI,LOP0 NOP JNB JIESHUWEI,LOP0 NOP JB ZHZHSRU,LOP1 CALL YS20MS JB ZHZHSRU,LOP1 JNB JITIN,LOP1 CALL YS20MS JNB JITIN,LOP1 CALL START220 AJMP START35 NOP AJMP START35;-START36: NOP CLR YSSHUC_Y3 NOP CLR YSSHUC_Y3 JNB JIESHUWEI,LOP0 CALL YS20MS JNB JIESHUWEI,LOP0 NOP JB ZHZHSRU,LOP1 CALL YS20MS JB ZHZHSRU,LOP1 JNB JITIN,LOP1 CALL YS20MS JNB JITIN,LOP1 JB YANSHIR,START36 NOP JB YANSHIR,START36 JNB KJSHUC_Y1,LOP1 CALL YS20MS JNB KJSHUC_Y1,LOP1 CLR KTSHUC_Y2 NOP CLR KTSHUC_Y2 NOP SETB YSSHUC_Y3 NOP SETB YSSHUC_Y3;-START37: JNB GONGJIN1,START38 CALL YS20MS JNB GONGJIN1,START38 NOP JNB YDWEI,LOP1 CALL YS20MS JNB YDWEI,LOP1 JNB JITIN,LOP1 CALL YS20MS JNB JITIN,LOP1 AJMP START37 NOP AJMP START37LOP0: AJMP START42 NOP AJMP START42LOP1: AJMP START43 NOP AJMP START43;-START38: SETB KTSHUC_Y2 NOP SETB KTSHUC_Y2 CALL YS1S JNB JITIN,LOP1 CALL YS20MS JNB JITIN,LOP1 JB ZHZHSRU,LOP1 CALL YS20MS JB ZHZHSRU,LOP1 CALL YS1S JNB JITIN,LOP1 CALL YS20MS JNB JITIN,LOP1 JB ZHZHSRU,LOP1 CALL YS20MS JB ZHZHSRU,LOP1 JNB KTSHUC_Y2,LOP1 CALL YS20MS JNB KTSHUC_Y2,LOP1 CLR KJSHUC_Y1 NOP CLR KJSHUC_Y1;-START39: JNB GONGJIN2,START40 CALL YS20MS JNB GONGJIN2,START40 NOP JNB JIESHUWEI,START42 CALL YS20MS JNB JIESHUWEI,START42 NOP JB ZHZHSRU,START43 CALL YS20MS JB ZHZHSRU,START43 JNB JITIN,START43 CALL YS20MS JNB JITIN,START43 AJMP START39 NOP AJMP START39START40: SETB KJSHUC_Y1 NOP SETB KJSHUC_Y1 SETB YSSHUC_Y3 NOP SETB YSSHUC_Y3;-START41: JNB JIESHUWEI,START42 CALL YS20MS JNB JIESHUWEI,START42 NOP JB ZHZHSRU,START43 CALL YS20MS JB ZHZHSRU,START43 JNB JITIN,START43 CALL YS20MS JNB JITIN,START43 CALL START220 AJMP START41 NOP AJMP START41;-START42: JNB KJSHUC_Y1,START43 CALL YS20MS JNB KJSHUC_Y1,START43 CLR KTSHUC_Y2 NOP CLR KTSHUC_Y2 JNB YDWEI,START43 CALL YS20MS JNB YDWEI,START43 NOP JNB JITIN,START43 ; CALL YS20MS JNB JITIN,START43 AJMP START42 NOP AJMP START42;-START43: MOV P1,#0FFH NOP MOV P1,#0FFH AJMP START10 NOP AJMP START10;-;-START50: NOP JB JITIN,START51 CALL YS20MS JB JITIN,START51 MOV P1,#0FFH NOP MOV P1,#0FFH AJMP START50 NOP AJMP START50START51: NOP JB SZDAN,START52 CALL YS20MS JB SZDAN,START52 MOV P1,#0FFH NOP MOV P1,#0FFH AJMP LOOP0 NOP AJMP LOOP0;-START52: NOP JB ZHZHAN,START54 CALL YS20MS JB ZHZHAN,START54 NOP JNB JIESHUWEI,START54 CALL YS20MS JNB JIESHUWEI,START54 CLR ZZSHUC_Y0 NOP CLR ZZSHUC_Y0START53: NOP JB JIESHUWEI,START54 CALL YS20MS JB JIESHUWEI,START54 SETB ZZSHUC_Y0 NOP SETB ZZSHUC_Y0;-START54: NOP JNB GONGJIN1,START55 CALL YS20MS JNB GONGJIN1,START55 NOP JNB KTSHUC_Y2,START55 CALL YS20MS JNB KTSHUC_Y2,START55 MOV C,KUAIJN MOV KJSHUC_Y1,C AJMP START56 NOP AJMP START56START55: NOP NOP SETB KJSHUC_Y1 NOP SETB KJSHUC_Y1;-START56: NOP JNB YDWEI,START57 CALL YS20MS JNB YDWEI,START57 NOP JNB KJSHUC_Y1,START57 CALL YS20MS JNB KJSHUC_Y1,START57 MOV C,KUAITUI MOV KTSHUC_Y2,C AJMP START58 NOP AJMP START58START57: SETB KTSHUC_Y2 NOP SETB KTSHUC_Y2START58: JB JIESHUWEI,START59 CALL YS20MS JB JIESHUWEI,START59 SETB ZZSHUC_Y0 NOP SETB ZZSHUC_Y0START59: NOP AJMP START50 NOP AJMP ST
温馨提示
- 1. 本站所有资源如无特殊说明,都需要本地电脑安装OFFICE2007和PDF阅读器。图纸软件为CAD,CAXA,PROE,UG,SolidWorks等.压缩文件请下载最新的WinRAR软件解压。
- 2. 本站的文档不包含任何第三方提供的附件图纸等,如果需要附件,请联系上传者。文件的所有权益归上传用户所有。
- 3. 本站RAR压缩包中若带图纸,网页内容里面会有图纸预览,若没有图纸预览就没有图纸。
- 4. 未经权益所有人同意不得将文件中的内容挪作商业或盈利用途。
- 5. 人人文库网仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对用户上传分享的文档内容本身不做任何修改或编辑,并不能对任何下载内容负责。
- 6. 下载文件中如有侵权或不适当内容,请与我们联系,我们立即纠正。
- 7. 本站不保证下载资源的准确性、安全性和完整性, 同时也不承担用户因使用这些下载资源对自己和他人造成任何形式的伤害或损失。
最新文档
- 爆破作业培训
- 《商品贸易学》课件
- 下载课件有哪些
- 《中国历史人物介绍》课件
- 找规律教学课件
- 农场旧房出售合同模板2024
- 2024年度影视制作与动产质押合同3篇
- 委托协议书范本
- “胜华”红木家具厂推广提案课件
- 贝聿铭课件教学课件
- GB/T 3798-2021汽车大修竣工出厂技术条件
- GB/T 2899-2017工业沉淀硫酸钡
- GB/T 18705-2002装饰用焊接不锈钢管
- 2023年贵州省普通高中学业水平考试历史试卷
- 培智学校启智教育人教版生活数学第四册认识人民币课件
- 小学数学六年级《外方内圆和外圆内方》优秀教学设计
- 压实度试验检测报告
- 急性中毒现场急救
- 气象站点分布信息
- 劳保用品发放记录表
- 收购协议模板(双语)Acquisition Agreement
评论
0/150
提交评论