Paul......
Sorry I have been away from base all day and missed all the activity relating to this...............
But back now and downloaded your fix, copied in as Audio library and tested with the sine wav KiloHz1.wav etc....
Yes they all play perfectly for me. Yes I know there is a "roughness sound" at the end of KiloHz3.wav due to the multiple fadeouts. I only put these fadeouts in so I could see easier what bits of the tail end of the file was getting distorted before the fix.....or indeed was it playing to the end.
KiloHz1.wav is stereo, has 2 ms fadein at start and 2 ms fadeout at end. KiloHz2.wav is just simply a copy of it, to see if there was an error would it be reproduced in both files. KiloHz3.wav is stereo with 2 ms fadein at start, then at end 8 ms fadeout followed by 6 ms fadeout followed by 4 ms fadeout at very end. There is no period of silence at start or end of any of the files. As far as I can see from recording the teensy DAC output using Audacity the waveforms of the original test files are reproduced by the teensy DAC output OK. I haven't tested the audio adaptor connected up to it yet.......
There is one problem I do see in the recorded output..............In the test sketch in the Zip in post #89 above, I changed the delays to 400 ms so as to stop playing the current file at end of the delay, before coming to end of file, and then send another playWav1.play(filename) to start playing the next file as quickly as possible. Most of the transitions between the last file playing and the next starting are completely tight with no gaps.....But I get repeated groups of 3 sucessive gaps together at 5.6 seconds intervals. The gaps are 3 ms wide (or maybe its 2.9 ms = 1 buffer??).......so for instance...all tones play for 400 ms.......say I get a gap at 2.0, 2.4 and 2.8 seconds.....then no gaps until 7.6 seconds (2 + 5.6), then gaps at 7.6, 8.0, and 8.4.....then no gaps until 13.2 and 3 successive gaps here as well between the files played. Apart from a gap it's not causing much problem but my question is why is it happening for some and at repeated intervals.....Paul are you getting this with your tests..??.
Thanks for your help..............
Sorry I have been away from base all day and missed all the activity relating to this...............
But back now and downloaded your fix, copied in as Audio library and tested with the sine wav KiloHz1.wav etc....
Yes they all play perfectly for me. Yes I know there is a "roughness sound" at the end of KiloHz3.wav due to the multiple fadeouts. I only put these fadeouts in so I could see easier what bits of the tail end of the file was getting distorted before the fix.....or indeed was it playing to the end.
KiloHz1.wav is stereo, has 2 ms fadein at start and 2 ms fadeout at end. KiloHz2.wav is just simply a copy of it, to see if there was an error would it be reproduced in both files. KiloHz3.wav is stereo with 2 ms fadein at start, then at end 8 ms fadeout followed by 6 ms fadeout followed by 4 ms fadeout at very end. There is no period of silence at start or end of any of the files. As far as I can see from recording the teensy DAC output using Audacity the waveforms of the original test files are reproduced by the teensy DAC output OK. I haven't tested the audio adaptor connected up to it yet.......
There is one problem I do see in the recorded output..............In the test sketch in the Zip in post #89 above, I changed the delays to 400 ms so as to stop playing the current file at end of the delay, before coming to end of file, and then send another playWav1.play(filename) to start playing the next file as quickly as possible. Most of the transitions between the last file playing and the next starting are completely tight with no gaps.....But I get repeated groups of 3 sucessive gaps together at 5.6 seconds intervals. The gaps are 3 ms wide (or maybe its 2.9 ms = 1 buffer??).......so for instance...all tones play for 400 ms.......say I get a gap at 2.0, 2.4 and 2.8 seconds.....then no gaps until 7.6 seconds (2 + 5.6), then gaps at 7.6, 8.0, and 8.4.....then no gaps until 13.2 and 3 successive gaps here as well between the files played. Apart from a gap it's not causing much problem but my question is why is it happening for some and at repeated intervals.....Paul are you getting this with your tests..??.
Thanks for your help..............