All blocks
Connectivity
I2S
Digital audio in and out: microphones, amplifiers, codecs
built, not flashedLoading the 3D view…
- BCLK
- WS
- DIN
- DOUT
Key facts
Two I2S interfaces (I2S0, I2S1) with separate transmit and receive units that run at the same time.
8, 16, 24 or 32-bit samples at 8 to 192 kHz, with a bit clock from 10 kHz up to 40 MHz.
Only I2S0 converts PDM microphones to PCM, and PCM to PDM.
Audio moves through a dedicated DMA, without the CPU copying each sample.
In our labs
8 labs use this block, across 1 tracks. Open a track to see them.
- done by you
- runs on the board
- built, not flashed
- planned
Key registers
I2S_RX_CONF_REGoffset 0x0020| Bits | Field | What it does |
|---|---|---|
| 20 | I2S_RX_PDM_EN | PDM receive mode. |
| 5 | I2S_RX_MONO | Mono mode. |
| 3 | I2S_RX_SLAVE_MOD | Take BCK and WS from outside (slave). |
| 2 | I2S_RX_START | Start receiving. |
| 0 | I2S_RX_RESET | Reset the receive unit. |
I2S_TX_CONF_REGoffset 0x0024| Bits | Field | What it does |
|---|---|---|
| 26:24 | I2S_TX_CHAN_MOD | Which channels carry data. |
| 5 | I2S_TX_MONO | Mono mode. |
| 2 | I2S_TX_START | Start sending. |
| 0 | I2S_TX_RESET | Reset the transmit unit. |
I2S_RX_CONF1_REGoffset 0x0028| Bits | Field | What it does |
|---|---|---|
| 17:13 | I2S_RX_BITS_MOD | Bits per sample minus 1: 15 for 16-bit. |
| 12:7 | I2S_RX_BCK_DIV_NUM | Bit-clock divider (never 1). |
I2S_RX_CLKM_CONF_REGoffset 0x0030| Bits | Field | What it does |
|---|---|---|
| 28:27 | I2S_RX_CLK_SEL | Clock source: 0 XTAL, 1 PLL_D2, 2 PLL_F160M, 3 MCLK input. |
| 26 | I2S_RX_CLK_ACTIVE | Receive clock on. |
| 7:0 | I2S_RX_CLKM_DIV_NUM | Whole part of the clock divider. |
Read the full sectionTechnical reference §28