Skip to content

I2C probing via shell fails with a transfer error on ESP32_devkitc_wroom #92288

@manoj-aerlync

Description

@manoj-aerlync

Describe the bug

Tried probing the I2C bus by connecting a BME280 sensor to the ESP32_DevKitC_WROOM board using the I2C0 bus in the "minimal" sample application. I2C and shell-related configurations were enabled. While scanning the I2C bus using the i2c scan i2c@3ff53000 command in the shell, a transfer error with code -14 was reported.

Pin configurations of I2C0 :

&i2c0 {
        status = "okay";
        clock-frequency = <I2C_BITRATE_STANDARD>;
        sda-gpios = <&gpio0 21 GPIO_OPEN_DRAIN>;
        scl-gpios = <&gpio0 22 GPIO_OPEN_DRAIN>;
        pinctrl-0 = <&i2c0_default>;
        pinctrl-names = "default";
};

Regression

  • This is a regression.

Steps to reproduce

Enable the configs below in zephyr/samples/basic/minimal/prj.conf

CONFIG_LOG=y
CONFIG_SHELL=y
CONFIG_I2C=y
CONFIG_I2C_SHELL=y

Connect an i2c device to the esp32 (Used BME280)

Use the following build and flash commands

west build -b esp32_devkitc_wroom/esp32/procpu samples/basic/minimal/
west flash

After flashing, open the serial console and run the following command to scan for I2C devices:

i2c scan i2c@3ff53000

Relevant log output

uart:~$ i2c scan i2c@3ff53000
     0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f
00:             -- -- -- -- -- -- -- -- -- -- -- -- 
10: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
20: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
40: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
50: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
60: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
70: -- -- -- -- -- -- 76 --                         
1 devices found on i2c@3ff53000
[00:04:21.545,000] <err> i2c_esp32: I2C transfer error: -14
--- 67 messages dropped ---
[00:04:21.545,000] <err> i2c_esp32: I2C transfer error: -14
[00:04:21.546,000] <err> i2c_esp32: I2C transfer error: -14
[00:04:21.546,000] <err> i2c_esp32: I2C transfer error: -14
[00:04:21.546,000] <err> i2c_esp32: I2C transfer error: -14
[00:04:21.546,000] <err> i2c_esp32: I2C transfer error: -14
[00:04:21.547,000] <err> i2c_esp32: I2C transfer error: -14
[00:04:21.547,000] <err> i2c_esp32: I2C transfer error: -14
[00:04:21.547,000] <err> i2c_esp32: I2C transfer error: -14
[00:04:21.547,000] <err> i2c_esp32: I2C transfer error: -14
[00:04:21.548,000] <err> i2c_esp32: I2C transfer error: -14
[00:04:21.548,000] <err> i2c_esp32: I2C transfer error: -14
[00:04:21.548,000] <err> i2c_esp32: I2C transfer error: -14
[00:04:21.549,000] <err> i2c_esp32: I2C transfer error: -14
[00:04:21.549,000] <err> i2c_esp32: I2C transfer error: -14
[00:04:21.549,000] <err> i2c_esp32: I2C transfer error: -14
[00:04:21.550,000] <err> i2c_esp32: I2C transfer error: -14
[00:04:21.569,000] <err> i2c_esp32: I2C transfer error: -14
[00:04:21.569,000] <err> i2c_esp32: I2C transfer error: -14
[00:04:21.570,000] <err> i2c_esp32: I2C transfer error: -14
[00:04:21.570,000] <err> i2c_esp32: I2C transfer error: -14
[00:04:21.570,000] <err> i2c_esp32: I2C transfer error: -14
[00:04:21.571,000] <err> i2c_esp32: I2C transfer error: -14
[00:04:21.571,000] <err> i2c_esp32: I2C transfer error: -14
[00:04:21.571,000] <err> i2c_esp32: I2C transfer error: -14
[00:04:21.571,000] <err> i2c_esp32: I2C transfer error: -14
[00:04:21.572,000] <err> i2c_esp32: I2C transfer error: -14
[00:04:21.572,000] <err> i2c_esp32: I2C transfer error: -14
[00:04:21.573,000] <err> i2c_esp32: I2C transfer error: -14
[00:04:21.573,000] <err> i2c_esp32: I2C transfer error: -14
[00:04:21.573,000] <err> i2c_esp32: I2C transfer error: -14

Impact

Annoyance – Minor irritation; no significant impact on usability or functionality.

Environment

No response

Additional Context

No response

Metadata

Metadata

Assignees

Labels

area: I2CbugThe issue is a bug, or the PR is fixing a bugplatform: ESP32Espressif ESP32priority: lowLow impact/importance bug

Type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions