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. [Solved] MySensors 2.0 Ethernet gateway (ENC28J60) restart / IP issue

[Solved] MySensors 2.0 Ethernet gateway (ENC28J60) restart / IP issue

Scheduled Pinned Locked Moved Troubleshooting
49 Posts 9 Posters 22.2k Views 8 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.
  • GizMoCuzG GizMoCuz

    No, the Node is resetting itself with the messages in the first post.
    If i disable debug, it is logging the IP Address over and over again (each second), connection is reset at that moment

    tekkaT Offline
    tekkaT Offline
    tekka
    Admin
    wrote on last edited by
    #29

    @GizMoCuz Please upload your sketch and describe your configuration, I will try to reproduce with my HW.

    1 Reply Last reply
    0
    • GizMoCuzG Offline
      GizMoCuzG Offline
      GizMoCuz
      wrote on last edited by GizMoCuz
      #30

      The sketch is 99,999% the same as 'GatewayW5100' except i changed:

      #define MY_IP_ADDRESS 192,168,0,50 
      

      The default Arduino ethernet server examples work perfectly

      Thanks in advance !

      tekkaT 1 Reply Last reply
      0
      • GizMoCuzG GizMoCuz

        The sketch is 99,999% the same as 'GatewayW5100' except i changed:

        #define MY_IP_ADDRESS 192,168,0,50 
        

        The default Arduino ethernet server examples work perfectly

        Thanks in advance !

        tekkaT Offline
        tekkaT Offline
        tekka
        Admin
        wrote on last edited by
        #31

        @GizMoCuz did you uncomment

        #define MY_DEBUG
        

        as suggested above?

        GizMoCuzG 1 Reply Last reply
        0
        • tekkaT tekka

          @GizMoCuz did you uncomment

          #define MY_DEBUG
          

          as suggested above?

          GizMoCuzG Offline
          GizMoCuzG Offline
          GizMoCuz
          wrote on last edited by GizMoCuz
          #32

          @tekka said:

          @GizMoCuz did you uncomment

          #define MY_DEBUG
          

          as suggested above?

          Yep, see three posts up (If i disable debug, it is logging the IP Address over and over again (each second), connection is reset at that moment)

          And unfortunately does not explain why version 1.5 is running (but missing important features/fixes)

          tekkaT 1 Reply Last reply
          0
          • GizMoCuzG GizMoCuz

            @tekka said:

            @GizMoCuz did you uncomment

            #define MY_DEBUG
            

            as suggested above?

            Yep, see three posts up (If i disable debug, it is logging the IP Address over and over again (each second), connection is reset at that moment)

            And unfortunately does not explain why version 1.5 is running (but missing important features/fixes)

            tekkaT Offline
            tekkaT Offline
            tekka
            Admin
            wrote on last edited by
            #33

            @GizMoCuz I cannot reproduce your observation with a UNO and W5100 shield. How about power-supply, SPI settings/pins in yor setup?

            1 Reply Last reply
            0
            • M Offline
              M Offline
              Maks_K
              wrote on last edited by
              #34

              I have the same problem:
              Mega 2560+ w5100
              Lib 1.5.4 all good
              Lib 2.0 restart again and again

              tekkaT 1 Reply Last reply
              0
              • M Maks_K

                I have the same problem:
                Mega 2560+ w5100
                Lib 1.5.4 all good
                Lib 2.0 restart again and again

                tekkaT Offline
                tekkaT Offline
                tekka
                Admin
                wrote on last edited by tekka
                #35

                @Maks_K @GizMoCuz see here for a solution: https://forum.mysensors.org/topic/4680/mysensors-2-0-ethernet-gateway-atmega-w5100-restart-all-time/3

                1 Reply Last reply
                1
                • tekkaT tekka

                  @intellium Sounds good - fyi, I'm using both, W5100 and ESP8266-based GWs, w/o issues.

                  intelliumI Offline
                  intelliumI Offline
                  intellium
                  wrote on last edited by
                  #36

                  @tekka After my original report that the serial gateway worked through the night, I have had to reset it every ~24 hours. Somewhere around that timeframe, the serial gateway just doesn't respond anymore. Restarting the controller doesn't help. When I reset the serial gateway, it instantly works again and continues to do so for around 24 hours. So it seems that although the serial gateway works longer, it eventually also suffers the same issue.... Is this some kind of memory leak perhaps ?

                  sundberg84S YveauxY 2 Replies Last reply
                  0
                  • intelliumI intellium

                    @tekka After my original report that the serial gateway worked through the night, I have had to reset it every ~24 hours. Somewhere around that timeframe, the serial gateway just doesn't respond anymore. Restarting the controller doesn't help. When I reset the serial gateway, it instantly works again and continues to do so for around 24 hours. So it seems that although the serial gateway works longer, it eventually also suffers the same issue.... Is this some kind of memory leak perhaps ?

                    sundberg84S Offline
                    sundberg84S Offline
                    sundberg84
                    Hardware Contributor
                    wrote on last edited by
                    #37

                    @intellium - as said before, I strongly as well suspect power issues. I would try out different power supplies and try changing out different parts in your setup.

                    Controller: Proxmox VM - Home Assistant
                    MySensors GW: Arduino Uno - W5100 Ethernet, Gw Shield Nrf24l01+ 2,4Ghz
                    MySensors GW: Arduino Uno - Gw Shield RFM69, 433mhz
                    RFLink GW - Arduino Mega + RFLink Shield, 433mhz

                    intelliumI 1 Reply Last reply
                    0
                    • sundberg84S sundberg84

                      @intellium - as said before, I strongly as well suspect power issues. I would try out different power supplies and try changing out different parts in your setup.

                      intelliumI Offline
                      intelliumI Offline
                      intellium
                      wrote on last edited by
                      #38

                      @sundberg84 I've tried different power supplies already with the same problem.

                      I'll source some more components from different shops and will build another gateway to test. Will report back once done.

                      1 Reply Last reply
                      0
                      • intelliumI intellium

                        @tekka After my original report that the serial gateway worked through the night, I have had to reset it every ~24 hours. Somewhere around that timeframe, the serial gateway just doesn't respond anymore. Restarting the controller doesn't help. When I reset the serial gateway, it instantly works again and continues to do so for around 24 hours. So it seems that although the serial gateway works longer, it eventually also suffers the same issue.... Is this some kind of memory leak perhaps ?

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

                        @intellium said:

                        seems that although the serial gateway works longer, it eventually also suffers the same issue

                        Getting into a 'reboot loop' and 'no longer responding' are probably two different things. We should be careful not to mix things up!

                        http://yveaux.blogspot.nl

                        1 Reply Last reply
                        0
                        • kk02067K Offline
                          kk02067K Offline
                          kk02067
                          wrote on last edited by
                          #40

                          I have just found this thread and are having the exact same problem. Arduino nano and en enc28j60 shield.

                          I don't think its a supply problem.

                          I had to drive the radio with softspi to get that working only to get the "reboot" issue.

                          I put this in the setup section of the sketch to catch whats reseting the mcu:

                           Serial.println(MCUSR);
                           MCUSR=0;
                          

                          This produces this result:

                          0;255;3;0;9;Starting gateway (RNNGA-, 2.0.0)
                          0;255;3;0;9;TSM:INIT
                          0;255;3;0;9;TSM:RADIO:OK
                          0;255;3;0;9;TSM:GW MODE
                          0;255;3;0;9;TSM:READY
                          IP: 192.168.0.72
                          2        <------------ this is when I push the reset button
                          0;255;3;0;9;Starting gateway (RNNGA-, 2.0.0)
                          0;255;3;0;9;TSM:INIT
                          0;255;3;0;9;TSM:RADIO:OK
                          0;255;3;0;9;TSM:GW MODE
                          0;255;3;0;9;TSM:READY
                          IP: 192.168.0.72
                          0        <------------  this is the cpu restarting the sketch because of something unknown
                          0;255;3;0;9;Starting gateway (RNNGA-, 2.0.0)
                          0;255;3;0;9;TSM:INIT
                          0;255;3;0;9;TSM:RADIO:OK
                          0;255;3;0;9;TSM:GW MODE
                          0;255;3;0;9;TSM:READY
                          IP: 192.168.0.72
                          0
                          0;255;3;0;9;Starting gateway (RNNGA-, 2.0.0)
                          0;255;3;0;9;TSM:INIT
                          0;255;3;0;9;TSM:RADIO:OK
                          0;255;3;0;9;TSM:GW MODE
                          0;255;3;0;9;TSM:READY
                          IP: 192.168.0.72
                          0
                          
                          

                          So it seems its not the mcu thats resets. The mcu either executes the nops inte unused flash space and wraps around to adress $0000 and starts over again, or there is a bug in the mysensors or the uipethernet files.

                          Any thoughts on this?

                          This is the complete sketch,

                          /**
                           * 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-2015 Sensnology AB
                           * Full contributor list: https://github.com/mysensors/Arduino/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 Tomas Hozza <thozza@gmail.com>
                           *
                           *
                           * DESCRIPTION
                           * The EthernetGateway sends data received from sensors to the ethernet link.
                           * The gateway also accepts input on ethernet interface, which is then sent out to the radio network.
                           *
                           * The GW code is designed for Arduino 328p / 16MHz.  ATmega168 does not have enough memory to run this program.
                           *
                           * LED purposes:
                           * - To use the feature, uncomment WITH_LEDS_BLINKING in MyConfig.h
                           * - RX (green) - blink fast on radio message recieved. In inclusion mode will blink fast only on presentation recieved
                           * - TX (yellow) - blink fast on radio message transmitted. In inclusion mode will blink slowly
                           * - ERR (red) - fast blink on error during transmission error or recieve crc error
                           *
                           * See http://www.mysensors.org/build/ethernet_gateway for wiring instructions.
                           *
                           */
                          
                          // Enable debug prints to serial monitor
                          #define MY_DEBUG 
                          
                          #define MY_RF24_CHANNEL 1
                          
                          // Enable and select radio type attached
                          #define MY_RADIO_NRF24
                          //#define MY_RADIO_RFM69
                          
                          // Enable gateway ethernet module type 
                          #define MY_GATEWAY_ENC28J60
                          
                          // W5100 Ethernet module SPI enable (optional if using a shield/module that manages SPI_EN signal)
                          //#define MY_W5100_SPI_EN 4  
                          
                          // Enable Soft SPI for NRF radio (note different radio wiring is required)
                          // The W5100 ethernet module seems to have a hard time co-operate with 
                          // radio on the same spi bus.
                          
                            #define MY_SOFTSPI
                            #define MY_SOFT_SPI_SCK_PIN 7
                            #define MY_SOFT_SPI_MISO_PIN 8
                            #define MY_SOFT_SPI_MOSI_PIN 9
                            
                          
                          // When W5100 is connected we have to move CE/CSN pins for NRF radio
                          #ifndef MY_RF24_CE_PIN 
                            #define MY_RF24_CE_PIN 5
                          #endif
                          #ifndef MY_RF24_CS_PIN 
                            #define MY_RF24_CS_PIN 6
                          #endif
                          
                          // Enable to UDP          
                          //#define MY_USE_UDP
                          
                          #define MY_IP_ADDRESS 192,168,0,72   // If this is disabled, DHCP is used to retrieve address
                          // Renewal period if using DHCP
                          //#define MY_IP_RENEWAL_INTERVAL 60000
                          // The port to keep open on node server mode / or port to contact in client mode
                          #define MY_PORT 5003      
                          
                          // 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, 254   
                           
                          // The MAC address can be anything you want but should be unique on your network.
                          // Newer boards have a MAC address printed on the underside of the PCB, which you can (optionally) use.
                          // Note that most of the Ardunio examples use  "DEAD BEEF FEED" for the MAC address.
                          #define MY_MAC_ADDRESS 0xDE, 0xAD, 0xBE, 0xEF, 0xFE, 0xDD
                          
                          // Flash leds on rx/tx/err
                          //#define MY_LEDS_BLINKING_FEATURE
                          // Set blinking period
                          //#define MY_DEFAULT_LED_BLINK_PERIOD 300
                          
                          // 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  3 
                          
                          // Uncomment to override default HW configurations
                          //#define MY_DEFAULT_ERR_LED_PIN 7  // Error led pin
                          //#define MY_DEFAULT_RX_LED_PIN  8  // Receive led pin
                          //#define MY_DEFAULT_TX_LED_PIN  9  // the PCB, on board LED
                          
                          #include <SPI.h>
                          
                          #if defined(MY_USE_UDP)
                            #include <EthernetUdp.h>
                          #endif
                          //#include <Ethernet.h>
                          #include <UIPEthernet.h>
                          #include <MySensors.h>
                          
                          
                          void setup()
                          {
                            Serial.println(MCUSR);
                            MCUSR=0;
                          }
                          
                          void loop() {
                            
                          }
                          
                          tekkaT 1 Reply Last reply
                          0
                          • kk02067K kk02067

                            I have just found this thread and are having the exact same problem. Arduino nano and en enc28j60 shield.

                            I don't think its a supply problem.

                            I had to drive the radio with softspi to get that working only to get the "reboot" issue.

                            I put this in the setup section of the sketch to catch whats reseting the mcu:

                             Serial.println(MCUSR);
                             MCUSR=0;
                            

                            This produces this result:

                            0;255;3;0;9;Starting gateway (RNNGA-, 2.0.0)
                            0;255;3;0;9;TSM:INIT
                            0;255;3;0;9;TSM:RADIO:OK
                            0;255;3;0;9;TSM:GW MODE
                            0;255;3;0;9;TSM:READY
                            IP: 192.168.0.72
                            2        <------------ this is when I push the reset button
                            0;255;3;0;9;Starting gateway (RNNGA-, 2.0.0)
                            0;255;3;0;9;TSM:INIT
                            0;255;3;0;9;TSM:RADIO:OK
                            0;255;3;0;9;TSM:GW MODE
                            0;255;3;0;9;TSM:READY
                            IP: 192.168.0.72
                            0        <------------  this is the cpu restarting the sketch because of something unknown
                            0;255;3;0;9;Starting gateway (RNNGA-, 2.0.0)
                            0;255;3;0;9;TSM:INIT
                            0;255;3;0;9;TSM:RADIO:OK
                            0;255;3;0;9;TSM:GW MODE
                            0;255;3;0;9;TSM:READY
                            IP: 192.168.0.72
                            0
                            0;255;3;0;9;Starting gateway (RNNGA-, 2.0.0)
                            0;255;3;0;9;TSM:INIT
                            0;255;3;0;9;TSM:RADIO:OK
                            0;255;3;0;9;TSM:GW MODE
                            0;255;3;0;9;TSM:READY
                            IP: 192.168.0.72
                            0
                            
                            

                            So it seems its not the mcu thats resets. The mcu either executes the nops inte unused flash space and wraps around to adress $0000 and starts over again, or there is a bug in the mysensors or the uipethernet files.

                            Any thoughts on this?

                            This is the complete sketch,

                            /**
                             * 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-2015 Sensnology AB
                             * Full contributor list: https://github.com/mysensors/Arduino/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 Tomas Hozza <thozza@gmail.com>
                             *
                             *
                             * DESCRIPTION
                             * The EthernetGateway sends data received from sensors to the ethernet link.
                             * The gateway also accepts input on ethernet interface, which is then sent out to the radio network.
                             *
                             * The GW code is designed for Arduino 328p / 16MHz.  ATmega168 does not have enough memory to run this program.
                             *
                             * LED purposes:
                             * - To use the feature, uncomment WITH_LEDS_BLINKING in MyConfig.h
                             * - RX (green) - blink fast on radio message recieved. In inclusion mode will blink fast only on presentation recieved
                             * - TX (yellow) - blink fast on radio message transmitted. In inclusion mode will blink slowly
                             * - ERR (red) - fast blink on error during transmission error or recieve crc error
                             *
                             * See http://www.mysensors.org/build/ethernet_gateway for wiring instructions.
                             *
                             */
                            
                            // Enable debug prints to serial monitor
                            #define MY_DEBUG 
                            
                            #define MY_RF24_CHANNEL 1
                            
                            // Enable and select radio type attached
                            #define MY_RADIO_NRF24
                            //#define MY_RADIO_RFM69
                            
                            // Enable gateway ethernet module type 
                            #define MY_GATEWAY_ENC28J60
                            
                            // W5100 Ethernet module SPI enable (optional if using a shield/module that manages SPI_EN signal)
                            //#define MY_W5100_SPI_EN 4  
                            
                            // Enable Soft SPI for NRF radio (note different radio wiring is required)
                            // The W5100 ethernet module seems to have a hard time co-operate with 
                            // radio on the same spi bus.
                            
                              #define MY_SOFTSPI
                              #define MY_SOFT_SPI_SCK_PIN 7
                              #define MY_SOFT_SPI_MISO_PIN 8
                              #define MY_SOFT_SPI_MOSI_PIN 9
                              
                            
                            // When W5100 is connected we have to move CE/CSN pins for NRF radio
                            #ifndef MY_RF24_CE_PIN 
                              #define MY_RF24_CE_PIN 5
                            #endif
                            #ifndef MY_RF24_CS_PIN 
                              #define MY_RF24_CS_PIN 6
                            #endif
                            
                            // Enable to UDP          
                            //#define MY_USE_UDP
                            
                            #define MY_IP_ADDRESS 192,168,0,72   // If this is disabled, DHCP is used to retrieve address
                            // Renewal period if using DHCP
                            //#define MY_IP_RENEWAL_INTERVAL 60000
                            // The port to keep open on node server mode / or port to contact in client mode
                            #define MY_PORT 5003      
                            
                            // 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, 254   
                             
                            // The MAC address can be anything you want but should be unique on your network.
                            // Newer boards have a MAC address printed on the underside of the PCB, which you can (optionally) use.
                            // Note that most of the Ardunio examples use  "DEAD BEEF FEED" for the MAC address.
                            #define MY_MAC_ADDRESS 0xDE, 0xAD, 0xBE, 0xEF, 0xFE, 0xDD
                            
                            // Flash leds on rx/tx/err
                            //#define MY_LEDS_BLINKING_FEATURE
                            // Set blinking period
                            //#define MY_DEFAULT_LED_BLINK_PERIOD 300
                            
                            // 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  3 
                            
                            // Uncomment to override default HW configurations
                            //#define MY_DEFAULT_ERR_LED_PIN 7  // Error led pin
                            //#define MY_DEFAULT_RX_LED_PIN  8  // Receive led pin
                            //#define MY_DEFAULT_TX_LED_PIN  9  // the PCB, on board LED
                            
                            #include <SPI.h>
                            
                            #if defined(MY_USE_UDP)
                              #include <EthernetUdp.h>
                            #endif
                            //#include <Ethernet.h>
                            #include <UIPEthernet.h>
                            #include <MySensors.h>
                            
                            
                            void setup()
                            {
                              Serial.println(MCUSR);
                              MCUSR=0;
                            }
                            
                            void loop() {
                              
                            }
                            
                            tekkaT Offline
                            tekkaT Offline
                            tekka
                            Admin
                            wrote on last edited by
                            #41

                            @kk02067 What bootloader are you running?

                            kk02067K 1 Reply Last reply
                            0
                            • tekkaT tekka

                              @kk02067 What bootloader are you running?

                              kk02067K Offline
                              kk02067K Offline
                              kk02067
                              wrote on last edited by
                              #42

                              @tekka Don't know. Cheap chinese clone of arduino nano

                              How do I check?
                              This is what the arduino IDE spits out when uploading to the nano:

                              avrdude: Version 6.0.1, compiled on Apr 15 2015 at 19:59:58
                                       Copyright (c) 2000-2005 Brian Dean, http://www.bdmicro.com/
                                       Copyright (c) 2007-2009 Joerg Wunsch
                              
                                       System wide configuration file is "C:\Program Files (x86)\Arduino\hardware\tools\avr/etc/avrdude.conf"
                              
                                       Using Port                    : COM6
                                       Using Programmer              : arduino
                                       Overriding Baud Rate          : 57600
                                       AVR Part                      : ATmega328P
                                       Chip Erase delay              : 9000 us
                                       PAGEL                         : PD7
                                       BS2                           : PC2
                                       RESET disposition             : dedicated
                                       RETRY pulse                   : SCK
                                       serial program mode           : yes
                                       parallel program mode         : yes
                                       Timeout                       : 200
                                       StabDelay                     : 100
                                       CmdexeDelay                   : 25
                                       SyncLoops                     : 32
                                       ByteDelay                     : 0
                                       PollIndex                     : 3
                                       PollValue                     : 0x53
                                       Memory Detail                 :
                              
                                                                Block Poll               Page                       Polled
                                         Memory Type Mode Delay Size  Indx Paged  Size   Size #Pages MinW  MaxW   ReadBack
                                         ----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
                                         eeprom        65    20     4    0 no       1024    4      0  3600  3600 0xff 0xff
                                         flash         65     6   128    0 yes     32768  128    256  4500  4500 0xff 0xff
                                         lfuse          0     0     0    0 no          1    0      0  4500  4500 0x00 0x00
                                         hfuse          0     0     0    0 no          1    0      0  4500  4500 0x00 0x00
                                         efuse          0     0     0    0 no          1    0      0  4500  4500 0x00 0x00
                                         lock           0     0     0    0 no          1    0      0  4500  4500 0x00 0x00
                                         calibration    0     0     0    0 no          1    0      0     0     0 0x00 0x00
                                         signature      0     0     0    0 no          3    0      0     0     0 0x00 0x00
                              
                                       Programmer Type : Arduino
                                       Description     : Arduino
                                       Hardware Version: 2
                                       Firmware Version: 1.16
                                       Vtarget         : 0.0 V
                                       Varef           : 0.0 V
                                       Oscillator      : Off
                                       SCK period      : 0.1 us
                              
                              avrdude: AVR device initialized and ready to accept instructions
                              
                              Reading | ################################################## | 100% 0.00s
                              
                              avrdude: Device signature = 0x1e950f
                              avrdude: reading input file "C:\Users\Tony\AppData\Local\Temp\build12bf64d7a85151b4ee71a15dfecff5f5.tmp/GatewayW5100.ino.hex"
                              avrdude: writing flash (26964 bytes):
                              
                              Writing | ################################################## | 100% 7.51s
                              
                              avrdude: 26964 bytes of flash written
                              avrdude: verifying flash memory against C:\Users\Tony\AppData\Local\Temp\build12bf64d7a85151b4ee71a15dfecff5f5.tmp/GatewayW5100.ino.hex:
                              avrdude: load data flash data from input file C:\Users\Tony\AppData\Local\Temp\build12bf64d7a85151b4ee71a15dfecff5f5.tmp/GatewayW5100.ino.hex:
                              avrdude: input file C:\Users\Tony\AppData\Local\Temp\build12bf64d7a85151b4ee71a15dfecff5f5.tmp/GatewayW5100.ino.hex contains 26964 bytes
                              avrdude: reading on-chip flash data:
                              
                              Reading | ################################################## | 100% 5.58s
                              
                              avrdude: verifying ...
                              avrdude: 26964 bytes of flash verified
                              
                              avrdude done.  Thank you.
                              
                              tekkaT 1 Reply Last reply
                              0
                              • kk02067K kk02067

                                @tekka Don't know. Cheap chinese clone of arduino nano

                                How do I check?
                                This is what the arduino IDE spits out when uploading to the nano:

                                avrdude: Version 6.0.1, compiled on Apr 15 2015 at 19:59:58
                                         Copyright (c) 2000-2005 Brian Dean, http://www.bdmicro.com/
                                         Copyright (c) 2007-2009 Joerg Wunsch
                                
                                         System wide configuration file is "C:\Program Files (x86)\Arduino\hardware\tools\avr/etc/avrdude.conf"
                                
                                         Using Port                    : COM6
                                         Using Programmer              : arduino
                                         Overriding Baud Rate          : 57600
                                         AVR Part                      : ATmega328P
                                         Chip Erase delay              : 9000 us
                                         PAGEL                         : PD7
                                         BS2                           : PC2
                                         RESET disposition             : dedicated
                                         RETRY pulse                   : SCK
                                         serial program mode           : yes
                                         parallel program mode         : yes
                                         Timeout                       : 200
                                         StabDelay                     : 100
                                         CmdexeDelay                   : 25
                                         SyncLoops                     : 32
                                         ByteDelay                     : 0
                                         PollIndex                     : 3
                                         PollValue                     : 0x53
                                         Memory Detail                 :
                                
                                                                  Block Poll               Page                       Polled
                                           Memory Type Mode Delay Size  Indx Paged  Size   Size #Pages MinW  MaxW   ReadBack
                                           ----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
                                           eeprom        65    20     4    0 no       1024    4      0  3600  3600 0xff 0xff
                                           flash         65     6   128    0 yes     32768  128    256  4500  4500 0xff 0xff
                                           lfuse          0     0     0    0 no          1    0      0  4500  4500 0x00 0x00
                                           hfuse          0     0     0    0 no          1    0      0  4500  4500 0x00 0x00
                                           efuse          0     0     0    0 no          1    0      0  4500  4500 0x00 0x00
                                           lock           0     0     0    0 no          1    0      0  4500  4500 0x00 0x00
                                           calibration    0     0     0    0 no          1    0      0     0     0 0x00 0x00
                                           signature      0     0     0    0 no          3    0      0     0     0 0x00 0x00
                                
                                         Programmer Type : Arduino
                                         Description     : Arduino
                                         Hardware Version: 2
                                         Firmware Version: 1.16
                                         Vtarget         : 0.0 V
                                         Varef           : 0.0 V
                                         Oscillator      : Off
                                         SCK period      : 0.1 us
                                
                                avrdude: AVR device initialized and ready to accept instructions
                                
                                Reading | ################################################## | 100% 0.00s
                                
                                avrdude: Device signature = 0x1e950f
                                avrdude: reading input file "C:\Users\Tony\AppData\Local\Temp\build12bf64d7a85151b4ee71a15dfecff5f5.tmp/GatewayW5100.ino.hex"
                                avrdude: writing flash (26964 bytes):
                                
                                Writing | ################################################## | 100% 7.51s
                                
                                avrdude: 26964 bytes of flash written
                                avrdude: verifying flash memory against C:\Users\Tony\AppData\Local\Temp\build12bf64d7a85151b4ee71a15dfecff5f5.tmp/GatewayW5100.ino.hex:
                                avrdude: load data flash data from input file C:\Users\Tony\AppData\Local\Temp\build12bf64d7a85151b4ee71a15dfecff5f5.tmp/GatewayW5100.ino.hex:
                                avrdude: input file C:\Users\Tony\AppData\Local\Temp\build12bf64d7a85151b4ee71a15dfecff5f5.tmp/GatewayW5100.ino.hex contains 26964 bytes
                                avrdude: reading on-chip flash data:
                                
                                Reading | ################################################## | 100% 5.58s
                                
                                avrdude: verifying ...
                                avrdude: 26964 bytes of flash verified
                                
                                avrdude done.  Thank you.
                                
                                tekkaT Offline
                                tekkaT Offline
                                tekka
                                Admin
                                wrote on last edited by
                                #43

                                @kk02067 The reason why I'm asking is that you got MCUSR=2 using the reset button - optiboot clears MCUSR:

                                https://github.com/Optiboot/optiboot/blob/master/optiboot/bootloaders/optiboot/optiboot.c#L479

                                kk02067K 1 Reply Last reply
                                0
                                • tekkaT tekka

                                  @kk02067 The reason why I'm asking is that you got MCUSR=2 using the reset button - optiboot clears MCUSR:

                                  https://github.com/Optiboot/optiboot/blob/master/optiboot/bootloaders/optiboot/optiboot.c#L479

                                  kk02067K Offline
                                  kk02067K Offline
                                  kk02067
                                  wrote on last edited by
                                  #44

                                  @tekka I found a sketch that identify the bootloader when googleing a bit. It reports bootloader as:

                                  CRC 2048b @ 0x7800 = 489C
                                  Boot loader: Duemilanove

                                  tekkaT 1 Reply Last reply
                                  0
                                  • kk02067K kk02067

                                    @tekka I found a sketch that identify the bootloader when googleing a bit. It reports bootloader as:

                                    CRC 2048b @ 0x7800 = 489C
                                    Boot loader: Duemilanove

                                    tekkaT Offline
                                    tekkaT Offline
                                    tekka
                                    Admin
                                    wrote on last edited by tekka
                                    #45

                                    @kk02067 Ok, I rebuilt your setup and could reproduce the rebooting issue. The problem seems AVR board defs > 1.6.11 related, try downgrading to 1.6.11 and comment MY_DEBUG - this is how it works for me:

                                    UIPEthernet 1.09
                                    AVR Board defs 1.6.11
                                    Arduino IDE 1.6.11
                                    MySensors 2.0.0

                                    kk02067K 1 Reply Last reply
                                    1
                                    • tekkaT tekka

                                      @kk02067 Ok, I rebuilt your setup and could reproduce the rebooting issue. The problem seems AVR board defs > 1.6.11 related, try downgrading to 1.6.11 and comment MY_DEBUG - this is how it works for me:

                                      UIPEthernet 1.09
                                      AVR Board defs 1.6.11
                                      Arduino IDE 1.6.11
                                      MySensors 2.0.0

                                      kk02067K Offline
                                      kk02067K Offline
                                      kk02067
                                      wrote on last edited by
                                      #46

                                      @tekka Updated arduino to latest version 1.6.11 and downgraded to boarddefs 1.6.11 and now it seems fixed, at least with softspi for the radio.
                                      I have to try it with hwspi some other day. Have to stop for today.

                                      The version of arduino 1.6.9 would not let me downgrade to boarddefs 1.6.11, thats why it did not work when I tryed it before.

                                      Thanks for all your help.

                                      tekkaT 1 Reply Last reply
                                      2
                                      • kk02067K kk02067

                                        @tekka Updated arduino to latest version 1.6.11 and downgraded to boarddefs 1.6.11 and now it seems fixed, at least with softspi for the radio.
                                        I have to try it with hwspi some other day. Have to stop for today.

                                        The version of arduino 1.6.9 would not let me downgrade to boarddefs 1.6.11, thats why it did not work when I tryed it before.

                                        Thanks for all your help.

                                        tekkaT Offline
                                        tekkaT Offline
                                        tekka
                                        Admin
                                        wrote on last edited by
                                        #47

                                        @kk02067 Perfect! ;)

                                        1 Reply Last reply
                                        1
                                        • cadetC Offline
                                          cadetC Offline
                                          cadet
                                          wrote on last edited by
                                          #48

                                          Please provide wiring for this hardware.

                                          UNO + enc28-shield + NRF24

                                          Andrey

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


                                          21

                                          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