WSN sensor daemon and supporting utilities
Switch branches/tags
Nothing to show
Clone or download
Pull request Compare This branch is 10 commits ahead, 119 commits behind herjulf:master.
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
doc
js/ui-flot
seltag
sensd
Makefile
README
sendItAway.sh

README

Taken from: https://github.com/herjulf/sensd

A small modification is made to send away the taken data via
another application. Current solution is only temporary, 
since calling a bash script is not the best solution. 
But it works for the purpose.

Project migrated from:
http://code.google.com/p/kth-wsn-longrange-radio-uplink/

For more information:
http://alpsayin.com/

              WSN sensor daemon and supporting utilities
              ------------------------------------------

Authors
--------					
Robert Olsson <robert@herjulf.se>
Jens Laas <jens.laas@uadm.uu.se>

Abstract
--------
We've outlined, designed and implemented and very simple concept for WSN data
reports, including collection, storage and retrieval using standard text tools.
The concept includes a mapping to URI (Unified Resource Identifier) to form
a WSN caching server similar to CoAP with http-proxy.

All programs are written C, Java-script and bash. And designed for for small
footprint and minimal dependencies. sensd runs on Raspberry Pi and openwrt.

Copyright
---------
GPL

Introduction
------------

This is collection of software to implement data monitoring and data collection
from WSN Wireless Sensor Networks. The basic idea is to do a very simple, 
straight-forward and robust framework.

The scenario, One or several mots is connected to USB or serial port to gather 
received information from connected WSN motes. Data can can visualized in two
ways.

1) Data is stored in ASCII with tagging and ID information. Data is conviently 
   handled, copied and viewed with standard text utilties of your OS.

2) Last mote report is cached into the file system suitable for URI use. The 
   Format is SID/TAG. The different TAGS are left for mote user to define.
   Although the TAGS used in our example setup is included is this draft 
   This for example purposes.
   
 
Both formats can easily the be stored or linked directly in web tree to form a 
URI to format WSN loggin/datafile or caching service..


The major components
--------------------

 sensd -- A daemon that reads WSN mote reports from USB/serial and stores 
          data in a ASCII data file. Usually sensors.dat

 js -- A set of Java-scripts can plot, print and visualize sensor data
           from sensd direct in your web-browser.

 seltag -- simple program that can extract data via tags and format 
           output for plottling and further analysis. Ie gnuplot.

 doc -- Documentation and sample files

Expose WSN data aternatives:


1) Datafile logging. 
--------------------

Below is and example of an anatomy of sensors.dat we currently using in our WSN 
data collection networks. 

2012-05-22 14:07:46 UT=1337688466 ID=283c0cdd030000d7 PS=0 T=30.56  T_MCU=34.6  V_MCU=3.08 UP=2C15C V_IN=4.66 

2012-05-22 14:11:41 UT=1337688701 ID=28a9d5dc030000af PS=0 T=36.00  V_MCU=2.92 UP=12C8A0 RH=42.0 V_IN=4.13  V_A1=3.43  [ADDR=0.175 SEQ=33 RSSI=21 LQI=255 DRP=1.00]

Each line is a mote report. Starting with date and time followd by a set of
tags. The tags is different for different motes. In other words thay can 
send different data. Essential is the ID which should be unigue for each mote.. 

The information with brackets is information generated by the receiving mote
and is not a part the motes data. Typically RSSI (Receiver Signal Strength
Indicator) and LQI (Link Quality Indicator)

The tags used in example above:

   UT= Unix time
   ID= Unique 64 bit ID
   T= temp in Celcius
   PS= Power Save Indicator
   V_MCU= Microcontorller Voltage
   UP= Uptime (HEX)
   RH= Relative Humidity in %
   V_IN= Voltage Input
   V_A1= Voltage Analog 1 (A1)
   RSSI= Reeiver Signal Strengh Indicator
   LQI= Link Quality Indicator
   SEQ= Sequental Number (packet)   
   DRP= Drop Probability (Contiki)
   ADDR= 

2) URI format. 
--------------
URI (Unified Resource Indenifier) displays the node ID and the tags in a file tree.
It is easy to export this into a web tree to form a URI similar to CoAP gateway.

Example: In our case we have a unique sensor ID followed by the different data
fields repesented by "tags".

/tmp/WSN1-GW1/281a98d20200004a:
DRP  ID  LQI  PS  RH  RSSI  SEQ  T  V_IN  V_MCU  ADDR

/tmp/WSN1-GW1/28be51ce02000031:
DRP  ID  LQI  PS  RH  RSSI  SEQ  T  UP  V_IN  V_MCU  ADDR


Read Temp from a sensor:
cat /tmp/WSN1-GW1/281a98d20200004a/T 
19.44

And very easy to link this tree into web-server.


Getting the source and building
-------------------------------
Code is stored in github. Typically procedure below is the very straight-
forward unix way:

git clone http://github.com/herjulf/sensd
cd sensd
make

Put your binaries after your preference:

Pre-built binary versions
--------------------------

For x86:
Sensd and friends are available in Bifrost/Linux packages. Those packages are
statically linked and can be used on most x86 Linuxes. 32-bit compiled.

http://ftp.sunet.se/pub/Linux/distributions/bifrost/download/opt/opt-sensd-2.3-1.tar.gz


Testing
-------
The WSN data logging and caching concept has been tested with Contiki, RIME 
broadcast application.