1.35.12.10 RTT_TimerValueGet Function

C

uint32_t RTT_TimerValueGet(void);

Summary

Returns the current timer value

Description

This function is used the counter value of RTT. This value can be use to calculate the time elapsed.

Precondition

None.

Parameters

None.

Returns

The current timer count

Example

uint32_t frequency = 0;
uint32_t count = 0;
uint64_t time_elapsed;

frequency = RTT_FrequencyGet();
count = RTT_TimerValueGet();

time_elapsed = count/frequency;