I2S not working as expected? #3231
Replies: 2 comments 3 replies
-
|
The I2S coming from the chip runs fine. I suggest starting with unmodified https://github.com/earlephilhower/arduino-pico/blob/master/libraries/I2S/examples/SimpleTone/SimpleTone.ino and hooking up your logic analyzer to GP20, 21, and 22 and verifying you get the square-wave tone I2S data. Note that GP20 is not pin 20 on the PCB, in general, so make sure you use the right PCB pin for those IOs. Once that's verified, you can move on to the hookup of your DACs. Some are PITAs like the PCM5102 modules I got from AX which need a very precise setup (and some shorting of on-board jumpers) to actually speak I2S and send analog out. After you get that running look at BackgroundAudio or ESP8266Audio for more complex I2S stuff. |
Beta Was this translation helpful? Give feedback.
-
Beta Was this translation helpful? Give feedback.


Uh oh!
There was an error while loading. Please reload this page.
-
It might be that I've done something wrong here but I've tried the demos (to keep it simple and pain free) from the I2S examples on the library on several different 2040s (all Pi Foundation) and not a single one of them seems to produce any actual audio data.
What works:
Bit Clock: Check (following the sample rates exactly as they should)
Word/Frame Clock: Check (ditto)
Master Clock: (to my surprise) Check and ditto
What doesn't:
Audio Data: Not a dickie-bird. I've checked every single pin on the header on several different boards and the same thing happens. Signals from bit, frame and master (controller) all appear as they should. Everything else either appears as a steady state or ground as the IOs aren't being using.
Outputs are probed with an oscilloscope and I need to make sure this works before I order some physical hardware from our friends in Asia - the entire PCB is already laid out for a Pico 2040 (official) but I followed the pinning in the sketches to make sure everything was OK. Am I missing something? While I'm not "new" to I2S I am new to the Pico and perhaps it needs something to trigger data IO, although that doesn't seem to likely with demos like the square wave.
I could use an STM32 but they are less convenient, and generally run at lower clock speeds and I wanted a solution that was easy for people to assemble hence the Pico seems the obvious choice, esp. when it comes to clock speeds above a couple of MHz as signal integrity becomes a very serious issue even over comparatively short jumps.
The other thing with the 2040 (or 2350) is that it's low-cost part and I can easily mount two or more on the PCB for the final iteration.
Beta Was this translation helpful? Give feedback.
All reactions