ESP32 Smart City Controller


Created 11 project docs

Project Specification — ESP32 Smart City Controller

View Document

Status: Review ESP32 DevKitC 38-pin carrier PCB for a smart-city demonstration with distance sensing, servo actuation, sound/sensitivity ana...

Power Budget — ESP32 Smart City Controller

View Document

| Rail | Load | Typical | Peak / Design Case | Basis | |---|---|---:|---:|---|

Firmware Starter — ESP32 DevKitC

View Document

MCU board: ESP32 DevKitC 38-pin / esp32dev Framework: Arduino

Board Bring-Up Plan — ESP32 Smart City Controller

View Document

Current-limited 5 V bench supply, multimeter, oscilloscope, USB cable, known HC-SR04, known servo, microphone module, 10 kΩ potentiometer, a...
Show 7 More
Created and verified the complete ESP32 Smart City Controller schematic, including HC-SR04 level shifting, servo stabilization, analog inputs, and six LED channels. Documentation: Project Specification, Power Budget, Firmware Starter, and Bring-Up Plan.
  • Open item: ERC reports U1:VP as an unpowered supply due to an incorrect library pin classification; VP is actually unused GPIO36 and is correctly marked no-connect.
  • Next: confirm the servo model/stall current, then configure the board and place components with antenna keepout and wide 5 V/ground paths.
hay un capacitor que no esta donde deveria estar ponlo en su lugar
Claro — necesito que me indiques cuál capacitor y dónde debería ir.
Puedes responder con algo como:
  • “C1 debe ir junto al conector del servo J3”
  • “C3 debe ir cerca del pin 5V del ESP32”
  • “El capacitor cerca de la esquina inferior derecha debe ir junto a U1”
Si puedes, selecciona el capacitor en Flux o dime su designador (C1, C2, C3, C4 o C5) y lo muevo a su lugar.
ya lo tengo seleccionado
Perfecto, revisaré el componente seleccionado y lo recolocaré donde corresponde según su función en el circuito.
Listo. Moví C1 junto al conector del servo J3, manteniendo el resto de los componentes en sus posiciones. Verifiqué que quedó dentro de la placa y sin solapamientos.
Revisar, enrutar y verificar
Revisar colocación completa
Enrutar placa
Ejecutar DRC
Revisar polaridad

J5
J4
J3
J10
J8
R4
Resistance
220Ω
J1
R3
Resistance
220Ω
J7
R6
Resistance
220Ω
J11
J9
R7
Resistance
10kΩ
R8
Resistance
18kΩ
R1
Resistance
220Ω
R2
Resistance
220Ω
R5
Resistance
220Ω
R9
Resistance
470Ω
R10
Resistance
10kΩ
J6
R11
Resistance
10kΩ
C3
Capacitance
47uF
J2
C4
Capacitance
100nF
U1
C1
Capacitance
470uF
C5
Capacitance
100nF
C2
Capacitance
100nF
Project Specification — ESP32 Smart City Controller
Project Overview
  • Status: Review
  • ESP32 DevKitC 38-pin carrier PCB for a smart-city demonstration with distance sensing, servo actuation, sound/sensitivity analog inputs, and six building-light outputs.
Intended Use
  • Low-voltage indoor prototype or educational demonstrator.
  • Powered by a regulated external 5 V DC adapter.
  • Not intended for safety-critical motion control or outdoor exposure without further protection.
What the Device Should Do
  • Read an HC-SR04 ultrasonic sensor.
  • Drive one hobby servo from GPIO13.
  • Sample an analog microphone on GPIO34.
  • Sample an external sensitivity potentiometer on GPIO35.
  • Independently drive six external LEDs.
  • Use ESP32 Wi-Fi/Bluetooth capabilities for future connectivity.
Main Features
  • ESP32-DEVKITC-VE 38-pin module.
  • 5 V screw-terminal input.
  • HC-SR04 header with protected ECHO input.
  • Servo header with local bulk capacitance and startup pulldown.
  • 3.3 V microphone and potentiometer headers.
  • Six active-high, resistor-limited LED headers.
System Architecture

Diagram


Regulated 5 V input J1 ESP32 DevKitC U1 HC-SR04 J2 Servo J3 Six LED outputs J6-J11 Analog microphone J4 Sensitivity potentiometer J5 Wi-Fi / Bluetooth
Hardware Subsystems
Power
  • J1 PIN1 = 5V_EXT; J1 PIN2 = GND.
  • 5V_EXT feeds U1 5V, HC-SR04 VCC, and servo VCC.
  • C1 470 uF + C2 100 nF support servo transients.
  • C3 47 uF + C4 100 nF support the DevKit 5 V input.
  • U1 3V3 supplies the microphone and external potentiometer.
Ultrasonic Sensor
  • J2 pin 1 VCC, pin 2 TRIG, pin 3 ECHO, pin 4 GND.
  • TRIG uses GPIO4.
  • ECHO passes through R7 10 kΩ / R8 18 kΩ divider to GPIO5; 5 V becomes approximately 3.21 V.
Servo
  • J3 Gnd/5v/Data pin names are used directly.
  • GPIO13 drives Data through R9 470 Ω.
  • R10 10 kΩ pulls the connector-side servo signal low during reset.
Analog Inputs
  • Microphone J4: pin 1 3V3, pin 2 GPIO34, pin 3 GND; C5 100 nF bypass.
  • Potentiometer J5: VCC 3V3, Output GPIO35, GND common.
  • GPIO34 and GPIO35 are ESP32 ADC1 input-only pins and remain usable while Wi-Fi is active.
LED Outputs

Table


ChannelGPIOResistorHeader
112R1 220 ΩJ6
214R2 220 ΩJ7
327R3 220 ΩJ8
426R4 220 ΩJ9
525R5 220 ΩJ10
633R6 220 ΩJ11
  • Header P1 is the resistor-limited active-high signal; P2 is GND.
  • R11 10 kΩ holds GPIO12 low at reset to protect the flash-voltage boot strap.
Interfaces and Connections
  • J1: regulated 5 V DC input.
  • J2: HC-SR04.
  • J3: hobby servo.
  • J4: 3.3 V analog microphone module; output must remain within 0–3.3 V.
  • J5: recommended 10 kΩ linear potentiometer.
  • J6–J11: external LEDs only; external voltage must not be driven into these outputs.
Power and Runtime Expectations
  • Continuous operation from a wall adapter; no battery subsystem.
  • Use a 5 V, 2 A minimum adapter for a known micro-servo; 5 V, 3 A preferred when stall current is unknown.
  • Do not power the DevKit simultaneously from USB and J1 unless the exact board revision is confirmed to prevent backfeed.
Power Tree and Power Budget
  • See the Power Budget project file.
  • 5V_EXT and GND are tagged for 2 A nominal and 3 A peak design current.
Manufacturing and Assembly Expectations
  • Through-hole external connectors and radial bulk capacitors; 0603 resistors and bypass capacitors.
  • C1 and C3 are polarized electrolytics: P1 to 5V_EXT, P2 to GND.
  • During PCB layout, use at least 0.5 mm / 20 mil for 5 V and GND, preferably wider for the servo branch and return.
  • Route servo current directly between J1 and J3; avoid sharing the microphone/potentiometer ground path.
Firmware-Relevant Hardware Requirements
  • Arduino-compatible ESP32 firmware.
  • GPIO12 must initialize low before enabling LED channel 1.
  • Servo GPIO13 should remain low/detached until commanded.
  • ADC attenuation should be configured for GPIO34/GPIO35.
Physical Design Expectations
  • Place the DevKit antenna at the board edge with no copper or components under/around its antenna region.
  • Keep J1 and J3 close together to minimize the high-current loop.
  • Keep analog connectors and traces away from the servo power path.
Important Design Decisions
  • Added HC-SR04 ECHO divider because ESP32 GPIO is not 5 V tolerant.
  • Added servo bulk/bypass capacitance and startup pulldown.
  • Retained all user-requested GPIO assignments.
  • Did not add reverse-polarity protection or a fuse to preserve the requested direct 5 V architecture; these remain recommended options.
Assumptions
  • External supply is regulated 5 V.
  • HC-SR04 module has conventional 5 V ECHO behavior.
  • External LEDs are connected anode to header signal and cathode to header GND.
  • Servo accepts a 3.3 V PWM high level.
Change Notes
  • Initial schematic created with safety corrections and documentation.
  • Project Overview

  • Intended Use

  • What the Device Should Do

  • Main Features

  • System Architecture

  • Hardware Subsystems

  • Power

  • Ultrasonic Sensor

  • Servo

  • Analog Inputs

  • LED Outputs

  • Interfaces and Connections

  • Power and Runtime Expectations

  • Power Tree and Power Budget

  • Manufacturing and Assembly Expectations

  • Firmware-Relevant Hardware Requirements

  • Physical Design Expectations

  • Important Design Decisions

  • Assumptions

  • Change Notes