Re: Formatting the memory card
- From: Paul J Gans <gans@xxxxxxxxx>
- Date: Tue, 21 Feb 2006 04:04:16 +0000 (UTC)
bjw@xxxxxxxxxxxxxxxxx wrote:
Paul J Gans wrote:
But the real reason is the following. A flash memory card
has only a certain number of read/write cycles that can
be performed on it. The number is fairly large so what I'm
going to say makes little difference.
A flash card can be read with no problems, but to erase it
takes more time and power. The manufacturers fix it so that
an entire block (perhaps 256 bytes or more) is erased at once
since erasing a file byte by byte is very slow.
So for each file you delete manually, the card suffers several
erase cycles in the parts of the card that were used.
In most file systems, when you delete a file, you don't actually
overwrite the blocks of the disk or card that contain the file data.
The OS just changes or removes the file's directory entry so
that it is no longer visible. The data still sits there until those
blocks are overwritten by some new file. This is how various
"undelete" utilities are able to recover files.
This is true of the FAT16 and FAT32 filesystems that are usually
used for memory cards. When you delete a file, the OS changes
the directory entry for that file to have a special character in the
name. It doesn't overwrite the data. Assuming that flash memory
works the same way (I think it would have to, as the OS doesn't
know whether it's writing to a flash card or a removable disk, etc)
deleting a file costs hardly any erase cycles.
That's not how flash memory works. One can't write 0's to
a flash card. [This depends on the actual circuitry. In
some one can write a 0 but not a 1]. To be able to write
one needs to reset an entire block to all zeros. Then one
can write 1's where needed.
You are right that the OS does not know what type of memory
is in use. But the card knows. It contains the circuitry
needed to read and write the flash memory.
The lifetime of a flash card in read/write cycles is generally much
longer than its time-to-obsolesence anyway, given the current trends
in flash card prices.
This is true. Which is why I noted that it wasn't too
important.
---- Paul J. Gans
.
- Follow-Ups:
- Re: Formatting the memory card
- From: bjw
- Re: Formatting the memory card
- References:
- Formatting the memory card
- From: Toomanyputters
- Re: Formatting the memory card
- From: tnom
- Re: Formatting the memory card
- From: ASAAR
- Re: Formatting the memory card
- From: tnom
- Re: Formatting the memory card
- From: Randall Ainsworth
- Re: Formatting the memory card
- From: Don Dunlap
- Re: Formatting the memory card
- From: JC Dill
- Re: Formatting the memory card
- From: Paul J Gans
- Re: Formatting the memory card
- From: bjw
- Formatting the memory card
- Prev by Date: Re: Polarisation filters. Fit and forget?
- Next by Date: Re: Formatting the memory card
- Previous by thread: Re: Formatting the memory card
- Next by thread: Re: Formatting the memory card
- Index(es):
Relevant Pages
|