Unable to Access Automatically Captured Images in Home Assistant

I am working on a project where my ESP32 CAM needs to automatically capture an image every 10 seconds. The goal is to send these captured images to an AI model for further processing. Manual image capture works fine.
I set up an automation to capture images every 10 seconds using the camera.snapshot service.
)
I see confirmation in the logs (under “Dogs”) that the images are being captured successfully every 10 seconds.
However,I cannot access these images.

I attempted to save the images to the /www folder within the File Editor in Home Assistant, but I cannot see the images in the folder or access them via the URL
esphome:
name: esp32-cam
platform: ESP32
board: esp32dev

Enable logging

logger:

Enable Home Assistant API

api:
reboot_timeout: 0s

ota:

  • platform: esphome

web_server:
port: 80

wifi:
ssid: !secret wifi_ssid
password: !secret wifi_password

Enable fallback hotspot (captive portal) in case wifi connection fails

ap:
ssid: “Esp32-Cam Fallback Hotspot”
password: “C3FOhAPFtouw”

captive_portal:

Example configuration entry

esp32_camera:
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

Image settings

name: My ESP32-CAM

Flashlight

output:

  • platform: gpio
    pin: GPIO4
    id: gpio_4

GPIO_4 is the flash light pin

light:

  • platform: binary
    output: gpio_4
    name: flashlight

interval:

  • interval: 10s
    then:
    • homeassistant.service:
      service: camera.snapshot
      data:
      entity_id: camera.my_esp32_cam
      filename: “/homeassistant/www/capture_{{ now().strftime(‘%Y%m%d%H%M%S’) }}.jpg”

Hi Zakaria

In trying to help classify your problem here, are the images being transferred to HA or not.
It is not clear to me if you can’t see them or if they are not there.

[quote=“Sir_Goodenough, post:2, topic:832171”]
In trying to help classify your problem here, are the images being transferred to HA or not.
It is not clear to me if you can’t see them or if they are not there
I cannot see the images and they are also not being saved to the folder lthough the logs show that the camera.snapshot service is triggered every 10 seconds and the image is supposed to be saved in the /www folder, the images do not appear there.
I checked the /homeassistant/www/


folder via the File Editor, but it remains empty, even though the automation seems to be working.

OK, then I don’t know the answer, but searching here should help.
The url you are putting into espHome is not correct.
Focus on that and getting the files to show up.

Treat the fact that you cannot read the files in HA as a separate problem.

Ok thank u so much