Atmega328p FatFS SDcard

Go To Last Post
4 posts / 0 new
Author
Message
#1
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Hy!

I am a bit stucked using SDcard. I read (i think) all the posts and tutorial in avrfreaks about this topic, and searched over the internet for this, but I still confused. 
I want to make a simple data logger with atmega328p. I receive some data from uart, and I want to save this data to an sd card in text (log.txt practically). With FatFS I know I just have to modify the diskio.c to get it work with my uc, but I cant.  Can somebody provide me a working project example to this atmega328p. The ffsample is too complex for me. 

 

Thanks in advance

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

I worked through this in a thread within the last month. Google may find it.

 

EDIT: Boy Google is good (unlike the search engine here). So the thread was:

 

https://www.avrfreaks.net/forum/f...

 

and the specific post I was thinking of was:

 

https://www.avrfreaks.net/comment...

 

Try that and see how you get on - if you have questions about it then it might be best to post them to that other thread so everything is kept together.

 

Note however that I was showing how to use SPI for SD/MMC (because the Sept 2016 ffsample only really provides UART-SPI as a possibility). In your case, using a 328 you can just use the UART-SPI stuff as it stands.

Last Edited: Thu. Oct 6, 2016 - 05:11 PM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Thanks. I found a topic here, maybe it will help me out, as well as your links too.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

yoman91 wrote:
maybe it will help me out,
I doubt it - your fundamental first step is knowing how to sort the wheat from the chaff in ffsample.zip.

 

I'd usually recommend this as the main thread about FatFs...

 

https://www.avrfreaks.net/forum/t...

 

but that's drifted out of date in recent times - hence my post in that other thread.