Arduino Forum

Using Arduino => Audio => Topic started by: Aadarsh on Jul 28, 2015, 04:40 pm

Title: WAV player using ATmega8A
Post by: Aadarsh on Jul 28, 2015, 04:40 pm
Hi

I have a arduino which uses ATmega8 as it's core microcontroller.I also found that ATmega8 have only limited memory ie.8Kbytes out of which 7.1Kbytes are usable for flashing memory.When I attempt to read SD card,after my compilation I found that the program memory is exceeding the limit of ATmega8. Now I like to make a SD card WAV player,but I am unable to do so :(

I also found this website http://elm-chan.org/fsw/ff/00index_e.html
In what way this website will help me?How can I reduce the code size compatible for ATmega8?

I also have another doubt about PWM. What is the difference in using DAC 8 digital pins output and the PWM. Can I able to play 44100Hz sampled audio in ATmega8 or atleast 16KHz sound using either of the methods?
Title: Re: WAV player using ATmega8A
Post by: Grumpy_Mike on Jul 31, 2015, 11:12 pm
Quote
I also found this website http://elm-chan.org/fsw/ff/00index_e.html
In what way this website will help me?
None that I can see.

Quote
How can I reduce the code size compatible for ATmega8?
I don't see how you can.

Quote
What is the difference in using DAC 8 digital pins output and the PWM
One produces poor quality where as the PWM produces crap quality.

Quote
Can I able to play 44100Hz sampled audio in ATmega8 or at least 16KHz sound using either of the methods?
Well 44100Hz no. As to 16KHz possibly both but your problem is reading in the data.

It is possible you could store it into external EEPROM on the I2C bus but it would be far cheaper getting an ATmega 328 chip.
Title: Re: WAV player using ATmega8A
Post by: Aadarsh on Aug 01, 2015, 09:00 pm
Hi Grumpy_Mike

Thanks for your reply.I want to play a song from SD card,I cant use EEPROM's since it have less memory capacity(compared to 10 MB song).Now I planned to buy a STM32F1xx series of 32 bit MCU .I hope,I don't have problem with program memory since it have 128Kbytes of Flash memory :)

I heard that STM32 doesn't requires any JTAG for uploading bootloader since it have builtin bootloader. I can connect it directly to the USB port and I'll program it.

Now a question arises.Can I able to convert the arduino program to .hex format?Is it possible ,how can I perform it?

Title: Re: WAV player using ATmega8A
Post by: Grumpy_Mike on Aug 01, 2015, 11:37 pm
Quote
I heard that STM32 doesn't requires any JTAG for uploading bootloader since it have builtin bootloader.
No Arduino requires JTAG.

Quote
Can I able to convert the arduino program to .hex format?
I am not sure you understand what you are saying. True .hex is a file format but that is all it is, the contents are not specified. When you compile source code you can store the resultant machine code in a .hex file, but this is different code depending on the target processor.

Quote
Now I planned to buy a STM32F1xx series of 32 bit MCU
What Arduino is this? If it is not supported by the Arduino IDE then you won't be able to use it.
Title: Re: WAV player using ATmega8A
Post by: Aadarsh on Aug 02, 2015, 07:54 am
Hi Grumpy_Mike

Actually I planned to make my own development board using STM32F. I don't think so that it will be an Arduino.By your reply,I understood that the board which I going to develop is not Arduino,so I cant use Arduino IDE.

I also understood that MCU by different manufacturer's will have different instruction codes and one MCU language will differ to the other MCU language. :)

Thanks for you replies.