BRN-Development: Difference between revisions
Jump to navigation
Jump to search
No edit summary |
|||
(9 intermediate revisions by 4 users not shown) | |||
Line 1: | Line 1: | ||
===Source Download=== |
|||
All source code could be obtained from [http://sarforge.informatik.hu-berlin.de/projects/berlinroofnet/ SarForge]. |
|||
===Quick Startup=== |
===Quick Startup=== |
||
To easiest way to run a BRN meshnode is to use a modified Netgear WGT634 [[Hacking_the_Netgear_wgt634u|Netgear]] router preloaded with the [http://openwrt.org/ OpenWRT] linux distribution. |
To easiest way to run a BRN meshnode is to use a modified Netgear WGT634 [[Hacking_the_Netgear_wgt634u|Netgear]] router preloaded with the [http://openwrt.org/ OpenWRT] linux distribution. |
||
Line 6: | Line 10: | ||
wget http://sarwiki.informatik.hu-berlin.de/~mj/berlinroofnet-20061115.ipk |
wget http://sarwiki.informatik.hu-berlin.de/~mj/berlinroofnet-20061115.ipk |
||
Installing BRN is quite simple: |
Installing BRN is quite simple: |
||
ipkg install berlinroofnet-20061115.ipk |
|||
Now reboot your BRN meshnode and enjoy .... |
Now reboot your BRN meshnode and enjoy .... |
||
===Development=== |
===Development=== |
||
==== <math>\Rightarrow</math> For Netgear WGT634U ==== |
|||
tbd.: getting brn sources and building ... |
|||
# '''Install''' a prepared '''image''' file as described [[BRN:Software:OpenWrt_Installation|here]]. Take an image from {{SERVER}}/~mj/openwrt/images/ |
|||
# '''Build''' your '''toolchain''' (from OpenWrt sources) and '''berlinroofnet''' ipkg package -- pay attention to the right OpenWrt revision you are using on your router (e.g. 6945) |
|||
## Checkout sources <pre>svn co https://svn.openwrt.org/openwrt/trunk Kamikaze -r 6945</pre> |
|||
## (optional) Get the relating config file for OpenWrt:<pre>wget http://sarwiki.informatik.hu-berlin.de/~mj/openwrt/images/2007-04-13/Kamikaze-config -O Kamikaze/.config</pre> |
|||
## Check out package description for berlinroofnet<pre>svn co https://sarforge.informatik.hu-berlin.de/svn/brn-core/BerlinRoofNet/trunk/click/ipkg/ Kamikaze/package/berlinroofnet</pre> |
|||
## Select berlinroofnet package to be built (Network -> berlinroofnet <M>):<pre><nowiki>cd Kamikaze |
|||
make menuconfig</nowiki></pre> |
|||
## Build: <pre>make</pre> |
|||
# '''Install''' berlinroofnet ipkg package:<pre><nowiki>scp bin/packages/berlinroofnet*.ipk bin/packages/libstdcpp*.ipk wgt01.sar.informatik.hu-berlin.de:/tmp # (at your development machine) |
|||
ipkg install /tmp/berlinroofnet*.ipk /tmp/libstdcpp*.ipk # (at your router wgt01) |
|||
</nowiki></pre> |
|||
==== <math>\Rightarrow</math> For x86 desktop machine ==== |
|||
==== General comments about click ==== |
|||
* Headers accessible through annotations should always be allocated '''inside''' a packet's data (for example via push_mac_header()). Like this they get freed when the packet is killed, thus avoiding memory leaks. Yet more important is that any other tricks - for example referencing to another packet's ethernet header via annotation - lead to nasty and hard to find memory management errors. Align elements for example may shift the header annotations along with the other data of the packet which would lead to invalid addresses. Align, however is only needed on some architectures which makes detecting these things a real pain. |
|||
* Most operations on a packets that return another packet may or may not kill the original one. Examples are push(), put(). '''Never''' touch the original packet after that. |
|||
==== See also ==== |
|||
* [[Hacking_the_Netgear_wgt634u|Hacking Netgear 634u]] |
|||
* [[BRN:Software:Build_and_Distribution:Userland_Debugging|Debugging BRN]] |
|||
* [[BRN:Software:Build_and_Distribution]] |
|||
===Bug-Tracking=== |
===Bug-Tracking=== |
Latest revision as of 18:00, 25 February 2008
Source Download
All source code could be obtained from SarForge.
Quick Startup
To easiest way to run a BRN meshnode is to use a modified Netgear WGT634 Netgear router preloaded with the OpenWRT linux distribution. You can also use our OpenWRT image BRN Base Image:
wget http://sarwiki.informatik.hu-berlin.de/~mj/openwrt-wgt634u-2.6-squashfs-20061115.bin
Thereafter you need to download the BRN software package BRN package:
wget http://sarwiki.informatik.hu-berlin.de/~mj/berlinroofnet-20061115.ipk
Installing BRN is quite simple:
ipkg install berlinroofnet-20061115.ipk
Now reboot your BRN meshnode and enjoy ....
Development
For Netgear WGT634U
- Install a prepared image file as described here. Take an image from https://sarwiki.informatik.hu-berlin.de/~mj/openwrt/images/
- Build your toolchain (from OpenWrt sources) and berlinroofnet ipkg package -- pay attention to the right OpenWrt revision you are using on your router (e.g. 6945)
- Checkout sources
svn co https://svn.openwrt.org/openwrt/trunk Kamikaze -r 6945
- (optional) Get the relating config file for OpenWrt:
wget http://sarwiki.informatik.hu-berlin.de/~mj/openwrt/images/2007-04-13/Kamikaze-config -O Kamikaze/.config
- Check out package description for berlinroofnet
svn co https://sarforge.informatik.hu-berlin.de/svn/brn-core/BerlinRoofNet/trunk/click/ipkg/ Kamikaze/package/berlinroofnet
- Select berlinroofnet package to be built (Network -> berlinroofnet <M>):
cd Kamikaze
- Checkout sources
make menuconfig
- Build:
make
- Build:
- Install berlinroofnet ipkg package:
scp bin/packages/berlinroofnet*.ipk bin/packages/libstdcpp*.ipk wgt01.sar.informatik.hu-berlin.de:/tmp # (at your development machine)
ipkg install /tmp/berlinroofnet*.ipk /tmp/libstdcpp*.ipk # (at your router wgt01)
For x86 desktop machine
General comments about click
- Headers accessible through annotations should always be allocated inside a packet's data (for example via push_mac_header()). Like this they get freed when the packet is killed, thus avoiding memory leaks. Yet more important is that any other tricks - for example referencing to another packet's ethernet header via annotation - lead to nasty and hard to find memory management errors. Align elements for example may shift the header annotations along with the other data of the packet which would lead to invalid addresses. Align, however is only needed on some architectures which makes detecting these things a real pain.
- Most operations on a packets that return another packet may or may not kill the original one. Examples are push(), put(). Never touch the original packet after that.
See also
Bug-Tracking
- Mantis [1]]
Other
- Click-Tutorials [2]