Welcome to installment number twenty four of the Design Challenge Project Summary series here at Element14. For those of you who are new to my content, in this series I will pick a single Design Challenge project from the current challenge, and write a short summary of the project to date. Over the course of each challenge, I try to revisit each project that I cover at least once, and I am sure that some project summaries will get more than one update if they themselves are updated frequently. Unfortunately, projects that stall out, or get abandoned, will not receive any updates. Some project creators like to keep their own project summary going, and this series is not meant to overshadow those post, but designed to highlight each project from an outsider's perspective.

 

IMG_2147.JPG

 

The subject of this installment is project Alarm Clock Control Unit (ACCU) by Frederick Vandenbosch (fvan), a project that is actually the first of two sub projects of a larger IoT smart-home control center. ACCU will be based on a previous design that Frederick built two years ago, but will upgrade to a Raspberry Pi 3Raspberry Pi 3, and get some software tweaks. Like many of the projects in the Smarter Spaces challenge, ACCU will based around OpenHAB and will feature both touch control and voice input control. As I mentioned earlier, the ACCU is just the first part of a bigger project. The second device will be very similar in design, and will utilize Puppet to ensure that both of the device’s file systems stay in sync with each other. Head over to the project’s introductory post if you would like to read more about the overall goals of this project.

 

Screen+Shot+2016-06-02+at+19.14.57.png

 

In the project’s first update post, Frederick clues readers in on Puppet, a key piece of software for the project. “Puppet is an open-source configuration management tool that helps automate the deployment and management of files and applications on target hosts,” he said. “A puppet master contains the definition of the desired configurations in files called manifests or modules. Agents can query the master in order to know which configuration changes to apply.” This post is a definitive guide to installing puppet in Raspbian, and reading the entire post is highly recommended before moving on with this summary. I have used Puppet in the past for speeding up multiple web server deployments, but never to sync settings and files between two Raspberry Pi’s, so this post was very intriguing to me.

 

2016-09-01 05_33_22-Pi IoT_ [Pi IoT] Alarm Clock #04_ Installing Op... _ element14 Community.png

 

In the project’s next update, Frederick showcases a Puppet Module that he is building to make deploying OpenHAB automatically to the Puppet Master. This will allow him to quickly and easily deploy OpenHAB instances to as many Puppet agents as needed, with the new install being identical to the master. Once again this post is pretty much a definitive guide to deploying OpenHAB in this manner, and the tutorial is simply a joy to follow. Frederick never ceases to amaze me with how well he structures tutorials.

 

 

On June 14th, the next update to the project was posted, and it clued us in on how EnOcean PiEnOcean Pi and its various range of sensors will be utilized in the alarm clock. Frederick said that he has been using EnOcean Pi and it’s wireless sensors in his home for two years now, and that he is very pleased with their longevity, and lack of maintenance. He does note however, that if you are using an EnOcean Pi in conjunction with a Raspberry Pi 3, you will need to make some additional changes during installation to get everything working correctly. The post goes on to detail how to configure everything, and to get EnOcean Pi and OpenHAB working together.

 

IMG_1595.JPG

 

With some of the sensor integration out of the way, Frederick moved on to adding in energy monitoring to the project. In the sixth update, he introduced us to emonPi, an open-hardware energy monitoring solution that is based on the Raspberry Pi. Since emonPi runs on a Raspbery Pi, Frederick is able to use MQTT to relay data to the main control hub, which can then be pulled into his OpenHAB install. The install is fairly simple, as the emonPi team have created their own image based on Raspbian Jessie Lite, but he does walk us through a few steps to turn off unneeded services the image has pre-configured.

 

 

In  the project’s seventh update Frederick walks us through some of his experiments with the Raspberry Pi Sense HATRaspberry Pi Sense HAT. He says that he had not originally planned on using the Sense HAT in this project, but some downtime between moving from one home to another provided the perfect opportunity to check out what it had to offer. If you are interested in seeing some of the features the Sense HAT has to offer this would be a good post to start with. At the end of the post, Frederick took a few moments to discuss an issue that has arose with some of the Sense HAT modules that were sent to other challengers, and confirmed that his was also affected by the faulty temperature sensor.

 

 

In post number eight, Frederick shows us how he incorporated a previous project, the IoT Tower Light, into his system using OpenHAB. The light will be used for notification announcements. In the light’s build tutorial, Frederick shows us how to connect it to the IoT using IFTTT, but for this project he wanted to stick with MQTT as the main protocol, so he details the process of integrating the light with OpenHab using the MQTT binding module.

 

IMG_1743.JPG

 

The project took a colorful step forward in update number nine where Frederick took us down the bright path to understanding how to control a Philips Hue light bulb using OpenHAB. This is a fairly simple task, but it does take a good bit of footwork in the software to get the item list, sitemap, and rules configured correctly, if you are having trouble getting your Hue lights connected to OpenHAB, this would be a good post to read. Frederick finished off the post by showcasing a small nightlight he built to house one of the Hue bulbs.

 

IMG_1892.JPG

 

In update number ten, Frederick pushed the project closer to completion with the additions of two IP cameras using the supplied Raspberry Pi camera modules. “The first one is the ZeroView,” [which is] “useful to stick a Pi Zero and camera on any window in a very compact format,” he said. “Even if you don't attach it onto a window, the spacers can be used to attach a string or similar to attach it somewhere else while keeping everything as one unit.” After enabling the camera in the Raspi-Config menu, Frederick chose the lightweight StreamEye program to manage the camera’s image feed. This allows the Pi Camera to stream an easily embeddable MJPEG stream of images to anywhere on or off his home network.

 

Updated Sept 9, 2016

 

 

The actual clock portion of the project began in update number eleven which features a LED matrix and a seven segment display that both utilize I2C. This saves a lot of data lines from occupying valuable GPIO pins, and will make coding for these two displays much easier. This post features a very good mini tutorial on how to enable I2C on the Raspberry Pi as well as some concern that logic level shifting might be needed to prevent damage to the Pi. Fortunately this concern was alleviated after some research in which Frederick used an oscilloscope to ensure that the I2C GPIO pins could power both the 7-segment display, and the LED matrix. The source code to control both displays is also included in this post, so head over to the link above to check it out.

 

 

In update number twelve, Frederick tackled the task of getting voice control working on the alarm clock. This proved to be one of the larger hurdles in this project that had to be overcame, due to a requirement to retain functionality if the alarm clock lost it’s connection to the internet. This issue was solved thanks to a roadtest article by Alan McDonley (alanmcdonley@yahoo.com) . Alan chose to use a Speech To Text tool called PocketSphinx, which has offline functionality built in. The post includes a full tutorial to replicate this feature on your project at home, so be sure to give the full post a read.

 

 

With voice control working on the alarm clock, the next step was to jump on the text to speech functionality. Once again, this feature needed to work even if the internet connection was lost, so Frederick looked around the internet, and finally stumbled across a lightweight version of Festival called Flight. Once again, Frederick wrote an entire mini tutorial on how to install and configure Flight on the Raspberry Pi, and as you can see from the demo video above, it actually works quite well, and has several different voices and accents.

 

IMG_2002.JPG

 

In update number fourteen Frederick switched gears from software integration into full on woodworker mode and used his ShapOko2 desktop cnc milling machine to cut out the clock's face plate. “To make the necessary cutouts for the clock display and button, I'm using my ShapeOko2 Desktop CNC machine. It uses a Dremel to mill and is controlled via an Arduino UNO with gShield used to control the stepper motors of the CNC,” he said. “On the software side I'm using Easel, Inventables' web-based all-in-one software application for CNC milling. It combines the CAD software to create the design, the CAM software to set the tool paths, and additional software to send the resulting G-Code to the Arduino.“ As an added bonus, Frederick included a link to the project in Easel, the cloud-based cnc controller software from Inventables, that is used to control the ShapOko. This means that anyone with the same cnc mill, or even the X-Carve or Carvey can replicate the housing for this alarm clock!

 

IMG_2088.JPG

 

Update number fifteen continued the alarm clock’s housing build, and I must say that it turned out very nice! “In my previous post, I showed you the start of the enclosure: the front panel. I have since then been working on the rest of the enclosure, trying to figure out which style to go for, one piece at the time,” he said. “I'm a software guy, not a product designer (or a wood worker for that matter), but I enjoy experimenting and giving projects a finished look.” As always with Frederick's projects, the design files are included in this post so those following along at home can build the same enclosure.

 

IMG_2129.JPG

 

With the case built, Frederick was able to move on to beginning the final wiring process. A Raspberry Pi prototyping board was sacrificed to create a right-angle header in which jumper wires could be used to quickly connect various components together. As you can see from the image above, space was tight, but by the end of the post, things were looking good, but you will have to check out the post itself to see how it turned out.

 

 

In the project’s seventeenth update, Frederick moved back into the software side of things, and detailed how he integrated I2S audio into the project, and talked about the amplification circuit that he used. “I just realized I didn't explain the audio amplifier of my alarm clock introduced in the wiring post. Silly me ... Anyway, as you may have seen from the wiring in my previous port, I'm using the I2S pins to get the audio from the GPIO header and amplify it. I2S (or Inter-IC Sound) is a digital sound protocol, meant to pass audio data around between integrated circuits,” he said.

 

IMG_2178.JPG

 

With most of the first control module finished, the time came to begin to build the second control unit. Since the second control unit will feature most of the same software as the alarm clock, development on this unit will move very fast. “Starting this challenge, I set out to build not one, but two control units. The idea behind this was that a single control unit would require the user to move to that room in order to be able to trigger actions (aside from using a smartphone of course). That's why I planned to have a control unit in the bedroom (the alarm clock) and one in the living room,” Frederick said. “This control unit will make use of the Raspberry Pi 7” Touchscreen Display as provided in this challenge's kit. Because the touch screen's resolution is limited, different views will be created, each focusing on a different aspect of my smarter spaces.”

 

 

With most of the hardware work done on the second control unit, work on the kiosk user interface could begin, and that is exactly what Frederick covered in the project’s nineteenth update. We have seen something similar to this from Rick Havourd (rhavourd) in his project Hanger Control System, but Frederick decided to go with Chromium as a way to offer a second approach to using a browser based UI in kiosk mode. Unfortunately, Chromium is not available in the Raspbian repositories, but Frederick walks us through how to install it from the Unbuntu repositories, as well as how to configure everything to get kiosk mode working

 

IMG_2231.JPG

 

With just a few days to go in the challenge, Frederick doubled down and worked hard to finish up everything before the deadline. Update number twenty was dedicated to finishing up the enclosure for the second controller. Using his ShapOko2 a sheet of white acrylic was milled to create the final pieces needed to complete the enclosure. Getting a good result from the acrylic did prove challenging though. “Milling acrylic using the CNC required a few attempts before achieving clean results. During the initial runs, the mill's feed rate was too low, causing the acrylic to heat up too much, melt and stick to the milling bit. This in turn, caused damage to the piece because of the molten blob swinging around,” Frederick said. “By increasing the feed rate to 1000mm / min, with passes of 0.7mm, the mill travelled fast enough to cut without melting, resulting in clean cut pieces, as demonstrated below.”

 

IMG_2238.JPG

 

Update number twenty-one was all about failure, and how to learn from those projects that do not go as planned. During the challenge, Frederick actually moved to a new home which was already outfitted with some rudimentary home automation from a company called Domestia. This worked perfectly into his project and he was excited to get the system integrated into the system that he just built. “The installation consists of two relay modules, capable of turning lights and outlets on or off. There are also two dimmer modules for lights,” he said. Unfortunately the system did not like his new LED bulbs, and the dimming functionality ceased to work. After some sleuthing, and a bit of research, Frederick decided to place this portion of the project on pause until he could make sense of why things were not working correctly.

 

IMG_2306.JPG

 

Frederick wrapped up the project in its twenty-second update post by building a small bonus device that is designed to hold the family’s keys. “The idea was to make a key holder allowing up to four different (sets of) keys. It serves two purposes: a fixed place to hang our keys (we tend to misplace them a lot!) and assuming proper use, could be used as an alternative/additional presence check,” he said. This simple little project is quite awesome, and I honestly may replicate it in the near future.

 

 

Two subsequent post were made that same day, with one of them being Frederick’s summary of the project, and the final update being a post that links to all of the sources used in this project.

 

 

That is going to wrap up my project summary coverage of project Alarm Clock Control Center. Once again, I am simply amazed at the quality of not only Frederick’s work, but his ability to document every step of the process. As a professional content creator, I know how difficult it can be to thoroughly explain how a project works, and keep things readable by everyone, including readers who might not me “engineer minded.” Overall I feel that the project turned out great, and I see it being one of the major contenders for the top prize. Thank’s again for taking the time out of your day to read my summary of this project. Head over to the project by visiting its blog page if you have not visited it yet. Tune in next week for another Design Challenge Project Summary here at Element14. Until then, Hack The World, and Make Awesome!