Difference between revisions of "Mesh/WalkThrough"

4,592 bytes added ,  18:39, 13 December 2019
adds troubleshooting and reset button soldering section
(added firmware feed info)
(adds troubleshooting and reset button soldering section)
 
(206 intermediate revisions by 21 users not shown)
Line 1: Line 1:
The following walk through assumes you're using linux and knowledge of terminal. The basic idea of getting a node (router) on the mesh consists of flashing (copying files to the flash) an operating system to node and installing additional drivers and packages. We use [https://openwrt.org/ OpenWRT] as the operating system on our embedded devices (routers), then connect to the node (via [https://en.wikipedia.org/wiki/Secure_Shell SSH]) and install mesh the related software and configure it. This operating system is meant to fit on small amount (4MB) of flash memory.
'''Congratulations''' on choosing to become part of the [https://peoplesopen.net/ People's Open Network]!


=Building an OpenWRT image=
Continue reading to follow these do-it-yourself / do-it-together instructions, or read more about [[Mesh#How_To_Participate|how to participate and get help]].


If you already have a image of the operating system (firmware), then you can skip this step. If your router has the stock software, then you'll probably have to use a '''factory image''', which has information in the header which allows you to install it. Otherwise, you'll be using a '''sysupgrade image''' (trx image).
= Summary =
This is a [[Mesh/WalkThrough#linkback|WalkThrough]] to install a custom operating system on a compatible network device for use as a '''node''' (e.g. your home router) on the network. You will learn how to flash Sudo Mesh's [https://github.com/sudomesh/sudowrt-firmware sudowrt-firmware] (a custom build of [https://openwrt.org/ OpenWRT]) and then configure it.


==Step One: Install Buildroot==
At the end of this walkthrough, you'll be able to plug in your router and join the mesh. '''Note:''' In order to access the internet, you will likely need your own connection with an existing Internet Service Provider (ISP), or otherwise be located near [https://peoplesopen.net/map/ another mesh node with its own route to the internet].


The Buildroot is software which will creates your firmware. The Buildroot has feeds associated with it that allow you to add more to your firmware. The feeds are comparable to [https://en.wikipedia.org/wiki/Repository_%28version_control%29 repositories] in linux. There's a [http://wiki.openwrt.org/doc/howto/buildroot.exigence full guide] at OpenWRT, this is a shorter version.
= Prerequisites =


*Install svn and git.
This walkthrough assumes you're using linux or another unix-like operating system (such as Mac OS X, Ubuntu, FreeBSD, etc) and that you have [https://help.ubuntu.com/community/UsingTheTerminal basic knowledge of the command-line interface terminal] ('terminal' for short). [https://github.com/sudomesh/sudowrt-firmware/issues/new Contact us] if you can contribute instructions for other systems.
*: <code>$ sudo apt-get install subversion build-essential</code>
*: <code>$ sudo apt-get install git-core</code>
*Make a new directory and download the Buildroot.
*: <code>$ mkdir ~/openwrt</code>
*: <code>$ cd ~/openwrt</code>
*: <code>$ git clone git://git.openwrt.org/openwrt.git</code>
*Update Buildroot and install feeds.
*: <code>$ cd ~/openwrt/openwrtt</code>
*: <code>$ ./scripts/feeds update -a</code>
*: <code>$ ./scripts/feeds install -a</code> (if you want to install all feeds)
*Run the Buildroot
*: <code>$ make defconfig</code> (build list of dependencies)
*: <code>$ make prereq</code> (install dependencies)
*: <code>$ make menuconfig</code> (run the software)


If you're still missing software, then you'll have to manually install it.  
The general idea of building your own mesh node consists of three steps:
# [[#Download/Build|downloading or compiling]] the custom firmware
# [[#Flash/Upload|flashing that firmware]] to the node (i.e. copying firmware to [https://en.wikipedia.org/wiki/Flash_memory '''flash''' memory])
# [[#Configure|configuring the node]] to function as part of a mesh.


==Step Two: Install Feeds==
Before you flash your router, it is recommended that you read the [[Home and extender nodes#Home_nodes|home node info]] to ensure your router is compatible to work as a mesh node.


There are other feeds than the standard that you may want to be available to Buildroot. These are the suggested feeds for nodes: 
= Download/Build =


*Find the drivers for your device.  
Now that you have a node, you can flash it with the latest sudowrt-firmware. The first step is to download the firmware image file for your supported router. At the moment, we are supporting the following firmware builds:
*: Determine drivers for your router based on the chipset (ex. Atheros AR9331)
*: The open source driver for ''this example'' is [http://wireless.kernel.org/en/users/Drivers/ath9k Ath9k]. ([http://wireless.kernel.org/en/users/Drivers all drivers for linux])
*Install the driver feed.
*: <code>$ ./scripts/feeds install <PACKAGENAME></code> (ex. kmod-ath9k)


[http://wiki.openwrt.org/doc/howto/wireless.overview Other feeds for OpenWRT].  
{| class="wikitable"
! Name !! OpenWRT Doc !! Firmware Image
|-
| Western Digital MyNet N600 || [https://wiki.openwrt.org/toh/wd/n600 OpenWRT Docs] || '''[https://builds.sudomesh.org/sudowrt-firmware/0.3.0/ar71xx/openwrt-ar71xx-generic-mynet-n600-squashfs-factory-0.3.0.bin 0.3.0]''' [https://zenodo.org/record/1205601/files/openwrt-ar71xx-generic-mynet-n600-squashfs-factory.bin 0.2.3] [https://builds.sudomesh.org/sudowrt-firmware/0.2.2/ar71xx/openwrt-ar71xx-generic-mynet-n600-squashfs-factory.bin 0.2.2][https://builds.sudomesh.org/sudowrt-firmware/0.2.0/ar71xx/openwrt-ar71xx-generic-mynet-n600-squashfs-factory.bin 0.2.0]
|-
| Western Digital MyNet N750 || [https://wiki.openwrt.org/toh/wd/n750 OpenWRT Docs] ||
'''[https://zenodo.org/record/1205601/files/openwrt-ar71xx-generic-mynet-n750-squashfs-factory.bin latest]'''
[https://zenodo.org/record/1205601/files/openwrt-ar71xx-generic-mynet-n750-squashfs-factory.bin 0.2.3]
[https://builds.sudomesh.org/sudowrt-firmware/0.2.2/ar71xx/openwrt-ar71xx-generic-mynet-n750-squashfs-factory.bin 0.2.2][https://builds.sudomesh.org/sudowrt-firmware/0.2.0/ar71xx/openwrt-ar71xx-generic-mynet-n750-squashfs-factory.bin 0.2.0]
|-
| TP-Link WDR3500 || [https://wiki.openwrt.org/toh/tp-link/tl-wdr3500 OpenWRT Docs] ||
'''[https://zenodo.org/record/1205601/files/openwrt-ar71xx-generic-tl-wdr3500-v1-squashfs-factory.bin latest]'''
[https://zenodo.org/record/1205601/files/openwrt-ar71xx-generic-tl-wdr3500-v1-squashfs-factory.bin 0.2.3]
[https://builds.sudomesh.org/sudowrt-firmware/0.2.2/ar71xx/openwrt-ar71xx-generic-tl-wdr3500-v1-squashfs-factory.bin 0.2.2] [https://builds.sudomesh.org/sudowrt-firmware/0.2.0/ar71xx/openwrt-ar71xx-generic-tl-wdr3500-v1-squashfs-factory.bin 0.2.0]
|-
| TP-Link WDR3600 || [https://wiki.openwrt.org/toh/tp-link/tl-wdr3600 OpenWRT Docs] ||
'''[https://zenodo.org/record/1205601/files/openwrt-ar71xx-generic-tl-wdr3600-v1-squashfs-factory.bin latest]'''
[https://zenodo.org/record/1205601/files/openwrt-ar71xx-generic-tl-wdr3600-v1-squashfs-factory.bin 0.2.3]
[https://builds.sudomesh.org/sudowrt-firmware/0.2.2/ar71xx/openwrt-ar71xx-generic-tl-wdr3600-v1-squashfs-factory.bin 0.2.2][https://builds.sudomesh.org/sudowrt-firmware/0.2.0/ar71xx/openwrt-ar71xx-generic-tl-wdr3600-v1-squashfs-factory.bin 0.2.0]


==Step Three: Build the Firmware==
|-
| TP-Link WDR4300 || [https://wiki.openwrt.org/toh/tp-link/tl-wdr4300 OpenWRT Docs] ||
'''[https://zenodo.org/record/1205601/files/openwrt-ar71xx-generic-tl-wdr4300-v1-squashfs-factory.bin latest]'''
[https://zenodo.org/record/1205601/files/openwrt-ar71xx-generic-tl-wdr4300-v1-squashfs-factory.bin 0.2.3]
[https://builds.sudomesh.org/sudowrt-firmware/0.2.2/ar71xx/openwrt-ar71xx-generic-tl-wdr4300-v1-squashfs-factory.bin 0.2.2][https://builds.sudomesh.org/sudowrt-firmware/0.2.0/ar71xx/openwrt-ar71xx-generic-tl-wdr4300-v1-squashfs-factory.bin 0.2.0]
|-
|}


Builds for other routers can be found on our [http://builds.sudomesh.org/sudowrt-firmware/ builds server] or on [https://doi.org/10.5281/zenodo.1205601 zenodo], though most builds for routers not listed above have not been tested. For release notes, please go to our [https://github.com/sudomesh/sudowrt-firmware/releases github release pages].


=Installing OpenWRT=
Alternatively, you can build your own copy of the firmware images by following the guide in the [https://github.com/sudomesh/sudowrt-firmware sudowrt-firmware source].


Tested and working on:
If you do not want to use Sudo Mesh's OpenWRT image, you can also install [https://downloads.openwrt.org/ a standard OpenWRT] release and configure it from scratch, ([https://github.com/sudomesh/sudowrt-firmware read more on github]).
    *Bullet M5
    *Bullet 2 HP
    *Picostation 2 HP


==Step One: Reset the router==
= Flash/Upload =
*Press and hold the reset button while plugging in the powered ethernet cable.
*Keep holding the reset button. Look at the LED above the power LED.
*It will go from one green light, to two, the start flashing orange and red
*Release the reset button when it turns on the second time.


The Bullet will now be running a TFTP server 192.168.1.20
Once you have a copy of the sudowrt-firmware intended for your router, you can proceed with flashing it to your router. There are different techniques for flashing each of the routers. Use the links above to the OpenWRT wiki and follow the instructions there to flash the router with the firmware you've downloaded.


==Step Two: Configure your IP address==
For convenience, if you have a Western Digital MyNet N600 or N750, follow these instructions:
*Ensure that you have an IP address different from 192.168.1.20 and different from 192.168.1.1 in the 192.168.1.x range.
*You probably want to stop network-manager (not all distros use this, but Ubuntu does):
    sudo /etc/init.d/network-manager stop
*On most linux machines (assuming your ethernet interface is eth0) setting your ip address looks like this:
    sudo ifconfig eth0 192.168.1.12 netmask 255.255.255.0 up


==Step Three: Install OpenWRT on the router==
== Reset your new N750/N600 router ==
*Afterwards do the following:
[[File:Router_reset_mynet.png|200px|thumb|right|Reset hole location!]]
    tftp 192.168.1.20
Instructions to reset / default a WD MyNet N600 or N750 router:
    binary
* Plug one end of the Ethernet cable into your laptop.
    rexmt 1
* Plug the other end of the Ethernet cable into one of the normal ports (LAN) on the router (not the Internet/WAN port).
    timeout 60
* With the router plugged in and power turned off, push a pin / paperclip / tiny screwdriver into the reset hole and hold it for at least 15 seconds. Keep another hand free.  
    trace
* With the pin still held down, turn on the router power button.
    tftp> put firmwarefile.bin (see below)
* Watch the front blue light - they will flash on and off a few times.
* Once the front blue is flashing, you can let go of the pin.


Where firmwarefile.bin is the name of the firmware file you want to flash.
== Configure your computer's network settings ==
On your laptop edit your network settings to reflect the following:


Assuming you want to run Attitude Adjustment, the correct firmwares for tested routers are:
* Network Manager Method: Manual
* IP Address: <code>192.168.1.10</code> (some devices will only accept from this IP)
* Subnet Mask: <code>255.255.255.0</code>
* Gateway: <code>0.0.0.0</code> (Or leave blank)


Bullet M5: http://downloads.openwrt.org/attitude_adjustment/12.09/atheros/generic/openwrt-ar71xx-generic-ubnt-airrouter-squashfs-factory.bin
You can also use the commands:
  sudo ip link set <eth_interface> down
  sudo ip addr add 192.168.1.10/24 dev <eth_interface>
  sudo ip link set <eth_interface> up


Bullet 2 HP: http://downloads.openwrt.org/attitude_adjustment/12.09/atheros/generic/openwrt-atheros-ubnt2-squashfs.bin
where <code><eth_interface></code> is the name of your ethernet interface found using the <code>ip addr</code> command (common names include <code>eth0</code>, <code>enp3s0</code>, ...)


Picostation 2 HP: http://downloads.openwrt.org/attitude_adjustment/12.09/atheros/generic/openwrt-atheros-ubnt2-pico2-squashfs.bin
See Network Configuration Guides: [[Mesh/Network%20Configuration%20for%20Linux | Linux]], [[Mesh/Network%20Configuration%20for%20MacOS%20X | Mac]]


You will see a bunch of lines like this:
== Upload sudowrt-firmware ==
In your web browser:


sent DATA <block=13468, 512 bytes>
* Go to [http://192.168.1.1 http://192.168.1.1], if the reset was successful, you should see the following page:
received ACK <block=13468>
[[File:Screenshot from 2017-04-04 18-27-09.png|thumb|center|upright=2]]
* If your reset was not successful, try debugging your network configuration described in the previous step.
** If you continue to have issues consider reloading network settings or restarting your computer.
** If you are still unable to access this firmware upload page, turn off your router and try to reset it again as instructed above.
* Click 'Browse' and select the firmware file you downloaded
* Click Upload and you will be taken to an exciting countdown timer:
[[File:Screenshot from 2017-04-02 17-20-51.png|thumb|center|upright=2]]
* Make sure not to disconnect or lose power at this stage, wait for the timer to complete.


Once those lines stop coming, the router will take somewhere between 1 and 7 minutes to stop flashing its lights at you. DO NOT unplug or turn off the router until it presents two adjacent green LEDs and has done so for 10+ seconds. On the older routers the upgrade can take much longer than on the newer routers so be patient.
'''Note:''' Sometimes the firmware upload will not complete correctly. After you click on 'Upload' You should get a page with a countdown of 120+ seconds. If this does not occur, reboot the router with the pin reset button depressed (as noted above), and try again.


If you have a PicoStation running AirOS, you can use the following shell script to reflash it without needing to press the reset button:
= Configure =
#!/bin/sh -e
FIRMWARE=openwrt-atheros-ubnt2-pico2-squashfs.bin
#FIRMWARE='PicoStation2HP-v3.2.build3734.bin'
curl http://ubnt:ubnt@192.168.1.20/upgrade.cgi
curl -F fwfile=@"$FIRMWARE" http://ubnt:ubnt@192.168.1.20/upgrade.cgi
curl -F 'nil=nil' http://ubnt:ubnt@192.168.1.20/fwflash.cgi
echo "FLASHING IN PROGRESS - It will be complete when the system displays two solid green lights for ten seconds."


'''''If you are configuring something other than a WD MyNet N600, or firmware version 0.2.3 or earlier, follow ([[#Makenode_.28v.0.2.3_and_earlier.29|these instructions]])'''''


Note, that if you're flashing AirOS instead, at least the Bullet M5 series will remember setting between firmware upgrades and others may do so too. To reset username / password / ip address and other settings to factory default, first let the router boot, then press and hold the reset button until more lights come on and release. Wait for the factory reset to complete (a minute or two) and try to access 192.168.1.1 in a browser (ensure that your own IP is in the 192.168.1.x range). Note: This procedure seems to have no effect on the Bullet 2 HP, but works on the Bullet M5. It could be that the Bullet 2 HP does not persist settings across firmware upgrades, and so doesn't have the factory reset procedure. When flashing AirOS on the PicoStation, only one green light will be on when the flash is complete.
[[File:Nodeports titles.png|400px|thumb|right|Plug into port 3 to access the private network from your laptop. Port 2 connects to the public 'peoplesopen.net' network]]
# Connect your newly-flashed MyNet N600 to your existing Internet router via ethernet cable from your existing router's '''LAN port''' to your new node's '''Internet port'''.
# Wait several minutes for your new node autoconfigure, connect to the Internet, and obtain its private IP address from the sudo mesh build server. When this process is complete, the node should broadcast several WiFi networks with the following SSIDs and purposes:
#* <code>peoplesopen.net</code> - This is the public network broadcast on the 2.4ghz band; it has no password, and is suitable for access to the internet.
#* <code>peoplesopen.net fast</code> - This is the same public network, but broadcast on the 5ghz band, which is more ideal for high-bandwidth activities such as streaming media.
#* <code>peoplesopen.net-node2node</code> - This is the public network used for mesh nodes to discover and communicate with one another. You should not need to connect or use this network, but you will want to verify it is active.
#* <code>pplsopen-admin</code> This is the private network, and you can use it to access a web dashboard to configure some settings, such as its SSID. The default WiFi password is <code>meshtheworld</code>. Try connecting to it (you can also connect to the private network using an ethernet cable connected to '''port 3''' on an N600 -- see diagram for details).


==Windows Instructions==
Learn more about the [[Mesh/Network topology|network's topology here]].


from the directory where you stored the .bin file:
== Configuring the Web Dashboard ==


>tftp -i 192.168.1.20 PUT openwrt-atheros-ubnt2-squashfs.bin
While connected to the ''private'' network (default <code>pplsopen-admin</code>), try connecting to the home node's web dashboard by opening a web browser and navigating to [http://172.30.0.1 172.30.0.1]


Downloads within a minute, wait about 5 minutes to finish installing...
If the flash was successful you should be brought to the following screen:


=Installing BATMAN=
[[File:Peoplesopen-dash.jpg|frame|center|upright=2]]


For Bullet, first run the following commands to free up space:
The default password is <code>meshtheplanet</code>.
  ssh root@192.168.1.1
  opkg remove --force-removal-of-dependent-packages remove luci*
  exit


Here you can set the amount of downstream and upstream bandwidth you're willing to share on the public <code>peoplesopen.net</code> network (default is set to 4096kb, or roughly 4 megabits/second):


== Online ==
[[File:homeScreen.jpg|frame|center|upright=2]]


Use these instructions if your router is connected to the internet:
[[File:WifiSettings.jpg|frame|left|upright=2|Set your private SSID and password via the 'WIFi Settings' tab. NOTE: When you first set your private SSID name and hit 'Save', you will have to reconnect to the newly-named SSID using the original default password (<code>meshtheworld</code>) and then reconnect again with the new password after setting it in the dashboard]] [[File:newrouter.png|frame|right|upright=2|See all devices connected to your node via the 'Connections' tab]]
<br clear=all>


  ssh root@192.168.1.1
== Changing Admin and Root User Passwords ==
  opkg update
  opkg install kmod-batman-adv


== Manually / Offline ==
'''''Note: If you would like to be able to change the above wifi settings in the future, or ssh into your router, you will need to change the admin and root passwords within 12 hours.'''''


If your router does not have internet connectivity when installing, then use these instructions.
To do so, open a terminal while connected to the <code>pplsopen-admin</code> private network (or whatever new SSID you may have chosen):
    ssh root@172.30.0.1
Enter the following password: <code>meshtheplanet</code>


Download these packages from:
Set the root password.
    passwd
Now set the admin password for logging into the web dashboard:
    passwd admin


    http://downloads.openwrt.org/<openwrt_version_name>/<openwrt_version_number>/<chipset_name>/<type>/packages
== Testing ==


As of 7/31/13, download this: http://downloads.openwrt.org/attitude_adjustment/12.09/atheros/generic/packages/kmod-batman-adv_3.3.8%2b2012.3.0-3_atheros.ipk
After you're finished with the flashing and configuration, your home node should be available for connections via your private WiFi SSID (default <code>pplsopen-admin</code>). Additionally the public SSIDs <code>peoplesopen.net <your mesh IP></code> and <code>peoplesopen.net fast <your mesh IP></code> will be available. It should also be populated on the [https://peoplesopen.herokuapp.com monitor]!


and this: http://downloads.openwrt.org/attitude_adjustment/12.09/atheros/generic/packages/kmod-lib-crc16_3.3.8-1_atheros.ipk
A fourth interface named <code>pplsopen.net-node2node</code> will be detectable as well. This is the interface used for the nodes to mesh with each other.


Go to http://downloads.openwrt.org and browse to the correct directory. If there are multiple types, you probably want the 'generic' one, but check with the OpenWRT wiki page for your device to make sure.
At this point you're setup. Reach out to the [[Mesh#How_To_Participate|rest of the network]]!


These are the required packages:
== Makenode (v.0.2.3 and earlier) ==
'''''Note: If you installed autoconfiguring [https://github.com/sudomesh/sudowrt-firmware/releases/tag/0.3.0 release 0.3.0] for myNet N600 routers, you do not need to use makenode. See the autoconf instructions above.'''''


kmod-batman-adv_<version>_<chipset>.ipk
Makenode's documentation has been consolidated to [[Mesh/Makenode|its page.]]
kmod-lib-crc16_<version>_<chipset>.ipk


Use scp to copy them to the router:
= Flashing TP-Link Routers =
If you happen to come across a TP-Link router, such as a WDR4300, you may discover that the above instructions absolutely do not work. This is especially true if the router has previously been flashed with the sudowrt firmware (or any kind of OpenWRT or DD-WRT?). If you find yourself attempting to reflash a TP-Link router, you will first need to reset the router to its factory default firmware. Luckily, redconfetti has provided instructions on how to do this, http://www.rubycoloredglasses.com/2016/04/tp-link-wdr4300-recovery/ (TODO, test/update these instructions and copy them to this wiki)


scp kmod-*.ipk root@192.168.1.1:
Next, upload the sudort-firmware manually through the router's gui? Presumably, I haven't gotten that far yet...


Then ssh into the router and install them:
After that, makenode should just work right?


ssh root@192.168.1.1
There also exists something called tp-flasher, https://github.com/sudomesh/tp-flasher. However, it is highly recommended that you avoid using this because there is a very good chance you will brick your router if you use it incorrectly. Of course, we don't want to discourage anyone from improving tp-flasher.
opkg install kmod-*.ipk


=Configuring BATMAN=
These notes are valid for OpenWrt 12.09 (Attitude Adjustment), which uses BATMAN 2012.4.0. In newer versions, the version of BATMAN used is 2013.0.0 and the syntax for configuring BATMAN differs slightly. See [http://www.open-mesh.org/projects/batman-adv/wiki/Batman-adv-openwrt-config this page on open-mesh.org] for more info.


==Step One: Wireless Configuration ==
= Flashing Extender Nodes =


In /etc/config/wireless:
If you would like to make long distance point-to-point connections between two or more home nodes, you'll want to setup an extender node (a roof mounted antenna).


<pre>
See [[Mesh/Flashing extender nodes]]
config wifi-device 'radio0'
option type 'mac80211'
option hwmode '11g'
option channel '3'        # You may want another channel
option disabled '0'
option phy 'phy0'


# the interface where non-mesh nodes connect
[[Category:Mesh]]
config wifi-iface
option device 'radio0'
option ifname 'ap0'
option encryption 'none'
option network 'lan'
option mode 'ap'
option ssid 'sudomesh'  # You should change the ssid to be unique for dev purposes


# the mesh interface
= Troubleshooting =
config wifi-iface
option device 'radio0'
option ifname 'adhoc0'
option encryption 'none'
option network 'mesh'
option mode 'adhoc'
option bssid 'CA:FE:C0:DE:F0:0D' # You should change this to be unique for development purposes, but for meshing this should be the same for all routers on the mesh
option ssid 'sudomesh-backchannel' # You should change the ssid to be unique for development purposes, but for meshing this should be the same for all routers on the mesh
</pre>


Write some of this stuff down for reference later! You might need it!
== Soldering A Reset Button ==


==Step Two: Network Configuration ==
As you are resetting routers, you may end up having a component, such as the reset button itself, fall off of the PCB (printed circuit board). The WD MyNet n600 has security screws, so you may need a [https://www.google.com/search?hl=en&ei=Zz30XZ-iLurJ0PEP8Mq90As&q=site%3Aaliexpress.com+torx+t10+security+bit&oq=site%3Aaliexpress.com+torx+t10+security+bit&gs_l=psy-ab.3...15707.23122..23261...0.0..2.605.6423.23j13j6j1j1j1......0....1..gws-wiz.......0i273j0j0i131j0i67.SQrobDcWg6U&ved=0ahUKEwjf8eHvgLTmAhXqJDQIHXBlD7oQ4dUDCAs&uact=5 Torx T10 Security Bit] to remove the case.


In /etc/config/network:
<gallery mode="traditional">
 
File:Wd_n600_naked_board.jpg|WD MyNet n600 naked (without case)
<pre>
File:Wd_n600_reset_button_resolder.jpg|WD MyNet n600 resolder of the reset button that fell off
config interface 'loopback'
</gallery>
option ifname 'lo'
option proto 'static'
option ipaddr '127.0.0.1'
option netmask '255.0.0.0'
 
# set up ethernet bridging between eth0 and bat0
# this means that packets can move between the ethernet port
# and the wifi mesh
config interface 'lan'
option type 'bridge'
option proto 'static'
option ipaddr '10.42.10.11' # this should be a unique IP
option netmask '255.255.0.0'
option dns '208.67.222.222'
option gateway '192.168.1.1' # an internet gateway, not sure how to deal with multiple gateways yet
option ifname 'eth0 bat0'
 
# the mesh interface
config interface 'mesh'
option ifname 'adhoc0'
option proto 'none'
option mtu '1528'
</pre>
 
==Step Three: BATMAN Configuration ==
 
In /etc/config/batman-adv:
 
<pre>
config mesh 'bat0'
option interfaces 'adhoc0' # the interface for which to enable batman0
option 'aggregated_ogms' # no idea what this means
option 'ap_isolation' # no idea what this means
</pre>
 
==Step Four: System Configuration ==
 
In /etc/config/system you can set hostname and timezone. This is not strictly necessary for BATMAN to work, but it should be set correctly. The below timezone is correct for the pacific U.S. timezone. The naming convention for hostnames is: <router-model-name>-<some-unique-name-you-choose>
 
<pre>
config system
option hostname tl-wr703n-foo
option timezone PST8PDT,M3.2.0,M11.1.0
</pre>
 
 
You may also have to turn off dnsmasq. (someone else can chime in if this contradicts their working knowledge)
 
<pre>
/etc/init.d/dnsmasq disable
</pre>
 
==Step Five: Testing ==
 
You should see the 'sudomesh' and 'sudomesh-backchannel' wifi interfaces when running `sudo iwlist wlan0 scan`