|
ChibiOS
21.6.0
|

Time Measurement APIs and services.
Macros | |
| #define | TM_CALIBRATION_LOOP 4U |
| Number of iterations in the calibration loop. More... | |
Data Structures | |
| struct | tm_calibration_t |
| Type of a time measurement calibration data. More... | |
| struct | time_measurement_t |
| Type of a Time Measurement object. More... | |
Functions | |
| void | chTMObjectInit (time_measurement_t *tmp) |
Initializes a TimeMeasurement object. More... | |
| NOINLINE void | chTMStartMeasurementX (time_measurement_t *tmp) |
| Starts a measurement. More... | |
| NOINLINE void | chTMStopMeasurementX (time_measurement_t *tmp) |
| Stops a measurement. More... | |
| NOINLINE void | chTMChainMeasurementToX (time_measurement_t *tmp1, time_measurement_t *tmp2) |
| Stops a measurement and chains to the next one using the same time stamp. More... | |
| static void | __tm_calibration_object_init (tm_calibration_t *tcp) |
| Time measurement initialization. More... | |
| #define TM_CALIBRATION_LOOP 4U |
| void chTMObjectInit | ( | time_measurement_t * | tmp | ) |
Initializes a TimeMeasurement object.
| [out] | tmp | pointer to a TimeMeasurement structure |
Definition at line 79 of file chtm.c.
References time_measurement_t::best, time_measurement_t::cumulative, time_measurement_t::last, time_measurement_t::n, and time_measurement_t::worst.
Referenced by __stats_object_init(), __thd_object_init(), and __tm_calibration_object_init().
| NOINLINE void chTMStartMeasurementX | ( | time_measurement_t * | tmp | ) |
Starts a measurement.
time_measurement_t structure must be initialized.| [in,out] | tmp | pointer to a TimeMeasurement structure |
Definition at line 96 of file chtm.c.
References chSysGetRealtimeCounterX, and time_measurement_t::last.
Referenced by __stats_start_measure_crit_isr(), __stats_start_measure_crit_thd(), and __tm_calibration_object_init().
| NOINLINE void chTMStopMeasurementX | ( | time_measurement_t * | tmp | ) |
Stops a measurement.
time_measurement_t structure must be initialized.| [in,out] | tmp | pointer to a time_measurement_t structure |
Definition at line 109 of file chtm.c.
Referenced by __stats_stop_measure_crit_isr(), __stats_stop_measure_crit_thd(), and __tm_calibration_object_init().
| NOINLINE void chTMChainMeasurementToX | ( | time_measurement_t * | tmp1, |
| time_measurement_t * | tmp2 | ||
| ) |
Stops a measurement and chains to the next one using the same time stamp.
| [in,out] | tmp1 | pointer to the time_measurement_t structure to be stopped |
| [in,out] | tmp2 | pointer to the time_measurement_t structure to be started |
Definition at line 126 of file chtm.c.
References chSysGetRealtimeCounterX, and time_measurement_t::last.
Referenced by __stats_ctxswc().
|
inlinestatic |
Time measurement initialization.
| [out] | tcp | pointer to the tm_calibration_t structure |
Definition at line 119 of file chtm.h.
References time_measurement_t::best, chTMObjectInit(), chTMStartMeasurementX(), chTMStopMeasurementX(), tm_calibration_t::offset, and TM_CALIBRATION_LOOP.
