Zephyr API Documentation
4.1.99
A Scalable Open Source RTOS
4.1.99
Toggle main menu visibility
Main Page
Related Pages
Topics
Data Structures
Data Structures
Data Structure Index
Data Fields
All
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Functions
Variables
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Enumerations
Enumerator
Files
File List
Globals
All
$
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
z
Functions
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
z
Variables
$
a
b
c
d
f
g
h
i
k
l
m
n
o
p
q
r
s
t
u
x
z
Typedefs
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
z
Enumerations
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
r
s
t
u
v
w
x
z
Enumerator
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
r
s
t
u
v
w
x
z
Macros
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
z
▼
Zephyr API Documentation
►
Introduction
Deprecated List
►
Topics
►
Data Structures
▼
Files
▼
File List
►
doc
►
kernel
►
lib
►
subsys
▼
zephyr
►
acpi
►
app_memory
►
arch
►
audio
►
bluetooth
►
canbus
►
console
►
crypto
►
data
►
debug
▼
devicetree
►
can.h
►
clocks.h
►
dma.h
►
fixed-partitions.h
►
gpio.h
►
interrupt_controller.h
►
io-channels.h
►
mbox.h
►
ordinals.h
►
pinctrl.h
►
port-endpoint.h
►
pwms.h
►
reset.h
►
spi.h
►
dfu
►
display
►
drivers
►
dsp
►
dt-bindings
►
fs
►
input
►
internal
►
ipc
►
kernel
►
linker
►
llext
►
logging
►
lorawan
►
math
►
mctp
►
mem_mgmt
►
mgmt
►
misc
►
modbus
►
modem
►
multi_heap
►
net
►
platform
►
pm
►
portability
►
posix
►
psa
►
random
►
retention
►
rtio
►
sd
►
sensing
►
settings
►
shell
►
sip_svc
►
stats
►
storage
►
sys
►
task_wdt
►
timing
►
toolchain
►
tracing
►
usb
►
usb_c
►
xen
►
zbus
►
zvfs
►
bindesc.h
►
cache.h
►
device.h
►
devicetree.h
►
fatal.h
►
fatal_types.h
►
init.h
►
irq.h
►
irq_multilevel.h
►
irq_nextlevel.h
►
irq_offload.h
►
kernel.h
kernel_includes.h
►
kernel_structs.h
►
kernel_version.h
►
net_buf.h
►
shared_irq.h
►
smf.h
►
spinlock.h
►
sw_isr_table.h
►
sys_clock.h
►
syscall.h
►
toolchain.h
types.h
►
Globals
•
All
Data Structures
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Macros
Modules
Pages
Loading...
Searching...
No Matches
gpio.h
Go to the documentation of this file.
1
6
/*
7
* Copyright (c) 2020, Linaro Ltd.
8
* Copyright (c) 2020 Nordic Semiconductor
9
*
10
* SPDX-License-Identifier: Apache-2.0
11
*/
12
13
#ifndef ZEPHYR_INCLUDE_DEVICETREE_GPIO_H_
14
#define ZEPHYR_INCLUDE_DEVICETREE_GPIO_H_
15
16
#ifdef __cplusplus
17
extern
"C"
{
18
#endif
19
53
#define DT_GPIO_CTLR_BY_IDX(node_id, gpio_pha, idx) \
54
DT_PHANDLE_BY_IDX(node_id, gpio_pha, idx)
53
#define DT_GPIO_CTLR_BY_IDX(node_id, gpio_pha, idx) \
…
55
65
#define DT_GPIO_CTLR(node_id, gpio_pha) \
66
DT_GPIO_CTLR_BY_IDX(node_id, gpio_pha, 0)
65
#define DT_GPIO_CTLR(node_id, gpio_pha) \
…
67
109
#define DT_GPIO_PIN_BY_IDX(node_id, gpio_pha, idx) \
110
DT_PHA_BY_IDX(node_id, gpio_pha, idx, pin)
109
#define DT_GPIO_PIN_BY_IDX(node_id, gpio_pha, idx) \
…
111
120
#define DT_GPIO_PIN(node_id, gpio_pha) \
121
DT_GPIO_PIN_BY_IDX(node_id, gpio_pha, 0)
120
#define DT_GPIO_PIN(node_id, gpio_pha) \
…
122
165
#define DT_GPIO_FLAGS_BY_IDX(node_id, gpio_pha, idx) \
166
DT_PHA_BY_IDX_OR(node_id, gpio_pha, idx, flags, 0)
165
#define DT_GPIO_FLAGS_BY_IDX(node_id, gpio_pha, idx) \
…
167
176
#define DT_GPIO_FLAGS(node_id, gpio_pha) \
177
DT_GPIO_FLAGS_BY_IDX(node_id, gpio_pha, 0)
176
#define DT_GPIO_FLAGS(node_id, gpio_pha) \
…
178
217
#define DT_NUM_GPIO_HOGS(node_id) \
218
COND_CODE_1(IS_ENABLED(DT_CAT(node_id, _GPIO_HOGS_EXISTS)), \
219
(DT_CAT(node_id, _GPIO_HOGS_NUM)), (0))
217
#define DT_NUM_GPIO_HOGS(node_id) \
…
220
262
#define DT_GPIO_HOG_PIN_BY_IDX(node_id, idx) \
263
DT_CAT4(node_id, _GPIO_HOGS_IDX_, idx, _VAL_pin)
262
#define DT_GPIO_HOG_PIN_BY_IDX(node_id, idx) \
…
264
307
#define DT_GPIO_HOG_FLAGS_BY_IDX(node_id, idx) \
308
COND_CODE_1(IS_ENABLED(DT_CAT4(node_id, _GPIO_HOGS_IDX_, idx, _VAL_flags_EXISTS)), \
309
(DT_CAT4(node_id, _GPIO_HOGS_IDX_, idx, _VAL_flags)), (0))
307
#define DT_GPIO_HOG_FLAGS_BY_IDX(node_id, idx) \
…
310
321
#define DT_INST_GPIO_PIN_BY_IDX(inst, gpio_pha, idx) \
322
DT_GPIO_PIN_BY_IDX(DT_DRV_INST(inst), gpio_pha, idx)
321
#define DT_INST_GPIO_PIN_BY_IDX(inst, gpio_pha, idx) \
…
323
332
#define DT_INST_GPIO_PIN(inst, gpio_pha) \
333
DT_INST_GPIO_PIN_BY_IDX(inst, gpio_pha, 0)
332
#define DT_INST_GPIO_PIN(inst, gpio_pha) \
…
334
345
#define DT_INST_GPIO_FLAGS_BY_IDX(inst, gpio_pha, idx) \
346
DT_GPIO_FLAGS_BY_IDX(DT_DRV_INST(inst), gpio_pha, idx)
345
#define DT_INST_GPIO_FLAGS_BY_IDX(inst, gpio_pha, idx) \
…
347
356
#define DT_INST_GPIO_FLAGS(inst, gpio_pha) \
357
DT_INST_GPIO_FLAGS_BY_IDX(inst, gpio_pha, 0)
356
#define DT_INST_GPIO_FLAGS(inst, gpio_pha) \
…
358
363
#ifdef __cplusplus
364
}
365
#endif
366
367
#endif
/* ZEPHYR_INCLUDE_DEVICETREE_GPIO_H_ */
zephyr
devicetree
gpio.h
Generated on Mon Mar 17 2025 18:05:23 for Zephyr API Documentation by
1.12.0