Wednesday, April 14, 2010

(04-14-2010) Chronos - Timer system

I wrote a timer application. It's very simple - does daily, monthly and annual timed events. Can do day(s) of week (For example my wake up timer: Every Monday-Friday at 6AM, duration of 15 minutes) , day of month (2nd Tuesday each month or the 15th of each month) or day of year (4th Thursday in November or every December 25th). Each timer has a start time and a duration, so that it can start at a specific time of day and continue on for minutes or hours, as defined by the timer event in a database.

You can assign a holiday flag, or holiday exemption for each timer - for example my wake-up timer is Monday through Friday at 6AM, with a duration of 15 minutes, but if it's a holiday then it is holiday exempt and the alarm will not go off on that day. Also, you can dismiss a timer - so that once I wake up and dismiss the alarm, it won't continue to try to wake me up.

The Chronos system also has OnStart, OnActive and OnEnd events for each timer. In the future I would like to add socket communications as well as Sunset and Sunrise timers.

(04-14-2010) Twitter Unit for Delphi


I created a simple unit for using Twitter through Delphi. It requires the Indy Internet component suite to be installed, but then it allows the user to send and receive tweets very easily. I created a simple example program to show all the functions. If you're interested in the code, please drop me a line and I'll send it to you.

Thursday, April 8, 2010

(04-08-2010) New twitter code

Created a new twitter interface. My old system was using CURL (a great little command-line URL utility), but this version is all internal. It works much better and faster than the old version. Also, I've added some new abilities like the ability to create databases via twitter, so that I can keep track of invoices or automotive upkeep with just a tweet back to my server. Would like to give the tweet'er program the ability to send weather warnings and updates, as well as send me my to-do list every day.

I plan to add this into my existing home automation code, so that controlling lights or getting updates from my cameras can be done via twitter, or even changing parameters to the home automation system can be done remotely. The home automation system has twitter support, but it's not very rich at this time.

Wednesday, March 24, 2010

(03-24-2010) Slow progress...

I have been working some on home automation. The home automation software that I have written seems good, but since the latest upgrade in operating systems to Windows 7 the USB to 4 COM port adapter I have seems to have trouble addressing a single port. Instead, a command sent to COM3, for example, is broadcast to all ports and this causes problems with garbage being sent and received on all ports.

I have been working on a few other small things. I wrote a new TV episode / movie release date scraper that will alert me when my new favorite shows are coming or a movie in a genre I like is being released. Not sure how I want to handle the use of this, maybe I'll tweet myself to let me know...

Anyway, I just wanted to update things here because it had been dormant for so long.

Monday, November 23, 2009

(11-23-2009) IR Support! I wish...


Worked on infrared remote (IR) support using my own software as well as trying WinLIRC to do the job. With my own software I don't seem to be able to get reliable, repeatable codes from the remote, while WinLIRC seems to think it does. Either way, when I try to send a command to the Roomba to initiate cleaning, it does nothing. Checked visually with my cell phone camera and the IR diode is flashing on the transmitter, but maybe the signal is too weak or not the right signal. I was really hoping to get scheduling of the Roomba put into the home automation system tonight, but it wasn't meant to be...

Wednesday, October 14, 2009

(10-14-2009) Motion detection example


The last few days I've been working on a passable version of motion detection. Here is a sample of my attempt. It still needs some more features, like the ability to block out certain areas from detection (like the television in the background of the picture). Another piece of the home-automation puzzle is done. This current version only works with a weird camera (IP Kamera), so adding support for other cameras will be coming.

If you're looking for a turn-key solution for web-cams and with good motion detection, I recommend WebCam XP. It's a great software product, but it was a little lacking on Home Automation features, so I had to roll-my-own in this case.

Friday, October 2, 2009

(10-02-2009) My home and it's automation...

This is a screen-shot of my CM11A prototyping application. Still need to add date/time and macro saving, but it does the bit of controlling X10 devices very well.

Right now my home automation setup is very simple. I have an array of X-10 devices installed in and around my home. I have a few X10 door/window switches, motion detectors and various lamp/appliance modules. I also have a CM11A and a Weeder W800RF for monitoring and issuing commands from my PC. I also have a CM17 that I plan to add into the works, but it's not in use at this time.

For software, I've decided to roll my own and it's all written in Delphi for the Windows platform. My software's current features are: CM11A, W800RF support - although CM11A support isn't completed at this time. Currently the software only has X10 events, so for example, when a movement is detected then a sound can be played, or a light turned on, or even synthesized speech - or any combination of these things. This is handy for reacting to things that happen, but there is definitely a need to add timed events (example: turn on bedroom light at 6 AM, Monday-Friday) and delayed events after a reactionary event has occurred (example: 5 minutes after movement, turn off the light).

There are two modes of software operation for now, those modes are "home" and "away". When "away" is flagged, then all home information is logged and passed on to the outside world via Twitter ("dons_house" on twitter, but the account is private). Also, monitoring of 2 security cameras with motion detection are forwarded on to my cell phone / e-mail account when this mode is set.

One of the problems with the motion detection system is that, on cloudy or windy days, shadow movement gives you LOTS of motion detection. This is something I need to address by either moving the cameras and motion detectors, or changing the amount of noise, blocking out certain areas from view or some combination of these.