Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependents: SSD1306_smart_watch
Fork of mbed-src by
Diff: targets/hal/TARGET_Freescale/TARGET_KLXX/us_ticker.c
- Revision:
- 97:a69e21de83fb
- Parent:
- 82:0b31dbcd4769
- Child:
- 304:89b9c3a9a045
diff -r c359415e941f -r a69e21de83fb targets/hal/TARGET_Freescale/TARGET_KLXX/us_ticker.c
--- a/targets/hal/TARGET_Freescale/TARGET_KLXX/us_ticker.c Tue Feb 18 15:45:07 2014 +0000
+++ b/targets/hal/TARGET_Freescale/TARGET_KLXX/us_ticker.c Tue Feb 18 18:00:05 2014 +0000
@@ -44,7 +44,7 @@
PIT->CHANNEL[1].TCTRL |= PIT_TCTRL_TEN_MASK; // Start timer 1
// Use channel 0 as a prescaler for channel 1
- PIT->CHANNEL[0].LDVAL = bus_frequency() / 1000000 - 1;
+ PIT->CHANNEL[0].LDVAL = (bus_frequency() + 500000) / 1000000 - 1;
PIT->CHANNEL[0].TCTRL = PIT_TCTRL_TEN_MASK; // Start timer 0, disable interrupts
}
