Go to main page
Biography, Resume, Projects, Blog

Smart Home project

Smart Home is my hobbyist project dedicated to home automation technology with extended set of features. The most notable features are:
  • Managing lighting and electrical equipment using IR remote control.
  • Voice control for all Smart Home features including its programming.
  • Voice-controlled audio player (a user can speak out audio composition name to play).
  • Using motion and presence sensors to control lighting.
  • Security features: continuous recording of video/audio, support for security alarm.
  • Remote control: Web-based interface, SMS notification/control, voice control over GSM network.

The architecture of Smart Home is based on multi-agent technologies. There are multiple hardware devices unified by the system bus which connects to the central computer. Each device has its own firmware. Central computer software is also multi-agent and can be easily distributed over several processing nodes. All high-level processing (system events such as pressing a button on remote control, recognized voice phrase, etc.) is done using versatile scripting language specially designed for event-oriented queuing systems with high level of parallelism which can be effectively utilized using multi-core processors and distributed computing.

The current state of the implementation is as follows:
  • High- and low-level architecture has been fully developed.
  • Core central processing software has been designed and implemented.
  • There are working hardware implementations for the following modules:
    main module, RS232<->RS485 interface converter, Digital Output module, IR receiver/transmitter module, dimmer module
  • All the firmware for the above mentioned modules was designed, implemented and tested
  • Work on attaching audio interfaces and voice control is in progress
  • Light control circuits (dimmers) are fully developed and tested.

Below are some photos of Smart Home hardware modules. Please, click any photo to enlarge it.

Main module (used as host for other modules installed via slots):
Copyright (c) Sergey B. Voinov.
Smart Home project.Copyright (c) Sergey B. Voinov.
Smart Home project.
Copyright (c) Sergey B. Voinov.
Smart Home project.Copyright (c) Sergey B. Voinov.
Smart Home project.

Main board (contains slots for installable modules and control logic for power management):

Copyright (c) Sergey B. Voinov.
Smart Home project.Copyright (c) Sergey B. Voinov.
Smart Home project.
Copyright (c) Sergey B. Voinov.
Smart Home project.

Relay block (used to switch AC power load, contains 10 relays and control circuitry):

Copyright (c) Sergey B. Voinov.
Smart Home project.Copyright (c) Sergey B. Voinov.
Smart Home project.

Test board (I used it to practice my skills on PIC16 series microcontroller):

Copyright (c) Sergey B. Voinov.
Smart Home project.

Electric panel (contains main module and high voltage circuits - relay blocks and dimmers):

Copyright (c) Sergey B. Voinov.
Smart Home project.

IR host (unified module for IR receiver and transmitter, the first remote device on the system bus):

Copyright (c) Sergey B. Voinov.
Smart Home project.

Barix IP audio module (www.barix.com). It's a high-end audio module capable of playing and recording audio using ordinary Ethernet network. The device can encode/decode MPEG 1 audio stream and transmit it over the network. It also has Web-interface, TCP<->UART converter, auxiliary I/O connectors and many other features. Unfortunately, it costs as much as 360 euro, so it is only my engineering sample. What I did is just packing the PCB into a plastic case (see last 3 photos) with audio input/output and AC/DC adapter input.

Copyright (c) Sergey B. Voinov.
Smart Home project.Copyright (c) Sergey B. Voinov.
Smart Home project.

Copyright (c) Sergey B. Voinov.
Smart Home project.Copyright (c) Sergey B. Voinov.
Smart Home project.
Copyright (c) Sergey B. Voinov.
Smart Home project.

Dimmer board - contains 20 dimmer circuits using BT139 series triacs and MOC3020 optocouplers. It also has a circuit which generates AC line synchronized pulses for triac phase control. The dimmers are controlled by MCU-based system network device (separate board).

Copyright (c) Sergey B. Voinov.
Smart Home project.Copyright (c) Sergey B. Voinov.
Smart Home project.
Copyright (c) Sergey B. Voinov.
Smart Home project.

Dimmer control board - its an "extension" board to be placed in main module's mother board. It features multiprocessor design. One PIC16F873A (at 20 MHz) runs phase-pulse algorithm to simultaneously control 20 dimmers. Another PIC16F648A (at 11.0592 MHz) interacts with the system network and sets brightness levels for the first MCU using custom MCU interconnection bus. Dimmer control board and dimmer board are connected using ordinary IDC-34 connectors. This design demonstrates the fact that a MCU is capable of controlling a large set of dimmer circuits using phase-pulse algorithm (some time ago an electronics engineering expert told me that such a design is not possible).

Copyright (c) Sergey B. Voinov.
Smart Home project.

Digital output module. It has 30 digital outputs that are controlled over the system network. The module is used to drive relay blocks (see above). So, 30 relays switching 220V loads can be simultaneously controlled. The relays are mainly used to switch power outlets and lights.

Copyright (c) Sergey B. Voinov.
Smart Home project.

System network module. This module provides RS-485 interface which is used to control all devices on the system bus. The module is capable of converting two standard RS-232 interfaces to the corresponding RS-485 interfaces with data transfer rate up to 115200 bod each. RS-232 interface is the primary mean of connecting Smart Home hardware to the central computer (PC).

Copyright (c) Sergey B. Voinov.
Smart Home project.

I cooperate with many companies regarding electronic component supplies, PCB design, metal processing (used to produce metal cases for the equipment). Some of the PCBs are home-made (using 2-layer FeCl3 etching process, vias are made by connecting layers by copper wires), others are ordered at industrial production fabs. So, for example, main board (see the photos above) has 6 layers with minimal route spacing of 0.635 mm.

All hardware modules use RS485 interface to connect to the central computer. The central computer is an ordinary PC containing Intel CoreDuo2 processor and 2GB RAM, running Windows Server 2003. The PC has special low-profile case which allows placing it in the ceiling space. All Smart Home Hardware and central computer are connected to UPS.

All hardware modules connected to the system network (RS485) use PIC16 series microcontrollers. Particularly, PIC16F628A are used in simple devices (which do not require much program memory). "Advanced" devices, such as IR receiver/transmitter, use PIC16F648A microcontrollers - it turns out that firmware features such as recognizing IR protocol, emitting IR packets and processing system requests require more than 2048 PIC's 14-bit instruction words.

It's hard to debug HW issues with my set of equipment, but I use well-recommended 2 channel digital oscilloscope Rigol DS1022C (25MHz bandwidth, 450MHz sampling):

Copyright (c) Sergey B. Voinov.
Smart Home project.

Since all MCUs are functioning at 11.059MHz clock, it's more than sufficient.

I use the following software to design Smart Home:
  • Proteus 7 Professional: schematics and PCB design.
  • SolidWorks: physical case/construction design.
  • AutoCAD: preparing documentation for industrial processes (metal processing, etc.).
  • Cadence OrCAD: modeling of analog circuits.
  • MS Visual Studio: central computer software development.
  • HI-TECH Software HI-TIDE: PIC16 firmware development.
  • Phyton ChipProg programmer: PIC16 MCU programming.