Github Upload Boards Devices Community Docs Blog

Gs-wds07 & digoo dg hosa

Hi,

I have a bunch of door sensor you can find in the title (same reviewed here).

I am acquiring them with EspHome, which I appreciate is a bit off-topic here, using pre-defined protocol and binary signal definition.

I am unsure that is the most reliable way though: EspHome allows also to define a custom protocol, I was then wondering if someone (@1technophile ? :slight_smile: ) could share the decoded signal characteristics for these sensors.
I tried to extract them from OMG GitHub code but…I am really not a programmer hence could not understand where it was defined.

Hi,

Could you detail what you would like to achieve by having the decoded signal characteristics?

Hi,

Thank you for your answer as first thing.
So currently I set ESPHOME with “protocol 1” and a binary code to receive the door/window sensor.

I am not sure though “protocol 1” is the best choice as I need to set a quite high decoding tolerance (50%) to be able to receive the signal.
Also i see I don’t receive a burst of signals all similar to each other, but usually I get 1 out of 2 being right.

For example if the code is “10101010111” I get it and then some spurious “101010” for example.

So finally I would like to see if I can get better performance defining a custom protocol (link) but to do so I think I need some signal parameter for those sensors.

I am not an expert so I could be wrong :slight_smile:

Hi,

Well, my first answer would be to ask if you tried with OMG and see if you get better results :wink:

If you receive at least one unique signal per sensor state you should be good, is it the case?

To be honest I didn’t try with OMG: reason is I am using esp32 devices for other things (to monitor a pump, etc…) which are not compatible with OMG.

So it is true I get at least 1 signal but that is not so consistent when sensors are farer from the gateway, so sometimes they are not captured (correctly) at all.
Therefore my request :slight_smile:

Which distance are we talking about ?

In terms of line on sight not much, probably 4-6 meters.
Issue is it is not free air.

Anyway the thing is event 1m far in free air still there is not a “clean” reception as described above.
So I hope with a better decoding I could get a more reliable signal

I would not be able to help on ESPHome, you can try OMG and see if you get better results.

Thanks for this anyway :-), I will try to grab a spare esp32 and install OMG

I have GDS-07 and ESPHome running on ESP8266 (installed about 1-2m near the window without anything that might block the signal). If I remember correctly, I connected RX6B to ESP. Works perfectly. (Initially I tried to reuse my RFLink device to read this sensor, but due to signal problems I decided to reuse local ESP installed in the same room).

Here’s my config:

remote_receiver:
  pin:
    number: GPIO13
  dump: rc_switch
  tolerance: 60
  - platform: remote_receiver
    name: "D1 Window Open"
    rc_switch_raw:
      code: "111001001100010100001010"
      protocol: 1
    filters:
      - delayed_off: 1s
  - platform: remote_receiver
    name: "D1 Window Closed"
    rc_switch_raw:
      code: "111001001100010100001110"
      protocol: 1
    filters:
      - delayed_off: 1s

And in my HA:

input_boolean:
  kids_window:
    name: "Вікно в дитячій"
    icon: mdi:window-closed-variant
  - platform: template
    sensors:
      kids_window:
        friendly_name: "Вікно в дитячій"
        value_template: >-
          {{ is_state("input_boolean.kids_window", "on") }}
        device_class: window
automation:
  - alias: Kids Window Open
    trigger:
      platform: state
      entity_id: binary_sensor.d1_window_open
      from: 'off'
      to: 'on'
    action:
      - service: input_boolean.turn_on
        data:
          entity_id: input_boolean.kids_window
  - alias: Kids Window Closed
    trigger:
      platform: state
      entity_id: binary_sensor.d1_window_closed
      from: 'off'
      to: 'on'
    action:
      - service: input_boolean.turn_off
        data:
          entity_id: input_boolean.kids_window