From 5c0378de77e8f6e7cb7a194b154b231b7303fac7 Mon Sep 17 00:00:00 2001 From: 1technophile Date: Wed, 15 Mar 2017 20:09:41 +0100 Subject: [PATCH] correct issue when using a special pulselength or/and a special protocol and the default subject in this case special protocol and pulselength are not taken into account https://community.home-assistant.io/t/433mhz-infrared-ir-to-and-from-mqtt-on-esp8266/6779/89?u=1technophile --- OpenMQTTGateway.ino | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/OpenMQTTGateway.ino b/OpenMQTTGateway.ino index bc26c4d..dba1c1c 100644 --- a/OpenMQTTGateway.ino +++ b/OpenMQTTGateway.ino @@ -18,7 +18,7 @@ - Spudtater - rickybrent -IMPORTANT NOTE: On arduino UNO connect IR emitter pin to D9 , comment #define IR_USE_TIMER2 and uncomment #define IR_USE_TIMER1 on library IRremote/IRremoteInt.h so as to free pin D3 for RF RECEIVER PIN +IMPORTANT NOTE: On arduino connect IR emitter pin to D9 , comment #define IR_USE_TIMER2 and uncomment #define IR_USE_TIMER1 on library IRremote/IRremoteInt.h so as to free pin D3 for RF RECEIVER PIN Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, @@ -305,7 +305,7 @@ void receivingMQTT(char * topicOri, char * datacallback) { trc(String(valuePLSL)); } - if ((topic == subjectMQTTto433)){ + if ((topic == subjectMQTTto433) && (valuePRT == 0) && (valuePLSL == 0)){ trc(F("Sending data by RF, default parameters")); mySwitch.setProtocol(1,350); mySwitch.send(data, 24);