Hi all,
After a lot of head-scratching, I figured out the proper syntax. The
following dts will configure P8_19 as a LED pin with a default state of
"on":
*/dts-v1/;/plugin/;&{/chosen} { overlays { GPIO_CUSTOM =
__TIMESTAMP__; };};&ocp { P8_19_pinmux { pinctrl-0 =
<&P8_19_gpio_pin>; };};&{/} { leds { led_P8_19 {
status = "okay"; label = "MY_GPIO"; default-state =
"on"; };*
* };*
*};*
Hopefully this will help out future head-scratchers!
On Wednesday, October 14, 2020 at 5:51:28 PM UTC-4 Douglas Conover wrote:
>
> Hi all,
>
> In the last few days, I've been working on updating my device tree files
> to be compatible with the 4.19 kernel image:
>
> https://rcn-ee.net/rootfs/bb.org/testing/2020-09-07/buster-
> iot/am57xx-debian-10.5-iot-armhf-2020-09-07-4gb.img.xz
>
> using the device tree files at:
>
> https://github.com/beagleboard/BeagleBoard-DeviceTrees/tree/v4.19.x-ti-
> overlays/src/arm/overlays
>
>
>
> I haven't been able to figure out how to properly set the default values
> (on or off) of my gpios on bootup. in *bbai-bone-buses.dtsi*, I found the
> group "*leds*" and thought I could configure these pins in a similar
> fashion to the older *am5729-beagleboneai-roboticscape.dts.* However,
> I've only been able to set the pins as gpios, and not choose whether they
> output on or off at boot. Here is my dts:
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
> */dts-v1/;/plugin/;/** Helper to show loaded overlays under:
> /proc/device-tree/chosen/overlays/*/&{/chosen} { overlays {
> VENTION-GPIO = __TIMESTAMP__; }; };&ocp { P8_11_pinmux {
> pinctrl-0 = <&P8_11_gpio_pin>; }; /* */ P8_13_pinmux { pinctrl-0 =
> <&P8_13_gpio_pin>; }; /* */ *
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
> * P8_14_pinmux { pinctrl-0 = <&P8_14_gpio_pin>; }; /* */
> P8_15_pinmux { pinctrl-0 = <&P8_15_gpio_pin>; }; /* */ P9_15_pinmux {
> pinctrl-0 = <&P9_15_gpio_pin>; }; /* */ P8_16_pinmux { pinctrl-0 =
> <&P8_16_gpio_pin>; }; /* */ P8_17_pinmux { pinctrl-0 =
> <&P8_17_gpio_pin>; }; /* */ P8_19_pinmux { pinctrl-0 =
> <&P8_19_gpio_pin>; }; /* */ P9_12_pinmux { pinctrl-0 =
> <&P9_12_gpio_pin>; }; /* */ P9_14_pinmux { pinctrl-0 =
> <&P9_14_gpio_pin>; }; /* */};&leds{ pinctrl-names = "default";
> compatible = "gpio-leds"; led_P8_11{ status="enabled"
> ; default-state="on"; };};*
>
> I would eventually like to configure the default state of all of these
> pins.This dts compiles, but will brick my device. Any ideas about how I can
> set the boot states with this framework?
>
> Thanks,
>
> Doug
>
--
For more options, visit http://beagleboard.org/discuss
---
You received this message because you are subscribed to the Google Groups
"BeagleBoard" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/beagleboard/7f47a502-a180-4363-8018-7b8fb864f5b5n%40googlegroups.com.