5#include "hpm_clock_drv.h"
6#include "hpm_mchtmr_drv.h"
27 HPMTimebase(MCHTMR_Type* timer = HPM_MCHTMR, clock_name_t clock = clock_mchtmr0);
HPM MCHTMR 时间基准实现 / HPM MCHTMR based timebase implementation.
MCHTMR_Type * timer_
定时器外设实例 / Timer peripheral instance.
MillisecondTimestamp _get_milliseconds() override
获取毫秒时间戳 / Get current timestamp in milliseconds.
HPMTimebase(MCHTMR_Type *timer=HPM_MCHTMR, clock_name_t clock=clock_mchtmr0)
构造 HPM 时间基对象 / Construct an HPM timebase object.
MicrosecondTimestamp _get_microseconds() override
获取微秒时间戳 / Get current timestamp in microseconds.
uint32_t clock_hz_
定时器输入时钟频率(Hz) / Timer input clock frequency in Hz.
表示微秒级时间戳的类。Class representing a timestamp in microseconds.
表示毫秒级时间戳的类。Class representing a timestamp in milliseconds.
时间基类,用于提供高精度时间戳。 Timebase class for providing high-precision timestamps.