What is CrouchHouse?

CrouchHouse is the name of my home automation / information project. My wife has taken to calling herself CHO (Chief Home Officer) of CrouchHouse and I’m the CTO (Chief Technology Officer). I’m a software developer and scientist by trade, so rather than go out and buy a complete home automation system, I figured it would be fun to slowly put one together where I know exactly how each part works.

 

ch-large
The Robohouse interface is a fun chance to create minimalist art with CSS.

The Robohouse Interface

The realish-time robohouse display for our house can be accessed by the public via the internet at https://www.crouchhouse.com

I decided to host the interface online so it would be easily accessible from the internet (on mobile devices, at work, etc). The obvious drawback here is that if the internet goes out, the interface is inaccessible. However, this hasn’t been an issue in the ~2 years the site has been live. The site is hosted on Dreamhost. I find their service is pretty great and they are open-minded about interesting projects.

Not all interface functionality is available when offsite. I’ve coded certain parts of the interface to only show up if the site is accessed by our home IP address. Since our home IP address is dynamic, there is a pinger script that updates an IP database field on the remote server every five minutes.

 

When the site first launched there were only four rooms.
When the site first launched there were only four rooms.

What’s On The Public Interface?

We live in a 10 room house in Boulder, CO, USA. When I first started CrouchHouse, I used four old PCs I had lying around to be sensor hubs located throughout the house. The first iteration of CrouchHouse reported temperature in four rooms of our house: the living room, my office, the baby’s bedroom, and our downstairs family room. In time, I added additional sensors in my wife’s office and the laundry room. Currently, the six operating sensor hubs are running on 2 Windows 8/8.1 desktop PCs (offices), 1 old Windows 8 laptop (family room), 2 old Windows 7 netbooks (baby’s bedroom, laundry room), and a Raspberry Pi B+ microcomputer (living room). The living room sensor hub is on a Raspberry Pi because I wanted to play around with one and it allowed us to put the hub out of sight on top of a piece of furniture. The laptop/netbooks also offer small, easily-hideable computers with the added benefit of having a built-in UPS (battery).

2015-09-06 18.49.48
Our living room sensor hub is a Raspberry Pi hidden behind plants on top of our china cabinet
2015-09-06 18.50.24
Closeup of the Raspberry Pi hidden on top of the china cabinet.
2015-09-06 18.50.36
A PC Sensor TEMPer2 USB thermister is used to gather temperature information.
2015-09-06 18.51.26
An old Dell laptop, seen here hidden on top of a bookcase, is used to monitor temperatures in the family room.

In addition to the sensors located within the house, the CrouchHouse remote server queries a Weather Underground API to retrieve current weather conditions from 3 backyard weather stations located within 0.2 miles of me. I then average these readings to come up with an “outside temperature”. This was both easier and cheaper than setting up my own weather station. Thanks neighbors for providing this weather information! The average of the three stations seems to be pretty spot on when I ground truth in my backyard.

CrouchHouse is coded in PHP and Javascript. Right now the public interface only displays temperature, time of day, presence of snow, and moon phase. There are four times of day represented on the site: sunrise, daytime, sunset, and nighttime. I use the handy PHP functions date_sunset and date_sunrise to calculate the time of sunrise and sunset on a given day. The sunrise scene is displayed for 30 minutes prior to sunrise, and 20 minutes following. Sunset is displayed for 20 minutes preceding sunset, and 15 after. The presence of snow is determined by querying a National Operational Hydrologic Remote Sensing Center model/measurements for our location. For the nighttime scene, I used a post by JiveBay to write a moon phase script that displays whether the moon is currently full, waxing, waning, or new. In the future, the interface will likely include forecast data for my location and light sensor data for each room.

 

How Does Data Get To The Interface?

Temperature data gets sent from each sensor hub to the remote site via automated cron scripts every five minutes. The remote site then stores that information in a MySQL database for archiving. The interface displays the most recent reading for each room (and outside) from the last 15 minutes. If a reading hasn’t been stored for the last 15 minutes, the interface displays a null value for that room (e.g., “–“). In general, the network is always online. There are some short periods when Windows auto-updates itself that certain rooms may appear offline.

 

How Else Is The Data Accessed?

In addition to the publicly-accessible website, I’ve created an iOS app my wife and I can use from our iPhones. Also, we have an Android tablet hanging from our wall to provide an easy readout when moving about the house. I’m also planning to convert an old iPhone 4 and an iPhone 5 into two more wall interfaces. They just need frames.

When viewed from home, the current interface can accept voice (e.g., “What’s the high today?”) and touch commands for charts. meSpeak is used for text-to-voice and annyang! is used for voice-to-text.

I will add posts to this site as new features are added to CrouchHouse or we create some fun home hacks. I’d love to hear about your similar projects / questions below in the comments!

 

phone-and-laptop
In addition to the public website, I’ve made an iOS mobile app and an Android app so we can access the interface from our phones and wall-mounted tablets.
The iOS app makes it super easy to view the interface from anywhere.
The iOS app makes it super easy to view the interface from anywhere.
A framed Android tablet provides wall-mounted touchscreen capabilities.
Wood tablet frame in profile.

 

2 thoughts on “Introduction to CrouchHouse.

Leave a Reply

Your email address will not be published. Required fields are marked *