From 2f04827b1f47fbcf07e4b21c61451f7045af7ac2 Mon Sep 17 00:00:00 2001 From: Michael Still Date: Wed, 16 Jan 2019 14:34:08 +1100 Subject: [PATCH 1/4] Update documentation for rpi_gpio This update brings the documentation inline with what is proposed in Home Assistant PR: https://github.com/home-assistant/home-assistant/pull/19732 --- .../binary_sensor.rpi_gpio.markdown | 8 ++++---- source/_components/rpi_gpio.markdown | 18 +++++++++++++++--- source/_components/switch.rpi_gpio.markdown | 8 ++++---- 3 files changed, 23 insertions(+), 11 deletions(-) diff --git a/source/_components/binary_sensor.rpi_gpio.markdown b/source/_components/binary_sensor.rpi_gpio.markdown index 8494c3af37c1..e8ada0e894d9 100644 --- a/source/_components/binary_sensor.rpi_gpio.markdown +++ b/source/_components/binary_sensor.rpi_gpio.markdown @@ -1,8 +1,8 @@ --- layout: page title: "Raspberry Pi GPIO Binary Sensor" -description: "Instructions on how to integrate the GPIO sensor capability of a Raspberry Pi into Home Assistant." -date: 2015-08-30 19:00 +description: "Instructions on how to integrate the GPIO sensor capability of a Raspberry Pi or Orange Pi into Home Assistant." +date: 2018-01-16 13:00 sidebar: true comments: false sharing: true @@ -13,7 +13,7 @@ ha_release: pre 0.7 ha_iot_class: "Local Push" --- -The `rpi_gpio` binary sensor platform allows you to read sensor values of the GPIOs of your [Raspberry Pi](https://www.raspberrypi.org/). +The `rpi_gpio` binary sensor platform allows you to read sensor values of the GPIOs of your [Raspberry Pi](https://www.raspberrypi.org/) or [Orange Pi](http://www.orangepi.org/). ## {% linkable_title Configuration %} @@ -35,7 +35,7 @@ ports: type: map keys: "port: name": - description: The port numbers (BCM mode pin numbers) and corresponding names. + description: Port numbers and corresponding names (GPIO number). For Raspberry Pi boards this is the BCM style pin numbering, for Orange Pi it is the SUNXI style pin numbering (i.e. PA7). required: true type: string bouncetime: diff --git a/source/_components/rpi_gpio.markdown b/source/_components/rpi_gpio.markdown index 31a1befde2e4..48e52c2d0de7 100644 --- a/source/_components/rpi_gpio.markdown +++ b/source/_components/rpi_gpio.markdown @@ -1,8 +1,8 @@ --- layout: page title: "Raspberry Pi GPIO" -description: "Instructions on how to integrate the GPIO capability of a Raspberry Pi into Home Assistant." -date: 2016-08-30 19:00 +description: "Instructions on how to integrate the GPIO capability of a Raspberry Pi or Orange Pi into Home Assistant." +date: 2018-01-16 13:00 sidebar: true comments: false sharing: true @@ -13,5 +13,17 @@ ha_release: pre 0.7 ha_iot_class: "Local Push" --- -The `rpi_gpio` component is the base for all related GPIO platforms in Home Assistant. There is no setup needed for the component itself, for the platforms please check their corresponding pages. +The `rpi_gpio` component is the base for all related GPIO platforms in Home Assistant. This component supports both Raspberry Pi, as well as the Orange Pi boards. +```yaml +# Example configuration.yaml entry +rpi_gpio: + board_family: raspberry_pi +``` + +{% configuration %} +board_family: + description: The type of board. The default is "raspberry_pi", but "orange_pi" is also supported. + required: false + type: string +{% endconfiguration %} \ No newline at end of file diff --git a/source/_components/switch.rpi_gpio.markdown b/source/_components/switch.rpi_gpio.markdown index 901734b1ee04..ce573782c7f1 100644 --- a/source/_components/switch.rpi_gpio.markdown +++ b/source/_components/switch.rpi_gpio.markdown @@ -1,8 +1,8 @@ --- layout: page title: "Raspberry Pi GPIO Switch" -description: "Instructions on how to integrate the GPIO of a Raspberry Pi into Home Assistant as a switch." -date: 2015-08-07 14:00 +description: "Instructions on how to integrate the GPIO of a Raspberry Pi or Orange Pi into Home Assistant as a switch." +date: 2018-01-16 13:00 sidebar: true comments: false sharing: true @@ -14,7 +14,7 @@ ha_iot_class: "Local Push" --- -The `rpi_gpio` switch platform allows you to control the GPIOs of your [Raspberry Pi](https://www.raspberrypi.org/). +The `rpi_gpio` switch platform allows you to control the GPIOs of your [Raspberry Pi](https://www.raspberrypi.org/) or [Orange Pi](http://www.orangepi.org/). ## {% linkable_title Configuration %} @@ -36,7 +36,7 @@ ports: type: list keys: port: - description: Port numbers and corresponding names (GPIO #). + description: Port numbers and corresponding names (GPIO number). For Raspberry Pi boards this is the BCM style pin numbering, for Orange Pi it is the SUNXI style pin numbering (i.e. PA7). required: true type: [integer, string] invert_logic: From 259ff1d48af3e207cb926f5a62c24b49cde19ff1 Mon Sep 17 00:00:00 2001 From: Klaas Schoute Date: Tue, 29 Jan 2019 14:38:55 +0100 Subject: [PATCH 2/4] :pencil2: Tweak --- source/_components/binary_sensor.rpi_gpio.markdown | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source/_components/binary_sensor.rpi_gpio.markdown b/source/_components/binary_sensor.rpi_gpio.markdown index e8ada0e894d9..3f424518bafb 100644 --- a/source/_components/binary_sensor.rpi_gpio.markdown +++ b/source/_components/binary_sensor.rpi_gpio.markdown @@ -2,7 +2,7 @@ layout: page title: "Raspberry Pi GPIO Binary Sensor" description: "Instructions on how to integrate the GPIO sensor capability of a Raspberry Pi or Orange Pi into Home Assistant." -date: 2018-01-16 13:00 +date: 2015-08-30 19:00 sidebar: true comments: false sharing: true From 5c17bb55feff3aebd4ff694e99d98ce2a047844e Mon Sep 17 00:00:00 2001 From: Klaas Schoute Date: Tue, 29 Jan 2019 14:39:28 +0100 Subject: [PATCH 3/4] :pencil2: Tweak --- source/_components/rpi_gpio.markdown | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/source/_components/rpi_gpio.markdown b/source/_components/rpi_gpio.markdown index 48e52c2d0de7..484da1b3a318 100644 --- a/source/_components/rpi_gpio.markdown +++ b/source/_components/rpi_gpio.markdown @@ -2,7 +2,7 @@ layout: page title: "Raspberry Pi GPIO" description: "Instructions on how to integrate the GPIO capability of a Raspberry Pi or Orange Pi into Home Assistant." -date: 2018-01-16 13:00 +date: 2016-08-30 19:00 sidebar: true comments: false sharing: true @@ -26,4 +26,4 @@ board_family: description: The type of board. The default is "raspberry_pi", but "orange_pi" is also supported. required: false type: string -{% endconfiguration %} \ No newline at end of file +{% endconfiguration %} From d168097ffdf4285fd1eb0fa6f05afaae3b4b7e51 Mon Sep 17 00:00:00 2001 From: Klaas Schoute Date: Tue, 29 Jan 2019 14:39:52 +0100 Subject: [PATCH 4/4] :pencil2: Tweak --- source/_components/switch.rpi_gpio.markdown | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source/_components/switch.rpi_gpio.markdown b/source/_components/switch.rpi_gpio.markdown index ce573782c7f1..a98b01431ff0 100644 --- a/source/_components/switch.rpi_gpio.markdown +++ b/source/_components/switch.rpi_gpio.markdown @@ -2,7 +2,7 @@ layout: page title: "Raspberry Pi GPIO Switch" description: "Instructions on how to integrate the GPIO of a Raspberry Pi or Orange Pi into Home Assistant as a switch." -date: 2018-01-16 13:00 +date: 2015-08-07 14:00 sidebar: true comments: false sharing: true