Pope lights Christmas Tree 130 miles away

On Dec 7 2011, Pope Benedict touched the screen of a Sony Android Tablet to transmit the command to switch on the electric current to the Christmas tree, a 2,132-foot-high lighting display on Mount Ingino above the Italian town of Gubbio, which is 130 miles away. Using the LEDs of the Bluetooth DAQ Starter Kit to simulate the Christmas lights, provide a solution which allows someone with the correct SMS code to turn on and off the LEDs even if he is miles away.


Program I: Receive an SMS check message for code

  1. Observe and understand the Receive SMS Program
  2. Modify the program to use a while loop to check for correct SMS code. Include a time delay.
  3. Exit loop and end program when correct SMS code is received.
  4. Use the Android SMS app to delete the SMSes before running the program again.

Program II: Turn On/Off LED

  1. Observe and understand Turn on and off the LEDs bitwise program

Program III: Solution

Combine Program II and Program I to obtain your solution to the problem

If you are using the emulator, you will need RemoteControl as you will be using the bluetooth connection on your PC and the android services in the emulator.

As you will be using 2 emulator instances to test your SMS, you need to specify a target instance when issuing adb commands. To so so, use the -s option in the command

adb -s emulator-5556 forward tcp:9999 tcp:4321 set AP_PORT=9999

Going Further (Optional)

  1. Programmatically remove coded SMS after reading it to prevent rereading it.
  2. Create a second program so that other android phone has a button to send the coded sms to turn on/off the Christmas Light
  3. Use the 24V DIO application adaptor to turn on/off loads upto 0.5A / 24 V.
  4. With relays, loads of up to 240VAC can also be used. Warning - please be aware of the dangers of operating at high voltages and understand the specification of the relays and use only appropriate ones.