Monday, November 15, 2010

Rebirth.

Hey guys, I've been away for a while and haven't updated... that's because I bought a house!!

Home Automation key ingredient: A house.

Got just that now. Along with all sorts of toys and gadgets. List of new toys:

Asus RN-N16 Gigabit Router
TrendNet 5-port Green Gigabit Switch
1000FT Cat5e cable
Samsung 7.2 Audio Video Receiver
5.1 Bose Surround speakers
Yamaha Outdoor Speakers
Some other floor standing speakers
Samsung Blueray Wireless Player w/ apps
DroidX 2.2 rooted

That's all the toys... gotta wire them all up, and start the long programming sessions, testing, and all the wiring.

I have found a nice Solid State Relay (from now on refer to as SSR) that are zero cross-over and cost about $5, which is how much I was gonna pay for the normal mechanical relays! Score. They're also VERY easy to use, and offer much quicker reaction with no "clicky" noise of mechanical relay. - Thanks to Kevin Johnson for the SSR, and the Temp Sensor.

I have successfully created a working prototype of a digital "thermostat" program with the Arduino, so the HVAC system will probably be the first to be automated... we'll see.

That's all for now... lots and lots more to come in the next few weeks.

Thursday, July 22, 2010

SUCCESS, Part I

The project is rolling along very nicely.

I have successfully set up the Arduino with the Ethernet Shield, and powering everything up the way I wanted to, and have all the common ground, and somewhat safe wiring.

I have successfully set up a webserver on my PC with PHP, MySQL, and all the jazz. Now I need to move that to a server soon... but that can wait. The PHP website is built, and is working.

I was able to turn on two LEDs and a locking mechanism solenoid with my phone! Through the wifi connection!

Here's a video:
http://www.youtube.com/watch?v=l9Ooo3GnrPo

More on parts I used tomorrow... and shopping.....

Monday, July 19, 2010

Day... 3?

This is the third post, but it's far from Day 3 of the project. I have managed to control an LED through PHP wrapped around the HTML server on the Arduino. In layman's term... I can turn on/off an LED from a website. On my phone, on the computer, from the other room, on the toilet. Whatever.

Ofcourse this is just concept, it'll be simple to turn this LED into a 60watt lightbulb, or a solenoid, or a sprinkler system, or whatever. The key here is that the I can control pins from the Arduino from a web interface.

So I guess the difficult interfacing hardware phase is out of the way. Not only can I control it, but it also has feedback, so I know if it's on or off! Which is sweeeeet. So I will also be able to monitor the house. This also mean I will be able to read in the data from the Arduino into a database.

Sunday, July 11, 2010

Pictures of the Toys

Here are the pictures of the toys... most of the things have arrived or I already have. Still waiting for a couple other things, but the prototyping and rough draft will start this week.






In the pictures, there are the 2 Arduino, the Seeeduino Mega, Arduino Ethernet shield, PIR sensor, Ultra Sonic Sensor, X10 modules with X10 transceiver, the locking mechanism, and some other relays and stuff.

Waiting on the Parallax RFID reader... and some other stuff.

Friday, July 9, 2010

Home Automation 1.0

So the draft work has begun. I have decided and picked out most of the components, shopping is already in process.

Part List (I will go back and update this as I get more things or receive more):
2 Arduino duemilanove (ordered) (received)
1 Seeeduino Mega (ordered) (received)
1 Ethernet shield (ordered) (received)
2 Parallax RFID Reader (ordered)
2 Parallax PIR Sensor (Got one, ordered one more)
2 Parallax Ultrasonic Sensor (Already Owned)
1 Electric Door Solenoid (ordered) (received) (will need 5)
X10 TW-523 (Ordered) (Received)
25 reed switch with magnet (Already have)
4 temperature sensor (ordered)
10 110V X10 Module (Already have)
There are a lot of other parts... as I remember them I'll put it on here.
But of course you'll have basic tools and electrical components.


The basic outline of the system:

Seeeduino will be the main "server-duino", communicating with the "Interface Server" sending informations from other arduinos or from sensors. The two other arduinos will be communicating with the Seeeduino using I2C protocol which only take up 2 wires.
The 2 arduino will be connected with the Parallax RFID reader, Ultrasonic Sensor, and PIR sensor. This is for the door side security measures. The PIR sensor will monitor the door way, to let me know when people come 20ft close to it. The Ultrasonic sensor will let me know when someone approach the RFID reader, which activate it. This will save a lot of energy because the Ultrasonic sensor pull only 20mA power, which is a LOT less than the RFID reader in "ACTIVE" mode.

The Interface will be PHP based. When the site "load", it will poll data from the Seeeduino and displays it. The server will poll information every 10 minutes, to keep a nice logging system so I can monitor the status.

The Interface will include buttons and controls, so that it can send commands to the Seeeduino using POST command straight to the Seeeduino, activating whatever device was requested.

The Seeeduino will either pull the relay, trigger an event, or send an X10 command.

That's all I have so far. The Interface server will be running XAMPP, which is a server that incorporate Apache Web Server, MySQL, PHP, and Pearl.
The Interface server will be running on a local network, which consist of the server (or router), a 24 port 10/100/1000 switch, and a Wifi AP (wont be needed if I use router). I prefer the server as the router because it's more customizable, but router is easier to "set and forget". Thanks for reading so far... if you're lost somewhere or want more details, ask. My OneNote research book is very thick now and my Bookmark tab for this research has gone wild.

Tuesday, July 6, 2010

Another day of research.

After much researching, I've came to the conclusion of using the Arduino as a base controller.

I will be using a Seeeduino Mega as a master, with an ethernet shield, then a couple slave arduino, depending how far the distance is from the sensors/relays to the main Seeeduino, which will be in the server cabinet along with a Windows 2008 Server computer running a web server.

The Seeduino, from now on refer to as (AR-master) will communicate with socket connection to the server, only to send/receive simple data, like if a GET / POST request from the HTTP server. Also will send information on different sensors, so the website will display temperatures / status of the house as well. That's going to be the gist of the controller side.

Here is the outline of the actual Home Automation side:

Door/Entrance
The entrance to the house can be controlled by WIFI through the web page, but that will require the person to have a Smartphone. The alternative way to enter the house, or back up, is with an RFID keytag, which there will be RFID readers at all the door. This will allow me to program who can come in and out by giving them an RFID tag. I can give my maid (if I ever can afford one) one that is set to allow entrance to the house only from 1-6pm on tuesday and thursday to do laundry. At other times, it will deny her access. Nice.
The door lock system will run on 12v, which the Arduino can easily control. There will be a 12V uninterrupt battery backup just in case... and one of the door in the back will use the regular old' key and lock, as precautionary measure. There will also be a smoke detector that will plug into the microcontroller, so that if it detects smoke, all doors automatically unlock. In case of fire ofcourse.

Lighting/Wiring/Socket Controls
The lighting will be simple CAT5 running 12v and pulling 12v car relays. This will trigger the 110v. Very simple set up, most of the main home lighting will be control by the system. Also some power socket, the critically located one, will be control by this as well, so I wont have to get those ugly timers and stuff for the house. This way I can plug a coffee maker or something in, set it on, and it'll go off at 6am and turn off at 6:30. Swell. Or another example would be my Aquarium lighting, set on a timer.

Security
The door and entrance are a security measure. But this section focus on a security system. Most doors and windows will use Hall Sensor, or Reed Switch with a magnet to sense if it's open/close. When the alarm is turned on, all the sensors will be read, and if it state change, the alarm will ring. This mean I can leave any of the doors/windows open and the alarm will still arm. A PIR (passive infrared sensor) will be used to monitor the larger rooms for movements. A laser along with reflective mirrors and a light sensor will be used for intrusion detection.

Monitoring:
As you know from above, there will be a smoke detector, on top of that, I'll have a water meter sensor, to read how much water I'm using by day, week, and month. An electric current sensor will allow me to see how much power I'm using as well. If I can figure out a way to measure my gas usage, I would add that on. A bunch of temperature probes will be installed throughout the house so I can see the correlation between temperature to electric usage, which would deprive at AC usage. Ofcourse I will be able to monitor all this on the web interface.



That's it for now, the shopping has begun. I've bought a Seeeduino Mega, and an Ethernet shield. I already have two arduinos, two Ultrasonic Sensor, a couple PIR sensor, the door locking mechanism, and other stuff to prototype the system with. Once I get everything working, I will order more for the installation and testing.

If you have to ask WHY i'm doing it... you might want to stop reading. Great minds are not limited by logic. **DISCLAIMER** This is MY quote, I will copyright it, please refrain from using it without credit to me :-P

Monday, July 5, 2010

Research

The "Home Automation Web Interface" Project has been initialized.

I am in the process of buying a home, and being a Computer Science major, I have to have it Wired to the T.

The purpose of the project is to have a house wired with automation and web interface control. With any web-enabled smart phone with wifi connection, I will connect to my home wifi, and be presented with a Web Interface that allow me to control the home.
The controls will include, but not limited to: Security System, Sprinkler System, Home Lighting and automation, and entertainment / media control.

I have not define the parameters for the project, as I am still in the research stage and have no pick any specific implementation yet. But as of now, the favored choice is the Arduino Mega, with an Ethernet Shield, and a Home Server.