Set the layout to 80 mm x 60 mm with a Standard 4 Layer stackup and compacted the board from the previously oversized outline. This matches the stage-2 and layout guidance to explicitly set board size and stackup before placement, and to use a 4-layer board for an ESP32 design with USB and multiple rails
MCU / communication on the upper-right around U1 with J2 inset in the lower-right programming area
RS485 centered between the MCU and sensor interface with U4
Sensor / user I O on the right edge with J3, S1, S2, D3, D4, and D5
Placed U1 at the top-right board edge with the antenna side facing outward and using an antenna overhang rule consistent with the ESP32 placement guidance for PCB antennas at the board edge
Verified the placement pass completed cleanly with no overlap or out-of-bounds placement problems. The only remaining review items are unrouted electrical connections, which are expected because trace routing has not been done yet.
Success criteria review
✅ The board size is set to 80 mm x 60 mm and the layout still has comfortable routing space
✅ Components are grouped into clear power, MCU/communication, RS485, and sensor/interface regions
✅ The ESP32 antenna on U1 is positioned at the board edge for RF-friendly placement
Next steps
I can continue with PCB finishing work next: route the critical nets, set any additional trace-width or keepout rules, and do a final RF / connector clearance review around U1, J1, and J3.
WiFi-enabled water flow meter for a 3/4 inch PVC pipe using an external 12 V ultrasonic flow sensor with RS485 communications. The board is powered from USB-C 5 V input, generates regulated 3.3 V for control electronics and 12 V for the sensor, and reports flow rate and totalized volume through an ESP32 WiFi module.
Architecture
Diagram
Functional Blocks
USB-C sink power input with CC pull-down resistors, VBUS ESD protection, reverse-current and reverse-polarity style ideal-diode MOSFET stage, and bulk plus local decoupling.
3.3 V low-noise regulation for ESP32, RS485 transceiver, and logic.
5 V to 12 V boost converter to power the external ultrasonic sensor.
ESP32-WROOM-32D WiFi controller with UART programming header, BOOT and RESET support, EN filtering, and dedicated status LEDs.
Half-duplex RS485 interface to an external ultrasonic flow sensor connector carrying GND, +12 V, RS485 A, and RS485 B.
Flow rate and total volume calculations performed in ESP32 firmware from RS485 sensor data.
Planned Interfaces
USB-C Power Input
USB-C receptacle used as a 5 V sink only.
CC1 and CC2 each use 5.1k pull-down resistors to GND.
Protected 5 V rail feeds both the 3.3 V regulator and 12 V boost converter.
Programming Header
UART header exposes GND, 3.3 V reference, ESP32 TX0, ESP32 RX0, DTR, and RTS.
DTR and RTS support automatic BOOT and RESET sequencing through the ESP32 reset network.
Flow Sensor Connector
Pin 1: GND
Pin 2: +12 V sensor power
Pin 3: RS485 A
Pin 4: RS485 B
Design Decisions
Use an ESP32 module rather than a bare chip to avoid RF matching and antenna design risk.
Use a 3.3 V LDO because the 5 V to 3.3 V rail drop is moderate and the circuit benefits from simplicity and low noise.
Use a dedicated boost converter because the external ultrasonic sensor requires 12 V while the system input is USB-C 5 V.
Perform flow-rate and total-volume calculations in firmware because the ultrasonic sensor already communicates digitally over RS485.
Validation Goals
All power rails are protected, decoupled, and connected to their intended loads.
ESP32 boot and reset behavior is deterministic and suitable for UART programming.
RS485 interface includes correct bus connections and support components for reliable single-sensor communication.
The schematic is complete enough to proceed to PCB layout after ERC review.
Summary
Architecture
Functional Blocks
Planned Interfaces
USB-C Power Input
Programming Header
Flow Sensor Connector
Design Decisions
Validation Goals
Reviews
Documents
Project Specification
design-notes
Assets
No assets added.
ESP32 RS485 Water Flow Meter
USB-C powered ESP32 WiFi water flow meter schematic with protected 5V input, 3.3V LDO, 12V boost supply for an external RS485 ultrasonic sensor, UART programming header, boot/reset network, and three status LEDs for power, WiFi, and flow activity.
Properties
Properties describe core aspects of the project.
Pricing & Availability
Distributor
Qty 1
Controls
Welcome 👋
Flux helps you build PCBs faster with an AI teammate!
Create your account to collaborate, stay updated, fork your own version, and get instant answers from our AI agent.