Automation

Discussions about RaZberry - Z-Wave board for Raspberry computer
peulberg
Posts: 5
Joined: 09 Jul 2013 00:48

On the z-way server you can

Post by peulberg »

On the z-way server you can do something like this:
zway.devices[5].instances[0].commandClasses[48].data.level.bind(function() {
try {
debugPrint("It worked, the value is: " + this.value);
system("/usr/bin/python /opt/z-way-server/automation/test.py -c " + this.value);
} catch(err) {
debugPrint("Failed to execute command: " + err);
}
});

This will run the python script if the specific device fires an event. In my case it is a Fibaro reed contact e.g. if a window/door opens or closes.
universaldilettant
Posts: 5
Joined: 31 Jul 2013 21:44

seems interesting. basically

Post by universaldilettant »

seems interesting. basically you pass the whole thing on to the server via http post?
Post Reply