Skip to content

Commit 8ab0cdd

Browse files
committed
feat(i2s): support i2s on esp32c61
1 parent 12398c0 commit 8ab0cdd

File tree

36 files changed

+1396
-69
lines changed

36 files changed

+1396
-69
lines changed
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
1-
| Supported Targets | ESP32 | ESP32-C3 | ESP32-C5 | ESP32-C6 | ESP32-H2 | ESP32-P4 | ESP32-S2 | ESP32-S3 |
2-
| ----------------- | ----- | -------- | -------- | -------- | -------- | -------- | -------- | -------- |
1+
| Supported Targets | ESP32 | ESP32-C3 | ESP32-C5 | ESP32-C6 | ESP32-C61 | ESP32-H2 | ESP32-P4 | ESP32-S2 | ESP32-S3 |
2+
| ----------------- | ----- | -------- | -------- | -------- | --------- | -------- | -------- | -------- | -------- |

components/driver/test_apps/i2s_test_apps/legacy_i2s_driver/pytest_legacy_i2s.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@
1212
@pytest.mark.esp32c6
1313
@pytest.mark.esp32h2
1414
@pytest.mark.esp32p4
15+
@pytest.mark.esp32c61
1516
@pytest.mark.generic
1617
@pytest.mark.parametrize(
1718
'config',

components/esp_driver_i2s/test_apps/.build-test-rules.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,10 @@ components/esp_driver_i2s/test_apps/i2s_multi_dev:
1111
disable:
1212
- if: SOC_I2S_SUPPORTED != 1
1313
- if: SOC_I2S_HW_VERSION_2 != 1
14+
disable_test:
15+
- if: IDF_TARGET in ["esp32c61"] # TODO: [ESP32C61] IDF-11442
16+
temporary: true
17+
reason: lack of runners
1418
depends_components:
1519
- esp_driver_i2s
1620

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
1-
| Supported Targets | ESP32 | ESP32-C3 | ESP32-C5 | ESP32-C6 | ESP32-H2 | ESP32-P4 | ESP32-S2 | ESP32-S3 |
2-
| ----------------- | ----- | -------- | -------- | -------- | -------- | -------- | -------- | -------- |
1+
| Supported Targets | ESP32 | ESP32-C3 | ESP32-C5 | ESP32-C6 | ESP32-C61 | ESP32-H2 | ESP32-P4 | ESP32-S2 | ESP32-S3 |
2+
| ----------------- | ----- | -------- | -------- | -------- | --------- | -------- | -------- | -------- | -------- |

components/esp_driver_i2s/test_apps/i2s/pytest_i2s.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@
1212
@pytest.mark.esp32s3
1313
@pytest.mark.esp32h2
1414
@pytest.mark.esp32p4
15+
@pytest.mark.esp32c61
1516
@pytest.mark.generic
1617
@pytest.mark.parametrize(
1718
'config',
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
1-
| Supported Targets | ESP32-C3 | ESP32-C5 | ESP32-C6 | ESP32-H2 | ESP32-P4 | ESP32-S3 |
2-
| ----------------- | -------- | -------- | -------- | -------- | -------- | -------- |
1+
| Supported Targets | ESP32-C3 | ESP32-C5 | ESP32-C6 | ESP32-C61 | ESP32-H2 | ESP32-P4 | ESP32-S3 |
2+
| ----------------- | -------- | -------- | -------- | --------- | -------- | -------- | -------- |
33

components/esp_hw_support/port/esp32c61/esp_clk_tree.c

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,9 @@ uint32_t *freq_value)
3333
case SOC_MOD_CLK_PLL_F80M:
3434
clk_src_freq = CLK_LL_PLL_80M_FREQ_MHZ * MHZ;
3535
break;
36+
case SOC_MOD_CLK_PLL_F120M:
37+
clk_src_freq = CLK_LL_PLL_120M_FREQ_MHZ * MHZ;
38+
break;
3639
case SOC_MOD_CLK_PLL_F160M:
3740
clk_src_freq = CLK_LL_PLL_160M_FREQ_MHZ * MHZ;
3841
break;

components/hal/esp32c3/include/hal/i2s_ll.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -366,7 +366,7 @@ static inline void i2s_ll_rx_set_bck_div_num(i2s_dev_t *hw, uint32_t val)
366366

367367
/**
368368
* @brief Configure I2S RX module clock divider
369-
* @note mclk on ESP32 is shared by both TX and RX channel
369+
* @note mclk on ESP32C3 is shared by both TX and RX channel
370370
*
371371
* @param hw Peripheral I2S hardware instance address.
372372
* @param mclk_div The mclk division coefficients

components/hal/esp32c5/include/hal/i2s_ll.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -398,7 +398,7 @@ static inline void i2s_ll_rx_set_bck_div_num(i2s_dev_t *hw, uint32_t val)
398398

399399
/**
400400
* @brief Configure I2S RX module clock divider
401-
* @note mclk on ESP32 is shared by both TX and RX channel
401+
* @note mclk on ESP32C5 is shared by both TX and RX channel
402402
*
403403
* @param hw Peripheral I2S hardware instance address.
404404
* @param mclk_div The mclk division coefficients
@@ -945,7 +945,7 @@ static inline uint32_t i2s_ll_tx_get_pdm_fs(i2s_dev_t *hw)
945945
*/
946946
static inline void i2s_ll_rx_enable_pdm(i2s_dev_t *hw, bool pdm_enable)
947947
{
948-
// Due to the lack of `PDM to PCM` module on ESP32-H2, PDM RX is not available
948+
// Due to the lack of `PDM to PCM` module on ESP32-C5, PDM RX is not available
949949
HAL_ASSERT(!pdm_enable);
950950
hw->rx_conf.rx_pdm_en = 0;
951951
hw->rx_conf.rx_tdm_en = 1;

components/hal/esp32c6/include/hal/i2s_ll.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -388,7 +388,7 @@ static inline void i2s_ll_rx_set_bck_div_num(i2s_dev_t *hw, uint32_t val)
388388

389389
/**
390390
* @brief Configure I2S RX module clock divider
391-
* @note mclk on ESP32 is shared by both TX and RX channel
391+
* @note mclk on ESP32C6 is shared by both TX and RX channel
392392
*
393393
* @param hw Peripheral I2S hardware instance address.
394394
* @param mclk_div The mclk division coefficients

0 commit comments

Comments
 (0)