--- a/src/routing/click/click.h Tue Jul 06 19:57:09 2010 +0530
+++ b/src/routing/click/click.h Wed Jul 07 14:17:09 2010 +0530
@@ -37,11 +37,68 @@
* Ipv4L3Protocol. Ipv4L3ClickProtocol passes on packets passing through
* the stack to Ipv4ClickRouting for processing.
*
-* \section api API and General Usage
+* \section build Build Instructions
+*
+* The first step is to build Click. At the top of your Click source directory:
+*
+* $: ./configure --enable-userlevel --disable-linuxmodule --enable-nsclick
+* $: make
+*
+* *Note: You don't need to do a 'make install'.
+*
+* Once Click has been built successfully, we proceed to configure ns-3 with
+* Click Integration support:
+*
+* $: ./waf configure --with-nsclick=/path/to/click/source
+*
+* If it says 'enabled' beside 'NS-3 Click Integration Support', then you're
+* good to go.
+*
+* Next, try running one of the examples:
+*
+* $: ./waf --run nsclick-simple-lan
+*
+* You will find a lot of output being generated. This is because of the
+* IPPrint and Print elements present in the nsclick-simple-lan.click
+* configuration file that the example script uses.
+*
+* \section clickgraph Click Graph Instructions
*
-* See the examples scripts inside examples/click/ to get an idea of
-* how Click is to be used.
+* The following should be kept in mind when making your Click graph:
+* - Only userlevel elements can be used.
+* - You will need to replace FromDevice and ToDevice elements
+* with FromSimDevice and ToSimDevice elements.
+* - Packets to the kernel are sent up using ToSimDevice(tap0,IP).
+* - For any node, the 0th device will be tap0. The remaining devices
+* should be eth0, eth1 and so forth (even if you're using wifi).
+* Please note that the device numbering should begin from 0.
+* - A routing table element is a mandatory. The OUTports of the routing
+* table element should correspond to the interface number of the device
+* through which the packet will ultimately be sent out. Violating this
+* rule will lead to really weird packet traces. This routing table element's
+* name should then be passed to the Ipv4ClickRouting protocol object as
+* a simulation parameter. See the Click examples for details.
+* - When using Wifi with ns-3-click, do not use wifi specific elements like
+* WifiEncap, ExtraEncap, MadWifiRate etc. for outgoing packets. Incoming
+* packets should have their Wifi headers removed using WifiDecap + ExtraDecap
+* or Strip elements. See the nsclick-raw-wlan.click file for an idea of the same.
+* - The current implementation leaves Click with mainly L3 functionality,
+* with ns-3 handling L2. We will soon begin working to support the use of
+* MAC protocols on Click as well.
*
+* \section usage Usage
+*
+* To have a node run Click, the easiest way would be to use the ClickInternetStackHelper
+* class in your simulation script. For instance:
+*
+* ClickInternetStackHelper click;
+* click.SetClickFile (myNodeContainer, "nsclick-simple-lan.click");
+* click.SetRoutingTableElement (myNodeContainer, "u/rt");
+* click.Install (myNodeContainer);
*
+* The example scripts inside examples/click/ demonstrate the use of Click based
+* nodes in different scenarios.
+*
+*
*/