Problem with flashing ESP32-CAM-MB using esphome-flasher(alternatives needed)

Using ESPHome add-on in HA created devices based on such config:

esphome:
  name: camera2

esp32:
  board: esp32cam
  framework:
    type: arduino

# Enable logging
logger:

# Enable Home Assistant API
api:

ota:
  password: "******************"

wifi:
  ssid: "*********"
  password: "***************"

  # Enable fallback hotspot (captive portal) in case wifi connection fails
  ap:
    ssid: "Camera2 Fallback Hotspot"
    password: "*******************"

captive_portal:

# Example configuration entry
esp32_camera:
  name: camera2
  external_clock:
    pin: GPIO0
    frequency: 20MHz
  i2c_pins:
    sda: GPIO26
    scl: GPIO27
  data_pins: [GPIO5, GPIO18, GPIO19, GPIO21, GPIO36, GPIO39, GPIO34, GPIO35]
  vsync_pin: GPIO25
  href_pin: GPIO23
  pixel_clock_pin: GPIO22
  power_down_pin: GPIO32

As a result, I have got camera.bin.
Next I am trying to flash it using esphome-flasher but as a result got next:

Using 'COM3' as serial port.
Connecting......................................
Unexpected error: ESP Chip Auto-Detection failed: Failed to connect to Espressif device: No serial data received.
For troubleshooting steps visit: https://github.com/espressif/esptool#troubleshooting

Is there another way to flash binary files? For example, using Arduino-IDE and existing binary file?

The four ways are presented to you when you click on upload.

But you may need to press one of the buttons on the esp32.

I often have issues with the first flash on ESP’s

What I used to do: use platformIO the first time
What I recently discovered: esphome-flasher

1 Like

It is exactly what I am using and facing the problem mentioned above…

Thx, and yes there is one interesting for me: “Plug into this computer” but unfortunately, I cannot configure https.

And thx for this, yes there is button on MB board… but it also makes no difference yet.

Do you have a nabu casa (home assistant cloud) subscription. If so, that will be ssl.

If an USB flash doesn’t work, you might consider having a faulty ESP. Never happened to me…

You might try platformio as a last resort, but I’m pretty sure it uses the same method as esphome-flasher

PS Regarding buttons, keep in mind you have to press the boot button until the connection is established.

2 Likes

This is good point. Will try later later replace esp32-mb with Arduino like it is showed in whtis article: Program ESP32-CAM using Arduino UNO - Electronics Projects .
ps: Also tried to replace USB cable, contacts sometimes are also faulty but not in my case this time :slight_smile:

The cable is a point of failure. Some are charge only, you need a data one.

1 Like

Hello,

i m facing the same issue…need to reflash physicaly, not OTA and the flashing process doesnt work…

The Solution is simple : as you flash with a FTDI-usb, GPIO 0 need to be grounded before plugin the usb and obviously the power. Its the same way with the ESP32-Cam-MB : you need:

1-No usb cord plug on the USB port of the PC : Press continuously IO0 buton.
2-Plug the usb cord into your USB port of PC or RPI or NUC…ect
3-select port, install the file .bin, thats it.
You can release after the erase sequence as start on ESPhome-flasher. Same on Esphome web.

Enjoy

2 Likes

I have same issue. I have 4 of those boards, and all of them are unable to flash.
I have even one, which is still working. So I can see the log. But unable to flash it. Wan to try IDE, if that helps.
Will try change programmer later. Any thoughts?

So, even another programmer does not work. Weirdly enough, only the ESP32-Cam-MB with CH340 can read the log / serial monitor. I see all the stats, but can not flash it. IO0 high, low, new ESP32-cam, old ESP32-cam, CH340, cp2102, it is just doesn’t care.
Am I the only one?

What works for me is to unplug the device from USB, press the RST and IO0 buttons, plug the device in, let the buttons go, then flash.

2 Likes

So, I found the issue.
It was the driver for CP2102. When I updated it, it starts to communicate. I still have no luck with CH340C, but I don’t need it as CP2102 works.

that’s why it is so good working with linux, the serial drivers are built in. Very frustrating that windows doesn’t.

No. Major issue aswell

@Pulcik fixed his problem by installing windows drivers. Have you tried that?

On a Mac not a good plan I think.

I have a serious phantom. I did one without an issue. The second one fails continuously. And no clue…

No, but posting logs etc would be.

Yep, this does it for me as well. brilliant solution. Works as a charme! Both for Arduino and ESPHome. Thanks !!