Help with buffer

Hello everyone,

I am new to the Arduino and I'm trying to record audio data with the Arduino. I have managed to record data for a few seconds before the buffer becomes full. Therefore, the Arduino cannot record more than just a few seconds worth of data. I was wondering if any of you knew whether this might be a programming issue (i.e., that the program to transfer data from the buffer to the SD card is limiting the transfer rate) or whether this is more likely a hardware issue (whereby I would need a board with a higher processing power)?

Thank you for your help!

There is at least one issue with your code. That issue is that you have not posted it here.
Before you do post it please read the stickies at the top of this page which give advice on how to post the code and provide relevant information.

sveera13:
I was wondering if any of you knew whether this might be a programming issue (i.e., that the program to transfer data from the buffer to the SD card is limiting the transfer rate) or whether this is more likely a hardware issue (whereby I would need a board with a higher processing power)?

You don't say what data rate you're trying to achieve with your recording, but if you're trying to record human speech with enough quality to make it intelligible then that would fill your available SRAM in a fraction of a second. The write performance of the SD card is highly sensitive to how you buffer the data and with the wrong algorithm you could easily find it's too slow to keep up with the audio stream. If you use a suitable buffering technique you may be able to keep up with a low quality audio stream, but might find that you are unable to record audio samples while you are writing to the SD card. One option would be to off-load the recording process onto a second device. The hardware serial port is fast enough to support a decent quality audio stream and you could use a second Arduino to receive/store it, or use a PC based application for that.