ESP32-CAM Problem with not enough pins

zdyboo
Posts: 1
Joined: Thu Nov 14, 2019 9:24 pm

ESP32-CAM Problem with not enough pins

Postby zdyboo » Thu Nov 14, 2019 9:35 pm

Hi, i am using this module with active camera and sd-card reader and i need 2 pins to software i2c to connect modules.
I added lines in SD_MMC.cpp

Code: Select all

slot_config.width = 1
host.flags = SDMMC_HOST_FLAG_1BIT; 
I try to use many combination of pins for example 13,16; 13,12; and more...
Anything dont work. According to this thread : viewtopic.php?t=11703, i have free pins 13,12 and 4 but 4 - it is flash led, 12 - if is use it, esp32 cant boot, the same o 16 pin - all time reboot. What i have to do to change these pins to I2C?

wattexi
Posts: 5
Joined: Mon Nov 25, 2019 8:21 pm

Re: ESP32-CAM Problem with not enough pins

Postby wattexi » Mon Dec 02, 2019 7:23 pm

I have the same problem, I need 2 pins free ... did you succeed and if so how?

chegewara
Posts: 1183
Joined: Wed Jun 14, 2017 9:00 pm

Re: ESP32-CAM Problem with not enough pins

Postby chegewara » Tue Dec 03, 2019 5:34 am

https://github.com/espressif/esptool/wi ... -Selection

When you read this you can see that pin 12 cant be connected to VCC (in your case, from your issue description):
If driven High, flash voltage (VDD_SDIO) is 1.8V not default 3.3V. Has internal pull-down, so unconnected = Low = 3.3V. May prevent flashing and/or booting if 3.3V flash is used and this pin is pulled high, causing the flash to brownout. See the ESP32 datasheet for more details.
but I2C requires SDA and SCL to be pullup.
There is solution for this, but its not easy. When you burn efuse then esp32 wont read pin 12 on restart:
https://github.com/espressif/esptool/wi ... e-vdd_sdio

Of course you have to know what you are doing burning efuse because you may brick your device.

wattexi
Posts: 5
Joined: Mon Nov 25, 2019 8:21 pm

Re: ESP32-CAM Problem with not enough pins

Postby wattexi » Wed Dec 04, 2019 7:39 pm

thanks for your answer i'm looking at that

NoChill_Senpai
Posts: 1
Joined: Mon Feb 24, 2020 4:35 pm

Re: ESP32-CAM Problem with not enough pins

Postby NoChill_Senpai » Mon Feb 24, 2020 4:41 pm

Hi, If I want to use an I2C device with the CAM and the SD card, could I use the pin 0 that is used for the clock on the camera with the SDL pin for the I2C?

bobtidey
Posts: 38
Joined: Mon Jun 18, 2018 2:24 pm

Re: ESP32-CAM Problem with not enough pins

Postby bobtidey » Tue Feb 25, 2020 11:21 am

You can use the TXD and RXD pins as GPIO.

Obviously they are not operational during a flash upload operation which may mean swapping wires to do uploads but if you use OTA then that doesn't matter after the first flash.

Using RXD doesn't affect any serial debug print but using TXD will.

alanesq
Posts: 10
Joined: Thu Dec 14, 2017 8:38 pm

Re: ESP32-CAM Problem with not enough pins

Postby alanesq » Tue Feb 25, 2020 4:15 pm

You can use the sd card in "1 bit" mode which means you can then still control the onboard led (gpio4) when using an sd card?
gpio12 and 13 are then not used by the sd card

see: https://www.reddit.com/r/esp32/comments ... alk_to_an/

dwienie
Posts: 2
Joined: Sun Mar 15, 2020 4:12 pm

Re: ESP32-CAM Problem with not enough pins

Postby dwienie » Sun Mar 15, 2020 4:24 pm

bobtidey wrote:
Tue Feb 25, 2020 11:21 am
You can use the TXD and RXD pins as GPIO.

Obviously they are not operational during a flash upload operation which may mean swapping wires to do uploads but if you use OTA then that doesn't matter after the first flash.

Using RXD doesn't affect any serial debug print but using TXD will.
Where you able to use OTA with this device?

alanesq
Posts: 10
Joined: Thu Dec 14, 2017 8:38 pm

Re: ESP32-CAM Problem with not enough pins

Postby alanesq » Tue Mar 17, 2020 6:05 pm

[/quote]
Where you able to use OTA with this device?
[/quote]

Hi,
I have used OTA sucesfully with the esp32-cam but select the "ESP32-cam" board in the Arduino IDE, use "ESP32 Dev Module" and make sure PSRAM is enabled

Who is online

Users browsing this forum: No registered users and 11 guests