Flash memory

Wei zen Liu
Sep 7, 2018 · 2 min read

Introduce ROM / PROM / EPROM / EEPROM
EEPROM:

  • NOR type: byte-addressed
  • NAND type: block device

Levels of Cells
SLC: 1 bit/cell; low error rates and good endurance (≈104–105 P/E cycles).
MLC: ≈ 103–104 P/E cycles.
TLC: ≈ 300–3000 P/E cycles.

Brownian motion is the random motion of particles suspended in a fluid (a liquid or a gas) resulting from their collision with the fast-moving molecules in the fluid.

High bits: 適合存取,不易更動

BER: Bit error rate

TSOP封裝成Chip

+----+   /   +----+   /   +-----+   /   +----+   /   +-----+   / bit
|Chip| < |Bank| < |Block| < |Page| < |Data | < - bit
+----+ \ +----+ \ +-----+ \ +----+ \ | Area| \ bit
\ +-----+ / bit
|Spare| < - bit
+-----+ \ bit

real page > 4KB

Write-once Property

  • Relaxed: Each page can be sequentially written for at most 4 times. (Can not turn back to write skipped bits)
  • Strict: Each page can be written for only once.

Bulk Erase Property: clean whole block (erase is slower than write)

Worn-out effect: breakdown of the oxide layer. Bits in a NAND flash block be erased over and over, it eventually breaks down the oxide layer -> causing bad cell/bit

System Architecture

+-----------------------------------------+
| Operating System |
| +---------------------------------+ |
| | File System (FAT, NTFS...) | |
| +---------------------------------+ |
| |
| +----------------------------------+ |
| | NAND Flash Translation Layer | |
| | +---------+ +------+ +--------+ | |
| | |Allocator| | Wear | | Garbage| | |
| | +---------+ +------+ +--------+ | |
| +-----------------^----------------+ |
+---------------------|-------------------+
|
|
v
+------------------------------------------+
| NAND Flash Memory |
+------------------------------------------+

Out-place update
Eraser is slower than write.
Insert updated data and turn original data invalid
garbage collector will free invalid pages.

Block 0                              Block 0
+------+ +------+
| A | --- A |
| B | | | B |
| C | | | C |
| D | ===Updata page A===> | | D |
| E | | | E |
| free | ˋ---> A' |
| Free | | free |
| free | | free |
+------+
Block 0 Block 1
+------+ +------+
| A | | A' |
| B | | B |
| C | | C |
| D | ===Live page coping===> | D | ==> Clean block 0
| E | | E |
| A' | | F |
| F | | G |
| G | | free |
+------+ +------+

北科理組文青蘿莉控’s 筆記空間

Data Engineering and Storage Lab, NTUT EE && QA, BOSCH

Wei zen Liu

Written by

Front-end developer / Mobile application developer, Study in NTUT. Skills: Html / SCSS / Javascript(es6) / gulp.js / Vue.js / Git / bash / linux / C / C++ /

北科理組文青蘿莉控’s 筆記空間

Data Engineering and Storage Lab, NTUT EE && QA, BOSCH

Welcome to a place where words matter. On Medium, smart voices and original ideas take center stage - with no ads in sight. Watch
Follow all the topics you care about, and we’ll deliver the best stories for you to your homepage and inbox. Explore
Get unlimited access to the best stories on Medium — and support writers while you’re at it. Just $5/month. Upgrade