Do You Know How Wear-Leveling Extends Flash Lifetime?

Posted by: Harte Onewein

Embedded devices are used for many different purposes, in many different industries, and the expectations for lifetime range vastly between them. Small consumer products, such as wrist-mounted fitness monitors have lifetimes of only a few years as new versions will take their place shortly, whereas embedded devices in cars and energy meters may be expected to last upwards of 30 years. NAND flash wears out over time and will eventually fail. How can you extend the life of your NAND-based devices?

Flash has only a finite number of times it can be written to and erased. As a block approaches its maximum write/erase limit, the likelihood of an uncorrectable read error increases. This can happen faster when some blocks are written and erased far more than others on the media. Remedying this problem means spreading the use of blocks across the media in a uniform fashion instead of using the same blocks over and over. This can be done with wear-leveling.

Wear-leveling can be handled in the flash media driver or the firmware for managed NAND flash. Some flash file systems offer this functionality built in but the effectiveness leaves much to be desired. Many device manufacturers have found that adding a Flash Translation Layer (FTL), like Datalight’s FlashFX Tera, provides effective wear-leveling that can extend the life of their flash.

Let’s explore how wear-leveling works. We will assume a device has a memory endurance of 1,000 cycles, of which it uses 1 per day, and includes 1 spare erase block.

(1,000 cycles ÷ 365 days) * 1 spare erase block = 2.74 years to cycle this erase sector 1,000 times

If you set aside another erase block and only erase the first block after the second set of data is recorded, the result is a simple wear-leveling scheme. Using the same equation above, but accounting for 2 erase blocks, you come up with flash lifetime of 5.48 years, double the initial calculation.

Read our updated whitepaper “Extending Product Lifespan Using Appropriate Wear-Leveling” to learn how to account for the important variables associated with wear-leveling techniques, and determine the expected lifetime of the flash in any application.

Download Whitepaper

Comments (0)

Add a Comment

Allowed tags: <b><i><br>Add a new comment: