Hello to everyone,
I search in the forum and webs but I have not found the solution. If there is any topic already open that I missed, I’m sorry and feel free to redirect it to it.
I’m creating my auto watering system and the circuit is divided in two parts. The first one is controlled by and ESP-32 that provides power to a relay and 4 buttons (that control the relay) and a second circuit that provides power to the water pumps.
The issue that I’m having (all the circuit is still on protoboard) is that if I turn off and back on the ESP-32 is not doing anything (seems to be stuck or “overcloking” and also doesn’t connect to the WiFi) but if I remove the 5V connection with the relay and put it back it start working.
I think that the issue is that at startup something happen that overclocks the ESP-32 and doesn’t allow it to fully complete the startup procedure and when I remove the 5V connection it allows it to do so.
Can anyone help me? Is there any option to delay the 5V output to provide power on startup (as this maybe and remove the issue)?
This is a picture of how I’m connecting all the cables (sorry for the quality):
This is the code that I’m currently using:
esphome:
name: esp-riego-comedor-test
friendly_name: ESP-Riego-Comedor-Test
esp32:
board: esp32dev
framework:
type: arduino
# Enable logging
logger:
# Enable Home Assistant API
api:
encryption:
key: "HsoB2OOD8OR2ZDd9PZT5NHQAlTapmPjleEN8OzV9/wY="
ota:
password: "092e0969db4149ed3b9d83d71295d481"
wifi:
ssid: !secret wifi_ssid
password: !secret wifi_password
# Enable fallback hotspot (captive portal) in case wifi connection fails
ap:
ssid: "ESP-Riego-Comedor-Test"
password: "XXXXXXXXXXX"
captive_portal:
web_server:
port: 80
sensor:
switch:
- platform: gpio
name: "Bomba Agua Coleo (Roja)"
id: relay_1
pin: GPIO13
restore_mode: RESTORE_DEFAULT_OFF
inverted: true
- platform: gpio
name: "Bomba Agua Potus (Blanca)"
id: relay_2
pin: GPIO12
restore_mode: RESTORE_DEFAULT_OFF
inverted: true
- platform: gpio
name: "Bomba Agua Mostera"
id: relay_3
pin: GPIO14
restore_mode: RESTORE_DEFAULT_OFF
inverted: true
- platform: gpio
name: "Bomba Agua Estafilo"
id: relay_4
pin: GPIO27
restore_mode: RESTORE_DEFAULT_OFF
inverted: true
binary_sensor:
- platform: gpio
name: "Botón Agua Coleo"
id: button_1
pin:
number: GPIO25
mode: INPUT_PULLUP
inverted: True
on_press:
- switch.toggle: relay_1
- platform: gpio
name: "Botón Agua Potus"
id: button_2
pin:
number: GPIO33
mode: INPUT_PULLUP
inverted: True
on_press:
- switch.toggle: relay_2
- platform: gpio
name: "Botón Agua Mostera"
id: button_3
pin:
number: GPIO32
mode: INPUT_PULLUP
inverted: True
on_press:
- switch.toggle: relay_3
- platform: gpio
name: "Botón Agua Estafilo"
id: button_4
pin:
number: GPIO15
mode: INPUT_PULLUP
inverted: True
on_press:
- switch.toggle: relay_4```