mirror of
https://github.com/espressif/esp-idf.git
synced 2026-06-04 20:26:38 +03:00
Merge branch 'feature/support_i2c_on_h2' into 'master'
i2c: support i2c on esp32h2 Closes IDF-6233 and IDF-6689 See merge request espressif/esp-idf!21982
This commit is contained in:
@@ -52,13 +52,13 @@ examples/peripherals/i2s/i2s_basic/i2s_tdm:
|
||||
|
||||
examples/peripherals/i2s/i2s_codec/i2s_es7210_tdm:
|
||||
disable:
|
||||
- if: SOC_I2S_SUPPORTS_TDM != 1 or SOC_I2C_SUPPORTED != 1
|
||||
reason: rely on I2S TDM mode and I2C support
|
||||
- if: SOC_I2S_SUPPORTS_TDM != 1 or (SOC_I2C_SUPPORTED != 1 or SOC_GPSPI_SUPPORTED != 1)
|
||||
reason: rely on I2S TDM mode to receive audio, I2C to config es7210 and SPI to save audio to SD card
|
||||
|
||||
examples/peripherals/i2s/i2s_codec/i2s_es8311:
|
||||
disable:
|
||||
- if: SOC_I2S_SUPPORTED != 1 or SOC_I2C_SUPPORTED != 1
|
||||
reason: rely on I2S STD mode and I2C support
|
||||
reason: rely on I2S STD mode and I2C to config es7210
|
||||
|
||||
examples/peripherals/i2s/i2s_recorder:
|
||||
enable:
|
||||
@@ -66,7 +66,8 @@ examples/peripherals/i2s/i2s_recorder:
|
||||
|
||||
examples/peripherals/lcd/i2c_oled:
|
||||
disable:
|
||||
- if: SOC_I2C_SUPPORTED != 1
|
||||
- if: SOC_I2C_SUPPORTED != 1 or IDF_TARGET == "esp32h2"
|
||||
reason: LCD has not been supported on esp32h2, IDF-6213
|
||||
|
||||
examples/peripherals/lcd/i80_controller:
|
||||
disable:
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
| Supported Targets | ESP32 | ESP32-C3 | ESP32-C6 | ESP32-S2 | ESP32-S3 |
|
||||
| ----------------- | ----- | -------- | -------- | -------- | -------- |
|
||||
| Supported Targets | ESP32 | ESP32-C3 | ESP32-C6 | ESP32-H2 | ESP32-S2 | ESP32-S3 |
|
||||
| ----------------- | ----- | -------- | -------- | -------- | -------- | -------- |
|
||||
|
||||
# I2C Self-Test Example
|
||||
|
||||
|
||||
@@ -7,7 +7,7 @@ menu "Example Configuration"
|
||||
config I2C_MASTER_SCL
|
||||
int "SCL GPIO Num"
|
||||
range ENV_GPIO_RANGE_MIN ENV_GPIO_OUT_RANGE_MAX
|
||||
default 2 if IDF_TARGET_ESP32S3
|
||||
default 2 if IDF_TARGET_ESP32S3 || IDF_TARGET_ESP32H2
|
||||
default 19 if IDF_TARGET_ESP32 || IDF_TARGET_ESP32S2
|
||||
default 6
|
||||
help
|
||||
@@ -16,7 +16,7 @@ menu "Example Configuration"
|
||||
config I2C_MASTER_SDA
|
||||
int "SDA GPIO Num"
|
||||
range ENV_GPIO_RANGE_MIN ENV_GPIO_OUT_RANGE_MAX
|
||||
default 1 if IDF_TARGET_ESP32S3
|
||||
default 1 if IDF_TARGET_ESP32S3 || IDF_TARGET_ESP32H2
|
||||
default 18 if IDF_TARGET_ESP32 || IDF_TARGET_ESP32S2
|
||||
default 5
|
||||
help
|
||||
@@ -24,7 +24,7 @@ menu "Example Configuration"
|
||||
|
||||
config I2C_MASTER_PORT_NUM
|
||||
int "Port Number"
|
||||
default 1 if IDF_TARGET_ESP32 || IDF_TARGET_ESP32S2 || IDF_TARGET_ESP32S3
|
||||
default 1 if SOC_I2C_NUM > 1
|
||||
default 0
|
||||
help
|
||||
Port number for I2C Master device.
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
| Supported Targets | ESP32 | ESP32-C3 | ESP32-C6 | ESP32-S2 | ESP32-S3 |
|
||||
| ----------------- | ----- | -------- | -------- | -------- | -------- |
|
||||
| Supported Targets | ESP32 | ESP32-C3 | ESP32-C6 | ESP32-H2 | ESP32-S2 | ESP32-S3 |
|
||||
| ----------------- | ----- | -------- | -------- | -------- | -------- | -------- |
|
||||
|
||||
# I2C Simple Example
|
||||
|
||||
|
||||
@@ -6,7 +6,7 @@ menu "Example Configuration"
|
||||
int "SCL GPIO Num"
|
||||
range ENV_GPIO_RANGE_MIN ENV_GPIO_OUT_RANGE_MAX
|
||||
default 19 if IDF_TARGET_ESP32 || IDF_TARGET_ESP32S2 || IDF_TARGET_ESP32S3
|
||||
default 6
|
||||
default 2
|
||||
help
|
||||
GPIO number for I2C Master clock line.
|
||||
|
||||
@@ -14,7 +14,7 @@ menu "Example Configuration"
|
||||
int "SDA GPIO Num"
|
||||
range ENV_GPIO_RANGE_MIN ENV_GPIO_OUT_RANGE_MAX
|
||||
default 18 if IDF_TARGET_ESP32 || IDF_TARGET_ESP32S2 || IDF_TARGET_ESP32S3
|
||||
default 5
|
||||
default 1
|
||||
help
|
||||
GPIO number for I2C Master data line.
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
| Supported Targets | ESP32 | ESP32-C2 | ESP32-C3 | ESP32-C6 | ESP32-S2 | ESP32-S3 |
|
||||
| ----------------- | ----- | -------- | -------- | -------- | -------- | -------- |
|
||||
| Supported Targets | ESP32 | ESP32-C2 | ESP32-C3 | ESP32-C6 | ESP32-H2 | ESP32-S2 | ESP32-S3 |
|
||||
| ----------------- | ----- | -------- | -------- | -------- | -------- | -------- | -------- |
|
||||
|
||||
# I2C Tools Example
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* SPDX-FileCopyrightText: 2022 Espressif Systems (Shanghai) CO LTD
|
||||
* SPDX-FileCopyrightText: 2022-2023 Espressif Systems (Shanghai) CO LTD
|
||||
*
|
||||
* SPDX-License-Identifier: Unlicense OR CC0-1.0
|
||||
*/
|
||||
@@ -28,7 +28,7 @@
|
||||
|
||||
static const char *TAG = "cmd_i2ctools";
|
||||
|
||||
#if CONFIG_IDF_TARGET_ESP32S3
|
||||
#if CONFIG_IDF_TARGET_ESP32S3 || CONFIG_IDF_TARGET_ESP32H2
|
||||
static gpio_num_t i2c_gpio_sda = 1;
|
||||
static gpio_num_t i2c_gpio_scl = 2;
|
||||
#elif CONFIG_IDF_TARGET_ESP32C3 || CONFIG_IDF_TARGET_ESP32H4 || CONFIG_IDF_TARGET_ESP32C2
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
| Supported Targets | ESP32 | ESP32-C3 | ESP32-C6 | ESP32-S2 | ESP32-S3 |
|
||||
| ----------------- | ----- | -------- | -------- | -------- | -------- |
|
||||
| Supported Targets | ESP32 | ESP32-C3 | ESP32-C6 | ESP32-H2 | ESP32-S2 | ESP32-S3 |
|
||||
| ----------------- | ----- | -------- | -------- | -------- | -------- | -------- |
|
||||
|
||||
# I2S ES8311 Example
|
||||
|
||||
|
||||
Reference in New Issue
Block a user