Connect your ESP32 to W5500 (Wiznet) ethernet module. and use Python requests as http client
Forked from Ayyoubzadeh/ESP32-Wiznet-W500-Micropython
Same as code posted by vinz-uts on Micropython Forum
Python3 must be installed on your system. Check the current Python version with the following command
python --version
python3 --version
Depending on which command Python 3.x.y
(with x.y as some numbers) is
returned, use that command to proceed.
python3 -m venv .venv
source .venv/bin/activate
pip install -r requirements.txt
Copy the module to the MicroPython board and import them as shown below using Remote MicroPython shell
Open the remote shell with the following command. Additionally use -b 115200
in case no CP210x is used but a CH34x.
rshell -p /dev/tty.SLAB_USBtoUART --editor nano
Perform the following command to copy all files and folders to the device
mkdir /pyboard/lib
cp wiznet5k*.py /pyboard/
cp -r lib/* /pyboard/lib
cp main.py /pyboard
cp boot.py /pyboard
ESP32 ESP-WROOM-32 with W5500 (or W5100)
ESP32 Board | W5500 |
---|---|
3V3 | VCC |
GND | GND |
GPIO15(HSPI_CS) | CS |
GPIO14(HSPI_CLK) | SCK |
GPIO13(HSPI_MOSI) | MOSI |
GPIO12(HSPI_MISO) | MISO |
GPIO19 | RST |
GPIO4 User LED |
Top view of WIZ5500 Mini module
LAN
| |
| |
|| ||
-------------
GND | GND GND | GND
GND | GND 3.3V | 3.3V
MOSI | MISO 3.3V | 3.3V
SCK | SCK NC | NC
CS | CS RST | 3.3V
NC | INT MISO | MISO
-------------
- Only Works with http (not https)
- Does not support asyncio