There has been several threads in the last weeks relating to problems experienced with playing WAV files using Teensy3.1 ans either audio shield or SD adaptor. Different issues arose with different users and basically I think all the issues have got mixed up and this makes them harder to untangle.
I am starting this thread for hopefully a specific problem I am experiencing, and I have had several threads running on it in the past and haven't got any solution yet.
The problem is when starting to play a wav file from SD using eg. wav.play("filename") if the file is stereo the file open for approx 3 ms and plays 3ms of sound then starts again and plays the start over again and then continues to play to the end of the file. I have tested this using the Audio shield outputs and also on the Teensy3.1 DAC port and it happens on both. My method of discovering this is to record the sound output using a PC and Audacity, then zoom in to see the waveform. I have tested it with pushbutton selecting play and also playing the files in a loop and it happens in both situations.
MONO files play perfectly.
There is also a problem as the play is coming to the end of the file for stereo files only. The last 1 or 2 ms are distorted. Again MONO files play perfectly.
I have been investigating this for a number of weeks now and even with the most basic setup, a teensy connected to a SD adaptor and output to DAC port and recorded on a PC it is possible to see this easily. I had been hoping that even though I may not be able to get a solution, that someone somewhere would be able to confirm that this happens with them, or that it doesn't happen with them. But to date I have been unable to get that confirmed. I have attached a zip file containing a most basic sketch, some sound files, jpeg files of a basic setup on a breadboard, jpegs of my recordings of the teensy output etc.
and I would be grateful if someone to try this out and either tell me I am doing something wrong or it happens with them.
I have been able to test this on 2 different Teensy3.1 and on 1 audio adaptor and it doesn't matter what combination it happens every time. I have more teensys and audio adaptors on order and will be able to test further then. I want to prove it with the most basic setup first and then try that audio adaptor after.
There is still a further problem I was finding with a project that has the audio adaptor, that was a glitch at 185 ms for stereo and 370 ms for mono files after the file starts to play, if there were more that 14 files on the SD. But that only happens with Audio adaptor connected not with the Teensy on its own so I don't want to mix the 2 problems here.
Hopefully I may get an outcome this time......Thanks..........
I am starting this thread for hopefully a specific problem I am experiencing, and I have had several threads running on it in the past and haven't got any solution yet.
The problem is when starting to play a wav file from SD using eg. wav.play("filename") if the file is stereo the file open for approx 3 ms and plays 3ms of sound then starts again and plays the start over again and then continues to play to the end of the file. I have tested this using the Audio shield outputs and also on the Teensy3.1 DAC port and it happens on both. My method of discovering this is to record the sound output using a PC and Audacity, then zoom in to see the waveform. I have tested it with pushbutton selecting play and also playing the files in a loop and it happens in both situations.
MONO files play perfectly.
There is also a problem as the play is coming to the end of the file for stereo files only. The last 1 or 2 ms are distorted. Again MONO files play perfectly.
I have been investigating this for a number of weeks now and even with the most basic setup, a teensy connected to a SD adaptor and output to DAC port and recorded on a PC it is possible to see this easily. I had been hoping that even though I may not be able to get a solution, that someone somewhere would be able to confirm that this happens with them, or that it doesn't happen with them. But to date I have been unable to get that confirmed. I have attached a zip file containing a most basic sketch, some sound files, jpeg files of a basic setup on a breadboard, jpegs of my recordings of the teensy output etc.
and I would be grateful if someone to try this out and either tell me I am doing something wrong or it happens with them.
I have been able to test this on 2 different Teensy3.1 and on 1 audio adaptor and it doesn't matter what combination it happens every time. I have more teensys and audio adaptors on order and will be able to test further then. I want to prove it with the most basic setup first and then try that audio adaptor after.
There is still a further problem I was finding with a project that has the audio adaptor, that was a glitch at 185 ms for stereo and 370 ms for mono files after the file starts to play, if there were more that 14 files on the SD. But that only happens with Audio adaptor connected not with the Teensy on its own so I don't want to mix the 2 problems here.
Hopefully I may get an outcome this time......Thanks..........