Page 1 of 1

Save custom settings to EEPROM

Posted: Tue Jun 13, 2017 11:23 am
by cengh
I would like to save and read back custom settings to the EEPROM of the Roboclaw 2x7A. The amount of data is very small. I want to save a 64-bit serial number, a 32-bit bitwise bank of flags and perhaps four more 32-bit values. Is there any way to do this?

I only need to set the settings occasionally, perhaps once per day at the most so it shouldn't wear out the EEPROM. I need to read them back on startup.

Re: Save custom settings to EEPROM

Posted: Wed Jun 14, 2017 9:52 am
by Basicmicro Support
Sorry. The Roboclaw does not allow user degined values to be saved to its internal EEPROM.

Re: Save custom settings to EEPROM

Posted: Wed Jun 14, 2017 10:49 am
by cengh
I see. What about commandeering a Roboclaw setting that isn't being used or doesn't apply to the particular board I have? Is that too dangerous?

Re: Save custom settings to EEPROM

Posted: Thu Jun 15, 2017 10:42 am
by Basicmicro Support
I would not recommend it.

Re: Save custom settings to EEPROM

Posted: Fri Sep 08, 2017 11:47 am
by robof
I believe the chip in the roboclaw supports user storage (512 bytes). What I'm not 100% sure on is whether this can only be written in bootloader mode.
If it's possible this can be written outside bootloader mode, is it possible this could be exposed to us? Or is it currently being used by roboclaw internally?

If it's not already being used and could be written in normal mode, I think it could be as simple as two functions, ReadUSR() and WriteUSR(). These would simply take/return a 512 byte array of the entire USR.

Re: Save custom settings to EEPROM

Posted: Mon Sep 11, 2017 11:27 am
by Basicmicro Support
There is no access to the eeprom by the user on the Roboclaw currently and is only a wish list item at the moment.

Re: Save custom settings to EEPROM

Posted: Thu Jun 28, 2018 8:10 am
by robof3
I saw in the latest firmware there is an update for writing to EEPROM. Is that related to this feature request or something entirely different?

When a new feature like that is added, how would we go about knowing (how to use) the change as the user manual appears to stay a few versions behind the firmware changes?

Re: Save custom settings to EEPROM

Posted: Fri Jun 29, 2018 8:58 am
by Basicmicro Support
The two new commands are 252(Read) and 253(Write).

Read Syntax: roboclaw address, 252, memory address(byte). Returns a word(word/2 bytes).

Write Syntax: roboclaw address, 253, memory address(byte), value(word/2 bytes).

There are 256 memory locations 2 bytes each for a total of 512bytes.

These commands have not been added to any of the libraries so for now you will have to implement them your self if you want to use them.

Re: Save custom settings to EEPROM

Posted: Mon Jul 16, 2018 5:58 am
by robof3
What is the write limit/count that we should limit to?

Re: Save custom settings to EEPROM

Posted: Mon Jul 16, 2018 9:00 am
by Basicmicro Support
100,000 cycles(at 85C) is the rated write cycles for each location. If you are running over 85C alot you will need to take that into account. The eeprom is rated for 30,000 cycles at 105C.