From e88444a73ef7bc16869e60ad1e392129a07a9f2c Mon Sep 17 00:00:00 2001 From: Phil Elwell Date: Wed, 3 Mar 2021 10:31:13 +0000 Subject: [PATCH] overlays: ghost-amp: Minor tweaks 1. Reduce the delay between RELAY1 and RELAY2 to 1000ms. 2. Rename the states to simplify LED control by an external script. 3. Claim all the required GPIOs, enabling pull-ups on the input. Signed-off-by: Phil Elwell --- .../boot/dts/overlays/ghost-amp-overlay.dts | 20 ++++++++++++++++--- 1 file changed, 17 insertions(+), 3 deletions(-) --- a/arch/arm/boot/dts/overlays/ghost-amp-overlay.dts +++ b/arch/arm/boot/dts/overlays/ghost-amp-overlay.dts @@ -54,6 +54,8 @@ __overlay__ { amp: ghost-amp { compatible = "rpi,gpio-fsm"; + pinctrl-names = "default"; + pinctrl-0 = <&ghost_amp_pins>; debug = <0>; gpio-controller; @@ -77,18 +79,18 @@ amp_on_1 { set = ; - amp_on = ; + amp_on = ; amp_off = ; fault = ; }; amp_on { set = ; - amp_off_wait = ; + amp_on_wait = ; fault = ; }; - amp_off_wait { + amp_on_wait { amp_off_1 = , ; amp_on = ; @@ -107,11 +109,23 @@ fault { set = , ; + amp_off = ; shutdown_state; }; }; }; }; + + fragment@4 { + target = <&gpio>; + __overlay__ { + ghost_amp_pins: ghost_amp_pins { + brcm,pins = <5 22 23>; + brcm,function = <0 1 1>; /* in out out */ + brcm,pull = <2 0 0>; /* up none none */ + }; + }; + }; __overrides__ { fsm_debug = <&>,"debug:0";