Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

PIC 18F series and SD storage

Status
Not open for further replies.

deadeye_pramath

Newbie level 3
Joined
Sep 28, 2009
Messages
3
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,281
Location
India
Activity points
1,329
How to read data from MMC using PIC microcontroller ???

Hey everyone I'm making a mp3 player for my final year project.
I'm using a MMC card to store the mp3 songs and a PIC 18LF4550 or PIC 18LF2550 to read the mp3 data and to transfer it to the audio decoder for decoding.

Can anyone please tell me how to interface the MMC card with the MC using SPI ?
I would appreciate if anyone can post a C program source code.

Please it is very important and urgent for me.....
 

How to read data from MMC using PIC microcontroller ???

You can try Microchip's Libraries (MDD File System, included in Microchip Application Libraries). My friend have used this one and he can read/write/create/delete a .txt file or a directory in MMC card.
 

    V

    Points: 2
    Helpful Answer Positive Rating
Re: How to read data from MMC using PIC microcontroller ???

I don't want to deal with .txt files. I want to initialize the mmc card and to read 512bytes of data from it using the PIC microcontroller and store that data in the RAM of the microcontroller and then send 32bytes at a time to another slave on the SPI.

Please help me ?
 

How to read data from MMC using PIC microcontroller ???

take a look here...



this is the best site i came around...
RAF
 
Re: How to read data from MMC using PIC microcontroller ???

deadeye_pramath said:
I don't want to deal with .txt files. I want to initialize the mmc card and to read 512bytes of data from it using the PIC microcontroller and store that data in the RAM of the microcontroller and then send 32bytes at a time to another slave on the SPI.

Please help me ?

Oh, I wonder that why you don't use 25LC512 or 1024 to do this? It will be much more easier. In my opinion, MMC Cards is useful when we can access data stored like a computer.

Anyway, I think you have got a reason to do like that. Just my curiousity :)
 

Flash File System

Dear All,

Anybody ever tried to use a Flash File System in the SD Card? I read something about wear leveling. Some manufaturer (i.e) microchip, mikroelektronika, etc..they give a SD file library for the code, most of them are using FAT.

I read some article about wear leveling.

Do their FAT filesystem provide wear leveling by distributing the write read cycle?

And if anybody has ever tried using a specific flash file system (JFFS?) please help me :(

Kindest Regards,




FE
 

I have PIC experience but I am new to interfacing with external storage. I want to create a CSV file onto either a SD card or a USB mass storage device.

I would like to interface directly to an SD card without needing the module that microchip sells.

Does anyone have any resources or opinions? A google search didn't come up with any sample code.
 

I know, that at least Microchip and CCS have ready to use PIC18 SD card driver applications for their C compilers. I guess, others too.
 

rongo024 said:
http://www.dharmanitech.com/2009/01/sd-card-interfacing-with-atmega8-fat32.html

I am noticing that that link requires the use of a PC and hyperterminal. My hopes were to create a PIC ckt that would write to the SD card in a CSV format without any other PC.

Is there documentation for this?
 


FvM said:

"I would like to interface directly to an SD card without needing the module that microchip sells. "

I included this in the original post. This document entails the use of the PICtail™ Daughter Board for SD and MMC, Microchip product number AC164122
 

This document entails the use of the PICtail™ Daughter Board for SD and MMC, Microchip product number AC164122 .
If I understand right, you are complaining, that the Microchip library is useless for you, because the demonstration software has been
designed using a specific interface board?.

Do you need a library that supports SD cards in a black case exclusively, or are blue SD cards acceptable as well?

how about wear leveling? Is it included in microchip library?
According to manufacturer statements, it's generally handled by the SD card controller.
 

If I understand right, you are complaining, that the Microchip library is useless for you, because the demonstration software has been
designed using a specific interface board?.

I am interested in designing a circuit that interfaces directly with a SD card. Are you telling me that all the 40 dollar interface board with circuitry on it is a direct link from the PIC controller to the SD card? There is no other circuitry that I will need when connecting a SD card directly to my PIC?

I should add that the demonstration software is useless for me because I don't know what the interface board does.
 

The PICtail interface board does effectively nothing essential. I fear, the problem is, that you don't know how to "read"
the schematic or the code, otherwise you won't ask. A SD card is operating at 3.3V, if the µP also uses low voltage, no interface
is needed (except for a connector).
 

FvM said:
The PICtail interface board does effectively nothing essential. I fear, the problem is, that you don't know how to "read"
the schematic or the code, otherwise you won't ask. A SD card is operating at 3.3V, if the µP also uses low voltage, no interface
is needed (except for a connector).

Thanks. That's the starting point I need. I never claimed to be a software engineer but I am able to do a lot with a little guidance. I saw a picture of the interface we are referring to and saw surface mounted components and assumed they actually did something. I also looked again at this document:
https://ww1.microchip.com/downloads/en/AppNotes/01045b.pdf
And would still, after being told other wise, think that the interface was essential. I figured the document would have included a pinout of how to connect the controller to the SD card if the interface was not necessary. BTW, where would I find such a pinout?
 

I didn't review the application in detail. But basically, the SD card has to be connected to the hardware SPI interface: SCK, SDO,
SDI and a pin acting as CS signal. The PICtail has buffer ICs to interface the 3.3V card with a 5V operated processor. You either
need to operate the processor at 3.3V or add similar level converters.
 

FvM said:
I didn't review the application in detail. But basically, the SD card has to be connected to the hardware SPI interface: SCK, SDO,
SDI and a pin acting as CS signal. The PICtail has buffer ICs to interface the 3.3V card with a 5V operated processor. You either
need to operate the processor at 3.3V or add similar level converters.

I actually read some data on how to interface with a SD card from scratch. It mentioned the voltage requirements for the card. That makes a lot more sense now that you mention it. But I didn't think about how I would drop the voltage for the data lines.

How would you recommend I accomplish this? Would a resistive voltage divider on each line be sufficient? Or is there an IC that would accomplish more efficiently?
 

Status
Not open for further replies.

Similar threads

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top