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. Wemos d1 mini : gateway error .

Wemos d1 mini : gateway error .

Scheduled Pinned Locked Moved Troubleshooting
13 Posts 2 Posters 901 Views 2 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.
  • David MarlingeD Offline
    David MarlingeD Offline
    David Marlinge
    wrote on last edited by
    #1

    Hello,

    this is the first time I'm trying to work with mysensors.
    So I have a wemos d1 mini and a nrf24L01.

    I upload gateway8266 sketch on the wemos card.

    I setup an ip adress (192.168.1.111) gateway 192.168.1.1 and submask : 255.255.255.0.

    But it does work, I can't reach the adress.

    If I plug the wemos on my computer, and launch the serial monitor in arduino IDE, I get this .

    09:15:10.888 -> f`f⸮⸮ff⸮⸮⸮20389 TSM:FAIL:RE-INIT
    09:15:10.888 -> 20413 TSM:INIT
    09:15:10.935 -> 20433 !TSM:INIT:TSP FAIL
    09:15:10.935 -> 20459 TSM:FAIL:CNT=3
    09:15:10.983 -> 20481 TSM:FAIL:DIS
    09:15:10.983 -> 20501 TSF:TDI:TSL

    What do I have to do ?

    Thank you

    PS : i tried with another wemos and same issue.

    mfalkviddM 1 Reply Last reply
    0
    • David MarlingeD David Marlinge

      Hello,

      this is the first time I'm trying to work with mysensors.
      So I have a wemos d1 mini and a nrf24L01.

      I upload gateway8266 sketch on the wemos card.

      I setup an ip adress (192.168.1.111) gateway 192.168.1.1 and submask : 255.255.255.0.

      But it does work, I can't reach the adress.

      If I plug the wemos on my computer, and launch the serial monitor in arduino IDE, I get this .

      09:15:10.888 -> f`f⸮⸮ff⸮⸮⸮20389 TSM:FAIL:RE-INIT
      09:15:10.888 -> 20413 TSM:INIT
      09:15:10.935 -> 20433 !TSM:INIT:TSP FAIL
      09:15:10.935 -> 20459 TSM:FAIL:CNT=3
      09:15:10.983 -> 20481 TSM:FAIL:DIS
      09:15:10.983 -> 20501 TSF:TDI:TSL

      What do I have to do ?

      Thank you

      PS : i tried with another wemos and same issue.

      mfalkviddM Offline
      mfalkviddM Offline
      mfalkvidd
      Mod
      wrote on last edited by mfalkvidd
      #2

      Welcome to the forum @David-Marlinge

      !TSM:INIT:TSP FAIL

      This means that the wemos was unable to initialize the nrf24 radio. Double-check the wiring. If you can't find anything wrong, post multiple photos of the wiring and we'll help check. Plase also post the entire sketch (with wifi namn/password removed).

      If you haven't already, see https://forum.mysensors.org/topic/666/read-this-first-it-could-save-you-a-lot-of-time/ for how to efficiently troubleshoot.

      1 Reply Last reply
      0
      • David MarlingeD Offline
        David MarlingeD Offline
        David Marlinge
        wrote on last edited by
        #3

        Oh, I will check the wiring ...
        I taught It means that it can't connect to wifi ...

        So it's normal that I can't ping the wemos ...

        For the sketch I just upload the example sketch for esp8266gateway..

        /*
         * The MySensors Arduino library handles the wireless radio link and protocol
         * between your home built sensors/actuators and HA controller of choice.
         * The sensors forms a self healing radio network with optional repeaters. Each
         * repeater and gateway builds a routing tables in EEPROM which keeps track of the
         * network topology allowing messages to be routed to nodes.
         *
         * Created by Henrik Ekblad <henrik.ekblad@mysensors.org>
         * Copyright (C) 2013-2019 Sensnology AB
         * Full contributor list: https://github.com/mysensors/MySensors/graphs/contributors
         *
         * Documentation: http://www.mysensors.org
         * Support Forum: http://forum.mysensors.org
         *
         * This program is free software; you can redistribute it and/or
         * modify it under the terms of the GNU General Public License
         * version 2 as published by the Free Software Foundation.
         *
         *******************************
         *
         * REVISION HISTORY
         * Version 1.0 - Henrik Ekblad
         * Contribution by a-lurker and Anticimex,
         * Contribution by Norbert Truchsess <norbert.truchsess@t-online.de>
         * Contribution by Ivo Pullens (ESP8266 support)
         *
         * DESCRIPTION
         * The EthernetGateway sends data received from sensors to the WiFi link.
         * The gateway also accepts input on ethernet interface, which is then sent out to the radio network.
         *
         * VERA CONFIGURATION:
         * Enter "ip-number:port" in the ip-field of the Arduino GW device. This will temporarily override any serial configuration for the Vera plugin.
         * E.g. If you want to use the default values in this sketch enter: 192.168.178.66:5003
         *
         * LED purposes:
         * - To use the feature, uncomment any of the MY_DEFAULT_xx_LED_PINs in your sketch, only the LEDs that is defined is used.
         * - RX (green) - blink fast on radio message received. In inclusion mode will blink fast only on presentation received
         * - TX (yellow) - blink fast on radio message transmitted. In inclusion mode will blink slowly
         * - ERR (red) - fast blink on error during transmission error or receive crc error
         *
         * See https://www.mysensors.org/build/connect_radio for wiring instructions.
         *
         * If you are using a "barebone" ESP8266, see
         * https://www.mysensors.org/build/esp8266_gateway#wiring-for-barebone-esp8266
         *
         * Inclusion mode button:
         * - Connect GPIO5 (=D1) via switch to GND ('inclusion switch')
         *
         * Hardware SHA204 signing is currently not supported!
         *
         * Make sure to fill in your ssid and WiFi password below for ssid & pass.
         */
        
        // Enable debug prints to serial monitor
        #define MY_DEBUG
        
        // Use a bit lower baudrate for serial prints on ESP8266 than default in MyConfig.h
        #define MY_BAUD_RATE 9600
        
        // Enables and select radio type (if attached)
        #define MY_RADIO_RF24
        //#define MY_RADIO_RFM69
        //#define MY_RADIO_RFM95
        
        #define MY_GATEWAY_ESP8266
        
        #define MY_WIFI_SSID "xxxx"
        #define MY_WIFI_PASSWORD "xxxxxx"
        
        // Enable UDP communication
        //#define MY_USE_UDP  // If using UDP you need to set MY_CONTROLLER_IP_ADDRESS or MY_CONTROLLER_URL_ADDRESS below
        
        // Set the hostname for the WiFi Client. This is the hostname
        // it will pass to the DHCP server if not static.
        #define MY_HOSTNAME "ESP8266_GW"
        
        // Enable MY_IP_ADDRESS here if you want a static ip address (no DHCP)
        #define MY_IP_ADDRESS 192,168,1,112
        
        // If using static ip you can define Gateway and Subnet address as well
        #define MY_IP_GATEWAY_ADDRESS 192,168,1,1
        #define MY_IP_SUBNET_ADDRESS 255,255,255,0
        
        // The port to keep open on node server mode
        #define MY_PORT 5003
        
        // How many clients should be able to connect to this gateway (default 1)
        #define MY_GATEWAY_MAX_CLIENTS 2
        
        // Controller ip address. Enables client mode (default is "server" mode).
        // Also enable this if MY_USE_UDP is used and you want sensor data sent somewhere.
        //#define MY_CONTROLLER_IP_ADDRESS 192, 168, 178, 68
        //#define MY_CONTROLLER_URL_ADDRESS "my.controller.org"
        
        // Enable inclusion mode
        //#define MY_INCLUSION_MODE_FEATURE
        
        // Enable Inclusion mode button on gateway
        //#define MY_INCLUSION_BUTTON_FEATURE
        // Set inclusion mode duration (in seconds)
        //#define MY_INCLUSION_MODE_DURATION 60
        // Digital pin used for inclusion mode button
        //#define MY_INCLUSION_MODE_BUTTON_PIN D1
        
        // Set blinking period
        //#define MY_DEFAULT_LED_BLINK_PERIOD 300
        
        // Flash leds on rx/tx/err
        // Led pins used if blinking feature is enabled above
        //#define MY_DEFAULT_ERR_LED_PIN 16  // Error led pin
        //#define MY_DEFAULT_RX_LED_PIN  16  // Receive led pin
        //#define MY_DEFAULT_TX_LED_PIN  16  // the PCB, on board LED
        
        #include <MySensors.h>
        
        void setup()
        {
        	// Setup locally attached sensors
        }
        
        void presentation()
        {
        	// Present locally attached sensors here
        }
        
        void loop()
        {
        	// Send locally attached sensors data here
        }
        
        mfalkviddM 1 Reply Last reply
        1
        • David MarlingeD David Marlinge

          Oh, I will check the wiring ...
          I taught It means that it can't connect to wifi ...

          So it's normal that I can't ping the wemos ...

          For the sketch I just upload the example sketch for esp8266gateway..

          /*
           * The MySensors Arduino library handles the wireless radio link and protocol
           * between your home built sensors/actuators and HA controller of choice.
           * The sensors forms a self healing radio network with optional repeaters. Each
           * repeater and gateway builds a routing tables in EEPROM which keeps track of the
           * network topology allowing messages to be routed to nodes.
           *
           * Created by Henrik Ekblad <henrik.ekblad@mysensors.org>
           * Copyright (C) 2013-2019 Sensnology AB
           * Full contributor list: https://github.com/mysensors/MySensors/graphs/contributors
           *
           * Documentation: http://www.mysensors.org
           * Support Forum: http://forum.mysensors.org
           *
           * This program is free software; you can redistribute it and/or
           * modify it under the terms of the GNU General Public License
           * version 2 as published by the Free Software Foundation.
           *
           *******************************
           *
           * REVISION HISTORY
           * Version 1.0 - Henrik Ekblad
           * Contribution by a-lurker and Anticimex,
           * Contribution by Norbert Truchsess <norbert.truchsess@t-online.de>
           * Contribution by Ivo Pullens (ESP8266 support)
           *
           * DESCRIPTION
           * The EthernetGateway sends data received from sensors to the WiFi link.
           * The gateway also accepts input on ethernet interface, which is then sent out to the radio network.
           *
           * VERA CONFIGURATION:
           * Enter "ip-number:port" in the ip-field of the Arduino GW device. This will temporarily override any serial configuration for the Vera plugin.
           * E.g. If you want to use the default values in this sketch enter: 192.168.178.66:5003
           *
           * LED purposes:
           * - To use the feature, uncomment any of the MY_DEFAULT_xx_LED_PINs in your sketch, only the LEDs that is defined is used.
           * - RX (green) - blink fast on radio message received. In inclusion mode will blink fast only on presentation received
           * - TX (yellow) - blink fast on radio message transmitted. In inclusion mode will blink slowly
           * - ERR (red) - fast blink on error during transmission error or receive crc error
           *
           * See https://www.mysensors.org/build/connect_radio for wiring instructions.
           *
           * If you are using a "barebone" ESP8266, see
           * https://www.mysensors.org/build/esp8266_gateway#wiring-for-barebone-esp8266
           *
           * Inclusion mode button:
           * - Connect GPIO5 (=D1) via switch to GND ('inclusion switch')
           *
           * Hardware SHA204 signing is currently not supported!
           *
           * Make sure to fill in your ssid and WiFi password below for ssid & pass.
           */
          
          // Enable debug prints to serial monitor
          #define MY_DEBUG
          
          // Use a bit lower baudrate for serial prints on ESP8266 than default in MyConfig.h
          #define MY_BAUD_RATE 9600
          
          // Enables and select radio type (if attached)
          #define MY_RADIO_RF24
          //#define MY_RADIO_RFM69
          //#define MY_RADIO_RFM95
          
          #define MY_GATEWAY_ESP8266
          
          #define MY_WIFI_SSID "xxxx"
          #define MY_WIFI_PASSWORD "xxxxxx"
          
          // Enable UDP communication
          //#define MY_USE_UDP  // If using UDP you need to set MY_CONTROLLER_IP_ADDRESS or MY_CONTROLLER_URL_ADDRESS below
          
          // Set the hostname for the WiFi Client. This is the hostname
          // it will pass to the DHCP server if not static.
          #define MY_HOSTNAME "ESP8266_GW"
          
          // Enable MY_IP_ADDRESS here if you want a static ip address (no DHCP)
          #define MY_IP_ADDRESS 192,168,1,112
          
          // If using static ip you can define Gateway and Subnet address as well
          #define MY_IP_GATEWAY_ADDRESS 192,168,1,1
          #define MY_IP_SUBNET_ADDRESS 255,255,255,0
          
          // The port to keep open on node server mode
          #define MY_PORT 5003
          
          // How many clients should be able to connect to this gateway (default 1)
          #define MY_GATEWAY_MAX_CLIENTS 2
          
          // Controller ip address. Enables client mode (default is "server" mode).
          // Also enable this if MY_USE_UDP is used and you want sensor data sent somewhere.
          //#define MY_CONTROLLER_IP_ADDRESS 192, 168, 178, 68
          //#define MY_CONTROLLER_URL_ADDRESS "my.controller.org"
          
          // Enable inclusion mode
          //#define MY_INCLUSION_MODE_FEATURE
          
          // Enable Inclusion mode button on gateway
          //#define MY_INCLUSION_BUTTON_FEATURE
          // Set inclusion mode duration (in seconds)
          //#define MY_INCLUSION_MODE_DURATION 60
          // Digital pin used for inclusion mode button
          //#define MY_INCLUSION_MODE_BUTTON_PIN D1
          
          // Set blinking period
          //#define MY_DEFAULT_LED_BLINK_PERIOD 300
          
          // Flash leds on rx/tx/err
          // Led pins used if blinking feature is enabled above
          //#define MY_DEFAULT_ERR_LED_PIN 16  // Error led pin
          //#define MY_DEFAULT_RX_LED_PIN  16  // Receive led pin
          //#define MY_DEFAULT_TX_LED_PIN  16  // the PCB, on board LED
          
          #include <MySensors.h>
          
          void setup()
          {
          	// Setup locally attached sensors
          }
          
          void presentation()
          {
          	// Present locally attached sensors here
          }
          
          void loop()
          {
          	// Send locally attached sensors data here
          }
          
          mfalkviddM Offline
          mfalkviddM Offline
          mfalkvidd
          Mod
          wrote on last edited by
          #4

          @David-Marlinge test it is normal, if there is a problem with the nrf24. A gateway is (usually) not useful if it can’t talk to any nodes, so it will block if initialization fails.

          1 Reply Last reply
          0
          • David MarlingeD Offline
            David MarlingeD Offline
            David Marlinge
            wrote on last edited by
            #5

            Now the wiring check.
            I have a nrf24l01 with antenna, and nothing is written on the board ...
            Does someone have a wiring diagram for that nrf module ?

            Thank you.

            mfalkviddM 1 Reply Last reply
            0
            • David MarlingeD David Marlinge

              Now the wiring check.
              I have a nrf24l01 with antenna, and nothing is written on the board ...
              Does someone have a wiring diagram for that nrf module ?

              Thank you.

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

              @David-Marlinge could you expand on what you mean by "nothing is written on the board". Which board?

              The wiring is available at https://www.mysensors.org/build/connect_radio#nrf24l01+-&-esp8266

              1 Reply Last reply
              0
              • David MarlingeD Offline
                David MarlingeD Offline
                David Marlinge
                wrote on last edited by
                #7

                nothing is written on the nrf24L01 board ...

                I send a picture ...

                mfalkviddM 1 Reply Last reply
                0
                • David MarlingeD David Marlinge

                  nothing is written on the nrf24L01 board ...

                  I send a picture ...

                  mfalkviddM Offline
                  mfalkviddM Offline
                  mfalkvidd
                  Mod
                  wrote on last edited by
                  #8

                  @David-Marlinge the nrf24 chip is not a board in the Arduino board meaning. Nothing can be written to it. It must be connected to a microcontroller to be useful.

                  1 Reply Last reply
                  0
                  • David MarlingeD Offline
                    David MarlingeD Offline
                    David Marlinge
                    wrote on last edited by
                    #9

                    IMG_20200805_103927.jpg IMG_20200805_103957.jpg

                    If it's the same wiring, I connect like your link, but it does not work.

                    Now I can ping the wifi adress even if the nrf24l01 is not plugin ... In fact It doesn't take the adress I give in the sketch ....

                    1 Reply Last reply
                    0
                    • David MarlingeD Offline
                      David MarlingeD Offline
                      David Marlinge
                      wrote on last edited by
                      #10

                      What I want to say, is that nothing is written on the pin ... So How can I be sure where the gnd, vcc and so on are ???

                      mfalkviddM 1 Reply Last reply
                      0
                      • David MarlingeD David Marlinge

                        What I want to say, is that nothing is written on the pin ... So How can I be sure where the gnd, vcc and so on are ???

                        mfalkviddM Offline
                        mfalkviddM Offline
                        mfalkvidd
                        Mod
                        wrote on last edited by
                        #11

                        @David-Marlinge I see. Sorry for misunderstanding.

                        The pinout is probably compatible with the smaller nrf24 (without PA). If you can, check with the vendor/store where you bought the nrf24.

                        1 Reply Last reply
                        0
                        • David MarlingeD Offline
                          David MarlingeD Offline
                          David Marlinge
                          wrote on last edited by
                          #12

                          I have already check, nothing is written on the store where i bought them ...

                          Is tha capacitor needed ? and Must the whole thing works connected on a PC usb ?

                          1 Reply Last reply
                          0
                          • David MarlingeD Offline
                            David MarlingeD Offline
                            David Marlinge
                            wrote on last edited by
                            #13

                            So I check the wiring. I think a wire was not well plugged.
                            Now it works.
                            I have such "sentences" :
                            11:52:22.169 -> 12496 GWT:TIN:CONNECTING...
                            11:52:22.499 -> scandone
                            11:52:23.204 -> 13525 GWT:TIN:CONNECTING...
                            11:52:23.204 -> 13555 GWT:TIN:IP: 192.168.1.111
                            11:52:23.251 -> 13588 MCO:BGN:STP
                            11:52:23.251 -> 13607 MCO:BGN:INIT OK,TSP=1
                            11:52:23.298 -> 13637 TSM:READY:NWD REQ
                            11:52:23.346 -> 13665 ?TSF:MSG:SEND,0-0-255-255,s=255,c=3,t=20,pt=0,l=0,sg=0,ft=0,st=OK:
                            11:52:23.535 -> pm open,type:2 0

                            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


                            20

                            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