How to caculate the needed capacity of the SD flash memory card

AI Thread Summary
To calculate the needed capacity of an SD flash memory card for data logging, multiply the number of bytes output per second by the desired recording duration in seconds. Alternatively, use the formula of bytes per sample times samples per second times the recording time. Consider that flash memory is organized by sectors, requiring full sector reads and writes, which can impact performance and endurance due to limited erase cycles. Implementing a Flash File System (FFS) can help manage memory but may require additional capacity for journaling. Addressability issues with SD cards are generally manageable, as most microcontrollers, including the msp430F2274, can fully address any card available.
mz8e08
Messages
3
Reaction score
0
Hi, I going to interface a microcontroller with SD flash memory card for data log. How to caculate the needed memory capacity?

Thanks
 
Engineering news on Phys.org
The number of bytes your datalogger will put output per second times the number of seconds you want to record. Alternately, the number of bytes per sample times the number of samples per second times the number of seconds of desired recording time.
 
mz8e08 said:
Hi, I going to interface a microcontroller with SD flash memory card for data log. How to caculate the needed memory capacity?

Thanks

Beyond negitron's answer, there are a bunch of things you need to look into before deciding. Flash memory is organized by sectors, where to write a byte in a sector, you need to first read the whole sector into your local RAM, erase the whole flash sector, change the byte in your local RAM copy, and then write the whole sector back to the flash.

Since the flash memory has a limited endurance (how many times it can be erased and re-written), and since you may accidentally get reset or lose power during the flash write process, you will generally use (or write) a "Flash File System" to manage the whole flash memory process. Using a FFS increases the required size of the flash memory, since multiple copies of things are kept at different times (a concept called "journaling").


This wikipedia article gives a pretty good description:

http://en.wikipedia.org/wiki/Flash_memory

.
 
Hi berkeman,
I've planned to choose a SD card, and thought the bigger capacity the better. But, will it happen that some of the memory addresses can not be accessed? I chosed the msp430F2274 microcontroller.
 
Last edited:
Oh, that's an entirely different question than what it appeared you were asking about. There are a number of ways to tackle addressability issues but in this case, it's particularly simple, since the SD card uses a serial interface:

http://www.interfacebus.com/Secure_Digital_Card_Pinout.html

Any uC should be able to fully address any card on the market.
 
Hi all I have some confusion about piezoelectrical sensors combination. If i have three acoustic piezoelectrical sensors (with same receive sensitivity in dB ref V/1uPa) placed at specific distance, these sensors receive acoustic signal from a sound source placed at far field distance (Plane Wave) and from broadside. I receive output of these sensors through individual preamplifiers, add them through hardware like summer circuit adder or in software after digitization and in this way got an...
I have recently moved into a new (rather ancient) house and had a few trips of my Residual Current breaker. I dug out my old Socket tester which tell me the three pins are correct. But then the Red warning light tells me my socket(s) fail the loop test. I never had this before but my last house had an overhead supply with no Earth from the company. The tester said "get this checked" and the man said the (high but not ridiculous) earth resistance was acceptable. I stuck a new copper earth...
Thread 'Beauty of old electrical and measuring things, etc.'
Even as a kid, I saw beauty in old devices. That made me want to understand how they worked. I had lots of old things that I keep and now reviving. Old things need to work to see the beauty. Here's what I've done so far. Two views of the gadgets shelves and my small work space: Here's a close up look at the meters, gauges and other measuring things: This is what I think of as surface-mount electrical components and wiring. The components are very old and shows how...
Back
Top