I have tried the shellpresencesensor-device
{
"id": "phone-signal",
"class": "ShellPresenceSensor",
"name": "Telefonie aktiv",
"command": "bash /usr/local/pimatic-app/phonedetect.sh",
"interval": 60000,
"autoReset": false,
"resetTime": 10000
},
but there is also an error:
Unhandled rejection Error: Command failed:
at ChildProcess.exithandler (child_process.js:637:15)
at ChildProcess.EventEmitter.emit (events.js:98:17)
at maybeClose (child_process.js:735:16)
at Socket.<anonymous> (child_process.js:948:11)
at Socket.EventEmitter.emit (events.js:95:17)
at Pipe.close (net.js:466:12)
also expects the device a result of 0 or 1. In my case but it is ‘0’ or ‘> 0’
description: "
the command to execute to get the presence state.
Can return on/off, true/false or 1/0 as string
"
On the shell my bash works well.