lpcware

HardFault error

Discussion created by lpcware Employee on Jun 15, 2016
Latest reply on Jun 15, 2016 by lpcware
Content originally posted in LPCWare by toniojesusde on Thu Apr 14 09:54:48 MST 2011
I have the next piece of code in my application. TIM2TCold is a global variable.
When I try to copy the contents of the counter/timer 2 from my timer0 handler i get a HARDFAULT! any ideas???

void TIMER0_IRQHandler(void) {//interrupt each second
    TIM2TCold=LPC_TIM2->TC;

many thanks,

Antonio

Outcomes