
Originally Posted by
MichaelMeissner
Note, the original post is about the Teensy 3.2 and the audio shield SD card.
Hi Michael,
I had not notice that!
So.. thank you for your detailed analysis: at the moment I would remain on Teensy 3.6, or maybe switch to T4.0 in a next release; and for all the topics you point out I have no answers... I can only try to modify my code and see what happend using the SD card on my Teensy 3.6.... Even if it seems that I've reached a good point with the 32MB chip: with this cabling
Attachment 18351
(really not so nice to see!!) my device is working good: not any clicks or other problems after 1 hr of sound tests. This seems to confirm that in the previous arrangement there were electric problems.
About switching my code from flash memory to SD, I unfortunately don't understand how play_SD_raw works... So this change will take long time. Don't even know what help to ask, because my library is too long and I don't want to annoy anyone. In a nutshell, I started with some trivial Ctrl-C / Ctrl-V from play_SD_raw, replacing this code:
Code:
rawfile = SerialFlash.open(filename);
AudioStartUsingSPI();
if(!rawfile)
AudioStopUsingSPI();
with this:
Code:
#if defined(HAS_KINETIS_SDHC)
if (!(SIM_SCGC3 & SIM_SCGC3_SDHC))
AudioStartUsingSPI();
#else
Serial.println("failed!");
AudioStartUsingSPI();
#endif
__disable_irq();
rawfile = SD.open(filename);
__enable_irq();
if (!rawfile)
{
//Serial.println("unable to open file");
#if defined(HAS_KINETIS_SDHC)
if (!(SIM_SCGC3 & SIM_SCGC3_SDHC))
AudioStopUsingSPI();
#else
AudioStopUsingSPI();
#endif
return false;
}
Is it a good start-point?