Skip to content
  • MySensors
  • OpenHardware.io
  • Categories
  • Recent
  • Tags
  • Popular
Skins
  • Light
  • Brite
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Brand Logo
  1. Home
  2. Development
  3. WiFi MQTTGateway

WiFi MQTTGateway

Scheduled Pinned Locked Moved Development
22 Posts 11 Posters 17.0k Views 4 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • H Offline
    H Offline
    hek
    Admin
    wrote on last edited by
    #9

    If you look at the development branch some hardware separation has been done. Should be much easier to port for the ESP.

    1 Reply Last reply
    0
    • M Offline
      M Offline
      Mickey
      wrote on last edited by
      #10

      Maybe in the first phase we can use an Arduino as an intermediate and use the serial gateway to talk with the esp and only implement (what is already implemented by this chip community) the WiFi and MQTT connectivity.

      1 Reply Last reply
      0
      • F Offline
        F Offline
        FotoFieber
        Hardware Contributor
        wrote on last edited by
        #11

        I was playing with NodeMCU on the ESP8266. With lua-script I could send and recieve MQTT messages via serial port to mosquitto.

        Plan a: modify http://forum.mysensors.org/topic/524/mqtt-client-gateway/27

        • remove pubsubclient
        • remove ethernet support
        • use serial communication to the ESP8266 to send and recieve MQTT messages
        • write lua startup scripts for ESP8266

        Plan b: use the original serial gateway sketch on the arduino and implement the logic on the ESP8266 with https://github.com/esp8266/Arduino. As pubsubclient is working on the ESP8266, the mqtt client gateway sketch should be easy portable to the ESP8266.

        Please vote for plan a or b. :smile:

        Y 1 Reply Last reply
        0
        • S Offline
          S Offline
          scalz
          Hardware Contributor
          wrote on last edited by scalz
          #12

          I was thinking about doing same thing, but during summer. I have no time for moment. And don't know if I will success. What I think:

          • Luckyfia idea is interesting. I have done a small board to plug Huzzah8266 with atsha+rfm69+nrf but it is not tested : https://github.com/scalz/MySensors-HW/tree/master/MysensorsGW_huzzah (I need to add a power connector)
          • I think a MQTT client GW would be interesting because we could let Mosquitto manage. But a MQTT Broker GW is interesting too of course.
          • for porting, I know that souliss have already done some work to implement some libs (radio...) on esp. Maybe it could help...
          • I would prefer connect rf module with spi to esp like LuckyFia did . Maybe it is in my head, but I think maybe comm would be faster and better managed...But I think it is much more work.

          A or B??? very similar, but maybe B is cleaner. I don't know.

          It is very interesting project. Maybe I am wrong but with MQTT we could have easily multi GW with multi radio type in same network (of course if GW is MQTT client).

          F 1 Reply Last reply
          0
          • S scalz

            I was thinking about doing same thing, but during summer. I have no time for moment. And don't know if I will success. What I think:

            • Luckyfia idea is interesting. I have done a small board to plug Huzzah8266 with atsha+rfm69+nrf but it is not tested : https://github.com/scalz/MySensors-HW/tree/master/MysensorsGW_huzzah (I need to add a power connector)
            • I think a MQTT client GW would be interesting because we could let Mosquitto manage. But a MQTT Broker GW is interesting too of course.
            • for porting, I know that souliss have already done some work to implement some libs (radio...) on esp. Maybe it could help...
            • I would prefer connect rf module with spi to esp like LuckyFia did . Maybe it is in my head, but I think maybe comm would be faster and better managed...But I think it is much more work.

            A or B??? very similar, but maybe B is cleaner. I don't know.

            It is very interesting project. Maybe I am wrong but with MQTT we could have easily multi GW with multi radio type in same network (of course if GW is MQTT client).

            F Offline
            F Offline
            FotoFieber
            Hardware Contributor
            wrote on last edited by
            #13

            @scalz said:

            I...
            It is very interesting project. Maybe I am wrong but with MQTT we could have easily multi GW with multi radio type in same network (of course if GW is MQTT client).

            You are not wrong. MQTT is the integration hub in my setup and I have multiple sensors/actors:

            • mysensors NRF24L01+
            • mysensors RFM69 (not yet tested)
            • netatmo
            • homematic (with homegear)
            • FritzBox telephony
            • router (Edgerouter, to disable/enable internet for specific IPs)
            • pushover
            • mail
            • OpenHab

            'Wiring' between the different systems is done with node-red.

            Porting the whole library to ESP8266 is to much work for me. :smiley:

            1 Reply Last reply
            0
            • S Offline
              S Offline
              scalz
              Hardware Contributor
              wrote on last edited by scalz
              #14

              nice setup. I use jeedom (I like it, it is very powerful and compatible with lot of things too) and sure node-red is a good addition to controllers, for some tasks or it can help to dev some plugins I think.

              for esp8266, I don't know very well esp yet, but I was software developer, so it's just a question of time I think. And you are right, it needs lot of work. Too bad LuckyFia has not shared it.But we will get same thing I hope.

              1 Reply Last reply
              0
              • F FotoFieber

                I was playing with NodeMCU on the ESP8266. With lua-script I could send and recieve MQTT messages via serial port to mosquitto.

                Plan a: modify http://forum.mysensors.org/topic/524/mqtt-client-gateway/27

                • remove pubsubclient
                • remove ethernet support
                • use serial communication to the ESP8266 to send and recieve MQTT messages
                • write lua startup scripts for ESP8266

                Plan b: use the original serial gateway sketch on the arduino and implement the logic on the ESP8266 with https://github.com/esp8266/Arduino. As pubsubclient is working on the ESP8266, the mqtt client gateway sketch should be easy portable to the ESP8266.

                Please vote for plan a or b. :smile:

                Y Offline
                Y Offline
                Yveaux
                Mod
                wrote on last edited by
                #15

                @FotoFieber I found NodeMCU to be highly instable. Random crashes, watchdog timeouts etc etc... Very frustrating...
                Arduino port seems to much more mature.

                http://yveaux.blogspot.nl

                1 Reply Last reply
                0
                • T Offline
                  T Offline
                  tekka
                  Admin
                  wrote on last edited by tekka
                  #16

                  Managed to run MySensors on ESP8266 (RF24 connected to HSPI of ESP8266): I'm using the dev branch with some nasty hacks here and there - but so far so good. Tested RepeaterNode and SerialGateway sketch - both working. Currently testing core functionality. PR to be prepared.

                  DidiD H M 3 Replies Last reply
                  1
                  • T tekka

                    Managed to run MySensors on ESP8266 (RF24 connected to HSPI of ESP8266): I'm using the dev branch with some nasty hacks here and there - but so far so good. Tested RepeaterNode and SerialGateway sketch - both working. Currently testing core functionality. PR to be prepared.

                    DidiD Offline
                    DidiD Offline
                    Didi
                    wrote on last edited by
                    #17

                    @tekka

                    :thumbsup:

                    if (knowledge == 0) { use BRAIN; use GOOGLE;use SEARCH; } else {make POST;}

                    1 Reply Last reply
                    0
                    • S Offline
                      S Offline
                      scalz
                      Hardware Contributor
                      wrote on last edited by
                      #18

                      wow. it is a good news. I'll follow your work for sure.
                      thank you for sharing. there are smart guys here I think. it is great :smiley:

                      1 Reply Last reply
                      0
                      • T tekka

                        Managed to run MySensors on ESP8266 (RF24 connected to HSPI of ESP8266): I'm using the dev branch with some nasty hacks here and there - but so far so good. Tested RepeaterNode and SerialGateway sketch - both working. Currently testing core functionality. PR to be prepared.

                        H Offline
                        H Offline
                        hek
                        Admin
                        wrote on last edited by
                        #19

                        @tekka

                        Great to hear you're making progress!
                        Not sure it will help you, but there is some ongoing work in this branch that might be interesting for you:
                        https://github.com/mysensors/Arduino/tree/gateway-refactoring/libraries/MySensors
                        This branch allows the gateway node to be a sensor as well and an embryo for cleaning up the gateway transport and protocol layers.
                        Currently only support serial and ethernet (as client) but I guess it could be helpful when running on the esp as well.

                        1 Reply Last reply
                        0
                        • T tekka

                          Managed to run MySensors on ESP8266 (RF24 connected to HSPI of ESP8266): I'm using the dev branch with some nasty hacks here and there - but so far so good. Tested RepeaterNode and SerialGateway sketch - both working. Currently testing core functionality. PR to be prepared.

                          M Offline
                          M Offline
                          Mickey
                          wrote on last edited by
                          #20

                          @tekka

                          Excellent progress.
                          Waiting to see this...

                          1 Reply Last reply
                          0
                          • nikil511N Offline
                            nikil511N Offline
                            nikil511
                            wrote on last edited by
                            #21

                            @tekka hello, any progress on the ESP8266 gateway ?
                            Can you pls share some code (even if it's incomplete/hacked)
                            Thanks

                            Y 1 Reply Last reply
                            0
                            • nikil511N nikil511

                              @tekka hello, any progress on the ESP8266 gateway ?
                              Can you pls share some code (even if it's incomplete/hacked)
                              Thanks

                              Y Offline
                              Y Offline
                              Yveaux
                              Mod
                              wrote on last edited by
                              #22

                              @Manolis-N please continue in this thread:http://forum.mysensors.org/topic/1870/esp8266-wifi-gateway-port-for-mysensors/1

                              http://yveaux.blogspot.nl

                              1 Reply Last reply
                              0

                              Hello! It looks like you're interested in this conversation, but you don't have an account yet.

                              Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.

                              With your input, this post could be even better 💗

                              Register Login
                              Reply
                              • Reply as topic
                              Log in to reply
                              • Oldest to Newest
                              • Newest to Oldest
                              • Most Votes


                              16

                              Online

                              12.0k

                              Users

                              11.2k

                              Topics

                              113.4k

                              Posts


                              Copyright 2025 TBD   |   Forum Guidelines   |   Privacy Policy   |   Terms of Service
                              • Login

                              • Don't have an account? Register

                              • Login or register to search.
                              • First post
                                Last post
                              0
                              • MySensors
                              • OpenHardware.io
                              • Categories
                              • Recent
                              • Tags
                              • Popular