Hello,
I am really glad about mE products and this great forum. So I would like to tell you something I am working on.
After 1.5 years of development (OK, I also have had to build the house itself) the first step of my home automation system is now released and operating!
Architecture:
Bus Nodes
Each group of switches on the wall contains one bus node (max. 8 buttons)
Circuit board 50mm diameter, 15 mm high adapted for normal UP-sockets
Connection for room temperature sensor and window contacts, one LED for status info
Bus node sends CAN messages according to an event (temperature, pressed button, window opened)
For power saving, sleep mode of PIC is used. Wake-up on CAN possible
All nodes and actors are linked together with one serial CAN bus line (200m, 125kBaud)
CAN cable also contains 12V power supply for the nodes
Each lamp, power socket or shutter has its own power cable to one of the 2 electric control cabinets in the base and first floor.
Bus Actors
In each cabinet is one bus actor. It contains LC-display, 4 buttons for manual control and 64 relays
RS232 connector for bootloading of new software
Bus actors analyses the CAN messages and controls the relays accordingly
Processors PIC18F2580 / PIC18F4580 with 4 / 8 MHz, programmed on EasyPic4 with mikroBasic from MikroElektronika
HW was made with single and double layer PCBs, using standard electronic components, so soldering was easly possible
Advantages for this architecture:
only few electronic units necessary
intelligence and program effort concentrated on the 2 bus actors
all types of cables are centralized, maximum flexibility
Disadvantages:
huge wiring effort. I installed about 2000m of cables (230V power, ISDN, TV, video, ethernet)
But wires are still cheaper and more reliable than electronic components
Yes, I know, there were already commercial solutions available, but they seem to expensive to me
Yes, my system is yet an other home control, but mine is already operating in a real house…
Already realized functionality:
light dimming, light central off/on, light scenarios, central shutter control
next steps:
display unit for status information, automated shutter control
GSM modem for alarm functions (water, fire, open windows)
I am also looking for an CAN bootloader. Does anyone can help me on that?
Project released: 20 PICs controlling my home via CAN
take a look to this project http://www.abcelectronique.com/bigonoff ... ?par=5cfad
it my help you for your project
it my help you for your project
-
- Posts: 337
- Joined: 17 Apr 2008 02:53
- Location: Fantasy Land
Awesome job, piccy! It sounds like you did a great job of planning to make it all work. I have given some small amount of thought to this for my own home as well and have a question or two.
1. You said you have the system running with 12V power and can bus. Do you have one 12V supply or many small ones?
2. What type of short-circuit protection do you have for the 12V?
3. Other protections? Lightning? Static? Overtemp?
4. Did you build in some sort of fail safe mode to allow you to operate your lights, etc. in the event of a system crash?
5. Is there connection to the outside world for emergency messages? Such as telephone modem or voice message or email?
If you have the time, some photos would be really cool!
1. You said you have the system running with 12V power and can bus. Do you have one 12V supply or many small ones?
2. What type of short-circuit protection do you have for the 12V?
3. Other protections? Lightning? Static? Overtemp?
4. Did you build in some sort of fail safe mode to allow you to operate your lights, etc. in the event of a system crash?
5. Is there connection to the outside world for emergency messages? Such as telephone modem or voice message or email?
If you have the time, some photos would be really cool!
Each of the 2 actors/cabinets have their own supply1. You said you have the system running with 12V power and can bus. Do you have one 12V supply or many small ones?
The supply itself is protected, for the output I use 2 electronic fuses (one for the bus, one for the relais)2. What type of short-circuit protection do you have for the 12V?
each node has a voltage regulator, which convers short-circuit protection3. Other protections? Lightning? Static? Overtemp?
If only the nodes or the bus is down, I am able to control each relais within the actor menu buttons4. Did you build in some sort of fail safe mode to allow you to operate your lights, etc. in the event of a system crash?
One of my next ideas. The actor has RS232 already on board. So connection to an GSM modem is no big deal.5. Is there connection to the outside world for emergency messages? Such as telephone modem or voice message or email?
Where I should upload them? I have no own serverIf you have the time, some photos would be really cool!
One of the best image upload site: http://imageshack.us/piccy wrote:Where I should upload them? I have no own server
I have send some pictures, scematics and code to mE.
The current CAN protocol is really pure simple:
Each pushbutton of the bus node send 3 states:
short press, long press and release after long press.
So I can use simple dimmer modules, which where normally controlled with pushbuttons directly. The CAN bus acts just as an extention.
The protocol for the buttons is therefore just one data byte, where I can see, which button is in which state.
the actors are receiving the byte and here I have a table, to see which button should switch which relais.
So mostly all SW changes are only here necessary.
The 2 way communication is in preparation for status indication etc.
Here I will need more bytes, so to distinguish, I can just use the length of the comands...
The bus nodes are in sleep mode to reduce the power consumption on the long bus line. They were just waked by a key press for a short time.
For back communication, they have to be waked-up.
The wake-up on CAN functionality was a little tricky, but now it works at least on my desk.
Piccy
The current CAN protocol is really pure simple:
Each pushbutton of the bus node send 3 states:
short press, long press and release after long press.
So I can use simple dimmer modules, which where normally controlled with pushbuttons directly. The CAN bus acts just as an extention.
The protocol for the buttons is therefore just one data byte, where I can see, which button is in which state.
the actors are receiving the byte and here I have a table, to see which button should switch which relais.
So mostly all SW changes are only here necessary.
The 2 way communication is in preparation for status indication etc.
Here I will need more bytes, so to distinguish, I can just use the length of the comands...
The bus nodes are in sleep mode to reduce the power consumption on the long bus line. They were just waked by a key press for a short time.
For back communication, they have to be waked-up.
The wake-up on CAN functionality was a little tricky, but now it works at least on my desk.
Piccy
Thanks to Zristic, here are some links:
Pictures and overview:
Visio-Plan Elektro V2.0.pdf
Scematics in Eagle format:
can actor main board.brd
can actor main board.sch
can sender.brd
can sender.sch
can_actor_driver_board.brd
can_actor_driver_board.sch
Source code:
http://www.mikroe.com/upld/piccy/can_receiver.pbas
http://www.mikroe.com/upld/piccy/can_receiver_og.pbas
http://www.mikroe.com/upld/piccy/can_receiver_ug.pbas
http://www.mikroe.com/upld/piccy/can_switch.pbas
Pictures and overview:
Visio-Plan Elektro V2.0.pdf
Scematics in Eagle format:
can actor main board.brd
can actor main board.sch
can sender.brd
can sender.sch
can_actor_driver_board.brd
can_actor_driver_board.sch
Source code:
http://www.mikroe.com/upld/piccy/can_receiver.pbas
http://www.mikroe.com/upld/piccy/can_receiver_og.pbas
http://www.mikroe.com/upld/piccy/can_receiver_ug.pbas
http://www.mikroe.com/upld/piccy/can_switch.pbas