TOSSIM simulator is a final year projects for specks via conceptualizing hardware function and software modeling. We comprise also a sensor network with large number of small hardware devices.  Our Tos-sim simulator projects in which detention on the network topics.

What is TOS-SIM:

  • Tossim is also a type of simulator used in TINY OS.
  • Directly compile from Tiny OS.
  • It has also an extensible network
  • Simultaneously tossim simulate thousands of nodes.
  • Also in TOS-SIM is a library

Features of TOSSIM:

  • TOSSIM uses two interfaces which are,
    • C++
    • and also a Python
  • Simulate MicaZ mote.
  • To model radio noise it uses CPM (Closest-fit Pattern Matching).


Other TOS-SIM Features:

  • Injecting packets
  • Also Inspecting internal variables
  • C++ interface
  • And also Debugging using gdb


  • A TinyViz plugin is a software module
  • It watches for events coming from the simulation
  • The main plugins likely to use are:
    • Debug messages
    • Set breakpoint
    • ADC readings
    • Sent radio packets
    • Radio links
    • Set location
    • and also Radio model

Radio interfaces:

  • Tiny OS provide direct access to the radio through several interfaces which includes:
    • Packet
    • Send
    • Receive
    • PacketAcknowledgements
  • Tiny OS provide Active Message (AM) layer to multiple access to the radio

AM layer:

  • AM layers are similar function to Ethernet frame type.
  • we also in AM layer also includes destination field.
  • and also in It stores the AM Address


from TOSSIM import *

import sys, os, getopt


optNumNodes = __NUM_NODES__

optLowRadioFidelity = True

ONE_SECOND = 10000000000

def usage():

print ‘Usage: [-options]’

print ‘\t\tto run the Tossim simulation.\n’

print ‘where options include:’

print ‘-h, –help\tdisplay this message’

print ‘–duration <t> in seconds\n\tdefault: ‘ + str(optSimDuration)

print ‘–num-nodes <n>\n\tdefault: ‘ + str(optNumNodes)

print ‘–low-radio-fidelity [true|false]\n\tdefault:’ + str(optLowRadioFidelity) + ” (set to true for faster simulations)”

#Converts a string to boolean based on the value of the first character.

def convertBool(text):

if text == ”:

return False

if text[0] in (‘T’,’t’):

return True

if text[0] in (‘F’,’f’):

return False

print ‘Cannot convert “‘+text+'” to boolean value’