News:

Rule #1 - Be Patient - Rule #2 - Don't ask when, if you don't contribute - Rule #3 - You have coding skills - LinuxMCE's small brother is available: http://www.agocontrol.com

Main Menu

Supporting the ACT Solutions ZCU201 USB Z-wave Interface

Started by totallymaxed, January 04, 2008, 12:59:34 AM

Previous topic - Next topic

totallymaxed

Quote from: Domodude on January 18, 2008, 08:12:55 AM
Morning all,

Almost there. As Hari wrote, we got a lot closer to a working Z-wave setup. The only problem remaining, I hope, is the transfer of the config from the ZTH200 Homepro primary controller to LinuxMCE.

(I had some trouble getting the ZCS201 recognized by lmce, but I think that it eventually worked again after I got rid of all interfaces, rebooted the core, and then started over. That included attaching the ZCS201, turning on the system, adding the interface in the web setup, update, reload dcerouter. I think that was all it took. I will replay everything once the download problem is out of the way.)

Andrew, I understand you own a ZTH200? Could you tell me if something is wrong here?

  • Add units to the ZTH200. I have one plugin dimmer unit on group 1, 3 and 6 each.
  • From setup, select transfer partial configuration
  • The ZTH200 will tell me Transfer Successful (or something like it)
After this, lmce has only one light as a child device to the zcs201. If I select Transfer FULL Config, the transfer somehow fails, I think it mentions a Data Error.

Any ideas?

Thanks,
Mark


Yes we use the ZTH200 Master Controller/remote. We always use 'transfer full config' but we do see a transfer error sometimes. Just resend a few times until you get a good transfer. Are you using the Lighting Wizard to manage the transfer/addition of the lights?
Andy Herron,
CHT Ltd

For Dianemo/LinuxMCE consulting advice;
@herron on Twitter, totallymaxed+inquiries@gmail.com via email or PM me here.

Get Dianemo-Rpi2 ARM Licenses [url="http://forum.linuxmce.org/index.php?topic=14026.0"]http://forum.linuxmce.org/index.php?topic=14026.0[/url]

Get RaspSqueeze-CEC or Raspbmc-CEC for Dianemo/LinuxMCE: [url="http://wp.me/P4KgIc-5P"]http://wp.me/P4KgIc-5P[/url]

Facebook: [url="https://www.facebook.com/pages/Dianemo-Home-Automation/226019387454465"]https://www.facebook.com/pages/Dianemo-Home-Automation/226019387454465[/url]

[url="http://www.dianemo.co.uk"]http://www.dianemo.co.uk[/url]

1audio

1813 and possibly 1820 are additional controllers on the network or the PIR. I have 3 additional ZWave controllers in the system which should explain that. Or they may be the PIR. I have one light with a device number after a large gap. It gets dumped buy the code and needs to be re-added with almost every router reload if I want to use it.

totallymaxed

Quote from: Domodude on January 19, 2008, 06:37:01 PM
Quote from: totallymaxed on January 19, 2008, 02:31:37 PM
Quote from: Domodude on January 18, 2008, 08:12:55 AM
Andrew, I understand you own a ZTH200? Could you tell me if something is wrong here?
Are you using the Lighting Wizard to manage the transfer/addition of the lights?

Thanks. I will try to use the full config transfer.

I am not using the lighting wizard, because the RS232 is not plug'n'play. It would be great to use the wizard, but so far I have had no luck. So, it's a matter of manually adding the interface, and then transfering the settings...

Mark

ok... well under the hood the same code is being called so doing the upload from Web Admin amounts to the same thing.
Andy Herron,
CHT Ltd

For Dianemo/LinuxMCE consulting advice;
@herron on Twitter, totallymaxed+inquiries@gmail.com via email or PM me here.

Get Dianemo-Rpi2 ARM Licenses [url="http://forum.linuxmce.org/index.php?topic=14026.0"]http://forum.linuxmce.org/index.php?topic=14026.0[/url]

Get RaspSqueeze-CEC or Raspbmc-CEC for Dianemo/LinuxMCE: [url="http://wp.me/P4KgIc-5P"]http://wp.me/P4KgIc-5P[/url]

Facebook: [url="https://www.facebook.com/pages/Dianemo-Home-Automation/226019387454465"]https://www.facebook.com/pages/Dianemo-Home-Automation/226019387454465[/url]

[url="http://www.dianemo.co.uk"]http://www.dianemo.co.uk[/url]

1audio

The lights won't appear until you rebuild the Orbiter. Have you reset the router and rebuilt the Orbiters?

totallymaxed

Quote from: Domodude on January 19, 2008, 06:51:29 PM
Come to think of it....

I have not yet been able to get the floorplan function to work. I added my lights thorugh the "Download Config" route on the web admin site, and added the lights to my map. However, I see no lights on the map on orbiters!

Another thing: reaction to the web interface is sometimes quite slow, or the command does not get processed at all. To any of you experienced Z-wave users: Is that normal?

Thanks,
Mark


After adding your lights and then adding them to the lighting floorplan you must do a regen all. Then they should appear on the lighting floor plan.
Andy Herron,
CHT Ltd

For Dianemo/LinuxMCE consulting advice;
@herron on Twitter, totallymaxed+inquiries@gmail.com via email or PM me here.

Get Dianemo-Rpi2 ARM Licenses [url="http://forum.linuxmce.org/index.php?topic=14026.0"]http://forum.linuxmce.org/index.php?topic=14026.0[/url]

Get RaspSqueeze-CEC or Raspbmc-CEC for Dianemo/LinuxMCE: [url="http://wp.me/P4KgIc-5P"]http://wp.me/P4KgIc-5P[/url]

Facebook: [url="https://www.facebook.com/pages/Dianemo-Home-Automation/226019387454465"]https://www.facebook.com/pages/Dianemo-Home-Automation/226019387454465[/url]

[url="http://www.dianemo.co.uk"]http://www.dianemo.co.uk[/url]

1audio

ZWave for a single device should be pretty quick. However many devices responding or network problems will slow ZWave down to a crawl. Every device in the system needs to get from the controller to the device to be live or the system will stall looking for them. I usually get almost instant response.

1audio

What do you see under lighting on the Web panel?

This is similar to the problem I have loosing a light form the system.

hari

Quote from: Domodude on January 20, 2008, 11:45:43 AM
I'm just wondering...
I frequently have no reaction to commands (mostly through the web page), but get the following in the log:
05   01/20/08 11:41:53.005      ### Go to timeout queue <0xb6977b90>
05   01/20/08 11:41:53.005      ### skip the next job from timeout queue <0xb6977b90>

What do those two lines mean? It looks like the command will just get skipped.

What also happens is that I try three commands fairly quickly after each other, and I only get the above two lines once.  ??? I'd expect at least six lines. Is there a way to get more verbose debugging output?

hmm, your serial port seems strange. Please try to use a usb/rs232 adapter.

best regards,
Hari
rock your home - [url="http://www.agocontrol.com"]http://www.agocontrol.com[/url] home automation

hari

Quote from: Domodude on January 20, 2008, 04:47:45 PM
It also seems that there are computers that have some sort of serial port stupidity going on that prevents proper communication. At the moment, I don't feel like investigating anymore. Perhaps later!
somehow i knew that ;) Do you provide power to the interface with a brick?

best regards,
Hari
rock your home - [url="http://www.agocontrol.com"]http://www.agocontrol.com[/url] home automation

totallymaxed

Quote from: Domodude on January 20, 2008, 04:47:45 PM
Well this is strange!  ::)

I installed LMCE on a different machine, that I was previously using as an MD. And guess what! It works.

The wizard did not initially recognize the RS232 interface, of course. So I skipped it initially, then I went to the web panel and manually added a Pluto/ZWave device. This recognized the interface, and immediately the video-Lady came on. Just to make sure, I reloaded the dcerouter anyway. I went back to the Setup Wizard through the orbiter, and it recognized my interface. What's more, it already knew that I have three lights. Is that cool or what?  8) Every step from that point on was easy and just *worked*. It's still working after a core reboot (that was a gamble on the other setup!).

So it seems that the ZCS201 is fully supported, obivously aside from the PnP-functionality.

It also seems that there are computers that have some sort of serial port stupidity going on that prevents proper communication. At the moment, I don't feel like investigating anymore. Perhaps later!

Cheers (I'm gonna have a beer!),

Mark


Nice work Mark ;-)
Andy Herron,
CHT Ltd

For Dianemo/LinuxMCE consulting advice;
@herron on Twitter, totallymaxed+inquiries@gmail.com via email or PM me here.

Get Dianemo-Rpi2 ARM Licenses [url="http://forum.linuxmce.org/index.php?topic=14026.0"]http://forum.linuxmce.org/index.php?topic=14026.0[/url]

Get RaspSqueeze-CEC or Raspbmc-CEC for Dianemo/LinuxMCE: [url="http://wp.me/P4KgIc-5P"]http://wp.me/P4KgIc-5P[/url]

Facebook: [url="https://www.facebook.com/pages/Dianemo-Home-Automation/226019387454465"]https://www.facebook.com/pages/Dianemo-Home-Automation/226019387454465[/url]

[url="http://www.dianemo.co.uk"]http://www.dianemo.co.uk[/url]

PeteK

Just out of curiosity, has anyone found a source for the ZCU101/ZCS101 U.S. Versions of these products?

hari

I did some munching to the spcp8x5 code and managed to compile and load the module on 0704. If somebody feels like sending me a ZCU201...

you can download the binary here: http://vt100.at/spcp8x5.ko

compile:

dcerouter_48407:/usr/src/spcp8x5# make
make -C /lib/modules/2.6.20-15-generic/build M=/usr/src/spcp8x5 modules
make[1]: Entering directory `/usr/src/linux-headers-2.6.20-15-generic'
  CC [M]  /usr/src/spcp8x5/spcp8x5.o
  Building modules, stage 2.
  MODPOST 1 modules
  CC      /usr/src/spcp8x5/spcp8x5.mod.o
  LD [M]  /usr/src/spcp8x5/spcp8x5.ko
make[1]: Leaving directory `/usr/src/linux-headers-2.6.20-15-generic'
dcerouter_48407:/usr/src/spcp8x5#


dmesg:

[165370.468000] usbcore: registered new interface driver spcp8x5
[165370.468000] /usr/src/spcp8x5/spcp8x5.c: SPCP8x5 USB to serial adaptor driver v0.01


here is the patch:

diff -u spcp8x5.orig/spcp8x5.c spcp8x5/spcp8x5.c
--- spcp8x5.orig/spcp8x5.c      2006-09-11 08:26:50.000000000 +0200
+++ spcp8x5/spcp8x5.c   2008-01-21 23:17:37.000000000 +0100
@@ -34,7 +34,6 @@
};

static struct usb_driver spcp8x5_driver = {
-       .owner                          = THIS_MODULE,
        .name                           = "spcp8x5",
        .probe                          = usb_serial_probe,
        .disconnect             = usb_serial_disconnect,
@@ -43,7 +42,6 @@

// All of the device info needed for the spcp8x5 SIO serial converter
static struct usb_serial_device_type spcp8x5_device = {
-       .owner                          = THIS_MODULE,
        .name                           = "SPCP8x5",
        .id_table                       = id_table,
        .num_interrupt_in       = 0,
@@ -379,20 +377,16 @@
                tty_flag = TTY_FRAME;
        trace("tty_flag = %d\n",tty_flag);

-       tty = port->tty;
-       if (tty && urb->actual_length) {
-               // overrun is special, not associated with a char
-               if (status & UART_OVERRUN_ERROR)
-                       tty_insert_flip_char(tty, 0, TTY_OVERRUN);
-
-               for (i = 0; i < urb->actual_length; ++i) {
-                       if (tty->flip.count >= TTY_FLIPBUF_SIZE) {
-                               tty_flip_buffer_push(tty);
-                       }
-                       tty_insert_flip_char (tty, data[i], tty_flag);
-               }
-               tty_flip_buffer_push (tty);
-       }
+        tty = port->tty;
+        if (tty && urb->actual_length) {
+                tty_buffer_request_room(tty, urb->actual_length + 1);
+                /* overrun is special, not associated with a char */
+                if (status & UART_OVERRUN_ERROR)
+                        tty_insert_flip_char(tty, 0, TTY_OVERRUN);
+                for (i = 0; i < urb->actual_length; ++i)
+                        tty_insert_flip_char(tty, data[i], tty_flag);
+                tty_flip_buffer_push(tty);
+        }

        // Schedule the next read _if_ we are still open
        if (port->open_count) {
diff -u spcp8x5.orig/spcp8x5.h spcp8x5/spcp8x5.h
--- spcp8x5.orig/spcp8x5.h      2006-09-25 08:11:35.000000000 +0200
+++ spcp8x5/spcp8x5.h   2008-01-21 23:02:49.000000000 +0100
@@ -19,7 +19,6 @@
#define SPCP8x5_835_VID                0x04fc
#define SPCP8x5_835_PID                0x0231
 
-#include <linux/config.h>
#include <linux/kernel.h>
#include <linux/errno.h>
#include <linux/init.h>
diff -u spcp8x5.orig/usb-serial.h spcp8x5/usb-serial.h
--- spcp8x5.orig/usb-serial.h   2004-12-24 22:35:50.000000000 +0100
+++ spcp8x5/usb-serial.h        2008-01-21 23:03:02.000000000 +0100
@@ -54,7 +54,6 @@
#ifndef __LINUX_USB_SERIAL_H
#define __LINUX_USB_SERIAL_H

-#include <linux/config.h>
#include <linux/kref.h>

#define SERIAL_TTY_MAJOR       188     /* Nice legal number now */
rock your home - [url="http://www.agocontrol.com"]http://www.agocontrol.com[/url] home automation

PeteK

Guys--

I've started to update the Wiki with the implementation details I learned from communicating with Eugen on the Pluto Zwave implementation and with with going over his code to create an Insteon PLC driver.  The code could use a clean up and a refresh to bring it up to the current Z-Wave standard of functionality and I think documenting its current fucntionality is a good first step.  I'll be adding more to it over the next few days.

http://wiki.linuxmce.org/index.php/ZWave#Implementation

If anyone has a ZCU201 and has any questions on the current implementation, I'll be glad to help.

-Pete

hari

Quote from: Domodude on January 22, 2008, 10:44:14 AM
Hi,

Merten has a fairly substantial Z-wave product line, and on February 8th, a salesperson will come by and show me some of their stuff. I will let the forum know about current possibilities and issues. Merten also has a USB interface, I will check that one too (I'll probably need Hari's fresh hack  ;) ).

Mark

last time i looked they took over 140€ for a single wall mounted switch!!

hope they did some sane pricing in between,

best regards,
Hari
rock your home - [url="http://www.agocontrol.com"]http://www.agocontrol.com[/url] home automation

totallymaxed

Quote from: hari on January 22, 2008, 11:25:19 AM
Quote from: Domodude on January 22, 2008, 10:44:14 AM
Hi,

Merten has a fairly substantial Z-wave product line, and on February 8th, a salesperson will come by and show me some of their stuff. I will let the forum know about current possibilities and issues. Merten also has a USB interface, I will check that one too (I'll probably need Hari's fresh hack  ;) ).

Mark

last time i looked they took over 140€ for a single wall mounted switch!!

hope they did some sane pricing in between,

best regards,
Hari

Hmmm... no they didn't!

Only 140€ per wall mounted switch ;-)

The Merten Connect range is one of the component products we will configure/install with our Dianemo professionally installed systems. In that market their quality and name means something... of course under the hood they are using the same z-wave chips and modules as everyone else. But Merten's products are engineered really well and their physical build quality is excellent.

Andy Herron,
CHT Ltd

For Dianemo/LinuxMCE consulting advice;
@herron on Twitter, totallymaxed+inquiries@gmail.com via email or PM me here.

Get Dianemo-Rpi2 ARM Licenses [url="http://forum.linuxmce.org/index.php?topic=14026.0"]http://forum.linuxmce.org/index.php?topic=14026.0[/url]

Get RaspSqueeze-CEC or Raspbmc-CEC for Dianemo/LinuxMCE: [url="http://wp.me/P4KgIc-5P"]http://wp.me/P4KgIc-5P[/url]

Facebook: [url="https://www.facebook.com/pages/Dianemo-Home-Automation/226019387454465"]https://www.facebook.com/pages/Dianemo-Home-Automation/226019387454465[/url]

[url="http://www.dianemo.co.uk"]http://www.dianemo.co.uk[/url]