Skip to content

WIP: Add ONVIF motion detection support and subscription handling #194

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Draft
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

OttoHollmann
Copy link

As discussed in #173 current agent doesn't support onvif motion detection.

This PR adds a function that creates an ONVIF subscription and listens for new ONVIF events. If a message with the following content is received:

<tt:Data>
	<tt:SimpleItem Value="true" Name="IsMotion"/>
</tt:Data>

it should start recording. The recording should be stopped once the same message (with false) is received again:

<tt:Data>
	<tt:SimpleItem Value="false" Name="IsMotion"/>
</tt:Data>

Changes Overview:

  • Make the topicKinds in the CreatePullPointSubscription function configurable.
  • Add a new config option AGENT_CAPTURE_MOTION_ONVIF that will disable internal motion detection and use ONVIF events instead.
  • Add functions for retrieving, parsing, and processing ONVIF motion messages.

TODO:

  • Correctly handle start and stop recording
  • Update the UI
  • Handle configuration change/reload
  • Update the documentation
  • Feature is thoroughly tested

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant