lpcware

Timer + Interrupt difficulties

Discussion created by lpcware Employee on Jun 15, 2016
Latest reply on Jun 15, 2016 by lpcware
Content originally posted in LPCWare by Sepheriod on Wed Jul 25 08:06:43 MST 2012
Hello, I'm using an LPC 11c24 MCU and my program consists of 2 ISR's ran by 2 seperate timers. timer_32_0 and timer_32_1

timer_32_0 runs on 1hz and the ISR takes about 150 mS to handle all the instructions in the ISR

timer_32_1 runs on 1000hz and is done in a few microseconds.

These timers have to run at the same time.

But the problem now is that when timer_32_0 is active for that 150 mS timer_32_1 is inactive.

if I change around the NVIC priorities timer_32_1 is always active and timer_32_0 is never called.

NVIC_SetPriority(TIMER_32_1_IRQn, 4);

is there a way to work around this problem?

Outcomes