Need help setting up Z-Wave integration for Smanos K2 Hub <> Home Assistant (Aeotec Z-Wave USB Stick)

Hello,

I have a Smanos K2 Hub for some home automation products. I’ve bought an Aeotec Z-Wave USB Stick plugged into my Raspberry Pi 4 running Home Assistant. I’m having a really hard time setting new up a Z-Wave integration to get these working together. Any help would be greatly appreciated!

I’m in New Zealand, and I bought all of these products from New Zealand suppliers.

Aeotec Z-Wave USB Stick details:

  • RF Protocol
  • Z‐Wave Plus (500 series chip)
  • 921.42Mhz ‐ AU/NZ approved RF for Z‐wave
  • Z-Wave Plus certified

Smanos K2 Hub details:

  • Wireless Working Frequency: 915MHz Approved for AU & NZ
  • Z-Wave Frequency: 921MHz Approved for AU & NZ

Here are some screenshots:

Z-Wave JS Configuration

I’ve tried with an without a network key. I tried using the same 6 digit numeric code from the smanos app, but I saw lots of errors in the logs (network key invalid.) It looks like it has to be 16 bytes.

Z-Wave JS Logs

I haven’t seen any logs that could be related to the K2 hub or any connected devices.

Smanos K2 Z-Wave Manual

From https://products.z-wavealliance.org/ProductManual/File?folder=&filename=MarketCertificationFiles/2865/smanos%20k2%20smart%20hub%20user%20manual.pdf

Has a lot of information about Z-Wave inclusion, but I don’t quite understand how it should work.

Z-Wave JS => Add Z-Wave Node => Started Inclusion

After clicking this, I went into the “smanos home” app and clicked “Connect K2 to Other Controller”. Nothing happened, and the commands failed on both ends. Nothing showed up in the logs.

smanos home iOS app => list of accessories

Some of the Z-Wave products I’m trying to connect to Home Assistant

smanos home iOS app => Settings

List of Z-Wave settings and options

smanos home iOS app => Connect K2 to Other Controller

During this step, it asks for a “network management password”. This must be 6 numeric digits. (Not sure how this relates to the Z-Wave network key.)

smanos home iOS app => Settings => Network Management Password

smanos home iOS app => Settings => Network Management Password => Change Z-Wave Password


Questions:

  • The “smanos home” app Z-Wave configuration requires a “network management password” that can only be 6 numeric digits. The Z-Wave JS configuration requires a network_key that is 16 bytes. Are these two different things? (Maybe the Smanos K2 hub is generating an SHA-256 hash from the code to create these 16 bytes?)
  • Can I continue using the K2 Hub and smanos home app as the main “controller”, and set up Home Assistant as a secondary controller? How would this work?
  • Would it be easier to just get rid of the K2 Hub, and rebuild all the alarm features inside Home Assistant? E.g. Use keypad or RFID to Arm and Disarm alarm, turn on Home mode (ignore motion sensors, only set off alarm if doors are opened.)
    • I think these features would be better suited for the K2 hub and app.
    • I like how the hub can be configured to sound a warning and a 20 second countdown timer before setting off the alarms, so you have time to swipe the RFID tag (or enter the code on the keypad) and disarm it. Also I like the push notifications from the app. I’m sure I could hack something together in Home Assistant with some custom code, but I’d rather keep using the existing smanos app.

Resources:

All previous discussions about Smanos (not much here):

Is there any way to set up the Aeotec Z-Wave USB Stick as a “sniffer” so that I can just try to see all the Z-Wave activity in the area? Similar to tcpdump. I’d just like to see if the K2 hub is broadcasting any kind of messages on the same frequency, but nothing is showing up in the logs when I put both controllers into “inclusion” mode

Tried using 111111 as the network_key in the Z-Wave JS configuration. (`111111’ was set as the “network configuration password” in the smanos home app.)

Z-Wave JS
[s6-init] making user provided files available at /var/run/s6/etc...exited 0.
[s6-init] ensuring user provided files have correct perms...exited 0.
[fix-attrs.d] applying ownership & permissions fixes...
[fix-attrs.d] done.
[cont-init.d] executing container initialization scripts...
[cont-init.d] config.sh: executing... 
[cont-init.d] config.sh: exited 0.
[cont-init.d] structure.sh: executing... 
[cont-init.d] structure.sh: exited 0.
[cont-init.d] done.
[services.d] starting services
[services.d] done.
[14:20:32] INFO: Successfully send discovery information to Home Assistant.
Error: Invalid networkKey defined
[14:20:37] INFO: Successfully send discovery information to Home Assistant.
Error: Invalid networkKey defined

Then I wondered if they might be converting this 6 digit code into 32 bytes using some kind of hash.

Ruby:

Digest::MD5.hexdigest('111111').upcase
=> "96E79218965EB72C92A549DD5A330112"
Digest::SHA256.hexdigest('111111').upcase[0...32]
=> "BCB15F821479B4D5772BD0CA866C00AD"

I tried both 96E79218965EB72C92A549DD5A330112 and BCB15F821479B4D5772BD0CA866C00AD as the network_key for Z-Wave JS but nothing changed. Still no log messages.

Tried to manually pair the USB stick by following these instructions:

I pressed the button and the blue LED started blinking slowly. Then I pressed “Connect K2 to Other Controller” in the smanos home app. The blue LED just continued blinking slowly until it turned off. (It didn’t go solid blue for 2 seconds.) Then the app showed an error saying “failed”.

You are trying to add the K2 as a secondary controller. According to this lost help article, you need to exclude all the nodes from the K2 before you add it as a secondary controller. I would guess that’s probably true for any controller being added as a secondary.

I’m not really sure in what way, if any, Z-Wave JS supports secondary controllers. It definitely doesn’t support running as a secondary.

1 Like

I think I’ve figured something out about the Smanos K2 hub and accessories. If you look at the product pages for these accessories:

You can see that they use a different frequency than Z-Wave.

Frequency: 868MHz or 915MHz (N. America)

Also:

The smanos K2 is AC-powered, WiFi-based and has Z-Wave and RF modules built in.

It sounds like the K2 hub has it’s own proprietary RF stuff that connects to accessories on a different frequency (868MHz or 915MHz), but you can also add other third-party Z-Wave devices as accessories.

So I think the Z-Wave functionality is mainly intended for compatibility with other locks, sensors, etc. But it also has this “Connect K2 to Other Controller” feature in the settings that I’ve been trying to get working. I’m hoping that Home Assistant will see the hub as a single Z-Wave device that can send and receive commands and events.

Thanks for your help! I finally got around to trying this again. This time I used a powered USB hub in case that was the issue. I also fully reset all the devices and started from scratch. And the other thing I changed is that I switched to “Z-Wave JS to MQTT” instead of “Z-Wave JS”, since the MQTT add-on has a UI and more customizable.

I was able to get the Smanos K2 Hub paired as a Z-Wave controller:

(It also added a bunch of random unknown devices, and I’m not sure if these are duplicates, or maybe accessories?)

I’ve got these showing up in MQTT (I use the “MQTT explorer” app on Mac)

I was hoping that I would be able to read and control the alarm status (Home Mode, Armed, Disarmed), as well as read all of the accessories as sensors (water sensor, motion sensors, door sensors, RFID reader, keypad), but it looks like the K2 Z-Wave integration only works in one direction. So that’s a real shame if I get stuck here. It’s a pretty good alarm system, but I’d love to be able to automate it and access all of the sensor data.

I had a phone call with Smanos support (in Aus/NZ), and they’ve opened a support ticket for me (I asked about an open API and a Home Assistant integration.) They confirmed that the accessories use a proprietary RF frequency / protocol, and the Z-Wave chip is just for adding external devices (if you use Smanos as your main controller.) So I’ll skip Z-Wave for now. But I’ve just set up the Amazon Alexa integration, and I’ve got IFTTT sending all the alarm events into Home Assistant. I can also trigger the alarm through IFTTT. I really don’t like relying on external cloud services to connect it all together (IFTTT and Smanos Cloud), but it’s better than nothing. (Maybe?!)

Now I can turn off the built-in autotimer and do some cool stuff like auto-arm the alarm in “home mode” at 10pm, but only if my wife and I are both home. And automatically disarm the alarm at 6am, but if we are both away then leave it armed.

It looks like IFTTT doesn’t support “trigger alarm” as an action, but that would be cool as well (e.g. if anyone turns on the light switch, or if some additional motion sensors go off (I also have some Philips Hue and Zigbee motion sensors.) I might request that as an option.

Hi, I know it’s been a while but has anyone been able to integrate the Smanos K2 kit with Home Assistant directly (other than relying on IFTTT)
Thanks

Hi @Guillaume_Corgnet, sorry I was never able to get this integrated properly, and I was just using IFTTT to control the alarm and get notifications when it was triggered. I am no longer using any Smanos products though, so sorry I won’t be able to help.