Building a Smart Home

luminosity_sensor_dataWhen I was 8, I discovered the code to a terminal-based game. When I figured out how to change the background color of the game, I almost pooped my pants. When I discovered the internet (older than I want to admit), I learned how to change the background color of someone else’s computer and I really did poop my pants. When I started playing with robotics, I realized my code could literally pick up a paintbrush and change the color of the world if I build the right robot. Now, I build robots that poop their pants for me.

The Garden Monitor

Let’s get one thing straight, when I say “Garden Monitor,” I’m not talking about a rain gauge or an anemometer. My garden monitor is really more of a garden guardian. When it’s done it will carry two 125db ultrasonic cannons which should take care of the deer and rabbits who seem to think it’s okay to ignore fences.

To be fair the system does include some more banal sensors, such as a luminosity sensor which records the amount and direction of light. But even those sensors are going to be used for cools stuff like tracking local vampire activity . . . okay, vampire bat activity . . . fine, plain-old regular bat activity. But bats are cool, right? Like bow ties and cowboy hats.

Searching for Aliens

My new house had one of those Direct TV dishes, and since we’re a pure internet-tv house, we don’t have any need for it. Last fall I pulled it off the house and built a motorized itty-bitty radio telescope. I also wrote an Android app that captures my phone’s orientation and transfers that to my home server. This allows me to point my phone at a star, then have the telescope automatically reorient itself on that location.

To be honest, I didn’t finish that one. Once I realized the limitations of the itty-bitty radio telescope, I decided to build a bigger antenna. The rest of the system works, I just need to learn more about radio waves, which is why I got my ham license.

Thermostats Are Boring

A few months ago I heard about the Nest thermostat, and it is a beautiful looking device. Unfortunately, it costs $250. That’s just plain stupid. And, all of the other network-controllable thermostats also cost between $100 and $400. So, out of sheer disgust, I build my own. The code for the thermostat and the Android app to control it are github, when I finish overhauling my Django app, I’ll post that too. I build this for $20. But there’s one catch — The Network.

The Internal Network

I have an extended I2C network running through my attic. I spent a lot of time debating what type of internal network to use. Ethernet seems like the obvious choice, but then each node costs a lot more because they need more hardware. Wireless is good for mobile devices like my garden monitor. It will use a wireless signal in conjunction with three signal-buoys in my attic to maintain exact location data. But, if a node is permanent, like the thermostat, or the signal-buoy, then it needs to be wired. I could just use serial communication, but I didn’t see any benefit to using that over an I2C network. The coolest solution, that I didn’t implement, would be to communicate over the power lines in my house. I’m definitely going to explore this someday, but for now, my I2C network is good enough.

I’ve also built a serial-to-I2C bridge which is also posted on github, to allow my Django app to communicate with the nodes on the network. Right now the bridge can be built for about $20, but most of that expense is the FTDI chip. One of my next goals is to find a good USB library that works on the Atmel chip to see if I can get rid of the FTDI chip which would bring the cost of the bridge down to about $6, which is way better than what some people are charging.

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: