doc/guides/dts: bindings: Fix code snippet for 'signal-gpios'

Code snippet to demonstrate use of 'zephyr,user' binding
for gpio pin was missing a #define to easily get the code
compiling.
Fix this.

Signed-off-by: Erwan Gouriou <erwan.gouriou@linaro.org>
This commit is contained in:
Erwan Gouriou 2021-06-08 09:43:43 +02:00 committed by Kumar Gala
parent c9fd7a6099
commit 2ef3ebed9c

View File

@ -1013,6 +1013,8 @@ gpio_dt_spec``, then use it like this:
#include <drivers/gpio.h>
#define ZEPHYR_USER_NODE DT_PATH(zephyr_user)
const struct gpio_dt_spec signal =
GPIO_DT_SPEC_GET(ZEPHYR_USER_NODE, signal_gpios);