本文介绍了ONVIF:如何从支持ONVIF的IP摄像机的IP地址中形成DeviceIO Web服务地址的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我具有支持ONVIF的IP摄像机的IP地址,如何形成DeviceIO Web服务的地址?
I have the IP address of an ONVIF supported IP camera,how do I form the address of the DeviceIO web service?
推荐答案
一种可靠的方法如下:
- 使用WS-Discovery探测相机
- 从
ProbeMatch
中提取字段XAddr
.通常是http://<ip_addr>/onvif/device_service
,但不能保证总是这样. - 验证您的相机是否支持
GetCapabilities
或是否具有新的GetServices
. - 从
GetCapabilitiesRepsonse
或GetServicesResponse
中的任何一个验证您的设备是否支持设备I/O服务并获取相应的XAddr
.
- Probe the camera, by using the WS-Discovery
- Extract the field
XAddr
from theProbeMatch
. Usually it ishttp://<ip_addr>/onvif/device_service
, but it is not guaranteed always to be like this. - Verify if your camera supports
GetCapabilities
or it has the newGetServices
. - Either from
GetCapabilitiesRepsonse
orGetServicesResponse
verify if your device supports the Device I/O service and get the correspondingXAddr
.
请注意,初始握手可能会比较棘手,因为如果摄像机仅支持UsernameToken进行身份验证,则需要将客户端与设备时钟同步.看看ONVIF 应用程序员的指南以获取更多详细信息.
Beware that the initial handshake may be tricky, because if the camera only supports UsernameToken for authtentication, you'll need to syncronize your client with the device's clock. Have a look at the ONVIF Application Programmer's Guide for further details.
这篇关于ONVIF:如何从支持ONVIF的IP摄像机的IP地址中形成DeviceIO Web服务地址的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!