The current setup for the sensor network consists of two sensor nodes, one controller node, one sink node as well as a border router. In order to use them, some prerequisites have to be met.
The implementation of all network parts is based on the component-based, extensible, tiny operating system for wireless networks (CometOS) which implies that in order to build the components, a working installation of OMNet++ is required as well as all contents of the repositories CometOS and CometOSv6.
CometOSv6 is an addition to CometOS and is also needed for the sensor network, the corresponding repository can be found at:
After checking out the project please adjust OMNet++ and CometOS according to these instructions.
In order to flash the programs to the boards, it is necessary to install further programs. These are the AVR8 toolchain and the AVRDude. Notes on which version to choose and how to install can be found at: [Outdated] Current Ubuntu version's (15.04+) gcc-avr toolchain support ATmega256RFR2
In general Python is supported on Ubuntu by default. If this is not the case for your machine, please install the corresponding package (currently python 2.7).
The next step depends on the routing protocol to be used. Currently there is the choice between static routing and RPL routing. Please use RPL.
To use static routing the next step is to publish the routing to the nodes. For this purpose modify the staticRouting.xml located in <cometos_v6>/platform/pyBaseStationMedical/ to match the boards at hand (notes about the staticRouting.xml can be found at: Addressing) and build the prgram with the command:
Then make sure every board is connected to a power source and the sink node is connected to a serial port(USB) of your computer and execute the python bs-script with the command:
python -i bs.py <tcp-port> staticRouting.xml
where <tcp-port> is the Port number the Borderrouter has open. (The default is Port 20000.)
To make sure that all nodes are working and responding, it is recommended to use checkPin() in the python terminal to check whether all nodes respond.(Note: in this case, SimpleRouting is used for communication between all nodes.)
If this is the case, the command ex.setup() can be executed to supply the static routes to all nodes.
Exit the terminal with stop() or quit().
Instead there is the possibility to use RPL routing. In order to do that certain flags in the makefiles of the corresponding nodes have to be set.
A mandatory flag to enable RPL routing is:
FLAGS += -DCOMETOS_V6_RPL
Further optional flags connected to RPL are:
#FLAGS += -DRPL_AUTHENTICATION_ENABLE #FLAGS += -DCOMETOS_V6_RPL_MRHOF #FLAGS += -DCOMETOS_V6_RPL_MRHOF_ETX
configuring RPL to force authentication, to use MRHOF as objective function and to use the ETX metric with MRHOF as objective function.
How to use the border router can be found at Using the Border Router.
So far all boards were flashed and the border router was setup. In case of static routing the basic sink node program was supplied with the static routes. In order to make sure that everything works as intended, it is recommended to test the whole setup by pinging each node once. To do that connect the nodes according to the staticRouting.xml with a power source/the computer and start the border router. Now ping every node once with the command:
ping6 <ipv6 address of node>
, for example
for a border router with the IP-Prefix 64:29:30:31:: and a node with the MAC address 3011.