tick.asm

来自「ucos在z80上的移植」· 汇编 代码 · 共 55 行

ASM
55
字号
;********************************************************************************************************
;                                               uC/OS
;                        Microcomputer Real-Time Multitasking Operating System
;                                               KERNEL
;
;                         (c) Copyright 1994, Jean J. Labrosse, Plantation, FL
;                                          All Rights Reserved
;
;
;                                               TICK ISR
;                                                 Z-80
;
; File : TICK.ASM
; By   : Jean J. Labrosse
;********************************************************************************************************


;*********************************************************************************************************
;                                            HANDLE TICK ISR
;*********************************************************************************************************

_TickISR:

            EI                              ; Allow interrupt nesting
;
            PUSH   AF                       ; Save task's context
            PUSH   BC
            PUSH   DE
            PUSH   HL
            PUSH   IX
            PUSH   IY
;
            CALL   _OSIntEnter              ; Notify uC/OS of ISR
            CALL   _OSTimeTick              ; Process system tick
            CALL   _OSIntExit               ; Notify uC/OS of end of ISR
;
            POP    IY                       ; Restore interrupted task's context
            POP    IX
            POP    HL
            POP    DE
            POP    BC
            POP    AF
;
            RETI                            ; Return to interrupted task

_TickISR

            PUBLIC _TickISR

            EXTRN  _OSIntEnter
            EXTRN  _OSIntExit
            EXTRN  _OSTimeTick

            END

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?