openaliro
Aliro reader: UWB/CCC core and ESP32-S3/C5/C6 port
Loading...
Searching...
No Matches
uwb_cirdiag.h
Go to the documentation of this file.
1
7#ifndef WOZ_UWB_CIRDIAG_H_
8#define WOZ_UWB_CIRDIAG_H_
9
10#include <stdbool.h>
11#include <stdint.h>
12
13#ifdef __cplusplus
14extern "C" {
15#endif
16
17/* No-op inlines when the feature is compiled out, so the latch call sites in the two RX shims
18 * and the console commands cost nothing in a build that does not want the diagnostics. */
19#if defined(ESP_PLATFORM)
20#include "sdkconfig.h" /* CONFIG_WOZ_UWB_CIRDIAG (Zephyr injects autoconf.h itself) */
21#endif
22
23#if defined(CONFIG_WOZ_UWB_CIRDIAG)
24
27void uwb_cirdiag_set_enabled(bool on);
28
30bool uwb_cirdiag_enabled(void);
31
39
42
45uint32_t uwb_cirdiag_ring_count(void);
46
62bool uwb_cirdiag_capture(uint32_t status, uint16_t datalength, bool deadline_pending);
63
66void uwb_cirdiag_flush(void);
67
73bool uwb_cirdiag_window_due(void);
74
88void uwb_cirdiag_probe(void);
89
90#else
91
95static inline void uwb_cirdiag_set_enabled(bool on)
96{
97 (void)on;
98}
102static inline bool uwb_cirdiag_enabled(void)
103{
104 return false;
105}
109static inline void uwb_cirdiag_dump_set_enabled(bool on)
110{
111 (void)on;
112}
116static inline bool uwb_cirdiag_dump_enabled(void)
117{
118 return false;
119}
123static inline uint32_t uwb_cirdiag_ring_count(void)
124{
125 return 0u;
126}
130static inline bool uwb_cirdiag_capture(uint32_t status, uint16_t datalength, bool deadline_pending)
131{
132 (void)status;
133 (void)datalength;
134 (void)deadline_pending;
135 return false;
136}
140static inline void uwb_cirdiag_flush(void)
141{
142}
146static inline bool uwb_cirdiag_window_due(void)
147{
148 return false;
149}
153static inline void uwb_cirdiag_probe(void)
154{
155}
156
157#endif /* CONFIG_WOZ_UWB_CIRDIAG */
158
159#ifdef __cplusplus
160}
161#endif
162
163#endif /* WOZ_UWB_CIRDIAG_H_ */
static bool uwb_cirdiag_window_due(void)
Stub: window_due returns false.
Definition uwb_cirdiag.h:146
static bool uwb_cirdiag_dump_enabled(void)
Stub: dump_enabled returns false.
Definition uwb_cirdiag.h:116
static uint32_t uwb_cirdiag_ring_count(void)
Stub: ring_count returns 0.
Definition uwb_cirdiag.h:123
static void uwb_cirdiag_probe(void)
Stub: probe is a no-op.
Definition uwb_cirdiag.h:153
static bool uwb_cirdiag_enabled(void)
Stub: enabled returns false.
Definition uwb_cirdiag.h:102
static void uwb_cirdiag_flush(void)
Stub: flush is a no-op.
Definition uwb_cirdiag.h:140
static void uwb_cirdiag_dump_set_enabled(bool on)
Stub: dump_set_enabled is a no-op.
Definition uwb_cirdiag.h:109
static void uwb_cirdiag_set_enabled(bool on)
Stub: set_enabled is a no-op.
Definition uwb_cirdiag.h:95
static bool uwb_cirdiag_capture(uint32_t status, uint16_t datalength, bool deadline_pending)
Stub: capture returns false.
Definition uwb_cirdiag.h:130