Email: Password: Remember Me | Create Account (Free)

Back to Subject List

Old thread has been locked -- no new posts accepted in this thread
???
12/08/10 08:57
Read: times


 
#179983 - This is the case here (LPC17xx)...
Responding to: ???'s previous message
... and I believe in most similar chips. There is a "fan-in" from various sources of interrupts in one peripheral (with individual enable bits) into a single input into the interrupt controller; and there are around two dozens of such inputs with an enable bit each; and then of course the "global" interrupt enable (whatever it is called) in the core itself.

This reveals one more weakness of this (and I believe others too) ARM-based "microcontrollers" (SoCs): there is only one interrupt vector for a peripheral, which is shared for all kinds of interrupt that peripheral can generate. I remember from the "kitchen sink" thread a couple of years ago that quite a couple of people "requested" a separate interrupt for UART Rx and Tx in the '51. So, for those moving to ARMs, this is a bad news: upon each interrupt, one has to find out what was its particular source, if there are more than one enabled for that particular interrupt vector (i.e. peripheral).

There is one more unfortunate consequence of this architecture: there is no automatic "source" interrupt flag clear upon entering the interrupt service routine. So, the required procedure is to 1. find all the sources which triggered this interrupt; 2. clear their flags; 3. do the work itself.

So, at the end of the day, interrupt handling on ARMs is much clumsier than we were used to from real microcontrollers. Knowing that they are not microcontrollers I am not surprised nor shocked, just disappointed.

JW


List of 12 messages in thread
TopicAuthorDate
[ARM] Default state of interrupts            01/01/70 00:00      
   Normally vectorized interrupt controller            01/01/70 00:00      
      but isn't this the case with ALL microcontrollers?            01/01/70 00:00      
         Often three layers of enable            01/01/70 00:00      
            This is the case here (LPC17xx)...            01/01/70 00:00      
               May vary a lot            01/01/70 00:00      
      Not the case anymore for Cortex-M3s.            01/01/70 00:00      
   Startup code?            01/01/70 00:00      
      not startup code, but the after-reset state            01/01/70 00:00      
         Hw-acceleration            01/01/70 00:00      
   According to the datasheet of my CM3 ...            01/01/70 00:00      
      ... but if we dig deeper to the datasheets...            01/01/70 00:00      

Back to Subject List