Arduino Plays Indian National Anthem

About the project

Arduino Indian Citizen.

Project info

Difficulty: Moderate

Platforms: ArduinoAtmel

Estimated time: 1 hour

License: GNU General Public License, version 3 or later (GPL3+)

Items used in this project

Hardware components

Transistor NPN (2N3904) Transistor NPN (2N3904) x 1
Speaker: 3W, 4 ohms Speaker: 3W, 4 ohms x 1
Micro SD Card Extender Micro SD Card Extender x 1
Genuino Uno Rev3 Genuino Uno Rev3 x 1

Story

Hi all,

I developed a Hardware prototype which is playing Indian National Anthem.

Components

First of all We need

  • Arduino Board Anyone
  • SD Card Module
  • Speaker 4ohm
  • BC547
  • 1k Resistor

Connect all hard wares as the circuit schematic.

You need one library to play your favorite song I found from this link.

This method only work for wav file. so you should convert your song with this settings

  • WAV file,
  • 8-bit,
  • 8-32khz Sample Rate,
  • mono.

https://github.com/TMRh20/TMRpcm/wiki#functions

Files easily converted:Using iTunes:

Click _> Edit > Preferences > Import Settings_Change the dropdown to _WAV Encoder_ and Setting: _Custom > 16.000kHz to 32kHz, 8-bit, Mono_Right click any file in iTunes, and select _"Create WAV Version"_

Using Audacity:

Tracks > Stereo Track to Mono    Project Rate (HZ) > set to 32000, 22050, 16000 or 11025    File > Export > Save as type: Other uncompressed files > Options...    Select WAV, Unsigned 8 bit PCM    

Then copy file to SD card using computer

This is the output

Schematics, diagrams and documents

Circuit

BC547 Fritzing Pinout E B C

Code

Code

Credits

Photo of nissiembeddedlab

nissiembeddedlab

I am Embedded Engineer, Arduino and Embedded C Programmer. Had PCB design knowledge with KiCad. I own a youtube channel and manging a facebook page. I own a Lab in my native place to do academic projects.

   

Leave your feedback...