腳位設置
網路大多列的表可能都不太一樣,以下表是我測試過正常的 (跟官方有小差距)。名稱 (ENC28J60) | 腳位 (Arduino PIN) |
---|---|
VCC | 3.3V |
GND | GND |
SCK | Pin-13 |
SO | Pin-12 |
SI | Pin-11 |
CS | Pin-10 |
RESET | RESET |
圖示
Arduino Library
這裡採用的 Arduino Library 是: https://github.com/jcw/ethercard ,請自行下載 .zip 後,Included 進 Arduino。問題排除
- 如果發現程式碼總是卡在 if(ether.begin... ,請重新確認所有腳位是否接對,尤其是 CS 腳位。
- 如果你的 AP 或 RJ45 連接的網路有 DHCP,你可能無法正常設定靜態 IP,請打開 DHCP 自動設置,不要關閉它。
Reference:
https://github.com/jcw/ethercard
http://www.instructables.com/id/Add-Ethernet-to-any-Arduino-project-for-less-than-/
http://www.homautomation.org/2014/10/27/how-to-choose-the-right-library-to-add-ethernet-enc28j60-to-your-arduino/
http://jeelabs.org/pub/docs/ethercard/
https://arduino.stackexchange.com/questions/31024/slow-response-from-enc28j60
https://arduino.stackexchange.com/questions/29744/arduino-uno-ethernet-shield-enc28j60-hangs-after-some-time/29746
https://stackoverflow.com/questions/33323740/arduino-enc28j60-ethercard-h-compile-error-word-homepage-was-declare/35244387
https://stackoverflow.com/questions/17791876/sending-post-data-with-arduino-and-enc28j60-ethernet-lan-network-module/17796425
http://jeelabs.net/boards/7/topics/2756
https://create.arduino.cc/projecthub/Sourcery/how-to-connect-the-enc28j60-to-an-arduino-efd0dd
https://arduinodiy.wordpress.com/2013/04/07/connect-an-enc28j60-ethernet-module-to-an-arduino/
http://jeelabs.org/pub/docs/ethercard/classENC28J60.html
沒有留言:
張貼留言