1technophile / OpenMQTTGateway

MQTT gateway for ESP8266 or ESP32 with bidirectional 433mhz/315mhz/868mhz, Infrared communications, BLE, Bluetooth, beacons detection, mi flora, mi jia, LYWSD02, LYWSD03MMC, Mi Scale, TPMS, BBQ thermometer compatibility & LoRa.
https://docs.openmqttgateway.com
GNU General Public License v3.0
3.57k stars 786 forks source link

Sonoff rf bridge #81

Closed prahjister closed 6 years ago

prahjister commented 7 years ago

Any plans to port over to new sonoff rf bridge?

1technophile commented 7 years ago

need to buy the device first, good idea

prahjister commented 7 years ago

Email me prahjister0 at the gmail domain and I will see if I can get one sent. I would send the one that I have but it looks like you are in France. I would try to port but it is beyond my skill set. Hardware seems solid on the review sample I have. Do you have the ability to reverse engineer. Looks like 2 chips are working together to make this work?

1technophile commented 7 years ago

if it is based on esp8266 like the other sonoff it shouldn't be a problem. I sent you an email.

prahjister commented 7 years ago

I never got the email. prahjister0

prahjister commented 7 years ago

Did they ship it and you receive it?

1technophile commented 7 years ago

Not received it yet

1technophile commented 7 years ago

Received !

prahjister commented 7 years ago

Awesome. Maybe you can improve latency over other firmware that I'm using. Also still getting duplicates.

On Oct 4, 2017 12:07 AM, "Florian" notifications@github.com wrote:

Received !

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/1technophile/OpenMQTTGateway/issues/81#issuecomment-334044736, or mute the thread https://github.com/notifications/unsubscribe-auth/AKhRdrOJRRDCoJjxg2EslaBxPluCLtH0ks5sowSTgaJpZM4Oqm73 .

prahjister commented 6 years ago

How goes it?

1technophile commented 6 years ago

I didn't put my hands on it still

1technophile commented 6 years ago

Begining to look at sonoff rf, there is already some interesting work about it especialy: http://tinkerman.cat/hacking-sonoff-rf-bridge-433/

At this time I'm able to receive RF with a mixed code between tinkerman one and mine (mainly tinkerman ;-)).

prahjister commented 6 years ago

Great. I'm using https://github.com/arendst/Sonoff-Tasmota

Latency and still getting duplicates. I think the way he is stopping duplicates is fooled when it missintepretes one of the duplicate transmission. I haven't looked into it much

1technophile commented 6 years ago

You should take a look at @xoseperez code he is well removing the duplicates code (key RF_RECEIVE_DELAY) http://tinkerman.cat/hacking-sonoff-rf-bridge-433/

1technophile commented 6 years ago

done based on Xose Pérez work ESPURNA

1technophile commented 6 years ago

Sending RF sudo mosquitto_pub -t home/commands/MQTTtoSRFB -m 1314884

Receiving RF

home/433toMQTT 34009
home/SRFBtoMQTT/Raw 2A80015E042E0084D9
home/SRFBtoMQTT 34009
home/SRFBtoMQTT/Tsyn 10880
home/SRFBtoMQTT/Thigh 350
home/SRFBtoMQTT/Tlow 1070
1technophile commented 6 years ago

@prahjister Hello, finally did you get it working with OpenMQTTGateway?

MACscr commented 6 years ago

I actually have espurna installed, but i dont think it can work as a receiver that way. Seems like it couldnt do both receiver and send. Only send after its learned. Im looking for something that can do both. At least receive since my broadlink can already do the sending part. I need the receive so that I can actually use RF remotes with it. Also, the RF Bridge is esp8265, not 66 afaik.

1technophile commented 6 years ago

OpenMQTTGateway will do the job you are requesting on the platform you want (sonoff rf bridge, ESP8266, arduino, ESP32)

xoseperez commented 6 years ago

@MACscr You can send arbitrary codes using the 0xA5 action, no need to have them learned beforehand. Using ESPurna you can send the code to "/rfout/set" topic and the device will broadcast it.

MACscr commented 6 years ago

@xoseperez im not sure what you are talking about. i need the bridge to act as a RF/MQTT gateway. So it can receive commands from my RF remote and pass that to my MQTT gateway. As @1technophile and I have figured out, it doesnt reliable work that way. It works fine for learning a code and sending that code, but it cant consistently receive commands. seems the same remote (etekcity) buttons are inconsistent on which code they send.

AKA-47 commented 6 years ago

i saw the same problem like @MACscr on some cheap self learning plugs. if i debug this with my gateway based on STX88 receiver it shows that the remote sends 5 different codes of which my plug only reacts on one of this if i resend it via my STX Gateway. Receiving or Sending the same code via RFbridge doesnt work. it only works on very static transmissions as i see so we maybe need to maintain an additional section in the compatibility list for this "additional microprocessor" based device