By Wolfgang Keller
Originally written 2018-06-02
Last modified 2022-06-08
In this tutorial, we use the following microcontroller boards:
Note that the former uses 5 V power levels while the latter uses 3.3 V. If you apply a power level of 5 V to the RP2040 microcontroller, it will likely become destroyed.
For ethernet, we use the following ICs/boards:
Documents: Document | WIZnet Document System [visited 2022-05-21T13:37:10Z]
A board in the form factor of a Raspberry Pi Pico HAT is available at
According to its description, this board supports both 3.3 V and 5 V, and can thus be connected both the Arduino Uno Rev 3 and Raspberry Pi Pico.
Board: A board that supports both 3.3 V and 5 V: ENC28J60 Ethernet Shield LAN Netzwerk Modul kompatibel mit Arduino – AZ-Delivery [visited 2022-05-27T23:04:50Z].
AZ-Delivery also offers an ebook for free on how to connect this board to an Arduino:
For the differences:
In this sense, the order given here is in increasing order of difficulty of implementing the software, and thus the order in which we will do the projects.
Just in case that you want to connect Wi-Fi® to your Raspberry Pi Pico, here a list of ICs and board (these are not of further relevance for this text since we work with Ethernet; rather, this list is intended as support to the reader).
By the data sheet linked above, the pins of the ENC28J60 are as follows:
|Pin # SPDIP,
|Pin # QFN||Name||Type||Connect to|
|1||25||VCAP||In (Power)||Power (GND with filter capacitator of ≈10 μF (minimum 1 μF) inbetween)|
|2||26||VSS||In (Power)||Power (GND)|
|5||1||NC||N.C. (Out)||N.C. (Out)|
|11||7||VSSRX||In (Power)||PHY RX (GND)|
|14||10||RBIAS||In||Power (GND with resistor of 2.32 kΩ, 1% inbetween)|
|15||11||VDDTX||In (Power)||PHY TX (+3.3V)|
|18||14||VSSTX||In (Power)||PHY TX (GND)|
|19||15||VDDRX||In (Power)||PHY RX (+3.3V)|
|20||16||VDDPLL||In (Power)||PHY PLL (+3.3V)|
|21||17||VSSPLL||In (Power)||PHY PLL (GND)|
|22||18||VSSOSC||In (Power)||OSC (GND)|
|25||21||VDDOSC||In (Power)||OSC (+3.3V)|
|28||24||VDD||In (Power)||Power (+3.3V)|
Remark: In many older schematics the NC pin (pin 5 (SPDIP, SSOP, SOIC) or 1 (QFN)) is instead called WOL (Wake On LAN). The ability to use this pin for Wake On LAN only existed in older chip revisions of the ENC28J60. Now for this functionality, the INT pin is used.
For our application it is very important that all SPI input pins (CS, SCK, SI), as well as RESET, are 5V tolerant, so we don't need a level shifter for the inputs. Note however that the output pins SI, CLKOUT and INT use 3.3V as high.
This leaves the following pins for us to connect with Power and MCU (ordered by category):
|VSS||In (Power)||Power (GND)|
|VDD||In (Power)||Power (+3.3V)|
Under https://arduino-hannover.de/2013/12/08/mein-paket-ein-enc28j60-ethernet-lan-netzwerk-modul/ [visited 2018-03-12T13:32:54Z], one can find a description of a module based on the ENC28J60. Here are three Arduino libraries for it:
A comparison between EtherCard and UIPEthernet (and ETHER_28J60) can be found at http://www.tweaking4all.com/hardware/arduino/arduino-enc28j60-ethernet [visited 2018-05-07T20:16:48Z].
In the README file of EtherCard [visited 2018-06-03T11:34:47Z] and its documentation , one can find the following instructions to connect the ENC28J60 to the Arduino UNO:
|Pin Name ENC28J60||Pin # Arduino Uno||Type|
If you are interested in further details why these are the natural pins for SPI on the Arduino Uno, read the text of Arduino's SPI library [visited 2018-06-03T12:10:05Z].