The project is essentially about building a smart lamp, that could to be controlled remotely via web apps, that can automatically turn on/off the lamp depending on surrounding light intensity (based on photosensitive sensor).
But I also refer to it as a smart lamp "on steroids", as it's able to detect motion, capture photo using webcam, and upload the photo to Azure Blob Storage. It's also controllable remotely and able to receive telemetry data by leveraging Azure IoT Hub.
The project was designed and built using a Raspberry Pi 2, running Windows 10 IoT Core. The app is written in Node.js, a supported development framework and runtime supported by Windows 10 IoT Core and Visual Studio 2015, but you might not find a lot of example in Microsoft IoT developer website. I painfully dug into Windows 10 API using a try and error approach, especially when accessing the SPI and working with webcam.
In this project, I used a custom built circuit for switching on/off AC line in order to turn on/off the light bulb. It's a kind of solid state AC switch. I made sure to avoid the use relay, as there is a moving component, I hate to hear the clicking sound and it was also necessary to avoid "spark" when the current is quite high.
Essential features of my smart lamp:
- Detect motion using PIR sensor
- Automatically capture photo using web camera upon motion detected
- Upload captured photo to Azure Blob Storage
- Opt-in to automatically turn on/off the lamp based on surrounding light, by leveraging light sensor.
- Hey I even integrate sound sensor. When detected surrounding sound is above certain level, turn on the lamp and take photo. Who knows there's an intruder.
I use this project for live demo during my talk about Windows 10 IoT Core, and also for delivering Windows 10 IoT Core hands-on lab.
More detail info and configuration are on the GitHub repository attached. Good luck.