Skip to content

Commit

Permalink
Use ProfileAlarmTransmit event for motion instead of AlarmLocal
Browse files Browse the repository at this point in the history
  • Loading branch information
dchesterton committed Feb 9, 2021
1 parent 7fe3146 commit b84537d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/amcrest2mqtt.py
Original file line number Diff line number Diff line change
Expand Up @@ -166,7 +166,7 @@ def signal_handler(sig, frame):
for code, payload in camera.event_actions("All", retries=5):
log(str(payload))

if code == "AlarmLocal":
if code == "ProfileAlarmTransmit":
mqtt_payload = "on" if payload["action"] == "Start" else "off"
mqtt_publish(motion_topic, mqtt_payload)

Expand Down

0 comments on commit b84537d

Please sign in to comment.