资源描述:
《限速滤波编程.doc》由会员上传分享,免费在线阅读,更多相关内容在教育资源-天天文库。
1、;****************限速滤波*************/STACK1SEGMENTSTACKDW100hDUP(?)STACK1ENDSDATASEGMENTFUDB10HDATEDB36H,35H,23HAVRDB?CNT=1DATAENDSCODESEGMENTASSUMECS:CODE,DS:DATASTART:MOVAX,DATAMOVDS,AXLEASI,DATELEADI,FUMOVCH,2LP1:MOVBH,[DI]MOVAL,[SI]INCSIMOVAH,[SI]SUBAH
2、,ALJCLP2;比较有借位,CMPAH,BHJGLP4;>SHI跳转至LP5JMPLP3LP2:MOVAH,[SI]SUBAL,AHCMPAL,BH;Y1-Y2>AX跳转至LP5JGLP4JMPLP3LP3:MOVBL,[SI]JMPLP6LP4:DECCHJNZLP1MOVAH,[SI]DECSIMOVAL,[SI]ADDAH,ALSHRAH,1MOVBL,AHLP6:MOVAVR,BLMOVAL,[AVR];分析结果进行显示MOVCL,04HSHRAL,CL;取出数据的十位CMPAL,09HJBE
3、B1ADDAL,07HB1:ADDAL,30H;对A~F的处理MOVDL,AL;对0~9的处理MOVAH,02HINT21HMOVAL,[AVR]ANDAL,0FH;取出数据的各位CMPAL,09HJBEB3ADDAL,07HB3:ADDAL,30H;对A~F的处理MOVDL,AL;对0~9的处理MOVAH,02HINT21HLP8:MOVAH,1;判断是否有按键按下INT16HJZLP8MOVAX,4C00HINT21HCODEENDSENDSTART