?? os_int_a.s
字號:
;********************************************************************************************************
; uC/OS-II
; The Real-Time Kernel
;
; (c) Copyright 1992-2002, Jean J. Labrosse, Weston, FL
; All Rights Reserved
;
; File : OS_CPU_A.ASM
; By : Jean J. Labrosse
;********************************************************************************************************
;********************************************************************************************************
; ARM7 Port
;
; Target : ARM7 (Includes ARM7TDMI, ARM710T, ARM720T, ARM740T)
; Ported by : Michael Anburaj
; URL : http://geocities.com/michaelanburaj/ Email : michaelanburaj@hotmail.com
;
;********************************************************************************************************
AREA UCOS_ARM_ASM_INT, CODE, READONLY
;*********************************************************************************************************
; IRQ HANDLER
;
; This handles all the IRQs
; Note: FIQ Handler should be written similar to this
;
;*********************************************************************************************************
IMPORT OSIntEnter
IMPORT OSIntExit
IMPORT OSIntCtxSwFlag
IMPORT _IntCtxSw
MACRO
$IRQ_AsmEntery HANDLER $IRQ_CEntry
EXPORT $IRQ_AsmEntery ; 輸出的標(biāo)號
IMPORT $IRQ_CEntry ; 引用的外部標(biāo)號
$IRQ_AsmEntery
stmfd sp!,{r0-r3,r12,lr}
bl OSIntEnter
bl $IRQ_CEntry
bl OSIntExit
ldr r0,=OSIntCtxSwFlag
ldr r1,[r0]
cmp r1,#1
beq _IntCtxSw
ldmfd sp!,{r0-r3,r12,lr}
subs pc,lr,#4
MEND
;所有的中斷按如下的格式在注冊(引用上面的宏定義)
;$IRQ_AsmEntery HANDLER $IRQ_CEntry
;串口0中斷
IRQASMUart0 HANDLER IRQCUart0
;串口0中斷
IRQASMUart1 HANDLER IRQCUart1
END
?? 快捷鍵說明
復(fù)制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -