rcbench
Servo and ESC test bench: panel, IOmcu and shared C
Loading...
Searching...
No Matches
ui_pinlist.h
Go to the documentation of this file.
1
14#pragma once
15
16#include <stddef.h>
17#include <stdint.h>
18
19#ifdef __cplusplus
20extern "C" {
21#endif
22
25#define UI_PINLIST_PINS 64u
26
28#define UI_PIN_WORD "GPIO"
29
31#define UI_PIN_NAME_SIZE 8u
32
46size_t ui_pin_name(char *out, size_t size, unsigned gpio);
47
67size_t ui_pinlist(char *out, size_t size, uint64_t mask, unsigned cells);
68
74unsigned ui_pinlist_count(uint64_t mask);
75
76#ifdef __cplusplus
77}
78#endif
size_t ui_pin_name(char *out, size_t size, unsigned gpio)
Writes the name of pin gpio into out: the pin word, a space and the number, "GPIO 13".
Definition ui_pinlist.c:12
unsigned ui_pinlist_count(uint64_t mask)
The number of pins in mask.
Definition ui_pinlist.c:26
size_t ui_pinlist(char *out, size_t size, uint64_t mask, unsigned cells)
Writes the pins of mask, lowest first, as "GPIO 2 GPIO 4 GPIO 5", each as ui_pin_name() names i...
Definition ui_pinlist.c:63