Home My Page Projects Contiki for Senslab nodes
Summary Activity Tracker Lists SCM Mediawiki

InriaForge

Main Page

From Contiki for Senslab nodes Wiki
Jump to: navigation, search

Contents

Contiki for Senslab nodes

This repository contains two branches.

  • The "master" branch from the official Contiki repository
  • A "wsn430" branch that contain drivers and platform definitions for the Senslab nodes

The two variants of the Senslab nodes are supported.

  • v1.3b using the CC1100 Radio Chip (sub-1GHz, open MAC)
  • v1.4 using the CC2420 Radio Chip (2.4GHz, 802.15.4 MAC)

To switch between the variants, simply define "WITH_CC1100" or "WITH_CC2420" in "platform/wsn430/Makefile.wsn430".

Contiki: http://www.contiki-os.org/

Senslab: http://www.senslab.info/

Current Status

The Senslab nodes have a lot of hardware similarities with the Tmote Sky node, so its platform definition was chosen as the starting point of our work.

Worked out of the box

  • MSP430F1611 uC (including internal Temperature and Battery Sensors)
  • CC2420 Radio Chip
  • Serial Number Chip (DS2411)
  • Flash Chip (M25P80)
  • LEDs

Changes made

  • SPI bus driver and UART driver — these are reversed, compared to the Tmote Sky (USART0 is UART, USART1 is SPI); I just copied the existing ones and renamed the referenced registers
  • CC1100 Radio Chip — written from scratch using the datasheet; like the RF230 driver, it uses an internal buffer as the hardware FIFO is only 64 bytes
  • Radio Sensors — uses radio driver functions; CC2420 one already exists for platform sky, CC1100 was easy to derive from CC2420 one

Not yet supported

  • 8Mhz Xtal — clock usage must be double-checked; for instance, the MSP430 UART driver currently only supports frequencies of 3900000 Hz and 2457600 Hz
  • Light Sensor (TSL2550T) — uses SMBus on USART0, needs a SMBus/I2C bus driver, and concurrent access to UART (also on USART0) must be handled
  • Temperature Sensor (DS1722S) — uses the SPI bus
  • Microphone (KEEG1540) — uses an ADC input

Setting up a Repository

To setup a repository, if you haven't done so already, you first need to clone the Contiki repository

git clone git://contiki.git.sourceforge.net/gitroot/contiki/contiki

Then, add the Contiki-Senslab as a remote repository, and fetch it

cd contiki
git remote add contiki-senslab https://gforge.inria.fr/git/contiki-senslab/contiki-senslab.git
git fetch contiki-senslab
git checkout -t contiki-senslab/wsn430

If you have issues with the server certificate verification while fetching the repo, you can just issue the following command and retry

git config http.sslVerify false

To work with the latest changes made to contiki, just merge them

git fetch --all
git checkout master
git merge origin/master
git checkout wsn430
git merge master

("git fetch" and the first "git merge" might be replaced by a simple "git pull", not sure though)

Changesets of Interest

As the goal is to eventually have support for the Senslab nodes merged back into Contiki's official development tree, here is a list of the important changesets.

  • Commit fa578af2eaec fixes an alignment bug in cxmac.c (https://sourceforge.net/tracker/?func=detail&aid=3383721&group_id=42303&atid=432701) (was later fixed by 076c208b7264)
  • Commit aa9cdc931391 adds a DEBUG_LEDS preprocessor macro to cxmac.c
  • Commit 94769a1c20bf adds the CC1100 driver
  • Commit b9150a5e67bb adds the wsn430 platform
  • Commit f093d8628ff5 fixes a CC1100 bug
  • Commit f47d0fddf96e adds internal temperature and battery sensors to the wsn430 platform