How to make use of generic 433Mhz sensors?

I agree the power saving is minimal but is is also useful to see what is switched on sometimes. I found another thread and it looks like there is nothing cheap available…

there is, but then you have to create it yourself :wink:

an ESP, a single relay and a button will do the trick. costs are around 6 bucks.

but you must program the ESP yourself (mysensors makes that easy for you) and you must built a box around it yourself.

You can put a sonoff RF:
https://www.itead.cc/sonoff-rf.html

Upload this to it:

and you will be able to command it by RF , wifi and to know the state by wifi

@1technophile,

After using the gateway for few months, there is one issue that annoys me the most.

Sometimes, the signal from some of my 433Mhz sensors are not captured by the gateway.

It causes some of the automation failed to trigger.

I suspect these are the possible reasons…

  1. Too many sensors trigger at the same time.
  2. The range of the sensors deteriorate perhaps due to diminishing battery strength.
  3. Gateway too far.

To overcome this, I plan to spread out multiple gateways across the house.

My question is, is it possible for the gateway to publish selective payloads to the MQTT topic?

For example, if I put a gateway on each floor, and each gateways only publish the code from sensors at respective floor to the MQTT topic.

That means, before I upload the sketch to the NodeMCU, I must obtain all the codes for each sensors. Maybe using another gateway. Then I hardcoded the codes that I want the gateway to process into the skectch so that the gateway only publish the code that is listed and ignore the rest.

This is to prevent multiple gateways publishing the same payload to the same topic.

I think a better way would be for home-assistant to handle the double code, or?
Is it for door/movement sensor?

Your solution would also be possible I guess, you’ll just have to check the received code against the wished code list and decide if he should be sent.

Hello,

Take a look to this post it has already been done by @ronvl by changing the topics maybe he can help you :

After this if you play with MQTT possibilities “+” you can send to all the gateway at the same time (not tested with HA)

Could you point me what is the receiver and antenna you are using?

thanks. but different gateway, different topic just solve half of the issue. What I worry is the MQTT network/traffic will become congested. if I have 3 different gateways, a sensor trigger might publish to 3 different topics simultaneously. if the house is really busy with multiple occupants and visitors, multiple sensors might trigger at the same time and cause 3 times the load on the MQTT broker.

do you think it will cause the HA to breakdown?

P/S - I am using Superheterodyne 3400 transmitter and receiver kit and this antenna

thats why i am glad that i use mysensors.
the sensors Always connect to 1 gateway and when they cant reach that one they automaticly search for the next gateway.

1 Like

I don’t believe this is a problem here if you setup 3 gateways i.e. one for each floor you are right that there is a chance that all 3 will pick up the 433Mhz message from one sensor.

All 3 will publish a MQTT topic on the MQTT broker however the processing of these messages is milliseconds and the messages are very short so only if you have 1000’s of them in a split second you might see a spike in traffic on your network.

So far HA has not yet been involved :slight_smile:

The MQTT broker will only post a message to systems that have subscribed to a topic that is updated. Now all 3 gateway update a different topic and HA will only be subscribed to one of the 3 topics i.e. the topic where you expect the message is received. In other word all sensors on the first floor should be configured in HA using the topics from the first floor gateway and HA will only listen to those topics for those sensors.

So basically HA doesn’t get more triggers than if you use only one gateway. There is a bit more traffic on your network and on your MQTT broker but I would not expect that this will tip your system or network over the edge unless you have a couple of 100’s sensors which are triggering every second.

Also the 3 different gateways will pick the 433Mhz signal up at a different time due to distance from the sensor and the fact that sensors send there messages multiple times and the chance that all 3 gateway process it in the same second and put it on the network is small.

I would give it a go as the other solution to hard code it is not so flexible :slight_smile:

3 Likes

Hello,

@ronvl gave a good solution, thanks. To go further I’m thinking about expanding the duplicate signal removal at a multi gateway point of view.

Do you have a recent code version implemented (from this year)? As a first reduction of traffic the last versions of this year removes duplicate of signal.

@masterkenobi the gateway is now able to remove duplicate on a multiple gateways installation see here

Don’t hesitate to give feedback

1 Like

That is super awesome. Thanks a lot man.

So do i need to use different topics for each gateways or can i maintain the same topic?

Should work keeping the same topic, for people wanting to differentiate the topics i need to do a little modification.

1 Like

It is great to see you keep on improving the gateway by leaps and bounds. So is the gateway already capable of receiving temperature and humidity data from a 433Mhz thermometer? If yes, may I know which model of thermometer is supported?

1 Like

@masterkenobi Dude… seriously… He’s like reading my mind with his jedi mind tricks! :smile: Last night I implemented the grand father clock chimes and he was in that forum teaching me… I just replaced the batteries in my Oregon Scientific 433mhz temperature and thought hey wouldn’t it be nice - found him here 7 minutes prior asking my question! lol

The force works in mysterious way.

1 Like

Not yet, we are lacking an arduino open source library with a wide range of protocol supported.
Nevertheless it is on my mind but it could take a lot of time to spend.

Modification done now the gateway can avoid RF and IR duplicate with a multiple gateway installation even if the first part of the topic 'home" is different between the gateways.

2 Likes

Was looking at the weather station protocols… there’s a plethora of them. I think we will have to stick to those that fit the remotesensor library. Maybe we pick a unit and use it because I’m probably the only one on the planet with my model… I found the remotesensor library here: https://bitbucket.org/fuzzillogic/433mhzforarduino/wiki/Home

My concern with this library is that it is licensed under GPL, due to this licensing type I cannot include it into my code without changing my current licensing to the restrictive GPL license…
Maybe Oregon is a good path to follow, here is some program to test if you have time.
http://www.connectingstuff.net/blog/decodage-protocole-oregon-arduino-1/
If it works I can try to include it into the gateway.

1 Like