SuperHouse gives you detailed instructions for everything from basic renovation tasks to more extreme modifications such as how to fit electronic door locks so you can unlock your front door using your mobile phone, and linking your sprinkler system to the internet so you can control it from anywhere in the world.
A watchdog timer helps keep your embedded devices running, by making sure they are responding properly and automatically hitting reset or cycling the power if they die. I’ve added a simple hardware watchdog timer to an Arduino compatible board running inside my ceiling, where it’s difficult to access if I need to reset it manually.
View directly on YouTube: https://youtu.be/GC6dGypGctQ
Links for this episode:
Ambient information displays allow a home automation system to provide you with subtle feedback embedded within your environment. Concealing RGB LEDs behind a wall tile allows them to display status information when they are turned on, but still be totally invisible when turned off.
View directly on YouTube: https://youtu.be/cQtFoTWKa9o
Because I installed the tile so many years ago, I used original Freetronics Addressable RGB LED Modules that came out before the term “NeoPixel” was invented and used the WS2801 driver IC. Newer modules use the WS2812B, which integrates the controller chip into the LED body itself.
Connect up as many LEDs as you need, and glue them in place behind the tile. It’s best to keep the controller somewhere accessible in case you need to replace or repair it, so just have the LEDs permanently fitted behind the tile. You don’t want to have to rip out tiles and then re-tile your wall just to plug in a USB cable and update the firmware!
I’ve published an example sketch that has two separate functions: firstly it subscribes to an MQTT topic and watches for messages telling it to change the colour of an LED, and secondly it reads periodically from a DHT-22 temperature and humidity sensor and publishes the readings to other MQTT topics.
You can see the example sketch at https://github.com/jonoxer/BasicOTAFastLEDHumidMQTT
The Power Shield for the WeMos D1 Mini is now available from our reseller, Freetronics. If you’re using the D1 Mini in any of your home automation projects, this shield will be a life saver!
Yet another shield for the D1 Mini! I laid out a bunch of them in a burst of sudden enthusiasm, so there are even more to come after this.
More info at its permanent page: www.superhouse.tv/d1mterminal
This is a simple shield outline designed to be used as a project skeleton for whatever you want to design.
All the details are at www.superhouse.tv/d1msho.
A very simple shield for the WeMos D1 Mini: the only thing that stops it being a simple grid of holes is that it has breakouts for the headers, and it includes the orientation notch to align it with the reset button on the Mini.
The permanent page for it is at www.superhouse.tv/d1mproto.
The WeMos D1 Mini is a fantastic little development board based on the ESP8266 microcontroller with WiFi. It’s super cheap, and there’s even support for it now in the Arduino IDE so you can program it easily. If you haven’t seen it before, check it out on the WeMos site.
One limitation is that it needs 5V USB power to run, which is a pain if you want to build it into a project that doesn’t have USB power easily available. I designed this shield to give the D1 Mini the ability to accept power from 7 to 14Vdc (up to 20Vdc in a pinch) via a 2.1mm DC jack or screw terminals.
I hope to turn this into a product soon: I just need some more parts to arrive. There’s a page for it now at www.superhouse.tv/d1mpower.
Most cat doors are a simple flap that can be pushed open from either side, and allow any cat to pass through. The SureFlap Microchip Cat Flap is physically quite similar to a traditional cat flap, but it includes an RFID reader that allows it to scan the RFID microchip implanted in your cat and only unlock if it detects a recognised ID. All other cats (and other unwanted intruders such as squirrels and possums) are prevented from entering.
There are two models available: the basic Microchip Cat Flap featured in this review, and the more advanced DualScan Microchip Cat Flap. The difference is that the standard model only includes an RFID reader on the outside while the DualScan has separate readers on both the outside and the inside, which allows it to provide more advanced features such as allowing one cat to exit while keeping another cat locked inside.
Physical installation of the Microchip Cat Flap requires some DIY skills, depending on the material in which it’s mounted. Fitting it in a wooden door or plain wall is a simple matter of tracing the shape, cutting it out with a jigsaw or similar, sliding the flap into place, and screwing it on. If you want to mount it in a glass door you’ll probably need to use the services of a glazier to make the cut for you, or replace one of the glass panels in the door with timber.
Once the flap has been mounted, programming it to recognise your cat is incredibly simple. Just put in the batteries, press the “program” button, and either hold your cat near the entrance of the door or just wait for it to come and investigate by itself. As soon as the flap reads a valid implanted RFID chip it will store the ID and enter normal operation mode, which will cause it to unlock whenever it sees that ID. Its memory can store up to 32 IDs, and you can also erase its memory and start again if you accidentally program the neighbour’s cat in by mistake!
Setup really is ridiculously easy. There’s no app to install, no Bluetooth or WiFi configuration, nothing confusing at all. Just power it up, press that button, and you’re done. I can’t overstate how smooth and easy the setup process is.
The only reason the MicroChip Cat Flap doesn’t receive a perfect 5/5 score for setup is because of the effort involved in physically installing it. This isn’t something you can take out of the box and use: you’ll need an hour or two of messing around with tools to get it installed, but once you’re past that stage it’s totally foolproof.
Setup score: 4 out of 5
One of the reasons the SureFlap Microchip Cat Flap is so easy to set up (hooray!) is because it doesn’t have many features (boo!). Once you’ve programmed in your cat IDs, the only control you have is a manual rotary dial that lets you select one of four operating modes: bidirectional; in-only; out-only; and locked. Most of the time you can just leave it in bidirectional mode, which means it will scan RFID tags to only let recognised cats enter but let any cat exit. If you want to trap your cats inside at night you can set it to enter-only, and they’ll be able to come inside but not get out again.
There’s no way to set the mode electronically, or to set acceptable time periods for different modes. Twisting the knob is the only way to change it.
Feature score: 2 out of 5
If you don’t care about different operation modes at different times of day, there’s nothing to do once the flap is set up so there’s not really any “usability” from that point of view. However, I had some major problems with it: including one problem so bad that it lead to one of our cats having part of its tail amputated. But we’ll get to that in a moment.
The flap requires significant force to open so our cats have had trouble pushing it open. As a result they couldn’t work out whether it was in “locked” mode or if they just needed to push harder to open it.
The solenoid triggered by the RFID reader makes a significant “clunk” noise when activating which may scare timid cats. As our cats sniffed around it out of curiosity about the new thing, it clunked and made them jump. It took a while for them to learn to ignore the sudden noise each time they came near it. To get them accustomed to it we took the batteries out and taped the door permanently open for a while, so they could get used to going through it without the noise.
Changing the mode requires crouching down to twist the knob while peering at the small symbols printed on it. Because it’s mounted down near the floor, you need good eyesight to see the symbols from a distance. Just checking what mode it’s in requires bending down close to it. Being able to tell at a glance from across the room would be very handy, and could be achieved by something like a coloured dot that changes with the mode.
Now for the really bad part. I’m sure the vast majority of SureFlap customers don’t have this problem, but one of our cats suffered a serious injury trying to use the door. Because she couldn’t figure out how to get the door open to go outside, she got in the habit of bashing at the bottom of the flap with one paw. The plastic locking tab that keeps the door closed is exposed on the bottom edge, so if she was desperate and persistent she found she could get the door to pop open slightly inwards, by bouncing the door as the locking tab was pushed down by her paw. She’d then pull the flap fully open and wriggle underneath to get outside, with the door opening inwards towards her – the opposite of the direction it’s meant to go!
But of course the flap is spring-loaded so it pushes down and tries to close, and because her tail is the last part to go through the door it gets pinched between the frame and the flap. The result was that one time she got her tail caught badly enough that she pulled apart two of the bones in it, and afterwards the end of her tail had a right-angle bend in it. That was bad enough, but then the tail began to die. Our vet said the only thing to do was to amputate it just short of the break, so now her tail is about 1/3rd shorter than it used to be.
Usability score: 1 out of 5
The build quality seems excellent. I pulled it apart to look inside and found that it’s very well made, and the coil design (looping right around the entrance instead of being merely placed above it) gives great read range. It recognises our cats as soon as they walk near it, before they even put their head into the entrance.
Quality score: 5 out of 5
Unfortunately this is where the SureFlap Microchip Cat Flap really loses points. It’s designed to be totally self contained: it stores all IDs internally, and provides absolutely no way to connect it to anything else. As high-tech as it is, this is not an Internet-of-Things device because it has zero connectivity. No Bluetooth, no WiFi, no Zigbee, no serial port, not even a set of dumb dry-contact terminals for activity reporting or mode control. Out of the box there is no way at all to integrate it with a home automation system.
Of course I’d never be satisfied with that, so my plan is to retrofit a DIY interface of some kind to report activity.
Extensibility score: 0 out of 5
If you have a problem with feline intruders, this may well be the solution you’re looking for. But to use it as part of a larger home automation system will take some significant work and ingenuity. You also need to pay close attention to how your cats start using it, so that they push on it the right way and don’t develop the bad habit of trying to pull the door open.
Overall score: 12 out of 25, and (in our case) a large vet bill and distressed cat.
Just wiring up some lights so you can control them from your phone isn’t real home automation: that’s just turning your house into a really big remote controlled toy, even if you can do it from the other side of the world. For real automation your house needs to change its behaviour based on sensor input, and security sensors are a great way to add simple inputs that allow your house to make decisions about things like turning lights on and off automatically.
In this episode I show a clever way to connect security sensors up so that intruders can’t tamper with the cables undetected.
View directly on YouTube: www.youtube.com/watch?v=NfPDpwtPi6g
Here’s an example Arduino sketch that can read End-of-Line sensors and publish the results to an MQTT server: https://github.com/SuperHouse/SecuritySensor4ToMQTT
Control physical devices using an Arduino based home automation controller that connects to your network and lets you switch things on and off using a web browser. This episode shows the construction sequence of a controller that combines an Arduino-compatible board, Power-over-Ethernet, and relay driver shields to create a self-contained controller that can serve up its own web interface so you can click buttons in your browser to turn devices on and off.
View directly on YouTube: youtu.be/jvuvyiyVqtc
As shown in the video, decide how your device will be mounted and where you want external connections such as the Ethernet cable to be located. Drill suitable holes in the case and mount your Arduino in place. It can be a good idea to use plastic screws as shown in the video to prevent any possibility of short circuits to the outside of the case.
There are many options for software to control the device. For example, you could have it subscribe to an MQTT broker (server) and update its outputs based on publications from other devices. Or you could provide a menu via the serial console to control it manually from a computer connected via USB.
For this example I’ve provided a sketch that runs as a web server via Ethernet, and serves up a web page that includes “on” and “off” buttons for each of 16 outputs. By loading the web page in your browser you can simply click the appropriate buttons to activate and deactivate devices connected to those outputs. This example uses two Relay 8 shields, but it works just fine with a single shield as well. There’s no harm having the extra buttons visible and nothing will be damaged if the Arduino tries to address outputs that don’t exist, but you can trim it down to only 8 outputs if you prefer. It can also be scaled up to 24, 32, etc outputs if required.
You can see the full source code for the sketch at https://github.com/SuperHouse/OutputControllerRelay8x2. There are plenty of comments in it to help explain how it works.