SD memory cards, especially the ones under 1GB are cheap, relatively easy to interface and provide vast amounts of memory for imbedded control.
This device lets you 'talk' to SD cards through your serial port. Communication is in ASCII so you just need a terminal program to access it.
SD sockets are available from SparkFun Electronics. The socket needs to be surface mounted so it was placed on the foil side of the single sided board (mouseover image above to see). The connections are close to 0.1 inch centers, so the layout was not difficult.
The PIC16F819 was chosen for its hardware support for SPI. (SD cards will usually work through an SPI interface) Running at 20Mhz, the SPI port clocks data at 5Mhz, and the serial communication is able to run at 115200 baud in software.
A quick look at the schematic shows one way to interface the 5 volt PIC to the 3.3 volt SD card. A red LED drops the 5 volt supply by about 1.8 volts to feed about 3.2 volts into the card. This is within the operating range.
Signals from the PIC go through a 1k/2k voltage divider to feed signals to the card. Signals back from the card feeding SDI input are a problem because the PIC uses schmit-trigger inputs in SPI mode requiring 3.5 volts for the high level. The circuit provides a 0.6 volt shift so the output of the card back to the PIC ranges from 0.6 to 3.8 volts. Cheesy, but it works.
This device lets you 'talk' to SD cards through your serial port. Communication is in ASCII so you just need a terminal program to access it.
The PIC16F819 was chosen for its hardware support for SPI. (SD cards will usually work through an SPI interface) Running at 20Mhz, the SPI port clocks data at 5Mhz, and the serial communication is able to run at 115200 baud in software.
A quick look at the schematic shows one way to interface the 5 volt PIC to the 3.3 volt SD card. A red LED drops the 5 volt supply by about 1.8 volts to feed about 3.2 volts into the card. This is within the operating range.
Signals from the PIC go through a 1k/2k voltage divider to feed signals to the card. Signals back from the card feeding SDI input are a problem because the PIC uses schmit-trigger inputs in SPI mode requiring 3.5 volts for the high level. The circuit provides a 0.6 volt shift so the output of the card back to the PIC ranges from 0.6 to 3.8 volts. Cheesy, but it works.
nice:)
ReplyDeleteI'm not sure exactly why but this blog is loading very slow for me. Is anyone else having this issue or is it a issue on my end? I'll сheck back
ReplyDeletelateг on and sеe if the problem
stіll exists.
Feel free to surf my homepage : hdd media player