JavaScript examples for z-wave not working

My z-wave is working fine,I am able to add a device and control it through the reference_client(libzwaveip) on the terminal.
But I want to do this from a program. I tried running the JavaScript examples(addnode.js, removenode.js, list.js) from this link -“” which is giving error.

So how do i proceed further, if there is any python examples please share that also will be very helpful.

the exmaples are using the malos layer, did you upgrade your node version to 6.5 as described also here:

you will also find examples for python there, but none for zwave, but you can port one using the zwave js examples as reference.

Hey loom,
Thank you for replying.

I found that i did not install “protobufjs” and installed it, and yes my node version is 6.5.0.
now i am getting this error:
pi@raspberrypi:~/matrix-malos-zwave/src/js_test $ node addnode.js
var matrixMalosBuilder =“matrix_malos”)
** ^**

TypeError: is not a function
at Object. (/home/pi/matrix-malos-zwave/src/js_test/addnode.js:17:39)
at Module._compile (module.js:556:32)
at Object.Module._extensions…js (module.js:565:10)
at Module.load (module.js:473:32)
at tryModuleLoad (module.js:432:12)
at Function.Module._load (module.js:424:3)
at Module.runMain (module.js:590:10)
at run (bootstrap_node.js:394:7)
at startup (bootstrap_node.js:149:9)
at bootstrap_node.js:509:3

I did try few things like running this commnd :“git submodule update --init” inside matrix-malos-zwave
directory and “npm install” inside src/js_test as on this issue:

But even after this it giving the same error.

Well, I don’t know much about nodejs, but the examples for zwave look a bit outdated than those of malos. You’d better wait for someone who knows more about it, or try to read yourself in. :slight_smile:

Hello Guys!

We are working on the Zwave examples now. We will release these examples soon. :slight_smile:


Kevin Patino.

1 Like

Hey Kevindpatino,

By when can we expect the new javascript examples for Z-wave?


Its been a month and I still don’t see any working examples for Z wave . At least let us know if we will get it and by when.

I’m also interesting to see ZWAVE examples. Especially if you can show a step to step instruction how to begin with matrix creator

Could you tell me that how you connect Matrix creator and ZWAVE at begin?

Could you tell me how to install protobufjs?

When I run malos-zwave ,it show

MALOS ZWave starting

You can query specific driver info using port 50000.

FLAGS_psk : 123456789012345678901234567890aa
I/O warning : failed to load external entity “ZWave_custom_cmd_classes.xml”
Could not load Command Class definitions
terminate called after throwing an instance of ‘zmq::error_t’
what(): Address already in use

Why this error?