Chief Delphi

Chief Delphi (http://www.chiefdelphi.com/forums/index.php)
-   Programming (http://www.chiefdelphi.com/forums/forumdisplay.php?f=51)
-   -   CRio Flash Memory (http://www.chiefdelphi.com/forums/showthread.php?t=124358)

adlasa 09-01-2014 10:14

CRio Flash Memory
 
In the WPI tutorial for vision tracking there is a warning about excessive rights to the CRio flash memory in the image tracking program.

It is in regard to writing images to the CRio memory from a camera within a While Loop
Quote:

Warning: It is strongly recommended to comment out the while loop before enabling the image writes in order to preserve the cRIO flash memory. Writing the images within the while loop may result in excessive wear to the cRIO flash memory.
Is this something to be concerned about? I have a hard time believing FIRST would right their code in a dangerous way by default given that a lot of teams may be inclined to just copy and paste.

Tom Line 09-01-2014 10:17

Re: CRio Flash Memory
 
All non-volatile flash memory has a limited number of writes before it fails. They are cautioning you that constantly using that feature, say on your robot code, can add hundreds of thousands of writes depending on how often you are writing and overwriting the pictures.

It's a bit of overkill: we're still using our first 8-slot cRIO on a regular basis and have not suffered a memory failure. However, it's sound advice. If you're not going to be using those images there's no need to keep writing them to the disk.

E Dawg 09-01-2014 10:28

Re: CRio Flash Memory
 
Using it is okay, just be careful. It shouldn't permanently damage your cRIO, but it can definitely eat up flash memory (and slow down your connection).

Joe Ross 09-01-2014 14:05

Re: CRio Flash Memory
 
Quote:

Originally Posted by adlasa (Post 1324394)
It is in regard to writing images to the CRio memory from a camera within a While Loop


Is this something to be concerned about? I have a hard time believing FIRST would right their code in a dangerous way by default given that a lot of teams may be inclined to just copy and paste.

Yes it is something to be concerned about. However, FIRST did not enable the image writing by default. You must uncomment the image write. They give the appropriate warning if you do uncomment the image write.


Quote:

Originally Posted by E Dawg (Post 1324404)
Using it is okay, just be careful. It shouldn't permanently damage your cRIO, but it can definitely eat up flash memory (and slow down your connection).

This is incorrect. You can permanently damage the flash memory in the cRIO. Like Tom and the Tutorial said, do not write more often then needed.

From the cRIO-FRC II datasheet

Quote:

For information about the life span of the nonvolatile memory and about best practices for using nonvolatile memory, go to ni.com/info
and enter the Info Code SSDBP.
This leads to Understanding and Extending the Life of my Solid-State Drive, which states the following

Quote:

However, solid-state drives have a limited number of write/erase cycles. This disadvantage is the primary focus of this white paper. The physical cells of SSDs wear out over time.
In practice, with the wear leveling that the cRIO performs, I would guess that each team could get at least 1 million 8k writes. Given that an image is likely larger then 8k, if you wrote an image every 20ms, the cRIO flash memory could fail in around 100 hours. But, it's easy to avoid that. Even reducing that rate to once a second makes it so that a team would never run into an issue.

virtuald 09-01-2014 16:32

Re: CRio Flash Memory
 
Interestingly enough, the 2014 version of WPILib/C++ writes a file to flash memory every time that the cRio boots.

Mark McLeod 09-01-2014 18:24

Re: CRio Flash Memory
 
Quote:

Originally Posted by virtuald (Post 1324614)
Interestingly enough, the 2014 version of WPILib/C++ writes a file to flash memory every time that the cRio boots.

Better not boot the robot more than a million times.:)


All times are GMT -5. The time now is 03:06.

Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi