mirror of
https://github.com/blakeblackshear/frigate.git
synced 2026-02-02 17:25:22 +03:00
Cleanup bad rebase
This commit is contained in:
parent
093c2f05af
commit
fa6618c800
@ -156,6 +156,7 @@ Topic to adjust motion contour area for a camera. Expected value is an integer.
|
||||
### `frigate/<camera_name>/motion_contour_area/state`
|
||||
|
||||
Topic with current motion contour area for a camera. Published value is an integer.
|
||||
|
||||
### `frigate/<camera_name>/birdseye/set`
|
||||
|
||||
Topic to turn birdseye for a camera on and off. Expected valures are `ON` and `OFF`.
|
||||
|
||||
@ -163,6 +163,7 @@ def create_mqtt_client(config: FrigateConfig, camera_metrics):
|
||||
logger.info(f"Setting motion threshold for {camera_name} via mqtt: {payload}")
|
||||
camera_metrics[camera_name]["motion_threshold"].value = payload
|
||||
motion_settings.threshold = payload
|
||||
|
||||
state_topic = f"{message.topic[:-4]}/state"
|
||||
client.publish(state_topic, payload, retain=True)
|
||||
|
||||
@ -187,6 +188,9 @@ def create_mqtt_client(config: FrigateConfig, camera_metrics):
|
||||
camera_metrics[camera_name]["motion_contour_area"].value = payload
|
||||
motion_settings.contour_area = payload
|
||||
|
||||
state_topic = f"{message.topic[:-4]}/state"
|
||||
client.publish(state_topic, payload, retain=True)
|
||||
|
||||
def on_birdseye_command(client, userdata, message):
|
||||
payload = message.payload.decode()
|
||||
logger.debug(f"on_birdseye_toggle: {message.topic} {payload}")
|
||||
@ -315,21 +319,18 @@ def create_mqtt_client(config: FrigateConfig, camera_metrics):
|
||||
on_improve_contrast_command,
|
||||
)
|
||||
client.message_callback_add(
|
||||
<<<<<<< HEAD
|
||||
f"{mqtt_config.topic_prefix}/{name}/motion_threshold/set",
|
||||
on_motion_threshold_command,
|
||||
)
|
||||
client.message_callback_add(
|
||||
f"{mqtt_config.topic_prefix}/{name}/motion_contour_area/set",
|
||||
on_motion_contour_area_command,
|
||||
=======
|
||||
f"{mqtt_config.topic_prefix}/{name}/birdseye/set",
|
||||
on_birdseye_command,
|
||||
)
|
||||
client.message_callback_add(
|
||||
f"{mqtt_config.topic_prefix}/{name}/birdseye/mode/set",
|
||||
on_birdseye_mode_command,
|
||||
>>>>>>> f223cd0 (Add mqtt topics)
|
||||
)
|
||||
|
||||
client.message_callback_add(
|
||||
|
||||
Loading…
Reference in New Issue
Block a user