UDB Counter values update

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
jepaz
Level 4
Level 4
25 replies posted 10 replies posted 10 questions asked

Hi Everyone,

   

I am having trouble with a Counter, my program has an EEPROM memory from which it reads the values and updates the counter,

   

I cant get the values to update.

   

the counter triggers an interrupt with a compare value

   

void update(){ 
    Counter_Stop();
     Counter_WritePeriod(revcount);
    Counter_WriteCompare(revcount);     
    Counter_WriteCounter(0); 

   

   Counter_SaveConfig();  
    Timer_WritePeriod(Period);  
    Timer_WriteCounter(Period); 
    Counter_Start();
    clr();screen();
}

0 Likes
7 Replies