This is the forum archive of Homey. For more information about Homey, visit the Official Homey website.

The Homey Community has been moved to https://community.athom.com.

This forum is now read-only for archive purposes.
Closed

return values for command_get_parser when using command_get NOTIFICATION_GET?

homey-zwavedriver expects to return several values for 'command_get_parser' when using 'command_get' : 'NOTIFICATION_GET'. Where can i find a list of values to return? It expects values for "V1 Alarm Type", "Notification Type" and "Event".

This is what i have got so far. it's for the capability 'alarm_motion' for a motion sensor. Any reports after starting are handling correctly. For example when there is a motion detected, homey reports a motion. But homey does not show any state for this device when i start the app. 

'alarm_motion': {
'command_class' : 'COMMAND_CLASS_NOTIFICATION',
'command_get' : 'NOTIFICATION_GET',
'command_get_parser' : function(){
return {
"V1 Alarm Type" : 0,
"Notification Type" : "Access Control",
"Event" : 0,
}
},
'command_report' : 'NOTIFICATION_REPORT',
'command_report_parser' : function( report ){
if (report['Event (Parsed)'] === 'Motion Detection, Unknown Location') {
return true;
}
if (report['Event (Parsed)'] === 'Event inactive') {
return false;
}
return null;
}
This discussion has been closed.