3

Which Raspberry Pi OS images support ENC28J60 Ethernet adapter natively? If none, how can this be installed via the command line and on which OS image?

enter image description here

1
  • I have a Pi running Rasbian 4.1.13+ I can load the driver with "sudo modprobe enc28j60". Commented Feb 17, 2016 at 22:27

2 Answers 2

1

A driver for the ENC28J60 has been in the Linux kernel for a few years, so I you should be able to interface with it.

As @RichardPennington wrote, you load the module with sudo modprobe enc28j60.

3
  • how come it doesn't load automatically like windows? Commented Feb 18, 2016 at 15:39
  • You mean you got the ethernet controller wired to your Pi, installed Windows on it and it just loaded automatically?
    – kba
    Commented Feb 18, 2016 at 15:50
  • 2
    Loading the module alone won't work, you also need some device tree bits to tell the kernel where the device is. I don't recall the detaill offhand though. Commented Mar 3, 2016 at 1:17
1

With moderne disk images, the software part is trivial to get an ENC28J60 work on Raspberry Pi (I did not try yet on other Pis): edit /boot/config.txt and add this where you can:

dtparam=spi=on
dtoverlay=enc28j60,int_pin=25,speed=12000000

There may variations such as int_pin=27.

Note that there are several different enc28j60 boards which may have different pinout. So don't rely on photos (unless your ENC28 is absolutely identical to the one on the tuto).

Also note that the pinout labelled on the RaspIO board on your picture is completely wrong, and does not match the official pinout published by the Raspberry fondation (it matches the documentation of a third party library). If you are trying to reuse rPi documentation to adapt to other Pis, you must ignore the labelling on the picture, and use this table from instructables:

Pi            ENC28J60     Colour
---------------------------------
+3V3          VCC          Red
GPIO10/MOSI   SI           Green
GPIO9/MISO    SO           Yellow
GPIO11/SCLK   SCK          Blue
GND           GND          Black

GPIO25        INT          Blue
CE0#/GPIO8    CS           Green

Unlike what's said on the instructables page, some trivial variations are possible: ground may be plugged from pin 20 or 25, and interruption can be wired to an other GPIO (as long as you update the config line). Using CE1 is probably more tricky.

http://www.instructables.com/id/Super-Cheap-Ethernet-for-the-Raspberry-Pi/

http://raspi.tv/2015/ethernet-on-pi-zero-how-to-put-an-ethernet-port-on-your-pi

1

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.