在Firmware library的介绍中(UM0427 User manual) Page224 有下表 Table 272. Pre-emption priority and subpriority values(1)(2) NVIC_PriorityGroup NVIC_IRQChann elPreemptionPri ority NVIC_IRQChan nelSubPriority Description NVIC_PriorityGroup_ 0 0 0-15 0 bits for pre-emption priority 4 bits for subpriority NVIC_PriorityGroup_ 1 0-1 0-7 1 bits for pre-emption priority 3 bits for subpriority NVIC_PriorityGroup_ 2 0-3 0-3 2 bits for pre-emption priority 2 bits for subpriority NVIC_PriorityGroup_ 3 0-7 0-1 3 bits for pre-emption priority 1 bits for subpriority NVIC_PriorityGroup_ 4 0-15 0 4 bits for pre-emption priority 0 bits for subpriority
在Cortex-M3 Revision: r1p1 Technical Reference Manual Page8—22 有下表 Interrupt priority grouping field: PRIGROUP Split of pre-emption priority from subpriority 0 7.1 indicates seven bits of pre-emption priority, one bit of subpriority 1 6.2 indicates six bits of pre-emption priority, two bits of subpriority 2 5.3 indicates five bits of pre-emption priority, three bits of subpriority 3 4.4 indicates four bits of pre-emption priority, four bits of subpriority 4 3.5 indicates three bits of pre-emption priority, five bits of subpriority 5 2.6 indicates two bits of pre-emption priority, six bits of subpriority 6 1.7 indicates one bit of pre-emption priority, seven bits of subpriority 7 0.8 indicates no pre-emption priority, eight bits of subpriority.