Changes between Version 1 and Version 2 of Old/TinyOS/How


Ignore:
Timestamp:
Dec 23, 2008, 9:29:48 PM (16 years ago)
Author:
tripti
Comment:

Legend:

Unmodified
Added
Removed
Modified
  • Old/TinyOS/How

    v1 v2  
    11== How to Work with TinyOS ==
    22
     3This page shows how to compile a TinyOS program and install it on mote.
     4
     5Typing '' motelist '' will display which nodes are currently plugged in:
     6
     7{{{
     8
     9node1-2:~# motelist
     10Reference  Device           Description
     11---------- ---------------- ---------------------------------------------
     12XBON3L3C   /dev/ttyUSB0     XBOW Crossbow Telos Rev.B
     13
     14}}}
     15
     16
    317== Compiling and Installing ==
     18
     19We compile TinyOS applications with the program '' make ''
     20The make command to compile a TinyOS application is make [platform], executed from the application's directory.
     21
     22For example:
     23To compile Blink, go the apps/Blink directory and depending on which hardware you have, type make micaz, make mica2, make telosb, or, for simulation, type make micaz sim.
     24
     25The output looks like
     26
     27    {{{
     28node1-2:/opt/tinyos-2.1.0/apps/Blink# make telosb
     29mkdir -p build/telosb
     30    compiling BlinkAppC to a telosb binary
     31ncc -o build/telosb/main.exe  -Os -O -mdisable-hwmul -Wall -Wshadow -Wnesc-all -target=telosb -fnesc-cfile=build/telosb/app.c -board= -DDEFINED_TOS_AM_GROUP=0x22 -DIDENT_APPNAME=\"BlinkAppC\" -DIDENT_USERNAME=\"root\" -DIDENT_HOSTNAME=\"node1-2.sb7.orb\" -DIDENT_USERHASH=0xabf5e143L -DIDENT_TIMESTAMP=0x495155d8L -DIDENT_UIDHASH=0xde29f8c9L  BlinkAppC.nc -lm
     32    compiled BlinkAppC to build/telosb/main.exe
     33            2650 bytes in ROM
     34              55 bytes in RAM
     35msp430-objcopy --output-target=ihex build/telosb/main.exe build/telosb/main.ihex
     36    writing TOS image
     37node1-2:/opt/tinyos-2.1.0/apps/Blink#
     38
     39    }}}
     40