not al @martinhjelmare, the last one is send.
but that is the sending back part from the node to the gateway.
that part is actually unneccesary.
if the code arrives to the node, there is no actual need to confirm that it arrived there.
if it doesnt arrive there you know it soon enough
I made a test changing all 9 switches to off and got this on the node:
Sending code A7849B56t
TSP:MSG:SEND 19-19-0-0 s=1,c=1,t=2,pt=2,l=2,sg=0,ft=0,st=ok:1
TSP:MSG:SEND 19-19-0-0 s=1,c=1,t=2,pt=2,l=2,sg=0,ft=0,st=ok:0
TSP:MSG:READ 0-0-19 s=1,c=1,t=32,pt=0,l=9,sg=0:A5504B16f
Changing code to A5504B16f
TSP:MSG:SEND 19-19-0-0 s=1,c=1,t=32,pt=0,l=9,sg=0,ft=0,st=ok:A5504B16f
Code received A5504B16f
TSP:MSG:SEND 19-19-0-0 s=1,c=1,t=33,pt=0,l=9,sg=0,ft=0,st=ok:A5504B16f
TSP:MSG:READ 0-0-19 s=1,c=1,t=32,pt=0,l=8,sg=0:A5504B8f
Changing code to A5504B8f
TSP:MSG:SEND 19-19-0-0 s=1,c=1,t=32,pt=0,l=8,sg=0,ft=0,st=ok:A5504B8f
Code received A5504B8f
TSP:MSG:SEND 19-19-0-0 s=1,c=1,t=33,pt=0,l=8,sg=0,ft=0,st=ok:A5504B8f
TSP:MSG:READ 0-0-19 s=1,c=1,t=32,pt=0,l=10,sg=0:A17035B16f
Changing code to A17035B16
!TSP:MSG:SEND 19-19-0-0 s=1,c=1,t=32,pt=0,l=9,sg=0,ft=0,st=fail:A17035B16
Code received A17035B16
TSP:MSG:SEND 19-19-0-0 s=1,c=1,t=33,pt=0,l=9,sg=0,ft=1,st=ok:A17035B16
TSP:MSG:READ 0-0-19 s=1,c=1,t=32,pt=0,l=9,sg=0:A5504B56f
Changing code to A5504B56f
TSP:MSG:SEND 19-19-0-0 s=1,c=1,t=32,pt=0,l=9,sg=0,ft=0,st=ok:A5504B56f
Code received A5504B56f
TSP:MSG:SEND 19-19-0-0 s=1,c=1,t=33,pt=0,l=9,sg=0,ft=0,st=ok:A5504B56f
TSP:MSG:READ 0-0-19 s=1,c=1,t=2,pt=0,l=1,sg=0:1
Receiving initial value from controller
Sending code A5504B56f
TSP:MSG:SEND 19-19-0-0 s=1,c=1,t=2,pt=2,l=2,sg=0,ft=0,st=ok:1
TSP:MSG:SEND 19-19-0-0 s=1,c=1,t=2,pt=2,l=2,sg=0,ft=0,st=ok:0
TSP:MSG:READ 0-0-19 s=1,c=1,t=32,pt=0,l=10,sg=0:A17035B56f
Changing code to A17035B56
TSP:MSG:SEND 19-19-0-0 s=1,c=1,t=32,pt=0,l=9,sg=0,ft=0,st=ok:A17035B56
Code received A17035B56
TSP:MSG:SEND 19-19-0-0 s=1,c=1,t=33,pt=0,l=9,sg=0,ft=0,st=ok:A17035B56
TSP:MSG:READ 0-0-19 s=1,c=1,t=2,pt=0,l=1,sg=0:1
Receiving initial value from controller
Sending code A17035B56
TSP:MSG:SEND 19-19-0-0 s=1,c=1,t=2,pt=2,l=2,sg=0,ft=0,st=ok:1
TSP:MSG:SEND 19-19-0-0 s=1,c=1,t=2,pt=2,l=2,sg=0,ft=0,st=ok:0
TSP:MSG:READ 0-0-19 s=1,c=1,t=32,pt=0,l=8,sg=0:A7849B8f
Changing code to A7849B8f
TSP:MSG:SEND 19-19-0-0 s=1,c=1,t=32,pt=0,l=8,sg=0,ft=0,st=ok:A7849B8f
Code received A7849B8f
TSP:MSG:SEND 19-19-0-0 s=1,c=1,t=33,pt=0,l=8,sg=0,ft=0,st=ok:A7849B8f
TSP:MSG:READ 0-0-19 s=1,c=1,t=2,pt=0,l=1,sg=0:1
Receiving initial value from controller
Sending code A7849B8f
TSP:MSG:SEND 19-19-0-0 s=1,c=1,t=2,pt=2,l=2,sg=0,ft=0,st=ok:1
TSP:MSG:SEND 19-19-0-0 s=1,c=1,t=2,pt=2,l=2,sg=0,ft=0,st=ok:0
TSP:MSG:READ 0-0-19 s=1,c=1,t=32,pt=0,l=9,sg=0:A17035B8f
Changing code to A17035B8f
TSP:MSG:SEND 19-19-0-0 s=1,c=1,t=32,pt=0,l=9,sg=0,ft=0,st=ok:A17035B8f
Code received A17035B8f
TSP:MSG:SEND 19-19-0-0 s=1,c=1,t=33,pt=0,l=9,sg=0,ft=0,st=ok:A17035B8f
TSP:MSG:READ 0-0-19 s=1,c=1,t=2,pt=0,l=1,sg=0:1
Receiving initial value from controller
Sending code A17035B8f
TSP:MSG:SEND 19-19-0-0 s=1,c=1,t=2,pt=2,l=2,sg=0,ft=0,st=ok:1
TSP:MSG:SEND 19-19-0-0 s=1,c=1,t=2,pt=2,l=2,sg=0,ft=0,st=ok:0
TSP:MSG:READ 0-0-19 s=1,c=1,t=32,pt=0,l=9,sg=0:A7849B19f
Changing code to A7849B19f
TSP:MSG:SEND 19-19-0-0 s=1,c=1,t=32,pt=0,l=9,sg=0,ft=0,st=ok:A7849B19f
Code received A7849B19f
TSP:MSG:SEND 19-19-0-0 s=1,c=1,t=33,pt=0,l=9,sg=0,ft=0,st=ok:A7849B19f
TSP:MSG:READ 0-0-19 s=1,c=1,t=2,pt=0,l=1,sg=0:1
Receiving initial value from controller
Sending code A7849B19f
TSP:MSG:SEND 19-19-0-0 s=1,c=1,t=2,pt=2,l=2,sg=0,ft=0,st=ok:1
TSP:MSG:SEND 19-19-0-0 s=1,c=1,t=2,pt=2,l=2,sg=0,ft=0,st=ok:0
TSP:MSG:READ 0-0-19 s=1,c=1,t=32,pt=0,l=9,sg=0:A7849B56f
Changing code to A7849B56f
TSP:MSG:SEND 19-19-0-0 s=1,c=1,t=32,pt=0,l=9,sg=0,ft=0,st=ok:A7849B56f
Code received A7849B56f
TSP:MSG:SEND 19-19-0-0 s=1,c=1,t=33,pt=0,l=9,sg=0,ft=0,st=ok:A7849B56f
TSP:MSG:READ 0-0-19 s=1,c=1,t=2,pt=0,l=1,sg=0:1
Receiving initial value from controller
Sending code A7849B56f
TSP:MSG:SEND 19-19-0-0 s=1,c=1,t=2,pt=2,l=2,sg=0,ft=0,st=ok:1
TSP:MSG:SEND 19-19-0-0 s=1,c=1,t=2,pt=2,l=2,sg=0,ft=0,st=ok:0
some of them respond to gateway and others not…
and I realized I don’t need the node give gateway feedback, just receive the code and sendo the RF command…
I will try making a final sketch with translation from A0000B000f to livolo.sendButton(0000, 000)
what can give problems is that you sometimes send a to big code.
for instance A17035B56 that should arrive as A17035B56f
i think you need to extend your charcode to 11 (char code[11] = “A12345B123”)
Did you check out the RFLink project?
www.nemcon.nl/blog2
It supports dozens of protocols and hundreds of devices including Livolo.
Not just 433mhz but also 868mhz and 2.4 Ghz…
Yep… and it is as good as or better than the RFXTRX.
I tried build one myself using cheap chinese RX / TX but I created a useless receiver. So I have already ordered it from nodo shop…
But not supports HA yet… Someone have already asked for the compatibility on both sides:
Got All working!!!
here is the final sketch:
#define MY_DEBUG
#define MY_RADIO_NRF24
#include <SPI.h>
#include <MySensors.h>
#include <IRLib.h>
#include <livolo.h>
#define CHILD_ID 1
Livolo livolo(8);
bool initialValueSent = false;
char code[11] = "17035B420t";
MyMessage msg(CHILD_ID, V_STATUS);
MyMessage msgCode(CHILD_ID, V_IR_SEND );
MyMessage msgCodeRec(CHILD_ID, V_IR_RECEIVE);
void setup() {
}
void presentation() {
sendSketchInfo("LivoloRF", "1.0");
present(CHILD_ID, S_IR);
}
void loop() {
if (!initialValueSent) {
Serial.println("Enviando valor inicial");
send(msg.set(0));
send(msgCode.set(code));
send(msgCodeRec.set(code));
Serial.println("Solicitando valor inicial do gateway");
request(CHILD_ID, V_STATUS);
wait(3000, C_SET, V_STATUS);
}
}
void receive(const MyMessage &message) {
if (message.type==V_STATUS) {
if (!initialValueSent) {
Serial.println("Valor inicial recebido!");
initialValueSent = true;
}
}
if (message.type==V_IR_SEND) {
String codigototal = message.getString();
if (message.sensor==CHILD_ID){
codigototal.remove(codigototal.length() - 1); //erase the "t" or "f" last char of the string
int symbpos = codigototal.indexOf('&');
String remotev = codigototal.substring(0, symbpos);
String buttonv = codigototal.substring(symbpos + 1);
Serial.print("TRANSMITINDO: ");
Serial.println("Controle(" + remotev + "), Botão(" + buttonv + ")");
livolo.sendButton(remotev.toInt(), buttonv.toInt());
}
}
}
Is there a way to tell the input_boolean toggle instead of turn on or turn off?
Asking that because once I don’t have feedback from Livolo, when I create an automation action I won’t know the last state to use input_boolean.turn_on or turn_off service.
thanks
you just have to rewrite a small part from your app.
if entity[14:18] == boolean_name_start:
self.log("id did send " + switch_code + "t to sensor " + switch,"INFO")
self.call_service("switch/mysensors_send_ir_code", entity_id = switch, V_IR_SEND=switch_code )
this would Always send the same code without t(rue) or f(alse)
toggling the switch would then toggle your livolo switch.
Thanks, that will solve the need of erasing the last char of the received code, but what I asked was about the service input_boolean.toggle when using automation, but it was added on the new HASS release… that was great…
Now I can turn the light on when my front door get unlocked AND nobody is home AND it is dark (sunset)… AWESOME
I should take off the log feature from the appdaemon as well, because the file size keeps increasing more and more.
Is there a way to erase the log file once a day?
i guess you could write a siple app with daily that deletes the log.
but appdeamon keeps the log locked.
maybe that @aimc knows an easy way or could add that possibility.
about the toggle function:
this app listens to any action on the input_booleans. doesnt matter if it is toggle or on or off.
so if you make an automation or app which toggles an input boolean it will automaticly send a code to your arduino.
The logfile will automatically rotate and keep 3 generations only so it wont keep growing.
Hello @ReneTode. As far as I understand these RF switches (Livolo andcetc) do not report their state. They are supporting only one way communication - receiving commands. How do you manage situations when someone physically push turn on button? HASS only have last state reported by Mysensors.
i dont know about the livolo switches, because i dont have one, but the 433 mhz switches i own, dont have a physical button to push.
There is no direct way to report manual status changing.
Unless you use a light sensor in the same room, you must send all off commands (two or three times) to ensure it is off, and then you know it is off…
did you got dedicated on and off command for livolo switches instead of the toggle or All off command?
No. But it is a livolo limitation. There is no dedicated on command for livolo switches.
You can have a dedicated off by connecting one gang remote for each gang but nothing about dedicated on button.
And we still need the button developing from HA instead of using a switch
Hi! I am using Livolo Switches with RFLINK GW and using domoticz for sending 433 and switch them over hass
I also have a remote with 4 buttons on it. you can pair 3 buttons and the last one is group off.
the idea is, to pair several remotes with one switch and sending for off the group off…
so remote codes will be needed… hopefully that the remotes have diffrent codes…
Button A was -> echo ‘10;Livolo;00B1;8;ON’ > /dev/ttyACM0
Button B was -> echo ‘10;Livolo;00B1;16;ON’ > /dev/ttyACM0
Button C was -> echo ‘10;Livolo;00B1;56;ON’ > /dev/ttyACM0
Button D was -> echo ‘10;Livolo;00B1;42;ON’ > /dev/ttyACM0
42 = GROUP OFF
I tried diffrent codes with the ui from domoticz but I can’t figured out the codes, because
it costs so much time to test each codes which where listet in the ui…
I also got the on-off-on when sending adding 00 to eg. 0000B1 and so on…
what I donÄt understand is, that the remote is sending Unit-Codes.
In domoticz there is not a possibillity to set unit code…
So itested with the echo to ttyACM0
Hi. With the hass and the rm-pro from broadlink, I used the script existing in this page to retrieve the codes and I was able to automate the whole set to my liking.