Publish to $aws/things/zwave/shadow/update (or update the thing shadow)
{
"state": {
"desired": {
"X": "Y"
}
}
}
Where X is one of:
secureAddNodehealNetworkaddNodecancelControllerCommandremoveNodesoftResetAnd Y is anything different, you might like to use the timestamp of when you did it.
When this has been received and actioned you will be able to see the same thing published in the thing shadow or to $aws/things/zwave/shadow/update
{
"state": {
"reported": {
"X": "Y"
}
}
}
docker run \
--device=/dev/ttyACM0 \
-e DEVICE=/dev/ttyACM0 \
-e AWS_ACCESS_KEY_ID=XXX \
-e AWS_SECRET_ACCESS_KEY=XX \
-e AWS_IOT_ENDPOINT_HOST=XX \
-e AWS_REGION=eu-west-2 \
-e ZWAVE_NETWORK_KEY=XX \
chrisns/iot-zwave
git clone [email protected]:chrisns/iot-zwave
cd iot-zwave
npm i
DEVICE=/dev/ttyACM0 \
AWS_ACCESS_KEY_ID=XXX \
AWS_SECRET_ACCESS_KEY=XX \
AWS_IOT_ENDPOINT_HOST=XX \
AWS_REGION=eu-west-2 \
ZWAVE_NETWORK_KEY=XX \
npm start
Use the random.org generator to get a fresh set of 16 random hex numbers but don't forget to add the "0x" prefix and the commas.
It should look something like: 0x97,0x81,0x18,0x90,0xd3,0x57,0xac,0x93,0xa2,0x20,0x9c,0x91,0x6d,0x83,0x17,0xcb
This will make a thingshadow for each of your zwave devices.
The name is zwave_x_n where x is the homeid and n is the node id.
So for example I have a Aeotec by Aeon Labs ZW120 Door / Window Sensor that reports:
{
"reported": {
"system": {
"Powerlevel": "Normal",
"Application Version": "1.05",
"Test Status": "Failed",
"Acked Frames": 0,
"Timeout": 0,
"ZWave+ Version": 1,
"Frame Count": 0,
"InstallerIcon": 3078,
"Library Version": "3",
"Maximum Wake-up Interval": 16777200,
"Default Wake-up Interval": 0,
"UserIcon": 3078,
"Test Node": 0,
"Test Powerlevel": "Normal",
"Minimum Wake-up Interval": 0,
"Wake-up Interval Step": 240,
"Wake-up Interval": 0,
"Protocol Version": "4.05"
},
"config": {
"Interval time of battery report": 0,
"Report type": 256,
"Basic Set Report": "Open: 0xFF, Close: 0x00",
"Sensor Binary Report": "Open: 0xFF, Close: 0x00",
"Enable wake up 10 minutes when re-power on the sensor": "Enable",
"Set the low battery value": 18,
"Reset To Factory Defaults": "Normal"
},
"user": {
"SourceNodeId": 0,
"Sensor": true,
"Alarm Type": 0,
"Burglar": 254,
"Battery Level": 74,
"Access Control": 254,
"Alarm Level": 0
},
"basic": {
"Basic": 255
}
}
}
If you update the shadow in desired with the same path, this app will do it's best to make that reality and report it back when it's done. Sleeping nodes can see that take quite a while.
Because Amazon IOT inflicts a 8kb limit on the payload I can't put all the nice helpful content that openzwave provides like what are valid values, and help text to accompany these values, or even what is read only.
zwave. you don't need to add attributes but I added manufacturerid, productid, producttype to mine so I can filter by those things.Currently make an awful lot more calls to AWS than I need to, this should really be batched up by maybe a few ms
The app open a telnet interface on port 8888 that will allow arbitary execution of code scoped to the zwave object, though would be trivial to break out of that, so DO NOT EVER EVER EVER expose that port to anything that could connect to it that's not you!
These are features I'd like to provide, but feel free to chip in
Pull Requests welcome
Content type
Image
Digest
Size
78.7 MB
Last updated
about 5 years ago
docker pull chrisns/iot-zwave