Page 1 of 2

Using the ESP with a Ethernet Port through SPI

Posted: Wed Sep 13, 2017 4:30 pm
by Pablo Oyarzo
I know there is http://www.ebay.com/itm/1xENC28J60-Ethe ... SwyXFUYaeZ this kind of module out there and it works through SPI. Based on my ignorance, I'm worried about how am I gonna tell the ESP to send the internet packets through the Ethernet port and not the wifi connection.

1) Is it possible?
2) Will I need a library for that?
3) Is said library implemented on Micropython?

Re: Using the ESP with a Ethernet Port through SPI

Posted: Thu Oct 19, 2017 4:53 am
by mcauser
1) Yes. Ethernet and Wifi would use separate libraries.
2) Yes. The existing network module is very specific to ESP8266s Wifi firmware. You'll need something separate for Eth.
3) I am not sure about the ENC28J60 but there is a driver for the Wiznet 5x00 ethernet boards. eg. W5100, W5500

See:
viewtopic.php?t=2443
https://github.com/micropython/micropyt ... /README.md

Around $4 for a W5500
https://www.aliexpress.com/item/W5500-E ... 20397.html

Anyone that has used the MicroPython wiznet5k driver care to chime in?

Re: Using the ESP with a Ethernet Port through SPI

Posted: Thu Oct 19, 2017 6:35 am
by Roberthh
The WIznet5k driver is for PyBoard, so porting it to the ES8266 could be some work. It was originally made for the W5200 device, and now extended for the W5500 device. It is pretty basic yet.

Re: Using the ESP with a Ethernet Port through SPI

Posted: Thu Oct 19, 2017 9:24 am
by devnull
Robert: This page https://github.com/micropython/micropyt ... er/drivers

Does state that they are available across all ports ???
This directory contains drivers for specific hardware. The drivers are intended to work across multiple ports.
I have ordered 10 of these (https://www.aliexpress.com/item/W5500-E ... 20397.html) based on that statement ?!

Re: Using the ESP with a Ethernet Port through SPI

Posted: Thu Oct 19, 2017 10:48 am
by Roberthh
I tested such a unit yesterday with a Pyboard, and it works well. I have serious doubts that this driver is intended to work with the ESP8266 port. The Makefile has no notice of it, and neither the network module. It may possible to fit it in, but I would be very suprised if just pulling in the files and adding a few code lines in modnetwork.c and Makefile is all you have to do.

Re: Using the ESP with a Ethernet Port through SPI

Posted: Fri Oct 20, 2017 10:54 pm
by Damien
It may actually be possible to use the Wiznet in raw Ethernet mode with the esp8266. It would at least be interesting to try and get it working. The main thing it depends on is being able to call netif_add in lwip. It depends how much the esp8266 lwip is modified from the stock version.

Sent from my GT-I9105P using Tapatalk


Re: Using the ESP with a Ethernet Port through SPI

Posted: Sat Oct 21, 2017 6:28 am
by devnull
I ordered 10 of them from aliexpress, they were shipped yesterday, I am really hoping that this will work on the 8266 and ESP32 as I have a couple of things that need ethernet connectivity rather than wifi ?!

Re: Using the ESP with a Ethernet Port through SPI

Posted: Tue Oct 24, 2017 9:31 am
by devnull
I have received these ethernet boards, what would it take to make it work on an ESP32, would that be easier ?

Re: Using the ESP with a Ethernet Port through SPI

Posted: Sun Jan 20, 2019 10:45 am
by gpson
does anyone succeeded to run esp8266 with any ethernet module?

Re: Using the ESP with a Ethernet Port through SPI

Posted: Sat Dec 07, 2019 7:30 am
by ta1db
Hi @devnull

What did you do with the 10 W5500 ethernet boards you've got.. Could you use them with ESP8266 or ESP32? If not did you try them with PyBoard?