Friday, October 4, 2013

Cheap and easy SD WAVE player

First of all, I would like to mention that I go to school, so I'm not always posting on my blog.

Second of all, I would like to mention that this project is from elm-chan.org
I don't claim it as mine, I am simply copying the project. I wanted to mention this so that people will know that doing this: http://www.expertcore.org/viewtopic.php?t=1210

They are the exact same project, done by two different people. If you look at the code from Magneto (expertcore) the only time he mentioned elm-chan was in the main.c

/*---------------------------------------------------------------*/
/* 8-pin SD audio player R0.03                     (C)ChaN, 2010 */
/*---------------------------------------------------------------*/

The original code had all of this:

/*----------------------------------------------------------------------------/
/  8-pin SD audio player R0.05d                    (C)ChaN, 2011              /
/-----------------------------------------------------------------------------/
/ This project, program codes and circuit diagrams, is opened under license
/ policy of following trems.
/
/  Copyright (C) 2010, ChaN, all right reserved.
/
/ * This project is a free software and there is NO WARRANTY.
/ * No restriction on use. You can use, modify and redistribute it for
/   personal, non-profit or commercial use UNDER YOUR RESPONSIBILITY.
/ * Redistributions of source code must retain the above copyright notice.
/
/----------------------------------------------------------------------------*/

I have to say Magneto did the right thing, including the copyright, however I was hoping to see (in expertcore) the original link to the project. Not only did he not mention elm-chan he copied the page word for word (with a little paraphrasing).

now that my mini-rant is over...

I want to tell you about this project. Ever since I got started in microcontrollers I thought that I would be using PIC. Well, because of the Arduino, Atmel got to me first. 
When I was looking for PIC projects then, I always wanted to make an MP3 player, or something that could hold at least 2GB of music and that I could use, you know, like an iPod shuffle.

So a week ago I found this project.
It basically uses PWM pins to simulate AC current (pretty amazing to me). Of course, with arduino you can play midi files from a PWM pin, but playing legitimate music (after converting them from MP3 to WAV) with 
  • $2 attiny85
  • $1 circuit board
  • $0.50 parts
  • $0 some old thrown out battery
  • $5 SD
which is <$10, is pretty awesome.

One might expect that PWM will generate a lot of distortion. TRUE.
If you listen to this WAV player with earbuds you will be somewhat disappointed. You will hear static and the music will be too loud.

However, if you have a somewhat decent audio system, you will be amazed by the quality...

Most audio setups have low pass filters built into them and all that, so the garbage from the WAV player gets removed!
Of course you could have a built in LPF and a volume control potentiometer, but I was a bit lazy this time.

Some pictures:


Dynex converter from BestBuy ~ $5


Solder on some headers to the pins after you take it apart


Now you know why?


Soldered some pins onto the SD so that I can use it on a breadboard and other projects.


Cut grooves into PCB like a stamp. That way I can just slide in this header


Components...


Soldered together, plugged into USBTinyISP


Wire all the programming pins to where the SD socket is supposed to be (as they are connected to the chip).


Packaged nicely.



Charging is simple too!



Here's a link to elm-chan's files... I added my own folder for the PCB, schematics, and other important reference items that were not included in the original package.

No comments:

Post a Comment