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. Troubleshooting
  3. ESP8266 and RFM69 send issue

ESP8266 and RFM69 send issue

Scheduled Pinned Locked Moved Troubleshooting
13 Posts 5 Posters 3.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.
  • U Offline
    U Offline
    user2684
    Contest Winner
    wrote on last edited by
    #3

    Thanks, I'll give it a try with a simpler sketch and report back. Good point, I've always thought the NACK was coming from the local radio unable to send, not from the remote one, very good to know!

    1 Reply Last reply
    0
    • gohanG Offline
      gohanG Offline
      gohan
      Mod
      wrote on last edited by
      #4

      NACK actually is when you send something but you don't get an ACK back from receiver (could be for many reasons: low signal, bad reception, interference, receiver dead, etc )

      1 Reply Last reply
      0
      • U Offline
        U Offline
        user2684
        Contest Winner
        wrote on last edited by
        #5

        Ok the problem is definitely related to the ESP8266 gateway. I re-wired the same radio to a serial gateway and everything is working fine. Back to the ESP8266, same problem as before. On the serial I'm using:

        #define MY_RADIO_RFM69
        #define MY_RFM69_FREQUENCY RF69_868MHZ
        #define MY_IS_RFM69HW
        

        On the esp8266:

        #define MY_RADIO_RFM69
        #define MY_RFM69_FREQUENCY RF69_868MHZ
        #define MY_IS_RFM69HW
        #define MY_RF69_IRQ_NUM D1
        #define MY_RF69_SPI_CS D2 
        

        Everything wired as the instructions from https://www.mysensors.org/build/connect_radio, I've double checked a few times already.
        I have now a workaround so I should be fine but I'd be really curious to understand what was wrong in the esp8266 setup causing that issue...

        Thanks

        mfalkviddM 1 Reply Last reply
        0
        • U user2684

          Ok the problem is definitely related to the ESP8266 gateway. I re-wired the same radio to a serial gateway and everything is working fine. Back to the ESP8266, same problem as before. On the serial I'm using:

          #define MY_RADIO_RFM69
          #define MY_RFM69_FREQUENCY RF69_868MHZ
          #define MY_IS_RFM69HW
          

          On the esp8266:

          #define MY_RADIO_RFM69
          #define MY_RFM69_FREQUENCY RF69_868MHZ
          #define MY_IS_RFM69HW
          #define MY_RF69_IRQ_NUM D1
          #define MY_RF69_SPI_CS D2 
          

          Everything wired as the instructions from https://www.mysensors.org/build/connect_radio, I've double checked a few times already.
          I have now a workaround so I should be fine but I'd be really curious to understand what was wrong in the esp8266 setup causing that issue...

          Thanks

          mfalkviddM Online
          mfalkviddM Online
          mfalkvidd
          Mod
          wrote on last edited by
          #6

          @user2684 this seems to be missing:

          #define MY_RF69_IRQ_NUM MY_RF69_IRQ_PIN
          

          I am not sure if it is needed, but it might be worth adding and see if it helps.

          U 1 Reply Last reply
          0
          • mfalkviddM mfalkvidd

            @user2684 this seems to be missing:

            #define MY_RF69_IRQ_NUM MY_RF69_IRQ_PIN
            

            I am not sure if it is needed, but it might be worth adding and see if it helps.

            U Offline
            U Offline
            user2684
            Contest Winner
            wrote on last edited by
            #7

            @mfalkvidd thanks for looking into it, but it should be already there, I've just consolidated the

            #define MY_RF69_IRQ_PIN D1
            #define MY_RF69_IRQ_NUM MY_RF69_IRQ_PIN
            

            into a single line:

            #define MY_RF69_IRQ_NUM D1
            
            1 Reply Last reply
            0
            • U Offline
              U Offline
              user2684
              Contest Winner
              wrote on last edited by
              #8

              Quick update on this. I've also tried as the last chance to connect the radio to an external power but the result is always the same (send failure).

              Apart from that, these RFM69 are amazing (this is the first time I'm using this radio), I've tested one with the working serial gateway; first I went downstairs and it was working (where the NRF24 got lost), then I moved outside and was working, then I walked and walked probably around 70-80 meters/yards (plus a few walls), in the dark for a while and was still working (sometimes the gateway was resetting I guess because the tx power required was too high). Pretty impressive.

              mfalkviddM 1 Reply Last reply
              0
              • U user2684

                Quick update on this. I've also tried as the last chance to connect the radio to an external power but the result is always the same (send failure).

                Apart from that, these RFM69 are amazing (this is the first time I'm using this radio), I've tested one with the working serial gateway; first I went downstairs and it was working (where the NRF24 got lost), then I moved outside and was working, then I walked and walked probably around 70-80 meters/yards (plus a few walls), in the dark for a while and was still working (sometimes the gateway was resetting I guess because the tx power required was too high). Pretty impressive.

                mfalkviddM Online
                mfalkviddM Online
                mfalkvidd
                Mod
                wrote on last edited by
                #9

                @user2684 I don't think you can omit defining MY_RF69_IRQ_PIN

                1 Reply Last reply
                1
                • U Offline
                  U Offline
                  user2684
                  Contest Winner
                  wrote on last edited by
                  #10

                  You are the man @mfalkvidd! I've been very superficial to face this issue for saving a single line of code ;-) I didn't notice that define is actually used in MyTransportRFM69.cpp.

                  After adding it back I had to reset it a good number of times, sometimes I had a soft WTD reset just before the send, other times I had !TSF:MSG:SEND once again and then started working, looks like consistently now. I cannot explain why hasn't worked straight away after the change, it could even be some bad wiring I fixed without noticing it. Thanks for the help!

                  1 Reply Last reply
                  1
                  • E Offline
                    E Offline
                    emc2
                    Hardware Contributor
                    wrote on last edited by
                    #11

                    I had the same problem when I was troubleshooting RFM69 on my Wemos GW shield.

                    It seems to me that

                    #define MY_RF69_IRQ_NUM MY_RF69_IRQ_PIN
                    

                    Is supposed to be automatically set when

                    #define ARDUINO_ARCH_ESP8266
                    

                    is defined.

                    You would assume that when you define

                    #define  MY_GATEWAY_ESP8266
                    

                    It would automatically add

                    #define ARDUINO_ARCH_ESP8266
                    

                    For example here in MySensors.h but it is not, meaning that

                    #define MY_RF69_IRQ_NUM MY_RF69_IRQ_PIN
                    

                    is never declared.

                    So you can simply use

                    #define ARDUINO_ARCH_ESP8266
                    #define MY_RF69_IRQ_PIN D1
                    

                    or

                    #define MY_RF69_IRQ_PIN D1
                    #define MY_RF69_IRQ_NUM MY_RF69_IRQ_PIN
                    

                    in your sketch.

                    I personally think it should be automatically done in MySensors.h (and would be happy to submit a ticket on github if needed) but maybe it was done on purpose.

                    1 Reply Last reply
                    1
                    • mppM Offline
                      mppM Offline
                      mpp
                      wrote on last edited by
                      #12

                      How did you get it to work finally?

                      I keep getting these "Soft WDT reset" crashes:

                      0;255;3;0;9;MCO:BGN:INIT GW,CP=RRNGE--,VER=2.1.1
                      0;255;3;0;9;TSF:LRT:OK
                      0;255;3;0;9;TSM:INIT
                      0;255;3;0;9;TSF:WUR:MS=0
                      scandone
                      state: 0 -> 2 (b0)
                      state: 2 -> 3 (0)
                      state: 3 -> 5 (10)
                      add 0
                      aid 3
                      cnt
                      0;255;3;0;9;!TSM:INIT:TSP FAIL

                      connected with Airport, channel 6
                      dhcp client start...
                      0;255;3;0;9;TSM:FAIL:CNT=1
                      0;255;3;0;9;TSM:FAIL:PDT
                      ip:192.168.0.149,mask:255.255.255.0,gw:192.168.0.1
                      pm open,type:2 0
                      0;255;3;0;9;TSM:FAIL:RE-INIT
                      0;255;3;0;9;TSM:INIT

                      Soft WDT reset

                      ctx: cont
                      sp: 3ffef260 end: 3ffef550 offset: 01b0

                      stack>>>
                      3ffef410: 00000004 3ffef940 3ffef5ec 402030bd
                      3ffef420: 00000027 3ffef940 3ffef5ec 40203071
                      3ffef430: 3ffef604 00000001 3ffef5ec 402031b5
                      3ffef440: 00000000 00000016 3ffef5ec 402033f0
                      3ffef450: 0000002f 3ffef940 3ffef5ec 000000ff
                      3ffef460: 00000000 00000016 3ffef5ec 402044bd
                      3ffef470: 00020401 40040203 33060305 40086c07
                      3ffef480: 42190009 07264025 dc291028 2d2f882e
                      3ffef490: 90376330 8f3c4238 306f123d 000000ff
                      3ffef4a0: 00000063 00000000 3ffefa30 40203834
                      3ffef4b0: 3ffef758 00000000 00000000 0000466d
                      3ffef4c0: 3ffef758 00000000 00000000 40204574
                      3ffef4d0: 3ffef758 0000466d 40204290 40204599
                      3ffef4e0: 00000000 00000000 00000000 40202e15
                      3ffef4f0: 000007ce 00000000 00000000 40204ca9
                      3ffef500: 3fffdad0 3ffef5a7 00000000 402050e7
                      3ffef510: 600002ff 00020000 3ffef758 3ffee528
                      3ffef520: 3fffdad0 3ffef5a7 3ffefa10 40205355
                      3ffef530: feefeffe 00000000 3ffee520 402053c0
                      3ffef540: feefeffe feefeffe 3ffee530 40100114
                      <<<stack<<<

                      MyController with USB powered WeMos D1/mini ESP8266 MQTT Gateways and battery powered Arduino Pro Mini using the RFM69 radio

                      U 1 Reply Last reply
                      0
                      • mppM mpp

                        How did you get it to work finally?

                        I keep getting these "Soft WDT reset" crashes:

                        0;255;3;0;9;MCO:BGN:INIT GW,CP=RRNGE--,VER=2.1.1
                        0;255;3;0;9;TSF:LRT:OK
                        0;255;3;0;9;TSM:INIT
                        0;255;3;0;9;TSF:WUR:MS=0
                        scandone
                        state: 0 -> 2 (b0)
                        state: 2 -> 3 (0)
                        state: 3 -> 5 (10)
                        add 0
                        aid 3
                        cnt
                        0;255;3;0;9;!TSM:INIT:TSP FAIL

                        connected with Airport, channel 6
                        dhcp client start...
                        0;255;3;0;9;TSM:FAIL:CNT=1
                        0;255;3;0;9;TSM:FAIL:PDT
                        ip:192.168.0.149,mask:255.255.255.0,gw:192.168.0.1
                        pm open,type:2 0
                        0;255;3;0;9;TSM:FAIL:RE-INIT
                        0;255;3;0;9;TSM:INIT

                        Soft WDT reset

                        ctx: cont
                        sp: 3ffef260 end: 3ffef550 offset: 01b0

                        stack>>>
                        3ffef410: 00000004 3ffef940 3ffef5ec 402030bd
                        3ffef420: 00000027 3ffef940 3ffef5ec 40203071
                        3ffef430: 3ffef604 00000001 3ffef5ec 402031b5
                        3ffef440: 00000000 00000016 3ffef5ec 402033f0
                        3ffef450: 0000002f 3ffef940 3ffef5ec 000000ff
                        3ffef460: 00000000 00000016 3ffef5ec 402044bd
                        3ffef470: 00020401 40040203 33060305 40086c07
                        3ffef480: 42190009 07264025 dc291028 2d2f882e
                        3ffef490: 90376330 8f3c4238 306f123d 000000ff
                        3ffef4a0: 00000063 00000000 3ffefa30 40203834
                        3ffef4b0: 3ffef758 00000000 00000000 0000466d
                        3ffef4c0: 3ffef758 00000000 00000000 40204574
                        3ffef4d0: 3ffef758 0000466d 40204290 40204599
                        3ffef4e0: 00000000 00000000 00000000 40202e15
                        3ffef4f0: 000007ce 00000000 00000000 40204ca9
                        3ffef500: 3fffdad0 3ffef5a7 00000000 402050e7
                        3ffef510: 600002ff 00020000 3ffef758 3ffee528
                        3ffef520: 3fffdad0 3ffef5a7 3ffefa10 40205355
                        3ffef530: feefeffe 00000000 3ffee520 402053c0
                        3ffef540: feefeffe feefeffe 3ffee530 40100114
                        <<<stack<<<

                        U Offline
                        U Offline
                        user2684
                        Contest Winner
                        wrote on last edited by
                        #13

                        @mpp it just started working at a certain point so I assumed my issue was just due to bad wiring. But I must say I stopped testing this configuration after a few days so there could be something else that I missed

                        1 Reply Last reply
                        0
                        Reply
                        • Reply as topic
                        Log in to reply
                        • Oldest to Newest
                        • Newest to Oldest
                        • Most Votes


                        15

                        Online

                        11.7k

                        Users

                        11.2k

                        Topics

                        113.1k

                        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