This sketch is missing a short description
Purpose is to build a smart presence detector. This device decides when you are home or not. When you are home, a number of other devices can be powered down.
Presence can be detected in a number of ways, but I would like to (also) detect it from the presence of your smartphone. This should be possible through its bluetoot LE function : when the presence monitor 'sees' the bluetooth signal of the smartphone, it decides you are nearby.
Problem is that Bluetooth Low Energy is not that easy to implement. I am starting from a BlendMicro board, which is an Arduino(-compatible) with BLE built-in (Nordic Semiconductor nRF8001 module)
BlendMicro can use its BLE module through a Application Controller Interface (ACI), which is a bidirectional interface, implemented as a Serial Peripheral Interface (SPI)
Embed This Sketch
Use the following HTML code to embed the sketch code above in your blog or website.
<iframe style="height: 510px; width: 100%; margin: 10px 0 10px;" allowTransparency="true" src="https://codebender.cc/embed/sketch:218178" frameborder="0"></iframe>
Embed The Serial Monitor
You can also embed the Serial Monitor section! Just use this HTML code.
<iframe style="height: 510px; width: 100%; margin: 10px 0 10px;" allowTransparency="true" src="https://codebender.cc/embed/serialmonitor" frameborder="0"></iframe>