Sunshade Awning RF remote HACK and control with HA

Hi everyone! I just wanted to show you how I integrated my sunshade awning at my balcony. Now, I’m able to give simple commands to the device (roll out, roll in, stop) and get state reporting too.

I know there are multiple alternative ways to control RF devices in HA. The most obvious way is using an Sonoff RF bridge, but to be honest I failed with the white one as it is not fully compatible with my sunshade’s single channel communication protocol and portisch firmware is unfortunately not an option with this hardware (maybe better luck with the black one). Another options are buying a rather expensive tool (broadlink RM) or build a custom 433Mhz transmitter. As I have only one RF device I decided to do the hard way and hack my remote directly (Anyway it’s more FUN). I also installed a zigbee contact sensor (SNzB-04) on one of the arms of the sunshade near to the covered elbow joints so I know whether it is still open or not.

The whole setup costs around 16$

  • contact sensor: 8$
  • 4 channel relay: 4$
  • ESP8266 module: 4$
  • few jumper cables and a used remote

First, I disassembled the remote and took out the 3V cell battery. After that, I got a nice green board.

You can see there are a few buttons on the board, however on my remote only three are active (one is for roll the shade in, another is for out and the third one is for stop the movement). The operation logic behind these buttons is that they short the circuit by connecting the two legs on each side when
the button is pressed. To simulate the button press I soldered some wires to the legs (three button, thus used six wires) and connected the other side to the relay ports (one for COM and another to NO (Normally Open port) to ensure that the remote circuit is not closed in normal circumstances).

Eventually, ESP and the relay was connected by jumper cables. As I had a 5V relay but the ESP control logic is limited to 3V3, I took off the jumper and connected the ESP VIN (5V) pin to JD VCC, ESP 3V3 to relay VCC, ESP output pins to the relay’s IN1, IN2, IN3 control pins. Thus ESP provide the necessary 5V operating voltage to the relay, but remains at 3v3 when controlling it.

Almost forgot! As a last step, I soldered and glued some wires to the back of remote where the battery originally located. One wire on the negative (goes for GND) and another for positive side (for 3V3) to provide constant power to the device through the ESP.

Here, you can see the ESPHome config:

> switch:
>   - platform: gpio
>     pin:
>       number: 14
>       inverted: true
>     id: terrace_awning_relay_out
>     name: "Terrace Awning Out"
>     icon: "mdi:storefront"
>     on_turn_on:
>     - delay: 500ms
>     - switch.turn_off: terrace_awning_relay_out
> 
>   - platform: gpio
>     pin:
>       number: 12
>       inverted: true
>     id: terrace_awning_relay_stop
>     name: "Terrace Awning Stop"
>     icon: "mdi:storefront"
>     on_turn_on:
>     - delay: 500ms
>     - switch.turn_off: terrace_awning_relay_stop
>     
>   - platform: gpio
>     pin:
>       number: 13
>       inverted: true
>     id: terrace_awning_relay_in
>     name: "Terrace Awning In"
>     icon: "mdi:storefront"
>     on_turn_on:
>     - delay: 500ms
>     - switch.turn_off: terrace_awning_relay_in

Last last note: I’m thinking of implementing a buck converter between the remote and the ESP when supplying power due to different voltage levels (3V3 and 3V). It may not necessary but let’s remain on the safe side.

Picture of the contact sensor:

Card:

image

Nice project.

If it works now then I see no reason for it to become unsafe later.
I don’t understand why you glued cables where the battery was, why not solder? edit; never mind, I see you wrote soldered and glued now.

If you had used optocouplers instead of relays then it would have been a lot smaller an probably more reliable since relays have a tendency to stick.

You don’t need relays to do this, if you power the remote with the ground and 3v3 from the controller, you can just pull down the buttons to simulate a button press. I recently did the same here:

1 Like