Replies: 5 comments 28 replies
-
Similar problems here. I2S example from pico-core (generating 440Hz square) - OK tried with two max98357A and two breadboards, powering it from 15W source |
Beta Was this translation helpful? Give feedback.
-
I think I may have the same problem. To rule that (and the SD card) out, I tried to get the PlayWAVFromPPROGMEM example working, except with an i2s output instead of i2sNoDac. It was way too loud, so I added a mixer and set the gain to 0.1. There was a lot of cracking. How I tested that my Hardware works flawlessly: Maybe the Pico is just not fast enough for that stuff? P.S: This is my first time using the Pico or i2s. Sorry if I'm missing something. My code: #include <Arduino.h>
#include <AudioFileSourcePROGMEM.h>
#include <AudioGeneratorWAV.h>
#include <AudioOutputI2S.h>
#include <AudioOutputSerialWAV.h>
#include <AudioOutputMixer.h>
// VIOLA sample taken from https://ccrma.stanford.edu/~jos/pasp/Sound_Examples.html
#include <viola.h>
AudioGeneratorWAV *wav;
AudioFileSourcePROGMEM *file;
AudioOutputMixer *mixer;
AudioOutputMixerStub *stub;
AudioOutputI2S *i2s;
void setup()
{
Serial.begin(115200);
delay(1000);
Serial.printf("WAV start\n");
//audioLogger = &Serial;
file = new AudioFileSourcePROGMEM( viola, sizeof(viola) );
i2s = new AudioOutputI2S(8000);
wav = new AudioGeneratorWAV();
mixer = new AudioOutputMixer(16,i2s);
stub = mixer->NewInput();
stub->SetGain(0.1);
wav->begin(file, stub);
}
void loop()
{
if (wav->isRunning()) {
if (!wav->loop()) wav->stop();
} else {
Serial.printf("WAV done\n");
delay(1000);
}
} |
Beta Was this translation helpful? Give feedback.
-
Could it be that you experienced this bug in arduino-pico which caused clicking/cracks? It's fixed in the latest release. |
Beta Was this translation helpful? Give feedback.
-
Dear Folks, Please update to core 3.2.2. Yours, PJ. |
Beta Was this translation helpful? Give feedback.
-
I am currently transferring an older project (RFID TAG player (not only) for children) that I wrote for STM32duino. (STM32F103c**). There is a series of a good 20 devices that I had sold. Unfortunately, the base (STM32F103c** - "Bluepill") is no longer available (only fake chips) and the libraries of the original software are hopelessly outdated. In the meantime I've rewritten most of the software (different graphics drivers, now u8g2) and it's working again on a RP2040.
|
Beta Was this translation helpful? Give feedback.
-
Dear Folks,
ESP32 and ESP32 S3 are doing great playing the WAV and MP3 files using this library.
But RP2040 133Mhz is noisy? Seems that the MCU speed is not fast enough?
Then, run the RP2040 at 240Mhz, the sound is breaking up/pop? The SD is running at 40Mhz, reading around 4MB/s.
Are there something wrong with the PIO I2S?
Best,
PJ.
Beta Was this translation helpful? Give feedback.
All reactions