All GPIO pins can be i2c?

Aung Cho Oo
Posts: 8
Joined: Sun Apr 16, 2023 4:40 pm

All GPIO pins can be i2c?

Postby Aung Cho Oo » Fri Jun 09, 2023 7:45 pm

When I looking for the i2c peripheral pins in some esp32 modules, I couldn't find anything in espressif website. Turns out all the gpio pins can be used as i2c. Is that true? I'm going to design my custom board, and I don't want to change the pins later.

MicroController
Posts: 1136
Joined: Mon Oct 17, 2022 7:38 pm
Location: Europe, Germany

Re: All GPIO pins can be i2c?

Postby MicroController » Fri Jun 09, 2023 9:21 pm

Docs are here.

Section 7.1 of the TRM:
The ESP32-C6 chip features 31 GPIO pins. Each pin can be [...] connected to an internal peripheral signal. [...] peripheral input signals can be from any IO pins, and peripheral output signals can be routed to any IO pins.
You don't want to use any of the pins connecting to the FLASH memory though.

Aung Cho Oo
Posts: 8
Joined: Sun Apr 16, 2023 4:40 pm

Re: All GPIO pins can be i2c?

Postby Aung Cho Oo » Sat Jun 10, 2023 4:50 am

MicroController wrote:
Fri Jun 09, 2023 9:21 pm
Docs are here.

Section 7.1 of the TRM:
The ESP32-C6 chip features 31 GPIO pins. Each pin can be [...] connected to an internal peripheral signal. [...] peripheral input signals can be from any IO pins, and peripheral output signals can be routed to any IO pins.
You don't want to use any of the pins connecting to the FLASH memory though.
So, It's true. How about other peripherals? Can they configure to other gpios too?

ESP_Sprite
Posts: 8921
Joined: Thu Nov 26, 2015 4:08 am

Re: All GPIO pins can be i2c?

Postby ESP_Sprite » Sun Jun 11, 2023 2:51 am

For the C6, the ADC and the two USB pins are dedicated and not-routable. Aside from that, there's 8 pins that can be controlled by the LP CPU, you want to pay attention to that if you want to use that. Finally, if you want to push SPI to the maximum speed, you can benefit from using the dedicated IO pins for that rather than using random GPIOs.

Who is online

Users browsing this forum: Google [Bot], Vilius and 95 guests