stm32f103
 All Classes Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
system.h
Go to the documentation of this file.
1 #ifndef STM32F103_LIB_SYSTEM_H_
2 #define STM32F103_LIB_SYSTEM_H_
3 
4 #include <cstdint>
5 #include <memory>
6 
7 #include "timer_device.h"
8 
12 class System {
13  public:
17  static void Init();
23  static uint32_t GetMs();
24 
25  private:
29  static void TicksListener();
30 
34  static uint32_t counter_;
38  static std::unique_ptr<TimerDevice> ticker_;
39 };
40 
41 #endif // STM32F103_LIB_SYSTEM_H_
Implements the system clock.
Definition: system.h:12
static void Init()
Performs initialization for system clock.
Definition: system.cpp:10
static uint32_t GetMs()
Retrieves how long the system has been running since power on or reset.
Definition: system.cpp:23