rcbench
Servo and ESC test bench: panel, IOmcu and shared C
Loading...
Searching...
No Matches
panel_perf.h
Go to the documentation of this file.
1
19#pragma once
20
21#include <stdbool.h>
22#include <stdint.h>
23
26#define PERF_PROBE_CLEARS 4u
27
28#if RCBENCH_PERF_LOG
29
30#include "esp_timer.h"
31
37static inline uint32_t perf_now_us(void)
38{
39 return (uint32_t)esp_timer_get_time();
40}
41
52void perf_probe_psram(void);
53
76void perf_frame(int screen, uint32_t draw_us, bool flip_timed_out,
77 bool quiet);
78
79#else
80
85static inline uint32_t perf_now_us(void)
86{
87 return 0u;
88}
89
91static inline void perf_probe_psram(void)
92{
93}
94
102static inline void perf_frame(int screen, uint32_t draw_us,
103 bool flip_timed_out, bool quiet)
104{
105 (void)screen;
106 (void)draw_us;
107 (void)flip_timed_out;
108 (void)quiet;
109}
110
111#endif
void perf_probe_psram(void)
Time the clears of the back buffer and log one's time (panel_perf.h).
Definition panel_perf.c:80
void perf_frame(int screen, uint32_t draw_us, bool flip_timed_out, bool quiet)
Account one frame and print the line due after it (panel_perf.h).
Definition panel_perf.c:281
static uint32_t perf_now_us(void)
Nothing: built without RCBENCH_PERF_LOG.
Definition panel_perf.h:85