Author Topic: x10 CM11A support is now fixed!  (Read 45096 times)

chrisbirkinshaw

  • Guru
  • ****
  • Posts: 431
    • View Profile
Re: x10 CM11A support is now fixed!
« Reply #45 on: April 11, 2008, 04:31:44 pm »
Still no luck with the latest binaries. Doesn't even trigger anything now or log anything other than the initial creation of children.

Compared the size of the CM11A binary:

2569811 LMCE original
2567069 First version of latest binaries
174880  Latest version of binaries

Hmm, something strange here!

Chris


nite_man

  • NEEDS to work for LinuxMCE
  • ***
  • Posts: 1019
  • Want to work with LinuxMCE
    • View Profile
    • Smart Home Blog
Re: x10 CM11A support is now fixed!
« Reply #46 on: April 11, 2008, 04:33:40 pm »
@Chris: I just used strip to make the size of binaries smaller.

@NOS: I have a strange problem. When I send a command to the X10 lamp module I don't see any messages in the CM11A log. But the lamp is switched ON/OFF with delay in 20-30 seconds. Here is a DCERouter.log:
Code: [Select]
08      04/11/08 17:28:58.692           Received Message from 0 (unknown / ) to 38 (X10 Light Switch (on/off) / Living Room/Family Room), type 1 id 192 Command:On, retry none, parameters: <0x2aaabd813950>
08      04/11/08 17:28:58.693             Parameter 97(PK_Pipe):  <0x2aaabd813950>
08      04/11/08 17:28:58.693             Parameter 98(PK_Device_Pipes):  <0x2aaabd813950>
05      04/11/08 17:28:58.738           Socket::ReceiveData 0x12778c0 failed, bytes left 0 start: 33360000 1: 0 1b: 0 2: 0 2b: 0 m_Socket: 169 Incoming_Conn Socket 169 127.0.0.1 <0x2aaabd813950>
05      04/11/08 17:28:58.738           Socket::ReceiveString2 ReceiveData failed m_Socket: -1 Incoming_Conn Socket 169 127.0.0.1 <0x2aaabd813950>
05      04/11/08 17:28:58.738           TCPIP: Closing connection to -1003 (Router Dev #0) 0x12778c0 m_Socket: -1 <0x2aaabd813950>
05      04/11/08 17:28:58.738           Router::RemoveAndDeleteSocket 0x12778c0 -1003 <0x2aaabd813950>

This is a CM11A.log:
Code: [Select]
========== NEW LOG SECTION ==========
1       04/11/08 17:27:43       37 (spawning-device)    Starting... 2
1       04/11/08 17:27:43       37 (spawning-device)    Found /usr/pluto/bin/CM11A
05      04/11/08 17:28:09.120           Creating child 38 <0x2af453a04940>
05      04/11/08 17:28:09.120           Note: Device manager has attached a device of type 37 that this has no custom event handler for.  It will not fire events. <0x2af453a04940>
05      04/11/08 17:28:09.120           Note: Device manager has attached a device of type 37 that this has no custom handler for.  This is normal for IR. <0x2af453a04940>
05      04/11/08 17:28:09.120           Creating child 39 <0x2af453a04940>
05      04/11/08 17:28:09.120           Note: Device manager has attached a device of type 54 that this has no custom event handler for.  It will not fire events. <0x2af453a04940>
05      04/11/08 17:28:09.120           Note: Device manager has attached a device of type 54 that this has no custom handler for.  This is normal for IR. <0x2af453a04940>

Michael Stepanov,
My setup: http://wiki.linuxmce.org/index.php/User:Nite_man#New_setup
Russian LinuxMCE community: http://linuxmce.ru

nosilla99

  • Veteran
  • ***
  • Posts: 120
    • View Profile
Re: x10 CM11A support is now fixed!
« Reply #47 on: April 11, 2008, 05:32:14 pm »
@nite_man

I can't understand why you see no startup messages such as which serial port the CM11A is using etc

Do you have time to get on IRC in the next 30 minutes or so ?

NOS
« Last Edit: April 11, 2008, 06:01:28 pm by nosilla99 »

nite_man

  • NEEDS to work for LinuxMCE
  • ***
  • Posts: 1019
  • Want to work with LinuxMCE
    • View Profile
    • Smart Home Blog
Re: x10 CM11A support is now fixed!
« Reply #48 on: April 11, 2008, 06:08:27 pm »
@nite_man

I can't understand why you see no startup messages such as which serial port the CM11A is using etc

Do you have time to get on IRC in the next 30 minutes or so ?

NOS

Will be able to chat after one hour.
Michael Stepanov,
My setup: http://wiki.linuxmce.org/index.php/User:Nite_man#New_setup
Russian LinuxMCE community: http://linuxmce.ru

nosilla99

  • Veteran
  • ***
  • Posts: 120
    • View Profile
Re: x10 CM11A support is now fixed!
« Reply #49 on: April 11, 2008, 06:17:35 pm »
@nite_man

I will probably be off line by then, however can you tell me which version of LMCE you are running and can you post a copy of devicepoll.cpp here ?

I will try to catch up with you later


NOS

chrisbirkinshaw

  • Guru
  • ****
  • Posts: 431
    • View Profile
Re: x10 CM11A support is now fixed!
« Reply #50 on: April 11, 2008, 07:03:59 pm »
I'm going to have a go at compiling it. Is it safe to build LMCE on a production system? I noticed that when I started to make it tried to stoop and start my mysql server and connect to it but failed. This scared me a bit so I stopped.

Chris


nosilla99

  • Veteran
  • ***
  • Posts: 120
    • View Profile
Re: x10 CM11A support is now fixed!
« Reply #51 on: April 11, 2008, 08:56:29 pm »
Hi Chris,

I always build on my production core and have not had a problem so far, some of the messages regarding mysql are indeed scary but it has not caused any problems on my system, but I may just be lucky  :o

As non of the executables or libraries are installed you should be ok

Good Luck

NOS


nite_man

  • NEEDS to work for LinuxMCE
  • ***
  • Posts: 1019
  • Want to work with LinuxMCE
    • View Profile
    • Smart Home Blog
Re: x10 CM11A support is now fixed!
« Reply #52 on: April 12, 2008, 10:39:07 am »
@nite_man

I will probably be off line by then, however can you tell me which version of LMCE you are running and can you post a copy of devicepoll.cpp here ?

I will try to catch up with you later

NOS

Thanks NOS for your help. I run LinxuMCE 0710 Beta 4 installed from DVD. See my devicepoll.cpp here - http://www.mediafire.com/?ymbnjcmyajx
Michael Stepanov,
My setup: http://wiki.linuxmce.org/index.php/User:Nite_man#New_setup
Russian LinuxMCE community: http://linuxmce.ru

chrisbirkinshaw

  • Guru
  • ****
  • Posts: 431
    • View Profile
Re: x10 CM11A support is now fixed!
« Reply #53 on: April 13, 2008, 03:20:04 pm »
Ok, I did a make as per the wiki but when I went into Lighting_Plugin and CM11A src dirs they did not seem to be built. I did a make, make bin, make so and was successful for all but the Lighting_Plugin. Error below:
Code: [Select]
dcerouter_64097:/usr/src/lmce_svn/lmce/src/Lighting_Plugin# make all
g++ -o Lighting_Plugin Main.o Lighting_Plugin.o ../Gen_Devices/Lighting_PluginBase.o -L../lib  -lpluto_main -lSerializeClass -lDCECommon -lPlutoUtils -lpthread
Lighting_Plugin.o: In function `DCE::Lighting_Plugin::LightingFollowMe(DCE::Socket*, DCE::Message*, DCE::DeviceData_Base*, DCE::DeviceData_Base*)':
/usr/src/lmce_svn/lmce/src/Lighting_Plugin/Lighting_Plugin.cpp:222: undefined reference to `DCE::FollowMe_Device::HandleFollowMe(DCE::Message*)'
Lighting_Plugin.o: In function `DCE::Lighting_Plugin::Register()':
/usr/src/lmce_svn/lmce/src/Lighting_Plugin/Lighting_Plugin.cpp:141: undefined reference to `DCE::Datagrid_Plugin::RegisterDatagridGenerator(DCE::DataGridGeneratorCallBack*, int, int)'
collect2: ld returned 1 exit status
make: *** [Lighting_Plugin] Error 1

I also tried going into the DCE and Datagrid_plugin folders and making them first but this made no difference. Does anyone know what's going on here?

Thanks,


Chris



nosilla99

  • Veteran
  • ***
  • Posts: 120
    • View Profile
Re: x10 CM11A support is now fixed!
« Reply #54 on: April 13, 2008, 04:44:07 pm »
Chris

Ignore that error, you just need to a "make so" in the lighting_plugin

NOS

nite_man

  • NEEDS to work for LinuxMCE
  • ***
  • Posts: 1019
  • Want to work with LinuxMCE
    • View Profile
    • Smart Home Blog
Re: x10 CM11A support is now fixed!
« Reply #55 on: April 13, 2008, 04:48:05 pm »
First of all, you should run make so for the Lighting_Plugin I guess. Also be sure that you use your working libraries:

Code: [Select]
export SNR_CPPFLAGS="-L/usr/pluto/lib"
Michael Stepanov,
My setup: http://wiki.linuxmce.org/index.php/User:Nite_man#New_setup
Russian LinuxMCE community: http://linuxmce.ru

nosilla99

  • Veteran
  • ***
  • Posts: 120
    • View Profile
Re: x10 CM11A support is now fixed!
« Reply #56 on: April 13, 2008, 05:01:56 pm »
@nite_man

Have you got any further in figuring out why you are not getting very little logging from the CM11A ?

Your devicepoll.cpp is definitely the last one which was committed to SVN so I am at a loss unless you have somehow managed to turn logging off

NOS

nite_man

  • NEEDS to work for LinuxMCE
  • ***
  • Posts: 1019
  • Want to work with LinuxMCE
    • View Profile
    • Smart Home Blog
Re: x10 CM11A support is now fixed!
« Reply #57 on: April 13, 2008, 09:22:34 pm »
Have no idea why. I have the same problem with GC100. I don't see any debug message there but can see in DCERouter.log
Michael Stepanov,
My setup: http://wiki.linuxmce.org/index.php/User:Nite_man#New_setup
Russian LinuxMCE community: http://linuxmce.ru

chrisbirkinshaw

  • Guru
  • ****
  • Posts: 431
    • View Profile
Re: x10 CM11A support is now fixed!
« Reply #58 on: April 14, 2008, 12:54:13 pm »

Checked out the latest SVN but the devicepoll.cpp was not the latest, so I downloaded the source from the charonmedia trac ticket. Compiled and installed as per instructions. CM11A now listens to messages from the powerline, and I do not see any checksum errors, however there is no enhanced logging at all.

I am no longer seeing 30 sec delays though, which is good news. I will say though that compared to the HA system I am migrating away from (Misterhouse) LMCE is not as fast. The delay seems to be be in DCE router rather the CM11A driver, as the delay also affect the floorplan.

Chris

caiman

  • Veteran
  • ***
  • Posts: 119
    • View Profile
Re: x10 CM11A support is now fixed!
« Reply #59 on: April 15, 2008, 04:12:49 pm »
Is anyone seeing this with the svn sources ?

Code: [Select]
Exception occured on CM11A's serial port: 0. Sleeping for 5.1 second.

It has worked for a while, not sure what changed...