I have a similar set up to yours and thanks to you for sorting the MQTT part. I was wondering if I can add a brightness_scale to my MQTT and if it can be configured using IR codes?
I am controlling a dimmer light switch which is controlled by an IR LED with codes for the levels of brightness.
I have the IR codes for various brightness levels and was wondering if I could use the brightness_scale to turn on and off the lights and adjust their brightness all in one?
I haven’t made my IR sensor gateway yet. (I’m slightly confused on which IR part to order) It was created and mentioned earlier by the talented 1technophile later in the thread.
As for making this an all in one dial for the multiple IR codes… Sounds like what your asking is for a light switch component to be made. I know we can send the individual codes as individual switches (for example: an on/off switch, a “25% switch” a 50% and 75% switch etc, but to make it a sliding scale on the webpage would require this. Have you looked at the components that dim yet to see if they are similar enough to use?
Could you send me the model or more info on your ir controlled light?
it seems that library are available on the net to support weather stations with arduino, never tested them.
If you want to do some test the library name is remotesensor and available below https://bitbucket.org/fuzzillogic/433mhzforarduino/wiki/Home
If tests are satisfying (the library is able to read data coming from your station) I could try to add the library to the gateway.
The temperature sensors like @masterkenobi,has in the picture typically use manchester encoding - a more complicated method which allows error checking of the received signal.
Hopefully the additional library mentioned would work for you, if not I would suggest building an RFLink. However you will need an arduino mega to use that software as provided by the RFLink people.
To link it to HASS via MQTT, you could add an ESP8266 like mentioned in this project
There is also work on a RFLink specific component for HASS which uses the RFLink arduino plugged directly in to your HASS server via USB
Inserted in this forum for cross reference of other threads in the forums!
Thanks. I have downloaded the stable code and put the RemoteSensor folder in C:\Users\abc\Documents\Arduino\libraries. Then I added these 2 lines into the sketch…
I think you need to take some of their examples from the remotesensors examples folder and load them to the esp8266,open the serial monitor and see if it receive something.
Before I upload it to my NodeMCU, I changed the Serial.begin from 115200 to 9600 and the SensorReceiver pin from 0 to 5…
void setup() {
Serial.begin(9600);
// Init the receiver on interrupt pin 0 (digital pin 2).
// Set the callback to function "showTempHumi", which is called
// whenever valid sensor data has been received.
SensorReceiver::init(5, showTempHumi);
}
Once it is done uploading, I opened up the serial monitor and all I can see is weird characters…
Weird characters on the serial monitor often means you have the serial monitor at the wrong baud rate.
What rate is in the Serial.begin statement in the sketch - set your monitor to that if it is different to what you have now & you should start to see normal characters.
@masterkenobi why do you not build a 433mhz dht22 sensor? its easy and more cheap and good results i think.
other question that i have for you, do you have your automation,yaml on github? i would like check that for some ideas.
I can consider that. Do you have any guide I can follow? The only thing I worry about DIY my own sensor based on my experience in MySensor, is the battery life. Normally, this kind of task requires an arduino or a nodemcu. When you add up the cost of each components, effort and time, it is really not worth it. Not to mention the poor battery life. I wasted 6 months trying to make Mysensor works. I dumped it due to poor battery life.
No, I don’t. Still trying to clean up and optimize each automation.
How do I upload the program to this? I know for Arduino, I just need to plug it to my PC via USB cable and then load it using the IDE. But for this, I don’t see any USB port.
Sorry for all the silly questions. My background is not from electronics.
Before going into this let me give you some warning, the most complex part of this tutorial is the bootloader and program loading into the standalone atmega328p it can take you a lot of hours (it was my case)…
Secondly I don’t know if HA is compatible with this, the question is HA able to handle mapping of value:
value 34567 received as RF = 4,567V
value 34463 received as RF = 4.463V
Finaly for your info I’m thinking about adding new libraries to the gateway to make it compatible with weather station but I need some time to test and check the feasability.
Here are the answers of your questions
1 Not changed the battery yet, here is the change in term of voltage (mv) which can help to deduct the battery life
2 You can make it every 5 minutes but it will reduce the battery life …
3 yes it is this one, you need an arduino uno to program it
4 resistor and led are not compulsory indeed, a 1000ohm one should be ok
5 yes it is
6 you need to program it either with an arduino uno either with an ftdi adapter, with an arduino follow the steps of “steps to follow” chapter of this tutorial
You mean the sensor will send signal to the gateway and then the gateway will publish payload=34463 to this MQTT topic: home/433toMQTT? What if I have multiple sensors? How do HA knows the payload is from which sensor?
You just change the offset on the sensor, instead of emitting 34463 an other sensor can emit 64463 or 134463. That’s why a mapping is needed for each sensor to say where the value goes