Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

nested interrupts in Atmel ARM AT91SAM7S64

Status
Not open for further replies.

Wlodek

Newbie level 2
Joined
Apr 23, 2005
Messages
2
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,281
Activity points
1,295
nested interrupts

have a problem with nested interrupts on ARM. I use Atmel's AT91SAM7S64 chip, and if I enable 2 interrupts, the chip after a while hangs up. For example, I enable interrupt from Time 0 at 200 Hz and from Timer 1 at 4800 Hz. I use Starter Kit with IAR software (C compiler). I did my best, but it doesn't work. Can anybody PLEASE pass me an example how to handle nested interrupts?
 

timer interrupt in at91sam7s64

Salam,

Nested interrupts are accessed according to their priority this insures that the controller will not hang up, i think there is something in your code there may be an infinite loop or a nowhere jump.

Hope i've helped u
 

nested interrupts arm

I dont have any idea of ARM, but on AVR normally when serving an interrupt routine, compilers disable the global interrupt enable bit and enables it after the "ret" from the interrupt (check this in AVR Studio). If there is an interrupt while serving another interrupt, it will be served after the first one finishes. You can enable the "Global interrupt enable bit" in the first statement of your ISR, but that may require carefull coding as this may corrupt stacks etc, if not handled properly.
 

at91sam7s64 timer example code

Try to push all ARM registers into the stack at the begining of ISR and restore all of them back at the ISR end - that should solve your problem. Of course calculate stack size properly to avoid stack overflow .
 

Status
Not open for further replies.

Similar threads

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top