AED 20.00
Description
The ENC28J60 Ethernet Board is a module designed for easy integration with Arduino and other microcontrollers featuring a built-in SPI protocol interface. Developed by Microchip, this module boasts plug-and-play compatibility with Arduino through readily available libraries. Operating at 3.3V while accommodating 5V interface lines, it leverages the SPI process for efficient communication. Unlock versatile applications such as hosting web servers, responding to network pings, or seamlessly incorporating it into home automation systems via the internet. At its core lies the advanced ENC28J60 Ethernet controller, a Microchip innovation. The integration of RJ45 with integrated magnetics streamlines network connectivity and contributes to a compact board design, making it an ideal choice for diverse projects.
Features:
- Ethernet Connectivity: Enables microcontrollers to connect to an Ethernet network.
- Compatibility: Designed for use with Arduino or any microcontroller with a built-in SPI protocol interface.
- SPI Interface: Utilizes the SPI (Serial Peripheral Interface) communication protocol for interfacing with microcontrollers.
- Voltage Compatibility: Operates at 3.3V but tolerates 5V interface lines, making it versatile and compatible with different systems.
- Web Server Capability: Allows the hosting of a web server, enabling the microcontroller to serve web pages or handle HTTP requests.
- Ping Support: Supports the ping functionality, allowing the module to respond to network ping requests.
- Home Automation Integration: Facilitates integration into home automation systems via the internet.
- ENC28J60 Ethernet Controller: Core component of the module, developed by Microchip, providing the necessary functionality for Ethernet communication.
- Integrated Magnetics: RJ45 connector with integrated magnetics reduces the board size and simplifies the physical connection to the network.
Specifications:
- Ethernet Chip: ENC28J60 Ethernet controller from Microchip.
- Network Interface: HR911105A.
- Mounting Compatibility: Can be easily mounted with microcontrollers such as Arduino, AVR, LPC, STM3.
- Supply Voltage: Operates at 3.3V, with 5V tolerant DIO (Digital Input/Output) lines.
- Crystal Oscillator: 25MHz crystal oscillator for precise timing.
- Size: Approximately 2.3 x 1.3 x 0.7 inches (58 x 34 x 17 mm).
ENC28J60 Module Connections With Arduino:
Label | Arduino Pin | Description |
+5V | 5V | 5V supply, this might be 3.3V on some modules |
GND | GND | Ground pin |
INT/LNT | NC | Interrupt output |
CLK | NC | Clock output from ethernet controller |
SO | MISO (12) | SPI output |
WOL | NC | NC; reserved pin, see datasheet. |
SCK | SCK (13) | SPI clock |
ST/SI | MOSI (11) | SPI Input |
RST | NC | Reset |
CS | SS (8/10) | Chip select |
Q3 | NC | The datasheet says, that this is the RX 3.3V supply |
Arduino Code for the Ethernet Network Module ENC28J60 (Big):
The EtherCard library is the best library that makes this module work with Arduino, It can be downloaded by clicking here then you would have to add it to Arduino IDE
after that, you can upload this code which can make the Arduino web server with the help of the Ethernet Module
#include "EtherCard.h" // ethernet interface mac address, must be unique on the LAN static byte mymac[] = { 0x74,0x69,0x69,0x2D,0x30,0x31 }; byte Ethernet::buffer[700]; static uint32_t timer; const char website[] PROGMEM = "www.google.com"; // called when the client request is complete static void my_callback (byte status, word off, word len) { Serial.println(">>>"); Ethernet::buffer[off+300] = 0; Serial.print((const char*) Ethernet::buffer + off); Serial.println("..."); } void setup () { Serial.begin(57600); Serial.println(F("\n[webClient]")); // Change 'SS' to your Slave Select pin, if you arn't using the default pin if (ether.begin(sizeof Ethernet::buffer, mymac, SS) == 0) Serial.println(F("Failed to access Ethernet controller")); if (!ether.dhcpSetup()) Serial.println(F("DHCP failed")); ether.printIp("IP: ", ether.myip); ether.printIp("GW: ", ether.gwip); ether.printIp("DNS: ", ether.dnsip); #if 1 // use DNS to resolve the website's IP address if (!ether.dnsLookup(website)) Serial.println("DNS failed"); #elif 2 // if website is a string containing an IP address instead of a domain name, // then use it directly. Note: the string can not be in PROGMEM. char websiteIP[] = "192.168.1.1"; ether.parseIp(ether.hisip, websiteIP); #else // or provide a numeric IP address instead of a string byte hisip[] = { 192,168,1,1 }; ether.copyIp(ether.hisip, hisip); #endif ether.printIp("SRV: ", ether.hisip); } void loop () { ether.packetLoop(ether.packetReceive()); if (millis() > timer) { timer = millis() + 5000; Serial.println(); Serial.print("<<< REQ "); ether.browseUrl(PSTR("/foo/"), "bar", website, my_callback); } }