调试Cortex M3(ARM)嵌入式-如何从xPSR.ISR判断正在运行的ISR?

调试Cortex M3(ARM)嵌入式-如何从xPSR.ISR判断正在运行的ISR?,arm,embedded,cortex-m3,Arm,Embedded,Cortex M3,我正在调试arm系列cpu(Cortex M3)上的固件 调试器显示CPU寄存器,包括一个名为“xPSR”的寄存器,其中包括一个子字段“ISR”。CPU寄存器中的模式是'mode=Handler',这意味着m3 CPU处于中断处理程序而不是'thread'模式 我在那里看到了字段xPSR.ISR=15的值。我想那一定是十六进制的15(12月21日)。我从ISR向量表的注释中猜测这是“系统计时器勾号0B”中断。实际上,我现在猜测它是15进制,我正在查看的是SysTick计时器中断处理程序。(注意,

我正在调试arm系列cpu(Cortex M3)上的固件

调试器显示CPU寄存器,包括一个名为“xPSR”的寄存器,其中包括一个子字段“ISR”。CPU寄存器中的模式是'mode=Handler',这意味着m3 CPU处于中断处理程序而不是'thread'模式

我在那里看到了字段xPSR.ISR=15的值。我想那一定是十六进制的15(12月21日)。我从ISR向量表的注释中猜测这是“系统计时器勾号0B”中断。实际上,我现在猜测它是15进制,我正在查看的是SysTick计时器中断处理程序。(注意,由于代码是汇编程序一行程序默认处理程序,其中大约100个不同的asm标签位于一个位置,因此很难从调用ISR的代码中分辨出来。)

然而,我对Cortex M3芯片还很陌生,我对ARM7TDMI的了解由于没有使用它而变得如此淡薄,以至于我记不得了。我在我的文档中到处都找不到这个


有人能告诉我如何解决这个问题吗?

异常数字15十进制是Cortex M3上的SYSTICK中断

有一个表(表5-1-异常类型),列出了M3使用的各种中断号

Exception type    Position       Priority       Description
--------------    ------------   --------       ------------------------------------
Reset               1             –3 (highest)  Invoked on power up and warm reset. On first instruction, 
                                                drops to lowest priority (Thread mode). This is asynchronous.
Non-maskable Int    2             –2            Cannot be stopped or pre-empted by any exception but reset. 
                                                This is asynchronous.
Hard Fault          3             –1            All classes of Fault, when the fault cannot activate because of 
                                                priority or the Configurable Fault handler has been disabled. 
                                                This is synchronous.
Memory Management   4             Configurable  Memory Protection Unit (MPU) mismatch, including access 
                                                violation and no match. This is synchronous. This is used 
                                                even if the MPU is disabled or not present, to support the 
                                                Executable Never (XN) regions of the default memory map.
Bus Fault           5             Configurable  Pre-fetch fault, memory access fault, and other 
                                                address/memory related. This is synchronous when precise 
                                                and asynchronous when imprecise.
Usage Fault         6             Configurable  Usage fault, such as Undefined instruction executed or illegal 
                                                state transition attempt. This is synchronous.
  -                 7-10            -           Reserved
SVCall              11            Configurable  System service call with SVC instruction. This is 
                                                synchronous.
Debug Monitor       12            Configurable  Debug monitor, when not halting. This is synchronous, but 
                                                only active when enabled. It does not activate if lower priority 
                                                than the current activation.
  -                 13              -           Reserved
PendSV              14            Configurable  Pendable request for system service. This is asynchronous 
                                                and only pended by software.
SysTick             15            Configurable  System tick timer has fired. This is asynchronous.

External Interrupt  16 and above  Configurable  Asserted from outside the core, INTISR[239:0], and fed 
                                                through the NVIC (prioritized). These are all asynchronous.