cancel
Showing results for 
Search instead for 
Did you mean: 

SDcard used like FIFO its possible ?

Marco1
Associate II
Posted on March 08, 2017 at 12:11

Hi,

i have a little project working on stm32f415, with a task producer and a task consumer, between i want put a SdCard ( with fat ) like cache, because if something going wrong during trasmission or consumer is busy for some reason, i not lost the data.

Add all data at the end of file is not a problem, but it's possible take packet from start address and shift all the data in easy way ?

I can't read entire file because can be also some megabyte of space.

So i think i need to use a file on Sdcard like FIFO.

Sorry for my english

2 REPLIES 2
Posted on March 08, 2017 at 14:06

You won't be able to 'move' the data in any efficient way.

You could construct a FIFO using a file by managing two file pointers, and pulling in 8K or 32K blocks at a time.

You could also spool data into multi files to send later, ie store and forward.

Tips, Buy me a coffee, or three.. PayPal Venmo
Up vote any posts that you find helpful, it shows what's working..
Posted on March 08, 2017 at 17:18

Ok, 

thank you !!