mirror of
https://github.com/kerberos-io/onvif.git
synced 2026-10-19 17:28:22 +00:00
Three fixes found while reading digital inputs from a camera that advertises DeviceIO only through GetServices: - NewDevice now also calls GetServices and registers any service it lists that GetCapabilities did not (e.g. DeviceIO). Endpoints already known from GetCapabilities are kept, and errors are ignored because GetServices is optional on older devices. Without this, deviceio.GetDigitalInputs fails with "target endpoint service not found". - Declare the tmd (DeviceIO) prefix on the SOAP envelope. DeviceIO requests such as tmd:GetDigitalInputs were sent as XML with an undeclared prefix, which devices answer with an empty body. - event.Unsubscribe is a WS-BaseNotification element: marshal it as wsnt:Unsubscribe instead of tev:Unsubscribe, and drop the empty <Any/> child. Devices rejected the old request with ActionNotSupported. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>