Code Search for Developers
 
 
  

invalidate.sh from EmStar at Krugle


Show invalidate.sh syntax highlighted

#!/bin/bash

CHIRP_DEVICE=""
if [ x != x$SIM_ID ]; then
    CHIRP_DEVICE=/dev/sim/group$SIM_GROUP/node0$SIM_ID/loc/trigger_chirp
    if [ $SIM_ID != "40" ]; then
    	if [ $SIM_ID != "16" ]; then
		if [ $SIM_ID != "33" ] ; then
			exit 0
		fi
	fi
    fi
else
    CHIRP_DEVICE=/dev/loc/trigger_chirp
fi



MY_RAND=
# $(( ( $RANDOM % 1200 ) + 600 )) 
if [ $SIM_ID == "40" ]; then
	MY_RAND=600
fi
if [ $SIM_ID == "16" ]; then
	MY_RAND=1500
fi
if [ $SIM_ID == "33" ]; then
	MY_RAND=2700
fi



echo "Sleeping for $MY_RAND seconds then invalidating $CHIRP_DEVICE"

sleep $MY_RAND

echo "Invalidating..."
echo inval > $CHIRP_DEVICE

# emrun will restart us!




See more files for this project here

EmStar

EmStar is a software system for developing and deploying wireless sensor networks involving Linux-based platforms. As the wireless sensor network community has attempted to deploy more complex designs---large-scale, long-lived systems that need self-organization and adaptivity---a number of difficult software design issues have arisen. Advances in software design have not kept pace with the capabilities of hardware. This is because designing for an adaptive, efficient, and useful sensor network has turned out to be surprisingly complex and difficult. EmStar is a Linux-based software framework, whose goal is to dramatically reduce this complexity, enabling work to be shared and reused, and simplifying and speeding the design of new sensor network applications.

Project homepage: http://cvs.cens.ucla.edu/emstar/
Programming language(s): C,Shell Script
License: other

  test/
    gen_gnuplot.sh
    multilat_generator.c
  coord_guess.c
  invalidate.sh
  loc_test.m
  multilat.c
  multilat_i.h
  multilat_main.c
  result.c