Lines Matching +full:gpio +full:- +full:leds
1 .. zephyr:code-sample:: gpio-custom-dts-binding
2 :name: GPIO with custom Devicetree binding
3 :relevant-api: gpio_interface devicetree-generic-id devicetree-generic-exist
5 Use custom Devicetree binding to control a GPIO.
10 In Zephyr, all hardware-specific configuration is described in the devicetree.
12 Consequently, also GPIO pins are configured in the devicetree and assigned to a specific purpose
16 output) of a GPIO pin is configured in the application firmware.
18 For typical use cases like LEDs or buttons, the existing :dtcompatible:`gpio-leds` or
19 :dtcompatible:`gpio-keys` compatibles can be used.
21 This sample demonstrates how to use a GPIO pin for other purposes with a custom devicetree binding.
24 custom devicetree binding for the power output controlled via a GPIO pin is specified in the file
25 :zephyr_file:`samples/basic/custom_dts_binding/dts/bindings/power-switch.yaml`. The gate driver for
37 .. zephyr-app-commands::
38 :zephyr-app: samples/basic/custom_dts_binding
43 For demonstration purposes, some boards use the GPIO pin of the built-in LED.
48 The GPIO pin should be switched to active level after one second.
52 .. code-block:: console