[En-Nut-Discussion] EVK1100 Timing Problem

Philippgl2 mt1961 at thi.de
Tue Oct 14 13:22:57 CEST 2014


Problem solved:

Just put this code in and the board will boot normally with the right
timing:

void NutRegisterTimer(void (*handler) (void *))
{
    /* Set compare value for the specified tick frequency. */
    Set_system_register(AVR32_COMPARE, NutGetCpuClock() / NUT_TICK_FREQ +
Get_system_register(AVR32_COUNT));
	Set_system_register(AVR32_COMPARE, NutGetCpuClock() / NUT_TICK_FREQ ); 
	Set_system_register(AVR32_COUNT, 0);
    sig_sysCompare.ir_handler = handler;
  
    register_interrupt(SystemCompareIrqEntry, AVR32_CORE_COMPARE_IRQ,
AVR32_INTC_INT0);
}


Kind Regards 
Philippgl



--
View this message in context: http://microcontrollers.2385.n7.nabble.com/EVK1100-Timing-Problem-tp192310p192446.html
Sent from the MicroControllers - Ethernut mailing list archive at Nabble.com.


More information about the En-Nut-Discussion mailing list