This project contains Application to test light sensor
The application is related to Question 5 in HW1, which requires mote
synchronization using the light sensor.

The Blinking mote blinks RED led at a certain frequency and the other Light
Sensing mote senses the light from the LED of the Blinking Mote and sets its
own RED led, when it sensed the light otherwise clears the RED led.

Same application can be used for Blinking Mote and Light Sensing Mote.

The Blinking mote has a periodic task, which  toggles RED led in each cycle.

The Light Sensing mote has a periodic task, which senses the light
using light sensor  in each cycle. In few initial cycles, the readings from
the light sensor are used to obtain base value. From then, If light
sensor reading is above  threshold compared to base value, which happens
when the light from RED led of Blinking mote falls into its own sensor,
it sets the RED led otherwise clears the  RED led.

Also UserButton functionilty is embedded into the application, so 
that when the UserButton is pressed, it stops the functionality of
Blinking mote which stops blinking the RED led. When the Userbutton is pressed again
the Blinking mote starts blinking RED led again.

How to test
-----------

Light Sensing Mote:

step 1: update makefile to contain NODE_ADDR =1

step 2: make clean; make program

Blinking Mote:

step 1: update makefile to contain NODE_ADDR =2

step 2: make clean; make program



Note:
1) While loading the program into Light Sensing mote, the other mote(powered down)
should be placed above the light sensing mote, so that the Light sensing mote
configures the base light reading.

2) Makefile may need to be updated to change /devttyUSB0 or /dev/ttyUSB1
as needed to select the mote on which application needs to be loaded.


