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. General Discussion
  3. Funny charachters at reset

Funny charachters at reset

Scheduled Pinned Locked Moved General Discussion
10 Posts 4 Posters 1.3k 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.
  • sghazaghS Offline
    sghazaghS Offline
    sghazagh
    wrote on last edited by sghazagh
    #1

    Hi all,
    I am using Lolin D1 mini pro along with NRF24L01 radio connected.
    I uploaded mysensors relay sketch and whenever the radio is connected, at reset time, I see funny charachters in serial consol preventing the device to come up.
    When I disconnect the radio +3v pin it starts then I have to re-connect the radio power to get it working otherwise it won't work and above problem happens!!!

    Do you guys have any idea why it's happening?

    For your info, the esp8266 library version 4.2.1 is used because as I read in a post, Mysensors won't work with version 4.2.2 and Lolin bored at the moment!

    YveauxY 1 Reply Last reply
    1
    • alowhumA Offline
      alowhumA Offline
      alowhum
      Plugin Developer
      wrote on last edited by
      #2

      I always get a few funny characters when I re-initiate the serial monitor on my Arduino Nano's. But there it's not blocking anything.

      1 Reply Last reply
      0
      • sghazaghS sghazagh

        Hi all,
        I am using Lolin D1 mini pro along with NRF24L01 radio connected.
        I uploaded mysensors relay sketch and whenever the radio is connected, at reset time, I see funny charachters in serial consol preventing the device to come up.
        When I disconnect the radio +3v pin it starts then I have to re-connect the radio power to get it working otherwise it won't work and above problem happens!!!

        Do you guys have any idea why it's happening?

        For your info, the esp8266 library version 4.2.1 is used because as I read in a post, Mysensors won't work with version 4.2.2 and Lolin bored at the moment!

        YveauxY Offline
        YveauxY Offline
        Yveaux
        Mod
        wrote on last edited by
        #3

        @sghazagh how did you connect the radio?
        An ESP8266 outputs some bootloader text at a nonstandard baud rate during startup (74880 iirr) which looks like nonsense characters in a terminal with a different baud rate; maybe that's what you're seeing.

        http://yveaux.blogspot.nl

        sghazaghS 1 Reply Last reply
        1
        • YveauxY Yveaux

          @sghazagh how did you connect the radio?
          An ESP8266 outputs some bootloader text at a nonstandard baud rate during startup (74880 iirr) which looks like nonsense characters in a terminal with a different baud rate; maybe that's what you're seeing.

          sghazaghS Offline
          sghazaghS Offline
          sghazagh
          wrote on last edited by sghazagh
          #4

          @yveaux thanks for your reply,
          The radio connected as usual:

          1_1536888951062_2.png
          0_1536888951061_1.png
          0_1536889425869_3.png 0_1536889523085_4.png
          (All cables used with color coding for better understanding of connection pins)

          I also have changed the different baud rate...it's not that, because at 115200, with radio power disconnected, I can see all the MySensor messages, also when I reconnect the radio power, I can see that the radio can connect to controller and send.receive data!

          Only when radio connected at boot time, device does not boot and does not work properly!

          1 Reply Last reply
          0
          • sghazaghS Offline
            sghazaghS Offline
            sghazagh
            wrote on last edited by sghazagh
            #5

            All,
            I have changed the baud rate to "74880" as @yveaux mentioned and surprisingly I see this message which prevent the device to boot:

             ets Jan  8 2013,rst cause:2, boot mode:(7,7)
            
            waiting for host
            

            Do you know why it's going to this mode and how can I avoid that?

            mfalkviddM 1 Reply Last reply
            0
            • sghazaghS sghazagh

              All,
              I have changed the baud rate to "74880" as @yveaux mentioned and surprisingly I see this message which prevent the device to boot:

               ets Jan  8 2013,rst cause:2, boot mode:(7,7)
              
              waiting for host
              

              Do you know why it's going to this mode and how can I avoid that?

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

              @sghazagh gpio 0,2 and 15 are used to select boot mode on the esp8266. See https://zoetrope.io/tech-blog/esp8266-bootloader-modes-and-gpio-state-startup/ for details, especially this part:

              When choosing GPIO pins to use, it’s best to avoid GPIO 0, 2 and 15 unless absolutely necessary. If you do end up using them, you’ll need pullups / pulldowns to ensure the correct bootloader mode.

              Not sure why this becomes a problem in your setup though. The wiring instructions used for MySensors usually works.

              sghazaghS 1 Reply Last reply
              0
              • mfalkviddM mfalkvidd

                @sghazagh gpio 0,2 and 15 are used to select boot mode on the esp8266. See https://zoetrope.io/tech-blog/esp8266-bootloader-modes-and-gpio-state-startup/ for details, especially this part:

                When choosing GPIO pins to use, it’s best to avoid GPIO 0, 2 and 15 unless absolutely necessary. If you do end up using them, you’ll need pullups / pulldowns to ensure the correct bootloader mode.

                Not sure why this becomes a problem in your setup though. The wiring instructions used for MySensors usually works.

                sghazaghS Offline
                sghazaghS Offline
                sghazagh
                wrote on last edited by
                #7

                @mfalkvidd

                I read this in forum:

                Ok, after debugging for a while: the problem is with the CSN pin on GPIO pin 15. Pin 15 is also used in the ESP8266 to define boot from SD card. Somehow, at least in my case, after a reset, the NRF chip sets the CSN pin to high (measured it with a multimeter), causing the ESP8266 to start the SD-card procedure, which fails of course. The solution for me is swapping the pins for inclusion with the CSN pin:

                So:
                CSN -> GPIO 5 -> D1
                Inclusion mode -> GPIO 15 -> D78

                One question though: I also seem to have SPI pins on the other side of the Devkit, why aren't those used?```

                That's the one you addressed in GIT.
                I tried to move the CE pin to something else but it seems that it's not working!

                // To use native I2C pins CE should be moved. Declare the new GPIO used here.
                // GPIO 3 is pin D9 (RX below D8)
                #define MY_RF24_CE_PIN D4
                
                mfalkviddM 1 Reply Last reply
                0
                • sghazaghS sghazagh

                  @mfalkvidd

                  I read this in forum:

                  Ok, after debugging for a while: the problem is with the CSN pin on GPIO pin 15. Pin 15 is also used in the ESP8266 to define boot from SD card. Somehow, at least in my case, after a reset, the NRF chip sets the CSN pin to high (measured it with a multimeter), causing the ESP8266 to start the SD-card procedure, which fails of course. The solution for me is swapping the pins for inclusion with the CSN pin:

                  So:
                  CSN -> GPIO 5 -> D1
                  Inclusion mode -> GPIO 15 -> D78

                  One question though: I also seem to have SPI pins on the other side of the Devkit, why aren't those used?```

                  That's the one you addressed in GIT.
                  I tried to move the CE pin to something else but it seems that it's not working!

                  // To use native I2C pins CE should be moved. Declare the new GPIO used here.
                  // GPIO 3 is pin D9 (RX below D8)
                  #define MY_RF24_CE_PIN D4
                  
                  mfalkviddM Offline
                  mfalkviddM Offline
                  mfalkvidd
                  Mod
                  wrote on last edited by mfalkvidd
                  #8

                  @sghazagh did you add the #define before including MySensors.h? (common mistake is to add it after)

                  I am not familiar with this particular board, but I think other esp8266-based boards use the other SPI for communicating with the flash memory.

                  sghazaghS 1 Reply Last reply
                  0
                  • mfalkviddM mfalkvidd

                    @sghazagh did you add the #define before including MySensors.h? (common mistake is to add it after)

                    I am not familiar with this particular board, but I think other esp8266-based boards use the other SPI for communicating with the flash memory.

                    sghazaghS Offline
                    sghazaghS Offline
                    sghazagh
                    wrote on last edited by sghazagh
                    #9

                    @mfalkvidd Yes, I double checked and it is just before Mysensors.h line.
                    I see the Mysensors message in console, however, the radio connection is failing....

                    I see in another post , have mentioned that the Mysensors library 2.3.1 or 4.0.0 will be release to resolve the issue we have when compiling for "Lonin D1 Mini Pro" board. Do you know when that gonna happen?
                    I afraid maybe the library is mismatching with older version of "Lolin D1 mini pro" which is "Wemos D1 mini pro".

                    At the moment I see the name Wemos... in the list of devices in Arduino IDE as I am using esp8266 version 4.2.1.
                    Version 4.2.2 of esp8266 is listing the devise as Lolin ... name. I thought maybe the library is not fully compatible with this device as if I use that library the compile won't be successful.
                    Do you think that might cause the issue?

                    1 Reply Last reply
                    0
                    • sghazaghS Offline
                      sghazaghS Offline
                      sghazagh
                      wrote on last edited by sghazagh
                      #10

                      It seems that I could fix the issue by making the pin 15, LOW at boot time as it triggers the SD BOOT option in ESP8266:

                      void setup() {
                        pinMode(15, OUTPUT); 
                        digitalWrite(15,LOW);
                      }
                      
                      1 Reply Last reply
                      1
                      Reply
                      • Reply as topic
                      Log in to reply
                      • Oldest to Newest
                      • Newest to Oldest
                      • Most Votes


                      12

                      Online

                      11.7k

                      Users

                      11.2k

                      Topics

                      113.0k

                      Posts


                      Copyright 2019 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