From 5d6fee84455d618fde807fa66984000fb59844a6 Mon Sep 17 00:00:00 2001 From: Jacob Walser Date: Wed, 24 Mar 2021 20:34:47 -0400 Subject: [PATCH] install: overlays: add spi0-led.dts for neopixel support on navigator board --- install/overlays/spi0-led.dts | 44 +++++++++++++++++++++++++++++++++++ 1 file changed, 44 insertions(+) create mode 100644 install/overlays/spi0-led.dts diff --git a/install/overlays/spi0-led.dts b/install/overlays/spi0-led.dts new file mode 100644 index 0000000000..01ea9f6a8c --- /dev/null +++ b/install/overlays/spi0-led.dts @@ -0,0 +1,44 @@ +// This is a custom device tree overlay for the spi0 peripheral on the +// Raspberry Pi 4. It will configure only the spi0 mosi pin +// (The other spi0 pins will not be driven by the spi0 peripheral, +// and can be used for other functions). This is to be used with +// the Blue Robotics Navigator autopilot hat, where the RGB +// 'neopixel' led data pin is connected to the spi0 mosi pin on the +// Raspberry Pi 4. + +/dts-v1/; +/plugin/; + + +/ { + compatible = "brcm,bcm2835"; + + fragment@0 { + target = <&spi0_cs_pins>; + frag0: __overlay__ { + brcm,pins = <>; + }; + }; + + fragment@1 { + target = <&spi0>; + frag1: __overlay__ { + cs-gpios = <>; + status = "okay"; + }; + }; + + fragment@2 { + target = <&spidev1>; + __overlay__ { + status = "disabled"; + }; + }; + + fragment@3 { + target = <&spi0_pins>; + __overlay__ { + brcm,pins = <10>; + }; + }; +};