IP 摄像机的 onvif-cli 查询中的参数无效

问题描述

我平安而来。尝试使用 onif-cli tool 设置 IP 摄像机的时间。发送 Get 请求时,得到正常响应:

$ onvif-cli devicemgmt GetSystemDateAndTime --host 10.10.10.14 --port 10080 --user admin --password 12345678 --verbose --wsdl /home/user/python-onvif/wsdl

True: {'DaylightSavings': False,'TimeZone': (TimeZone){
   TZ = "PST0PDT"
 },'UTCDateTime': (DateTime){
   Time =
      (Time){
         Hour = 17
         Minute = 14
         Second = 59
      }
   Date =
      (Date){
         Year = 2021
         Month = 6
         Day = 23
      }
 },'DateTimeType': Manual}

尝试 Set 时,出现错误

$ onvif-cli devicemgmt SetSystemDateAndTime "{UTCDateTime: {Time: {Hour: 10,Minute: 10,Second: 10}}}" --host 10.10.10.14 --port 10080 --user admin --password 12345678 --verbose --wsdl /home/python-onvif/wsdl

False: Invalid params

尝试提供整个结构,如下所示:

$ onvif-cli devicemgmt SetSystemDateAndTime "{DaylightSavings: False,TimeZone: {TZ: UTC},UTCDateTime: {Time: {Hour: 10,Second: 10},Date: {Year: 2010,Month: 10,Day: 10}},DateTimeType: Manual}" --host 10.10.10.14 --port 10080 --user admin --password 12345678 --verbose --wsdl /home/user/python-onvif/wsdl

False: Invalid params

到处都试过引号,没有变化。 /home/user/python-onvif/wsdldevicemgmt.wsdl 中的条目如下所示:

<xs:element name="SetSystemDateAndTime">
    <xs:complexType>
        <xs:sequence>
            <xs:element name="DateTimeType" type="tt:SetDateTimeType">
                <xs:annotation>
                    <xs:documentation>Defines if the date and time is set via NTP or manually.</xs:documentation>
                </xs:annotation>
            </xs:element>
            <xs:element name="DaylightSavings" type="xs:boolean">
                <xs:annotation>
                    <xs:documentation>Automatically adjust Daylight savings if defined in TimeZone.</xs:documentation>
                </xs:annotation>
            </xs:element>
            <xs:element name="TimeZone" type="tt:TimeZone" minOccurs="0">
                <xs:annotation>
                    <xs:documentation>The time zone in POSIX 1003.1 format</xs:documentation>
                </xs:annotation>
            </xs:element>
            <xs:element name="UTCDateTime" type="tt:DateTime" minOccurs="0">
                <xs:annotation>
                    <xs:documentation>Date and time in UTC. If time is obtained via NTP,UTCDateTime has no meaning</xs:documentation>
                </xs:annotation>
            </xs:element>
        </xs:sequence>
    </xs:complexType>
</xs:element>

帮助?

解决方法

暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!

如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。

小编邮箱:dio#foxmail.com (将#修改为@)

相关问答

Selenium Web驱动程序和Java。元素在(x,y)点处不可单击。其...
Python-如何使用点“。” 访问字典成员?
Java 字符串是不可变的。到底是什么意思?
Java中的“ final”关键字如何工作?(我仍然可以修改对象。...
“loop:”在Java代码中。这是什么,为什么要编译?
java.lang.ClassNotFoundException:sun.jdbc.odbc.JdbcOdbc...