modm API documentation
modm::chrono::micro_clock Struct Reference

#include <modm/architecture/interface/clock.hpp>

Inheritance diagram for modm::chrono::micro_clock:
modm_test::chrono::micro_clock

Public Typedefs

using duration = std::chrono::duration< uint32_t, std::micro >
 
using rep = duration::rep
 
using period = duration::period
 
using time_point = std::chrono::time_point< micro_clock, duration >
 

Static Public Member Functions

static time_point now () noexcept
 

Static Public Attributes

static constexpr bool is_steady = false
 

Detailed Description

Returns a time_point in microseconds.

This clock is meant for measuring durations (time differences), not time since reboot. You must not depend on this clock for timekeeping, especially not over long periods of time, since:

    >
  1. the clock is NOT STEADY! The 32-bit microsecond counter will wrap around after 71 minutes!
  2. the clock may have quite some drift and is not synchable to an external reference. You must therefore not rely on this clock for very long durations that need to be accurate.

You must use an actual calendar implementation for proper time keeping!


The documentation for this struct was generated from the following files: