Tuesday, April 17, 2007

First step with cameras... and further planning to be done

After my incident last week, I immediately went up to Automated Outlet and ended up buying two of their Panasonic IP cameras (a huge thanks to Martin). The cameras themselves were pretty easy to set up (one in the kitchen, one in the living room to check up on motion sensor alerts), and they come with their own http servers so they can be accessed over the internet. However, since my HomeSeer site is already using port 80, I set up the cameras to use ports 52 and 54 (quite randomly, I assure you). Unfortunatley, these ports are blocked by my firewall at work, so I can't even view the cameras at work. I'm working with a security guy at work to set up VNC over SSH so I can view the cameras appropriately, but that will probably take a couple of days. In the meantime, my wife can view the cameras from her office, and I can access them with my cell phone since they have special built-in access for phones as well.

I must say, although the camera setup was fairly easy, the installation took some creative planning, due to the lack of wiring in my house. The camera in the living room (across the house from the office where the server is) is hooked up to a Netgear wireless print server which happened to have 4 ethernet ports as well. The camera in the kitchen is using ethernet over the powerlines. So far, the one in the kitchen has a faster refresh rate, and the ethernet over the powerlines doesn't seem to be interfering with UPB communications at all.

Also, this weekend is another meeting of the North Texas Home Automation Users Group, and I'll be taking plans of the house up there to see what we can do about wiring the home for security purposes. This has been just a terrible week (capped off by my 2-year-old daughter hitting me in the nuts last night), and I'd like to get it behind me as quickly as possible.

It happened to me...

I'm tired of talking about it... I'm tired of writing about it... All I will say is that it happened last Wednesday, April 11 and point you at my post on cocoontech

Tuesday, April 03, 2007

Next Step: Cameras!

Well, I was at work yesterday when my phone got an email from HomeSeer saying there was unauthorized motion in the kitchen (i.e., nobody home, but motion anyways). I called my wife to see if she was home, but she was also at work. I then logged onto my remote access website to see if there was anything else wrong. It only showed motion in the kitchen, but not in any adjacent rooms, so I thought it was just probably shadows or something. But this gave me an idea of what to do next (and my wife had the same thought!): cameras.

I need to find some way to figure out what is going on at my house should this type of alert happen. They don't really need to be hooked up to a DVR yet (although that would be nice in the future), but just something where I can log on the internet and make sure everything is okay. A new project begins...

Sunday, March 04, 2007

Electrical problems

So, ever since I installed the switch in the bathroom, it has been having problems. It made noises and couldn't keep the lights on, often rebooting itself. So this weekend, I was starting to replace it, and looking at the instructions, and saw that the switch only supports 600V, which I knew, but didn't even think about when installing the switch. Well, I decided to look at what kind of bulbs were in the fixtures, and sure enough, the bulbs left over from the previous owner were all 120V bulbs... so, it seems there was somewhere between 800V and 900V coursing through this switch rated at 600V.

I replaced all the 120V with 100V-equivalent (actually 26V) CFL's and tried the switch again. Sure enough, it worked.... except for a single fixture, which was making buzzing noises. I turned off the breaker again and pulled down the fixture from the ceiling. The wiring sheath had been burned off the wires, and the wires were exposed. Turns out those wires were only rated for 60V or 80V, and the previous owners were more than happy to put 120V bulbs (2 in each fixture!), thereby ruining the wiring.

So I called my electrician out for a minor emergency Saturday call, and he came and replaced the burned out wiring. I turned the breaker back on and turned on the lights... wa la! The lights worked great. Then I tried to test the communications of the switch... . Turns out the overload of the voltage seems to have burned out the communications of the switch, so I essentially have a $38 light switch (sans UPB capabilities). So, I had to replace the switch anyways.

On the software side, I set up HomeSeer with an email address, so it can email me under certain situations (e.g., nobody is home, but the front door opens).

Sunday, February 25, 2007

Finally, more switches installed...

Yay, got a few hours this afternoon with the kid asleep and the wife busy enough elsewhere that I could install some of the switches I bought from Fry's in Austin several weeks ago. My first priority was to address lights that are used most often (and thus, left on by my wife most often!). So, I installed switches on her closet in the bedroom, her closet in the bathroom, my closet in the bathroom, and the main light in the bathroom (as well as a slave in the 3-way for the main bathroom switch). Programming these are straightforward as I don't need to the send any links, and they only need to receive All Off and Bedtime links.

This brings my total up 17 UPB devices, 2 of which are slave switches (bathroom, living room), and 2 of which do not control loads (tabletop controllers on our nightstands), so maybe it's more correct to say 13 UPB controlled loads. I still have left to install 4 more US11-30's from Fry's, a single US-240 that I have leftover from starter kits, and a slave switch for the top of the stairs. For self-documentation purposes, here's where I want to install the switches:
Slave - top of stairs
US2-40: playroom, so I can control living room lights from there as well
US11-30's x 4: laundry room, garage light, dining room, office

EDIT: rather than the garage light, I think I would rather do the front porch exterior light

On more philosophical notes, I continue to reference Smart Home Hacks (the book that got me into this mess in the first place) on a regular basis for ideas on what I could/should be doing. I do have a list of ideas somewhere (and it should be here at some point), but simply lack the free time to implement these for now. As I read through the book more and more, I wonder more and more why the author chose to make the large majority (>90%) or his examples using software that is only Mac compatible. I think it would have served him equally well or better to write his scripts in a PC based software (such as HomeSeer), or at least to make equivalent scripts available over the website. At least that way, I could have a good reference (again, lack of basic VB skills on my part) for the logic that I want to perform. OK, I'm off my soapbox.

Monday, February 19, 2007

Quick status update

Nothing in depth to report... just a status update.

Had a few minutes over the weekend in between building bookshelves, hanging large batik artwork, and doing my taxes. I set up door sensors on the front and back doors, although I'm not really sure what events to program them for at this point. All I have for them now is to tell me if one of them is open for 15 seconds. I'll probably set up some sort of notification (you know, once I get HomeSeer email working) that let's me know if one of these devices goes to Alert status while nobody is home. But I know I didn't want a sound every time a door opened or closed... that would get annoying (but not a bad idea for windows that are not supposed to be open).

Also, I put up an outdoor motion sensor over the front stoop. Managed to totally strip one of the mounting screws in the process, so I ended up mounting it with velcro (hope that holds up outside). Not entirely sure whether or not the event set up for it works or not... I told HomeSeer to make an announcement that somebody is at the front door when the motion detector is changed to active, but only if the door is closed. I didn't want to make the announcement when someone is leaving, just when they are arriving (and I haven't yet opened the door for them, obviously). It also turns on the foyer lights at night, as I don't have a UPB switch set up for the porch lights yet.

And that brings us to what really needs to get done... I MUST find time to install those switches. I know, a boring post... but remember, I started this blog for my own documentation purposes, not necessarily for your enjoyment :-)

Thursday, February 15, 2007

More motion detection... and a little retrospective

Last night (Valentine's Day!), the wife and kid went to bed early, and gave me some time to set up more stuff (you know, aside from the blinds I'm supposed to hang the bookshelf I'm supposed to put together). So of course, I started messing with more motion detectors.

After having already set up a motion detector for the kitchen/breakfast room, the actual hardware setup of the motion detectors is easy. But since my living room is so large, and has two separate entrances, I decided to use two motion detectors in the living room. HomeSeer's ACRF plug-in has a nice shadowing feature which allows a single motion detector to control a device (or multiple devices), I don't believe it allows for multiple motion detectors to control a single device (and thus, I believe, was the genesis of HomeSeer's DooMotion plug-in, which I am attempting to avoid spending more money on).

Once the hardware was setup, I created virtual devices in HomeSeet with the appropriate house/device codes I set the motion detectors to. And with HomeSeer's UltraStatus plug-in, I'm able to set it up to say Motion/No Motion instead of On/Off on the main status page. But the logic of interacting with two motion detectors is quite a bit different than a single detector.

With the kitchen light, it turns on whenever there is motion, and off whenever there has been 8 minutes of no motion (we tend to move enough during dinner time). But in the living room, I don't want the lights to turn on during the daytime (sufficient light), even when there is motion. So, I set up separate events for receiving each motion detector's ON signal (to be precise, I triggered the events based on a status change in the virtual devices, not on a received X10 code like shadowing would... I don't know how much of a delay this introduces, but there's already a considerable one between RF/HomeSeer/UPB/CFL, so an extra 0.1 of a second wouldn't make a difference). When either status is changed to ON (i.e., Motion), and it's early in the morning or late at night (i.e., the sun is not yet up), and the lights are still off, then turn them on. I suppose I could add to the condition that somebody must be home... not a bad security idea for the future.

However, when one of the virtual devices has its status changed to off (i.e. No Motion), it checks the other device's status, and if both of them are OFF, only then does it turn out the lights. That way, only a single motion detector active is sufficient to keep the lights on. I'm sure more fine tuning of this rule will need to take place, but for one night, it seemed okay.

With this pretty much in place, I decided to take a look back at my original list of priorities that I wrote down during my first week, and surprisingly, I've accomplished much of it.

1. Turn on/off the lights in the bedroom without getting up.
This is taken care of using a single rocker switch for the overhead light and two lamp modules for the bedside lamps. Additionally, both my wife and I have tabletop controllers on our nightstands which control the bedroom lights and lamps both individually and as scenes. Furthermore, I have voice command over those lights, individually and scenes, through the tablet PC on my nightstand running HomeSeer's speaker client.

2. Automatically turn on the lights in my living room when someone walks in.
You can see why completing this task caused me to look back at this list... it was my #2 priority! As described above, I'm using two motion detectors for this, and I'll tweak the logic on the HomeSeer event as necessary. I may just end up writing scripts for this if the logic becomes too convoluted.

3. Automatically turn on the lights in my kitchen/breakfast room when someone walks in.
Accomplished with a single motion detector set up to shadow my UPB Kitchen and Breakfast link. Very straightforward, no event required.

4. Set up a computer with smart home software.
As should be painfully obvious by now, I'm invested in HomeSeer and its plug-ins.

5. Install in-wall terminals around the house, both controllers as well as jacks.
I do have several in-wall controllers using 8-button and 4-button+rocker layouts on SAI's US-240 universal transceivers, and overall, I'm very pleased. What I don't have yet are UPB controlled outlets, and that has turned out not to be a terrible thing. But it does count as the highest priority on this list that is not fully complete.

6. Control things with my Harmony remote control
This is not even started yet, and I still don't know how I'm going to accomplish it. I have a Harmony 880, which emits IR signals (i.e., not RF signals). As to how to convert these IR signals into something HomeSeer will recognize, I'm not yet sure. PCS does make a UPB switch with an IR receiver, but I wouldn't really know where to put as I don't have good line of sight to any switches in my living room from my couch. X10 has something called a PowerMid which translates IR to RF (and then to X10 by a receiver to put on the powerline), but the generate RF is not standard X10 RF and cannot be received by the W800RF32, so that's out. If anyone has any suggestions as to how to get IR commands from my remote control in the living room up to (preferablly wirelessly) the HomeSeer computer upstairs so it can transmit UPB links, I'm all ears.

7. Install webcams for remote monitoring
This is probably the farthest out. I will likely use IP cams in the future, but for now, cameras cost too much, and I've pretty much used my budget for the year (yes, 2007) on switches, software, and X10 RF devices, the setup of which will probably take me the whole year anyways.

8. Automatically turn on porch lights when a visitor walks up
This one is in the very near future (as in, next)... I do have a couple of outdoor X10 RF motion detectors, and it should be easy to put one over the front stoop to detect motion only on the porch (rather than in the yard). My concern here is that we tend to have cats run across our porch, and that would set off the motion detector. Well, I'll think about this..

9. Set up a state machine
Well, I have a state machine setup (as of a couple days ago), but it doesn't really alter any behavior yet. All it does is turn off lights when we're both gone. There are other ideas (alarm clock auto-set, for example) that need to be taken care of when I have the time.

10. Set up a sensor on my garage and back door, so I know if they are left open
I do have half a dozen door/window sensors that use X10 RF... just need to find the time to do it. What will be more interesting here is if not only could I sense the garage door, but also control it. There are several articles on this at CocoonTech, plus one in a home automation book my parents got me for Christmas... one step at a time.

11. Install thermostats
This will probably happen before cameras, but after everything else :-) So far off in the future, I won't even speculate.

12. Program garage controllers in our cars
This may not need to be done after all... If the CheaperRFID thread on the HomeSeer forum is any indication, I can stick active RFID transmitters in our cars and let the computer automatically detect when they are in range rather than us having to push a button to inform it. This is tentatively scheduled for the end of this year (after installing switches, basically).

13. Setup computer to email me events
Actually, this can be done now if I took the time to do it. HomeSeer has native email functionality... I just haven't felt the need to use it yet.

For 6 months worth of work, I'd say I've done okay. I might even say that I was too naive to set my priorities correctly earlier, but that's how the cookie crumbles.

It's probably also good here to warn my readers (apparently, myself and Dave at this point) that things will slow down. I do have other things around the house I need to take care of (see blinds and bookshelf reference earlier), plus some personal things to advance my career (learn Java, as painful and dumb as that may sound). More updates as things happen.

Tuesday, February 13, 2007

State Machine

Well, I guess I now have a rudimentary state machine. My original plan was to take an X10RF Slimline switch (one of the wireless switches I mentioned in an earlier post) and put that by the entrance from the garage so that we could press it whenever we came or went. Well, it turns out the wireless reception was not good from ALL THE WAY ACROSS THE HOUSE, so that didn't turn out too well. Fortunately, the next room off the laundry room (where the garage entrance is) is the breakfast room, and right there, 4 feet away from the garage entrance is one of the 8-button controllers I had installed months ago. And it had 3 unused buttons... wait for it... wait for it... Eureka!

I reprogrammed two of the buttons to just send links (received only by the software, not any other switches) to tell when my wife and I were home. I set them up as multibuttons (as is common in my house... one press for ON, two presses for OFF). As a confirmation, and this also fulfills my novelty wish of more voice announcements, the Audrey in the kitchen says hello and goodbye phrases appropriately when these links are activated. When both of us are out of the house, the lights turn off automatically, although my wife complained about a 15 second delay in that this morning. I set up the event in HomeSeer to be triggered by the condition that both of us were away using a condition trigger, but I don't know how often HomeSeer decides it wants to check if conditions are true (feel free to comment on this if you are one of the 4 people who read this blog and know the answer). Maybe it would be better to set up two events using device value changes (one for each of us) that checks if the other is home or not. I know those types of events are run immediately when the value changes.

As for the RF Slimline switches, I bought two with the initial thoughts that I would use one to turn on the kitchen lights from outside the bedroom (obviously, not well thought out since these are motion activated) and one by the garage. Now, looks like I'm not using either! Plus, the tactile feedback on these is minimal; although, I'm used to the audible click on the SAI UPB switches and controllers.

What is really holding me back at this point is my complete lack of VB or VB.NET scripting skills. I want to be able to have our alarms set automatically depending on who is home when the bedtime link is activated, but this is more than simple conditional logic and likely requires a script. I suppose I could use Perlscript (since that's what I know) as it is supported by HomeSeer, but that would put me in a HUGE minority as seemingly nobody elects to go this route. I'll probably try it anyways just to see what I can do. Plus, scripting would certainly clean up my events list as I have multiple events for many things that can be scripted. All in good time, I'm sure... Rome wasn't built in a day (but we can watch it in nice little hour snippets on HBO).