谷歌致力於推進種族平等的黑人社區。 怎麼看。
本頁面由 Cloud Translation API 翻譯而成。
Switch to English

OpenWeave +愉快的跨網絡的多播的Inet層HOWTO

神社佔位符-0 .MD“> GitHub上查看源代碼

你已經決定,你想用OpenWeave跨網絡的多播實驗。該如何引導說明了使用開心網的模擬工具來設置該演示如何使用OpenWeave的Inet電子層在兩個不同的網絡具有多播代理服務器虛擬拓撲。

下載並構建mcproxy

IPv6組播代理守護進程, mcproxy ,用於代理/轉發/路由IPv6組播流量橫跨兩個不相交的IPv6網絡鏈接。

雖然它在那裡你克隆和構建並不是特別重要mcproxy守護程序的可執行文件,請大家在其中創建它作為一個相對或絕對路徑,它是在下面的步驟6必要位置的音符。

 git clone https://github.com/mcproxy/mcproxy.git mcproxy
sudo apt-get install qt5-qmake qt5-default
cd mcproxy/mcproxy
qmake
make

下載,編譯並安裝快樂

 git clone https://github.com/openweave/happy.git happy
sudo apt-get install bridge-utils python-lockfile python-psutil python-setuptools
cd happy
sudo make install

下載並構建openweave核心

 git clone https://github.com/openweave/openweave-core.git openweave-core
cd openweave-core
./configure
make

建立拓撲快樂

這將創建非常相似的拓撲快樂程式碼實驗室

 happy-network-add ThreadNetwork thread
happy-network-address ThreadNetwork fd00:0000:0000:0006::
happy-network-add WiFiNetwork wifi
happy-network-address WiFiNetwork fd00:0000:0000:0001::
happy-network-address WiFiNetwork 192.168.1.0
happy-node-add ThreadNode
happy-node-add WiFiNode
happy-node-add BorderRouter
happy-node-join ThreadNode ThreadNetwork
happy-node-join WiFiNode WiFiNetwork
happy-node-join BorderRouter ThreadNetwork
happy-node-join BorderRouter WiFiNetwork
happy-network-route --prefix fd00:0000:0000:0006:: ThreadNetwork BorderRouter
happy-network-route --prefix fd00:0000:0000:0001:: WiFiNetwork BorderRouter
happy-network-route --prefix 192.168.1.0 WiFiNetwork BorderRouter

創建mcproxy配置的快樂拓撲

這創建IPv6組播模擬的“螺紋”網絡“wpan0”接口和模擬“WiFi”的網絡上的“為wlan0”在我們上面步驟4中創建的快樂拓撲接口之間的代理配置。

雖然在其中創建的不是特別重要mcproxy.conf文件,請大家在其中創建它給它的相對或絕對路徑是在第6步必要位置的音符。

 cat > mcproxy.conf << EOF
protocol MLDv2;
pinstance myProxy: wpan0 ==> wlan0;
EOF

運行演示

這將運行的IPv6多播代理, mcproxy中,“BorderRouter”節點上,然後啟動在INET層組播功能測試發送者和接收者在模擬“線程”和“WiFi”的節點,分別。

如果你願意,你可以移調發送者和接收者節點和示例將工作同樣也是如此。

每個下面的命令集的應從平行的,獨立的外殼中運行。

邊界路由器

 happy-shell BorderRouter
<path-to-mcproxy-from-step1> /mcproxy -f <path-to-mcproxy-config-from-step5> /mcproxy.conf

接收器

 happy-shell WiFiNode
openweave-core/src/test-apps/TestInetLayerMulticast -6 --udp -I wlan0 -g 5 --group-expected-rx-packets 5 --group-expected-tx-packets 0 -l

寄件人

 happy-shell ThreadNode
openweave-core/src/test-apps/TestInetLayerMulticast -6 --udp -I wpan0 -g 5 --group-expected-rx-packets 0 --group-expected-tx-packets 5 -L

產量

寄件人

 openweave-core/src/test-apps/TestInetLayerMulticast -6 --udp -I wlan0 -g 5 ... -L
Weave Node ready to service events; PID: 50845; PPID: 46482
Using UDP/IPv6, device interface: wpan0 (w/o LwIP)
Will join multicast group ff15::5
1/5 transmitted for multicast group 5
2/5 transmitted for multicast group 5
3/5 transmitted for multicast group 5
4/5 transmitted for multicast group 5
5/5 transmitted for multicast group 5
Will leave multicast group ff15::5
WEAVE:IN: Async DNS worker thread woke up.
WEAVE:IN: Async DNS worker thread exiting.
WEAVE:IN: Async DNS worker thread woke up.
WEAVE:IN: Async DNS worker thread exiting.

接收器

 openweave-core/src/test-apps/TestInetLayerMulticast -6 --udp -I wlan0 -g 5 ... -l
Weave Node ready to service events; PID: 50826; PPID: 46499
Using UDP/IPv6, device interface: wlan0 (w/o LwIP)
Will join multicast group ff15::5
Listening...
UDP packet received from fd00::6:8693:b7ff:fe5a:1dc1:4242 to ff15::5:4242 (59 bytes)
1/5 received for multicast group 5
UDP packet received from fd00::6:8693:b7ff:fe5a:1dc1:4242 to ff15::5:4242 (59 bytes)
2/5 received for multicast group 5
UDP packet received from fd00::6:8693:b7ff:fe5a:1dc1:4242 to ff15::5:4242 (59 bytes)
3/5 received for multicast group 5
UDP packet received from fd00::6:8693:b7ff:fe5a:1dc1:4242 to ff15::5:4242 (59 bytes)
4/5 received for multicast group 5
UDP packet received from fd00::6:8693:b7ff:fe5a:1dc1:4242 to ff15::5:4242 (59 bytes)
5/5 received for multicast group 5
Will leave multicast group ff15::5
WEAVE:IN: Async DNS worker thread woke up.
WEAVE:IN: Async DNS worker thread exiting.
WEAVE:IN: Async DNS worker thread woke up.
WEAVE:IN: Async DNS worker thread exiting.