Circuit Documentation
Summary
This document provides a detailed overview of a circuit that primarily consists of an ESP32 microcontroller and a W5500 Ethernet module. The circuit also includes a ZMPT101B voltage sensor and a DHT22 temperature and humidity sensor. The ESP32 is responsible for interfacing with these sensors and potentially communicating data over Ethernet using the W5500 module. The circuit is designed for monitoring environmental parameters and voltage, with the capability to send this data over a network.
Component List
ESP32 (30 pin)
- Description: A microcontroller with Wi-Fi and Bluetooth capabilities, featuring a wide range of GPIO pins for interfacing with various sensors and modules.
- Pins: EN, VP, VN, D34, D35, D32, D33, D25, D26, D27, D14, D12, D13, GND, Vin, D23, D22, TX0, RX0, D21, D19, D18, D5, TX2, RX2, D4, D2, D15, 3V3
Module Ethernet W5500
- Description: An Ethernet module that allows microcontrollers to connect to a wired network. It supports up to 8 independent sockets simultaneously.
- Pins: NC, INT, RST, GND, 5V, SCK, SS, MOSI, MISO, 3.3V
ZMPT101B
- Description: A module for voltage sensing in AC circuits, useful for monitoring mains voltage.
- Pins: OUT, GND, VCC, NEUTRO, FASE
DHT22
- Description: A sensor for measuring ambient temperature and humidity.
- Pins: +, Out, -
Wiring Details
ESP32 (30 pin)
- EN connected to Module Ethernet W5500 RST
- VP connected to ZMPT101B OUT
- D32, D33, D26, D27 connected together and to DHT22 Out
- D25 connected to Module Ethernet W5500 INT
- GND connected to DHT22 - and shared with Module Ethernet W5500 GND and ZMPT101B GND
- Vin connected to ZMPT101B VCC
- D23 connected to Module Ethernet W5500 MOSI
- D19 connected to Module Ethernet W5500 MISO
- D18 connected to Module Ethernet W5500 SCK
- D5 connected to Module Ethernet W5500 SS
- 3V3 connected to Module Ethernet W5500 3.3V and DHT22 +
Module Ethernet W5500
- RST connected to ESP32 EN
- INT connected to ESP32 D25
- GND connected to ESP32 GND and ZMPT101B GND
- MOSI connected to ESP32 D23
- MISO connected to ESP32 D19
- SCK connected to ESP32 D18
- SS connected to ESP32 D5
- 3.3V connected to ESP32 3V3
ZMPT101B
- OUT connected to ESP32 VP
- GND connected to ESP32 GND
- VCC connected to ESP32 Vin
DHT22
-
- connected to ESP32 3V3
- Out connected to ESP32 D32, D33, D26, D27
-
- connected to ESP32 GND
Documented Code
ESP32 Microcontroller Code (sketch.ino)
void setup() {
// put your setup code here, to run once:
}
void loop() {
// put your main code here, to run repeatedly:
}
Module Ethernet W5500 Code (sketch.ino)
void setup() {
// put your setup code here, to run once:
}
void loop() {
// put your main code here, to run repeatedly:
}
Note: The provided code for both the ESP32 and the W5500 Ethernet module is a template with empty setup and loop functions. The actual implementation should include initialization of the Ethernet module, reading data from the sensors, and handling communication over the network.
