Blog.WIZnet.HK — 建構以太網網關

1.5M ratings
277k ratings

See, that’s what the app is perfect for.

Sounds perfect Wahhhh, I don’t wanna

建構以太網網關

image

您可以使用幾乎任何型號的Arduino去建立一個以太網網關。

市場上有幾個不同的以太網模塊。我們建議使用WIZnet公司W5100其卸載Arduino的MCU並保留為網關的代碼更多的內存。

接線的步驟

射頻模塊必須連接有點不同於標準傳感器連接,因此請務必仔細按照接線說明如下。

image

WIZnet (W5100) Ethernet module

image

注:請參閱下面的配置說明!

image
NRF24L01 Radio module

image

注:如果沒有其他說明,以太網模塊應採用3.3V供電。

Configuration

WIZnet公司W5100:編輯RF24_config.h在(XXX/庫/ MySensors/實用程序),使softspi(“#定義SOFTSPI”之前刪除//)。
這必須被還原回來時,你已經編譯並上傳代碼到你的網關。

ENC28J60:啟用正確的以太網庫,如下圖所示:

#include <UIPEthernet.h>  // Use this if you have attached a Ethernet ENC28J60 shields
//#include <Ethernet.h>   // Use this for WizNET module and Arduino Ethernet Shield 

選擇要使用網關的靜態IP地址和端口。

#define IP_PORT 5003        // The port you want to open
IPAddress myIp (192, 168, 178, 66);  // Configure your static ip here

最後,編譯和使用Arduino的IDE修改草圖上傳到您的Arduino網關。

Source: mysensors.org
arduino wiznet w5100 ethernet gateway

See more posts like this on Tumblr

#arduino #wiznet #w5100 #ethernet gateway