I have the TinyUSB configured for 32bit 48KHz and I have made some changes to the PIO code because my BCK and LRCK pins arent adjascent(cant use side set 2).
Code:
frameL: ; || set pins, 0 side 0b0 set x, 30 side 0b1 pull noblock side 0b0 ; One clock after edge change with no datadataL: out pins, 1 side 0b1 jmp x-- dataL side 0b0Alternatively you could delays and run the SM at 4x BCK, so the 3 instruction starting with pull would look like "pull noblock side 0b1 [1]" and take 2 cycles instead of 1.
Regarding DMA, it's really not that complicated to setup once all the individual pieces are working. Start with just feeding the PIO with static, hardcoded data from a buffer in SRAM. There's some example code for that in the official repo: https://github.com/raspberrypi/pico-exa ... hannel_irq
Once that works you can switch to double buffering, with 2 buffers containing different data so it's audible. And then switch to the data from USB.
Statistics: Posted by Tharre — Sat Jun 14, 2025 12:03 am