Skip to content
  • 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. ClearEprom does not work for Sensebender GW
  • Getting Started
  • Controller
  • Build
  • Hardware
  • Download/API
  • Forum
  • Store

ClearEprom does not work for Sensebender GW

Scheduled Pinned Locked Moved Troubleshooting
12 Posts 5 Posters 2.2k Views 5 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.
  • Nca78N Offline
    Nca78N Offline
    Nca78
    Hardware Contributor
    wrote on last edited by
    #3

    @tbowmo is any special action needed to clear EEPROM on Sensebender gateway ?

    1 Reply Last reply
    0
    • tbowmoT Offline
      tbowmoT Offline
      tbowmo
      Admin
      wrote on last edited by
      #4

      @tomkxy @Nca78

      the ClearEEPROM sketch does use the hw abstraction layer, so it should work with the sensebender gateway. We did have some timing issues at one point in time, if I remember right. But I think we solved it.

      Which version of arduino are you using? And which version of the Arduino SAMD and MySensors SAMD board packages are you using?

      1 Reply Last reply
      0
      • T Offline
        T Offline
        tomkxy
        wrote on last edited by
        #5

        The changed the sketch as follows:

        #define MY_CORE_ONLY
        
        #include <MySensors.h>
        
        void setup()
        {
        
        	unsigned long enter = hwMillis();
          while (hwMillis() - enter < (unsigned long)15000);
        
        	Serial.begin(MY_BAUD_RATE);
        
          Serial.print("EEPROM_LOCAL_CONFIG_ADDRESS: ");
          Serial.println(EEPROM_LOCAL_CONFIG_ADDRESS);
        	Serial.println("Started clearing. Please wait...");
        	for (int i=0; i<EEPROM_LOCAL_CONFIG_ADDRESS; i++) {
        		hwWriteConfig(i,0xFF);
        	}
        	Serial.println("Clearing done. You're ready to go!");
        }
        
        void loop()
        {
        	// Nothing to do here...
        }
        

        The output is:

        EEPROM_LOCAL_CONFIG_ADDRESS: 413
        Started clearing. Please wait...

        I use the following versions:
        My Arduino version is: 1.8.5
        MySensors Board Version: 1.0.5
        Arduino SAMD Board Version: 1.6.11 (M3), 1.6.17 (M0+)

        Interesting observation which might be hinting at a fundamental problem:
        I need to double the baud rate in the serial monitor. So in order to get any output I need to set the baud rate to 230400

        1 Reply Last reply
        1
        • NiklasON Offline
          NiklasON Offline
          NiklasO
          wrote on last edited by NiklasO
          #6

          I have the same problem:

          void setup()
          Serial.begin(MY_BAUD_RATE);
           while(!Serial);
            Serial.print("EEPROM_LOCAL_CONFIG_ADDRESS: ");
            Serial.println(EEPROM_LOCAL_CONFIG_ADDRESS);
          	Serial.println("Started clearing. Please wait...");
          	for (uint16_t i=0; i<EEPROM_LOCAL_CONFIG_ADDRESS; i++) {
              Serial.println("Clearing");
          		hwWriteConfig(i,0xFF);
          	}
          	Serial.println("Clearing done.");
          }
          

          Output:

          EEPROM_LOCAL_CONFIG_ADDRESS: 413
          Started clearing. Please wait...
          Clearing
          

          Edit:
          Changed to

          //#define MY_CORE_ONLY
          #define MY_RADIO_NRF24
          

          and added the code to before() and it works?

          1 Reply Last reply
          1
          • tbowmoT Offline
            tbowmoT Offline
            tbowmo
            Admin
            wrote on last edited by
            #7

            @NiklasO @tomkxy

            Could any of you open an issue on github? Then we can track it with the project (and include it in an upcoming core group hackaton in February)

            alexsh1A 1 Reply Last reply
            0
            • tbowmoT tbowmo

              @NiklasO @tomkxy

              Could any of you open an issue on github? Then we can track it with the project (and include it in an upcoming core group hackaton in February)

              alexsh1A Offline
              alexsh1A Offline
              alexsh1
              wrote on last edited by
              #8

              @tbowmo Any luck on fixing it please?

              1 Reply Last reply
              0
              • tbowmoT Offline
                tbowmoT Offline
                tbowmo
                Admin
                wrote on last edited by
                #9

                @alexsh1

                I thought that we had it solved, during our last collaboration code-sprint-evening a couple of months ago. But now I see that the bug was re-opened..

                I'll see if I can have a look later this week, when I'm in the lab.. (But I am terrible at remembering stuff at the moment... :( )

                alexsh1A 2 Replies Last reply
                0
                • tbowmoT tbowmo

                  @alexsh1

                  I thought that we had it solved, during our last collaboration code-sprint-evening a couple of months ago. But now I see that the bug was re-opened..

                  I'll see if I can have a look later this week, when I'm in the lab.. (But I am terrible at remembering stuff at the moment... :( )

                  alexsh1A Offline
                  alexsh1A Offline
                  alexsh1
                  wrote on last edited by
                  #10

                  @tbowmo I'll give you heads-up :-)
                  Thanks for sorting it out!

                  1 Reply Last reply
                  0
                  • tbowmoT tbowmo

                    @alexsh1

                    I thought that we had it solved, during our last collaboration code-sprint-evening a couple of months ago. But now I see that the bug was re-opened..

                    I'll see if I can have a look later this week, when I'm in the lab.. (But I am terrible at remembering stuff at the moment... :( )

                    alexsh1A Offline
                    alexsh1A Offline
                    alexsh1
                    wrote on last edited by
                    #11

                    @tbowmo Any luck please?

                    1 Reply Last reply
                    0
                    • tbowmoT Offline
                      tbowmoT Offline
                      tbowmo
                      Admin
                      wrote on last edited by
                      #12

                      @alexsh1

                      Sorry, didn't have access to my hardware lab, so got thrown off by other projects.

                      The upcoming weekend will probably go with looking at old nasty php code, fixing issues in a 7 year old project I made for a former employer..

                      / Thomas

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


                      8

                      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
                      • OpenHardware.io
                      • Categories
                      • Recent
                      • Tags
                      • Popular