From: <Rob...@fr...> - 2001-01-17 17:33:19
|
Hello, I'm designing custom home automation network and would like to add custom made serial interface class to mh. Carefully studying sources of Serial_Item and X10_Item I have some questions (my knowledge of Perl is 'short' so maybe there are some wrong opinions): - is Serial_Item really general class - as I saw it is X10 aware (parsing messages that start with 'X' and switching states to all X10 Items and so on) ? - if one would like to add custom serial interface - should I inherit from Serial_Item, or go into Serial_Item class and add my 2 cents. IMHO the best would be to make general serial item and then inherit all custom ones (X10, Homevision, ....). In that case it would be easier to add custom interfaces to all other people - when one needs it it just picks the right one. - if I use Serial_Item as generic serial port and I want to send message that incidentally begins with 'X' will anything strange happen ? Thanks in advance, Robert Rozman. P.S.: Many times we just ask, but occasionally is nice to give all the credits to this incredible 'misterhouse' community and of course all the pioneers of this projects (especially Bruce). |