delay.asm
来自「胎压监测系统接收端控制器motorolar开发源代码」· 汇编 代码 · 共 23 行
ASM
23 行
* Delay.asm
**********************************************************************
* Delay *
* Simple delay routine. Delay time is equal to: *
* (7+3)+(256*5*XR)+(XR*3)+4 *
* bus cycles, or 1283*XR + 14. *
* If the bus frequency is 1.2288MHz, this is equal to just over *
* 1 ms per XR bit. *
* *
* INPUT: Cycle count in XR *
* Usage example: *
* LDX #DELAY *
* JSR Delay *
**********************************************************************
;7 bus cycles to get here
Delay: CLR BUFFER ;3 bus cycles
LoopX: DBNZ BUFFER,LoopX ;5 bus cycles
DBNZX LoopX ;3 bus cycles
Finished: RTS ;4 bus cycles
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?