-
-
Notifications
You must be signed in to change notification settings - Fork 91
Camera MQTT Config
seydx edited this page Jan 24, 2022
·
1 revision
Here you can configure the specific MQTT Topics/Messages camera.ui should listen to
Example:
"name": "My Camera",
"videoConfig": {
...
},
"mqtt": {
"motionTopic": "sricam/motion",
"motionMessage": "ON",
"motionResetTopic": "sricam/motion",
"motionResetMessage": "OFF"
}
If your camera does not send simple message like "ON" / "OFF" and sends a JSON payload instead, the following is also possible
Assuming your camera sends a JSON payload like this on motion detection:
{
"timestamp": 123456789,
"event": {
"type": "motion",
"state": true
}
}
And you need the "state"
value in the payload. You can give camera.ui the path to the value and camera.ui will automatically read this value:
"name": "My Camera",
"videoConfig": {
...
},
"mqtt": {
"motionTopic": "sricam/motion",
"motionMessage": {
"event": {
"state": true
}
},
"motionResetTopic": "sricam/motion",
"motionResetMessage": {
"event": {
"state": false
}
},
}
Attributes | Required | Usage | Default | Options |
---|---|---|---|---|
motionTopic | The MQTT topic to watch for motion alerts. The topic (prefix/suffix) should be unique, it will be used to assign the motion detected message to the desired camera. | |||
motionMessage | The message to watch for to trigger motion alerts. | |||
motionResetTopic | The MQTT topic to watch for motion resets. The topic (prefix/suffix) should be unique, it will be used to assign the reset motion message to the desired camera. | |||
motionMessage | The message to watch for to trigger motion resets. | |||
motionResetMessage | The MQTT topic to watch for doorbell alerts. The topic (prefix/suffix) should be unique, it will be used to assign the doorbell message to the desired camera. | |||
doorbellMessage | The message to watch for to trigger doorbell alerts. Will use the name of the camera if blank. |