forked from Qortal/Brooklyn
48 lines
1.1 KiB
Plaintext
48 lines
1.1 KiB
Plaintext
|
/*
|
||
|
* Devicetree overlay for GPIO based backlight on/off capability.
|
||
|
*
|
||
|
* Use this if you have one of those HDMI displays whose backlight cannot be
|
||
|
* controlled via DPMS over HDMI and plan to do a little soldering to use an
|
||
|
* RPi gpio pin for on/off switching.
|
||
|
*
|
||
|
* See: https://www.waveshare.com/wiki/7inch_HDMI_LCD_(C)#Backlight_Control
|
||
|
*
|
||
|
*/
|
||
|
/dts-v1/;
|
||
|
/plugin/;
|
||
|
|
||
|
/ {
|
||
|
compatible = "brcm,bcm2835";
|
||
|
|
||
|
fragment@1 {
|
||
|
target = <&gpio>;
|
||
|
__overlay__ {
|
||
|
hdmi_backlight_hwhack_gpio_pins: hdmi_backlight_hwhack_gpio_pins {
|
||
|
brcm,pins = <17>;
|
||
|
brcm,function = <1>; /* out */
|
||
|
};
|
||
|
};
|
||
|
};
|
||
|
|
||
|
fragment@2 {
|
||
|
target-path = "/";
|
||
|
__overlay__ {
|
||
|
hdmi_backlight_hwhack_gpio: hdmi_backlight_hwhack_gpio {
|
||
|
compatible = "gpio-backlight";
|
||
|
|
||
|
pinctrl-names = "default";
|
||
|
pinctrl-0 = <&hdmi_backlight_hwhack_gpio_pins>;
|
||
|
|
||
|
gpios = <&gpio 17 0>;
|
||
|
default-on;
|
||
|
};
|
||
|
};
|
||
|
};
|
||
|
|
||
|
__overrides__ {
|
||
|
gpio_pin = <&hdmi_backlight_hwhack_gpio>,"gpios:4",
|
||
|
<&hdmi_backlight_hwhack_gpio_pins>,"brcm,pins:0";
|
||
|
active_low = <&hdmi_backlight_hwhack_gpio>,"gpios:8";
|
||
|
};
|
||
|
};
|