Demo PAH8011+ HeartRate on nRF52
Dependencies: mbed pixart_heart_rate_demo pixart_heart_rate_lib_keil_m4
Fork of PixArt_PAH8011_HeartRate_nRF52 by
Diff: system_clock.cpp
- Revision:
- 1:3abb06bb21c5
- Parent:
- 0:a6408c845aba
diff -r a6408c845aba -r 3abb06bb21c5 system_clock.cpp --- a/system_clock.cpp Fri Oct 27 08:53:49 2017 +0000 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,31 +0,0 @@ -#include "system_clock.h" - -#include <mbed.h> - - -static Ticker g_ticker; -static volatile uint64_t g_sys_tick = 0; - - -static void system_tick_handle(void) -{ - g_sys_tick++; -} - -void system_clock_init() -{ - g_sys_tick = 0; - - g_ticker.attach(system_tick_handle, 0.001f); -} - -uint64_t system_clock_get_tick() -{ - return g_sys_tick; -} - -uint64_t system_clock_time_to_milliseconds(uint64_t time) -{ - return time; -} -