I have the cc1111 timer4 set up as follows:
clock 24MHz
timer tick using prescalar 128
// f=187500Hz/64/5=3kHz/5 --> 1.7ms / IRQ T4CCTL0 = 0x44; T4CC0 = 0x04; T4CTL = 0xDE; INT_ENABLE(INUM_T4, INT_ON);
Now here is the issue, changing T4CC0 or T4CCTL0 prescalar or even the clock frequency does not seem to change the interrupt frequency.... I am trying to space the interrupts by approx 30 seconds and cannot seem to achieve that no matter what? What am I doing wrong? I am also clearing the interrupt flag in the interrupt routine as follows:
#pragma vector=T4_VECTOR __interrupt void timer4_ISR(void) { // Clear IRQ flag TIMIF &= ~BIT3;
}
Fahd