Home/Support/Support Forum/Variables in Flash -- RCM3200/3700
New and improved user forum site going live on 12/6 (All users will need to reset their password when the new forum is active)
Welcome to Digi Forum, where you can ask questions and receive answers from other members of the community.

Variables in Flash -- RCM3200/3700

0 votes
I am using a RCM3200 or 3700 to monitor a device via Ethernet. Recently I added the capability to change the static IP from a web form. The IP Address is stored in a global variable so it will retain its value after a reset. Everything works great up to this point. The problem is retaining the value after a complete power loss.

I have tried creating a file and using fwrite() and fread(). There are no errors reported, but it does not seem to work. After going through the documentation I can not determine if fwrite() is writing to flash or SRAM.

Is there any way to write a variable to a permanent area in flash, so that it can be read after a complete power loss?

If not then I assume I will be stuck modifying my boards to support external battery backup?

Any help is appreciate. Thanks!
Jon Barrett
asked May 29, 2007 in Rabbit by Leodox New to the Community (2 points)

Please log in or register to answer this question.

3 Answers

0 votes
Leodox;474 wrote:
Is there any way to write a variable to a permanent area in flash, so that it can be read after a complete power loss?

I have answered my own question. Further reading on these forums lead me to the UserBlock. The UserBlock sample programs were exactly what I needed.

writeUserBlock() and readUserBlock() worked perfectly.

I recommend to anyone that is working with the flash or UserBlock to run the UserBlock sample programs. They provide a great deal of information concerning what your Rabbit hardware supports.

Jon
answered May 30, 2007 by Leodox New to the Community (2 points)
0 votes
Hi,
Please help me regarding writing data to Flash at Runtime.We are also facing same problem what you have faced regarding writing IP address in to Flash.
Please let me know the detail procedure and functions to write Flash at Run time.
Thanks for your valuable support.Plz help me as it is very urgent!

Thanks & Regards
s.sathyamurthy
answered Jun 30, 2007 by sathyamurthy New to the Community (2 points)
0 votes
Hi,
Please help me regarding writing data to Flash at Runtime.We are also facing same problem what you have faced regarding writing IP address in to Flash.
Please let me know the detail procedure and functions to write Flash at Run time.We have used rabbit4000 processor and 512K flash.
Thanks for your valuable support.Plz help me as it is very urgent!

Thanks & Regards
s.sathyamurthy
answered Jun 30, 2007 by sathyamurthy New to the Community (2 points)
...