Hello RIOTers, I tried to implement a hwtimer for MKW2xDxxx and failed.
The MCU has 4 downcounter PIT(Periodic Interrupt Timmer) 32-bit timers, PITs can be cascaded so that timer[0] acts as prescaler for timer[1]. PIT can be loaded with a start value. The timer will count down and generate an interrupt at 0. Then the start value will be reloaded and it will repeating. PITs can not run in low power modes. Apart from the fact that it is a down counter, the timer do not work in low power mode, and that bothers me. The MCU has also one Low-Power Timer. This one is a upcounter 16-bit timer with compare register and can be configured as as Free-Running Counter (reset on overflow not on compare match). Also LPTMR can run in (very) low power modes. I tried to implement the hwtimer with LPTMR. The implementation divided (or multiply) the tick-values by 1000 and run the timer with 1kHz. But this does not work reliable. There is also a RTC module, but it fits even less for the hwtimer. Ideas? Regards, Johann Fischer _______________________________________________ devel mailing list [email protected] http://lists.riot-os.org/mailman/listinfo/devel
