AnsweredAssumed Answered

ADuCM360 generating periodic interrupt with wake-up timer Reg A & B

Question asked by Lightseek on Nov 20, 2013
Latest reply on Nov 21, 2013 by ABuda

I can't seem to generate a periodic interrupt with the wake-up timer with reg A & B (T2WUFA, T2WUFB). Can you use periodic mode with Red A & B? or is it only with Reg?

 

For example for Reg A, I initialize with the following:

 

WutCfg(T2CON_MOD_PERIODIC,T2CON_WUEN_DIS,T2CON_PRE_DIV1,T2CON_CLK_EXTCLK);

WutCfgInt(T2IEN_WUFA,1);

WutLdWr(0,11);

WutGo(T2CON_ENABLE_EN);

NVIC_EnableIRQ(WUT_IRQn);

 

in the interrupt handler, I just clear the interrupt and try to reload the counter value and reenable the interrupt but the interrupt only seems to fire ONCE:

 

void WakeUp_Int_Handler(void)

{

          WutClrInt(T2CLRI_WUFA);

WutCfgInt(T2IEN_WUFA,1);

  WutLdWr(0,11);

 

}

Outcomes