IpCamera: New IP Camera Binding

Yes if you upgrade to openhab 3 milestone 3 when it gets released as the changes were merged a few days ago.

@sidamos
Re cameras not re-connecting, I do test for that whenever I make big changes to the binding and it worked last time I checked. Please report if it happens in V3, but I would need to know what the text shows as the things status and any logs in TRACE level as that would help narrow down what has happened. Under V2.x it should restart but it is possible that it may make a difference when the disconnection occurs, I would not be surprised if you retest 10 times and it works. When the camera is online it checks every 8 seconds if the alarm streams are still running and will restart them if they are not.

Testing my Amcrest with OH3M3. The binding scan does not find it (there is nothing in the log when scanning). ODM and Android app Onvifer do find it.
Added manually as Dahua thing and added channels GotoPreset, Pan and Tilt. Got an exception and says Tilt is NULL.

2020-11-23 08:03:57.901 [TRACE] [amera.internal.onvif.OnvifConnection] - Sending ONVIF request:GetSystemDateAndTime
2020-11-23 08:03:57.929 [TRACE] [amera.internal.onvif.OnvifConnection] - Onvif reply is:<?xml version="1.0" encoding="utf-8" standalone="yes" ?><s:Envelope xmlns:sc="http://www.w3.org/2003/05/soap-encoding" xmlns:s="http://www.w3.org/2003/05/soap-envelope" xmlns:tt="http://www.onvif.org/ver10/schema" xmlns:tds="http://www.onvif.org/ver10/device/wsdl"><s:Header/><s:Body><tds:GetSystemDateAndTimeResponse><tds:SystemDateAndTime><tt:DateTimeType>NTP</tt:DateTimeType><tt:DaylightSavings>false</tt:DaylightSavings><tt:TimeZone><tt:TZ>GMT+01:00</tt:TZ></tt:TimeZone><tt:UTCDateTime><tt:Time><tt:Hour>7</tt:Hour><tt:Minute>3</tt:Minute><tt:Second>57</tt:Second></tt:Time><tt:Date><tt:Year>2020</tt:Year><tt:Month>11</tt:Month><tt:Day>23</tt:Day></tt:Date></tt:UTCDateTime><tt:LocalDateTime><tt:Time><tt:Hour>8</tt:Hour><tt:Minute>3</tt:Minute><tt:Second>57</tt:Second></tt:Time><tt:Date><tt:Year>2020</tt:Year><tt:Month>11</tt:Month><tt:Day>23</tt:Day></tt:Date></tt:LocalDateTime></tds:SystemDateAndTime></tds:GetSystemDateAndTimeResponse></s:Body></s:Envelope>
2020-11-23 08:03:57.929 [TRACE] [amera.internal.onvif.OnvifConnection] - Sending ONVIF request:GetCapabilities
2020-11-23 08:03:57.931 [DEBUG] [amera.internal.onvif.OnvifConnection] - Cameras  UTC dateTime is:2020-11-23T7:3:57
2020-11-23 08:03:57.931 [DEBUG] [amera.internal.onvif.OnvifConnection] - Openhabs UTC dateTime is:2020-11-23T07:03:57.931Z
2020-11-23 08:03:57.957 [TRACE] [amera.internal.onvif.OnvifConnection] - Onvif reply is:<?xml version="1.0" encoding="utf-8" standalone="yes" ?><s:Envelope xmlns:sc="http://www.w3.org/2003/05/soap-encoding" xmlns:s="http://www.w3.org/2003/05/soap-envelope" xmlns:tt="http://www.onvif.org/ver10/schema" xmlns:tds="http://www.onvif.org/ver10/device/wsdl"><s:Header/><s:Body><tds:GetCapabilitiesResponse><tds:Capabilities><tt:Analytics><tt:XAddr>http://192.168.0.18/onvif/analytics_service</tt:XAddr><tt:RuleSupport>true</tt:RuleSupport><tt:AnalyticsModuleSupport>true</tt:AnalyticsModuleSupport></tt:Analytics><tt:Device><tt:XAddr>http://192.168.0.18/onvif/device_service</tt:XAddr><tt:Network><tt:IPFilter>false</tt:IPFilter><tt:ZeroConfiguration>false</tt:ZeroConfiguration><tt:IPVersion6>false</tt:IPVersion6><tt:DynDNS>false</tt:DynDNS><tt:Extension><tt:Dot11Configuration>false</tt:Dot11Configuration></tt:Extension></tt:Network><tt:System><tt:DiscoveryResolve>false</tt:DiscoveryResolve><tt:DiscoveryBye>true</tt:DiscoveryBye><tt:RemoteDiscovery>false</tt:RemoteDiscovery><tt:SystemBackup>false</tt:SystemBackup><tt:SystemLogging>true</tt:SystemLogging><tt:FirmwareUpgrade>true</tt:FirmwareUpgrade><tt:SupportedVersions><tt:Major>2</tt:Major><tt:Minor>00</tt:Minor></tt:SupportedVersions><tt:SupportedVersions><tt:Major>2</tt:Major><tt:Minor>10</tt:Minor></tt:SupportedVersions><tt:SupportedVersions><tt:Major>2</tt:Major><tt:Minor>20</tt:Minor></tt:SupportedVersions><tt:SupportedVersions><tt:Major>2</tt:Major><tt:Minor>30</tt:Minor></tt:SupportedVersions><tt:SupportedVersions><tt:Major>2</tt:Major><tt:Minor>40</tt:Minor></tt:SupportedVersions><tt:SupportedVersions><tt:Major>2</tt:Major><tt:Minor>42</tt:Minor></tt:SupportedVersions><tt:SupportedVersions><tt:Major>16</tt:Major><tt:Minor>12</tt:Minor></tt:SupportedVersions><tt:SupportedVersions><tt:Major>18</tt:Major><tt:Minor>06</tt:Minor></tt:SupportedVersions><tt:SupportedVersions><tt:Major>18</tt:Major><tt:Minor>12</tt:Minor></tt:SupportedVersions><tt:Extension><tt:HttpFirmwareUpgrade>true</tt:HttpFirmwareUpgrade><tt:HttpSystemBackup>false</tt:HttpSystemBackup><tt:HttpSystemLogging>false</tt:HttpSystemLogging><tt:HttpSupportInformation>false</tt:HttpSupportInformation></tt:Extension></tt:System><tt:IO><tt:InputConnectors>0</tt:InputConnectors><tt:RelayOutputs>0</tt:RelayOutputs><tt:Extension><tt:Auxiliary>false</tt:Auxiliary><tt:AuxiliaryCommands></tt:AuxiliaryCommands><tt:Extension></tt:Extension></tt:Extension></tt:IO><tt:Security><tt:TLS1.1>false</tt:TLS1.1><tt:TLS1.2>false</tt:TLS1.2><tt:OnboardKeyGeneration>false</tt:OnboardKeyGeneration><tt:AccessPolicyConfig>false</tt:AccessPolicyConfig><tt:X.509Token>false</tt:X.509Token><tt:SAMLToken>false</tt:SAMLToken><tt:KerberosToken>false</tt:KerberosToken><tt:RELToken>false</tt:RELToken><tt:Extension><tt:TLS1.0>false</tt:TLS1.0><tt:Extension><tt:Dot1X>false</tt:Dot1X><tt:SupportedEAPMethod>0</tt:SupportedEAPMethod><tt:RemoteUserHandling>false</tt:RemoteUserHandling></tt:Extension></tt:Extension></tt:Security></tt:Device><tt:Events><tt:XAddr>http://192.168.0.18/onvif/event_service</tt:XAddr><tt:WSSubscriptionPolicySupport>true</tt:WSSubscriptionPolicySupport><tt:WSPullPointSupport>true</tt:WSPullPointSupport><tt:WSPausableSubscriptionManagerInterfaceSupport>false</tt:WSPausableSubscriptionManagerInterfaceSupport></tt:Events><tt:Imaging><tt:XAddr>http://192.168.0.18/onvif/imaging_service</tt:XAddr></tt:Imaging><tt:Media><tt:XAddr>http://192.168.0.18/onvif/media_service</tt:XAddr><tt:StreamingCapabilities><tt:RTPMulticast>true</tt:RTPMulticast><tt:RTP_TCP>true</tt:RTP_TCP><tt:RTP_RTSP_TCP>true</tt:RTP_RTSP_TCP></tt:StreamingCapabilities><tt:Extension><tt:ProfileCapabilities><tt:MaximumNumberOfProfiles>6</tt:MaximumNumberOfProfiles></tt:ProfileCapabilities></tt:Extension></tt:Media><tt:PTZ><tt:XAddr>http://192.168.0.18/onvif/ptz_service</tt:XAddr></tt:PTZ><tt:Extension><tt:DeviceIO><tt:XAddr>http://192.168.0.18/onvif/deviceIO_service</tt:XAddr><tt:VideoSources>1</tt:VideoSources><tt:VideoOutputs>0</tt:VideoOutputs><tt:AudioSources>1</tt:AudioSources><tt:AudioOutputs>1</tt:AudioOutputs><tt:RelayOutputs>0</tt:RelayOutputs></tt:DeviceIO><tt:Recording><tt:XAddr>http://192.168.0.18/onvif/recording_service</tt:XAddr><tt:ReceiverSource>false</tt:ReceiverSource><tt:MediaProfileSource>true</tt:MediaProfileSource><tt:DynamicRecordings>true</tt:DynamicRecordings><tt:DynamicTracks>false</tt:DynamicTracks><tt:MaxStringLength>129</tt:MaxStringLength></tt:Recording><tt:Search><tt:XAddr>http://192.168.0.18/onvif/search_service</tt:XAddr><tt:MetadataSearch>false</tt:MetadataSearch></tt:Search><tt:Replay><tt:XAddr>http://192.168.0.18/onvif/replay_service</tt:XAddr></tt:Replay></tt:Extension></tds:Capabilities></tds:GetCapabilitiesResponse></s:Body></s:Envelope>
2020-11-23 08:03:57.957 [DEBUG] [amera.internal.onvif.OnvifConnection] - deviceXAddr:/onvif/device_service
2020-11-23 08:03:57.957 [DEBUG] [amera.internal.onvif.OnvifConnection] - eventsXAddr:/onvif/event_service
2020-11-23 08:03:57.958 [DEBUG] [amera.internal.onvif.OnvifConnection] - mediaXAddr:/onvif/media_service
2020-11-23 08:03:57.958 [DEBUG] [amera.internal.onvif.OnvifConnection] - ptzXAddr:/onvif/ptz_service
2020-11-23 08:03:57.958 [TRACE] [amera.internal.onvif.OnvifConnection] - Sending ONVIF request:GetProfiles
2020-11-23 08:03:58.016 [TRACE] [amera.internal.onvif.OnvifConnection] - Onvif reply is:<?xml version="1.0" encoding="utf-8" standalone="yes" ?><s:Envelope xmlns:sc="http://www.w3.org/2003/05/soap-encoding" xmlns:s="http://www.w3.org/2003/05/soap-envelope" xmlns:tt="http://www.onvif.org/ver10/schema" xmlns:trt="http://www.onvif.org/ver10/media/wsdl"><s:Header/><s:Body><trt:GetProfilesResponse><trt:Profiles token="MediaProfile00000" fixed="true"><tt:Name>MediaProfile_Channel1_MainStream</tt:Name><tt:VideoSourceConfiguration token="00000"><tt:Name>VideoSourceConfig_Channel1</tt:Name><tt:UseCount>2</tt:UseCount><tt:SourceToken>00000</tt:SourceToken><tt:Bounds x="0" y="0" width="2048" height="1536"/></tt:VideoSourceConfiguration><tt:AudioSourceConfiguration token="00000"><tt:Name>AudioSourceConfig_Channel1</tt:Name><tt:UseCount>2</tt:UseCount><tt:SourceToken>00000</tt:SourceToken></tt:AudioSourceConfiguration><tt:VideoEncoderConfiguration token="00000"><tt:Name>VideoEncoderConfig_Channel1_MainStream</tt:Name><tt:UseCount>1</tt:UseCount><tt:Encoding>H264</tt:Encoding><tt:Resolution><tt:Width>1920</tt:Width><tt:Height>1080</tt:Height></tt:Resolution><tt:Quality>4.000000</tt:Quality><tt:RateControl><tt:FrameRateLimit>15</tt:FrameRateLimit><tt:EncodingInterval>1</tt:EncodingInterval><tt:BitrateLimit>4096</tt:BitrateLimit></tt:RateControl><tt:H264><tt:GovLength>30</tt:GovLength><tt:H264Profile>Main</tt:H264Profile></tt:H264><tt:Multicast><tt:Address><tt:Type>IPv4</tt:Type><tt:IPv4Address>224.1.0.0</tt:IPv4Address></tt:Address><tt:Port>40000</tt:Port><tt:TTL>64</tt:TTL><tt:AutoStart>false</tt:AutoStart></tt:Multicast><tt:SessionTimeout>PT60S</tt:SessionTimeout></tt:VideoEncoderConfiguration><tt:AudioEncoderConfiguration token="00000"><tt:Name>AudioEncoderConfig_Channel1_MainStream</tt:Name><tt:UseCount>1</tt:UseCount><tt:Encoding>AAC</tt:Encoding><tt:Bitrate>64</tt:Bitrate><tt:SampleRate>16</tt:SampleRate><tt:Multicast><tt:Address><tt:Type>IPv4</tt:Type><tt:IPv4Address>224.1.0.0</tt:IPv4Address></tt:Address><tt:Port>40002</tt:Port><tt:TTL>64</tt:TTL><tt:AutoStart>false</tt:AutoStart></tt:Multicast><tt:SessionTimeout>PT60S</tt:SessionTimeout></tt:AudioEncoderConfiguration><tt:VideoAnalyticsConfiguration token="00000"><tt:Name>AnalyticsConfig_Channel1</tt:Name><tt:UseCount>2</tt:UseCount><tt:AnalyticsEngineConfiguration><tt:AnalyticsModule Name="MyCellMotion" Type="tt:CellMotionEngine"><tt:Parameters><tt:SimpleItem Name="Sensitivity" Value="60"/><tt:ElementItem Name="Layout"><tt:CellLayout Columns="22" Rows="18"><tt:Transformation><tt:Translate x="-1" y="-1"/><tt:Scale x="0.0062500000000000003" y="0.0083400000000000002"/></tt:Transformation></tt:CellLayout></tt:ElementItem></tt:Parameters></tt:AnalyticsModule></tt:AnalyticsEngineConfiguration><tt:RuleEngineConfiguration><tt:Rule Name="Region1" Type="tt:CellMotionDetector"><tt:Parameters><tt:SimpleItem Name="MinCount" Value="20"/><tt:SimpleItem Name="AlarmOnDelay" Value="1000"/><tt:SimpleItem Name="AlarmOffDelay" Value="1000"/><tt:SimpleItem Name="ActiveCells" Value="0P8A8A=="/></tt:Parameters></tt:Rule></tt:RuleEngineConfiguration></tt:VideoAnalyticsConfiguration><tt:PTZConfiguration token="00000" MoveRamp="0" PresetRamp="0" PresetTourRamp="0"><tt:Name>PTZConfig_Channel1</tt:Name><tt:UseCount>2</tt:UseCount><tt:NodeToken>00000</tt:NodeToken><tt:DefaultAbsolutePantTiltPositionSpace>http://www.onvif.org/ver10/tptz/PanTiltSpaces/PositionGenericSpace</tt:DefaultAbsolutePantTiltPositionSpace><tt:DefaultAbsoluteZoomPositionSpace>http://www.onvif.org/ver10/tptz/ZoomSpaces/PositionGenericSpace</tt:DefaultAbsoluteZoomPositionSpace><tt:DefaultRelativePanTiltTranslationSpace>http://www.onvif.org/ver10/tptz/PanTiltSpaces/TranslationGenericSpace</tt:DefaultRelativePanTiltTranslationSpace><tt:DefaultRelativeZoomTranslationSpace>http://www.onvif.org/ver10/tptz/ZoomSpaces/TranslationGenericSpace</tt:DefaultRelativeZoomTranslationSpace><tt:DefaultContinuousPanTiltVelocitySpace>http://www.onvif.org/ver10/tptz/PanTiltSpaces/VelocityGenericSpace</tt:DefaultContinuousPanTiltVelocitySpace><tt:DefaultContinuousZoomVelocitySpace>http://www.onvif.org/ver10/tptz/ZoomSpaces/VelocityGenericSpace</tt:DefaultContinuousZoomVelocitySpace><tt:DefaultPTZSpeed><tt:PanTilt space="http://www.onvif.org/ver10/tptz/PanTiltSpaces/GenericSpeedSpace" x="0.80000001192092896" y="0.80000001192092896"/><tt:Zoom space="http://www.onvif.org/ver10/tptz/ZoomSpaces/ZoomGenericSpeedSpace" x="0.80000001192092896"/></tt:DefaultPTZSpeed><tt:DefaultPTZTimeout>PT10S</tt:DefaultPTZTimeout><tt:PanTiltLimits><tt:Range><tt:URI>http://www.onvif.org/ver10/tptz/PanTiltSpaces/PositionGenericSpace</tt:URI><tt:XRange><tt:Min>-1.000000</tt:Min><tt:Max>1.000000</tt:Max></tt:XRange><tt:YRange><tt:Min>-1.000000</tt:Min><tt:Max>1.000000</tt:Max></tt:YRange></tt:Range></tt:PanTiltLimits><tt:ZoomLimits><tt:Range><tt:URI>http://www.onvif.org/ver10/tptz/ZoomSpaces/PositionGenericSpace</tt:URI><tt:XRange><tt:Min>0.000000</tt:Min><tt:Max>1.000000</tt:Max></tt:XRange></tt:Range></tt:ZoomLimits></tt:PTZConfiguration><tt:MetadataConfiguration token="00000" CompressionType=""><tt:Name>MetadataConfig_Channel1</tt:Name><tt:UseCount>2</tt:UseCount><tt:PTZStatus><tt:Status>false</tt:Status><tt:Position>false</tt:Position></tt:PTZStatus><tt:Events><tt:Filter><wsnt:TopicExpression Dialect="http://www.onvif.org/ver10/tev/topicExpression/ConcreteSet" xmlns:wsnt="http://docs.oasis-open.org/wsn/b-2" xmlns:tns1="http://www.onvif.org/ver10/topics">tns1:RuleEngine/CellMotionDetector/Motion</wsnt:TopicExpression></tt:Filter></tt:Events><tt:Analytics>true</tt:Analytics><tt:Multicast><tt:Address><tt:Type>IPv4</tt:Type><tt:IPv4Address>224.2.0.0</tt:IPv4Address></tt:Address><tt:Port>40020</tt:Port><tt:TTL>64</tt:TTL><tt:AutoStart>false</tt:AutoStart></tt:Multicast><tt:SessionTimeout>PT60S</tt:SessionTimeout></tt:MetadataConfiguration><tt:Extension><tt:AudioOutputConfiguration token="00000"><tt:Name>AudioOutputConfig_Channel1</tt:Name><tt:UseCount>2</tt:UseCount><tt:OutputToken>00000</tt:OutputToken><tt:SendPrimacy>www.onvif.org/ver20/HalfDuplex/Auto</tt:SendPrimacy><tt:OutputLevel>50</tt:OutputLevel></tt:AudioOutputConfiguration><tt:AudioDecoderConfiguration token="00000"><tt:Name>AudioDecoderConfig_Channel1_MainStream</tt:Name><tt:UseCount>1</tt:UseCount></tt:AudioDecoderConfiguration></tt:Extension></trt:Profiles><trt:Profiles token="MediaProfile00001" fixed="true"><tt:Name>MediaProfile_Channel1_SubStream1</tt:Name><tt:VideoSourceConfiguration token="00000"><tt:Name>VideoSourceConfig_Channel1</tt:Name><tt:UseCount>2</tt:UseCount><tt:SourceToken>00000</tt:SourceToken><tt:Bounds x="0" y="0" width="2048" height="1536"/></tt:VideoSourceConfiguration><tt:AudioSourceConfiguration token="00000"><tt:Name>AudioSourceConfig_Channel1</tt:Name><tt:UseCount>2</tt:UseCount><tt:SourceToken>00000</tt:SourceToken></tt:AudioSourceConfiguration><tt:VideoEncoderConfiguration token="00001"><tt:Name>VideoEncoderConfig_Channel1_SubStream1</tt:Name><tt:UseCount>1</tt:UseCount><tt:Encoding>H264</tt:Encoding><tt:Resolution><tt:Width>640</tt:Width><tt:Height>480</tt:Height></tt:Resolution><tt:Quality>4.000000</tt:Quality><tt:RateControl><tt:FrameRateLimit>15</tt:FrameRateLimit><tt:EncodingInterval>1</tt:EncodingInterval><tt:BitrateLimit>512</tt:BitrateLimit></tt:RateControl><tt:H264><tt:GovLength>30</tt:GovLength><tt:H264Profile>Main</tt:H264Profile></tt:H264><tt:Multicast><tt:Address><tt:Type>IPv4</tt:Type><tt:IPv4Address>224.1.0.1</tt:IPv4Address></tt:Address><tt:Port>40008</tt:Port><tt:TTL>64</tt:TTL><tt:AutoStart>false</tt:AutoStart></tt:Multicast><tt:SessionTimeout>PT60S</tt:SessionTimeout></tt:VideoEncoderConfiguration><tt:AudioEncoderConfiguration token="00001"><tt:Name>AudioEncoderConfig_Channel1_SubStream1</tt:Name><tt:UseCount>1</tt:UseCount><tt:Encoding>AAC</tt:Encoding><tt:Bitrate>64</tt:Bitrate><tt:SampleRate>16</tt:SampleRate><tt:Multicast><tt:Address><tt:Type>IPv4</tt:Type><tt:IPv4Address>224.1.0.1</tt:IPv4Address></tt:Address><tt:Port>40010</tt:Port><tt:TTL>64</tt:TTL><tt:AutoStart>false</tt:AutoStart></tt:Multicast><tt:SessionTimeout>PT60S</tt:SessionTimeout></tt:AudioEncoderConfiguration><tt:VideoAnalyticsConfiguration token="00000"><tt:Name>AnalyticsConfig_Channel1</tt:Name><tt:UseCount>2</tt:UseCount><tt:AnalyticsEngineConfiguration><tt:AnalyticsModule Name="MyCellMotion" Type="tt:CellMotionEngine"><tt:Parameters><tt:SimpleItem Name="Sensitivity" Value="60"/><tt:ElementItem Name="Layout"><tt:CellLayout Columns="22" Rows="18"><tt:Transformation><tt:Translate x="-1" y="-1"/><tt:Scale x="0.0062500000000000003" y="0.0083400000000000002"/></tt:Transformation></tt:CellLayout></tt:ElementItem></tt:Parameters></tt:AnalyticsModule></tt:AnalyticsEngineConfiguration><tt:RuleEngineConfiguration><tt:Rule Name="Region1" Type="tt:CellMotionDetector"><tt:Parameters><tt:SimpleItem Name="MinCount" Value="20"/><tt:SimpleItem Name="AlarmOnDelay" Value="1000"/><tt:SimpleItem Name="AlarmOffDelay" Value="1000"/><tt:SimpleItem Name="ActiveCells" Value="0P8A8A=="/></tt:Parameters></tt:Rule></tt:RuleEngineConfiguration></tt:VideoAnalyticsConfiguration><tt:PTZConfiguration token="00000" MoveRamp="0" PresetRamp="0" PresetTourRamp="0"><tt:Name>PTZConfig_Channel1</tt:Name><tt:UseCount>2</tt:UseCount><tt:NodeToken>00000</tt:NodeToken><tt:DefaultAbsolutePantTiltPositionSpace>http://www.onvif.org/ver10/tptz/PanTiltSpaces/PositionGenericSpace</tt:DefaultAbsolutePantTiltPositionSpace><tt:DefaultAbsoluteZoomPositionSpace>http://www.onvif.org/ver10/tptz/ZoomSpaces/PositionGenericSpace</tt:DefaultAbsoluteZoomPositionSpace><tt:DefaultRelativePanTiltTranslationSpace>http://www.onvif.org/ver10/tptz/PanTiltSpaces/TranslationGenericSpace</tt:DefaultRelativePanTiltTranslationSpace><tt:DefaultRelativeZoomTranslationSpace>http://www.onvif.org/ver10/tptz/ZoomSpaces/TranslationGenericSpace</tt:DefaultRelativeZoomTranslationSpace><tt:DefaultContinuousPanTiltVelocitySpace>http://www.onvif.org/ver10/tptz/PanTiltSpaces/VelocityGenericSpace</tt:DefaultContinuousPanTiltVelocitySpace><tt:DefaultContinuousZoomVelocitySpace>http://www.onvif.org/ver10/tptz/ZoomSpaces/VelocityGenericSpace</tt:DefaultContinuousZoomVelocitySpace><tt:DefaultPTZSpeed><tt:PanTilt space="http://www.onvif.org/ver10/tptz/PanTiltSpaces/GenericSpeedSpace" x="0.80000001192092896" y="0.80000001192092896"/><tt:Zoom space="http://www.onvif.org/ver10/tptz/ZoomSpaces/ZoomGenericSpeedSpace" x="0.80000001192092896"/></tt:DefaultPTZSpeed><tt:DefaultPTZTimeout>PT10S</tt:DefaultPTZTimeout><tt:PanTiltLimits><tt:Range><tt:URI>http://www.onvif.org/ver10/tptz/PanTiltSpaces/PositionGenericSpace</tt:URI><tt:XRange><tt:Min>-1.000000</tt:Min><tt:Max>1.000000</tt:Max></tt:XRange><tt:YRange><tt:Min>-1.000000</tt:Min><tt:Max>1.000000</tt:Max></tt:YRange></tt:Range></tt:PanTiltLimits><tt:ZoomLimits><tt:Range><tt:URI>http://www.onvif.org/ver10/tptz/ZoomSpaces/PositionGenericSpace</tt:URI><tt:XRange><tt:Min>0.000000</tt:Min><tt:Max>1.000000</tt:Max></tt:XRange></tt:Range></tt:ZoomLimits></tt:PTZConfiguration><tt:MetadataConfiguration token="00000" CompressionType=""><tt:Name>MetadataConfig_Channel1</tt:Name><tt:UseCount>2</tt:UseCount><tt:PTZStatus><tt:Status>false</tt:Status><tt:Position>false</tt:Position></tt:PTZStatus><tt:Events><tt:Filter><wsnt:TopicExpression Dialect="http://www.onvif.org/ver10/tev/topicExpression/ConcreteSet" xmlns:wsnt="http://docs.oasis-open.org/wsn/b-2" xmlns:tns1="http://www.onvif.org/ver10/topics">tns1:RuleEngine/CellMotionDetector/Motion</wsnt:TopicExpression></tt:Filter></tt:Events><tt:Analytics>true</tt:Analytics><tt:Multicast><tt:Address><tt:Type>IPv4</tt:Type><tt:IPv4Address>224.2.0.0</tt:IPv4Address></tt:Address><tt:Port>40020</tt:Port><tt:TTL>64</tt:TTL><tt:AutoStart>false</tt:AutoStart></tt:Multicast><tt:SessionTimeout>PT60S</tt:SessionTimeout></tt:MetadataConfiguration><tt:Extension><tt:AudioOutputConfiguration token="00000"><tt:Name>AudioOutputConfig_Channel1</tt:Name><tt:UseCount>2</tt:UseCount><tt:OutputToken>00000</tt:OutputToken><tt:SendPrimacy>www.onvif.org/ver20/HalfDuplex/Auto</tt:SendPrimacy><tt:OutputLevel>50</tt:OutputLevel></tt:AudioOutputConfiguration><tt:AudioDecoderConfiguration token="00001"><tt:Name>AudioDecoderConfig_Channel1_SubStream1</tt:Name><tt:UseCount>1</tt:UseCount></tt:AudioDecoderConfiguration></tt:Extension></trt:Profiles></trt:GetProfilesResponse></s:Body></s:Envelope>
2020-11-23 08:03:58.017 [TRACE] [amera.internal.onvif.OnvifConnection] - String was found:MediaProfile00000
2020-11-23 08:03:58.017 [TRACE] [amera.internal.onvif.OnvifConnection] - String was found:MediaProfile00001
2020-11-23 08:03:58.017 [TRACE] [amera.internal.onvif.OnvifConnection] - Sending ONVIF request:GetSnapshotUri
2020-11-23 08:03:58.019 [TRACE] [amera.internal.onvif.OnvifConnection] - Sending ONVIF request:GetStreamUri
2020-11-23 08:03:58.025 [TRACE] [amera.internal.onvif.OnvifConnection] - Sending ONVIF request:GetNodes
2020-11-23 08:03:58.074 [TRACE] [amera.internal.onvif.OnvifConnection] - Onvif reply is:<?xml version="1.0" encoding="utf-8" standalone="yes" ?><s:Envelope xmlns:sc="http://www.w3.org/2003/05/soap-encoding" xmlns:s="http://www.w3.org/2003/05/soap-envelope" xmlns:tt="http://www.onvif.org/ver10/schema" xmlns:trt="http://www.onvif.org/ver10/media/wsdl"><s:Header/><s:Body><trt:GetStreamUriResponse><trt:MediaUri><tt:Uri>rtsp://192.168.0.18:554/cam/realmonitor?channel=1&amp;subtype=0&amp;unicast=true&amp;proto=Onvif</tt:Uri><tt:InvalidAfterConnect>true</tt:InvalidAfterConnect><tt:InvalidAfterReboot>true</tt:InvalidAfterReboot><tt:Timeout>PT0S</tt:Timeout></trt:MediaUri></trt:GetStreamUriResponse></s:Body></s:Envelope>
2020-11-23 08:03:58.074 [DEBUG] [amera.internal.onvif.OnvifConnection] - GetStreamUri:rtsp://192.168.0.18:554/cam/realmonitor?channel=1&amp;subtype=0&amp;unicast=true&amp;proto=Onvif
2020-11-23 08:03:58.081 [TRACE] [amera.internal.onvif.OnvifConnection] - Onvif reply is:<?xml version="1.0" encoding="utf-8" standalone="yes" ?><s:Envelope xmlns:sc="http://www.w3.org/2003/05/soap-encoding" xmlns:s="http://www.w3.org/2003/05/soap-envelope" xmlns:tt="http://www.onvif.org/ver10/schema" xmlns:trt="http://www.onvif.org/ver10/media/wsdl"><s:Header/><s:Body><trt:GetSnapshotUriResponse><trt:MediaUri><tt:Uri>http://192.168.0.18/onvifsnapshot/media_service/snapshot?channel=1&amp;subtype=0</tt:Uri><tt:InvalidAfterConnect>false</tt:InvalidAfterConnect><tt:InvalidAfterReboot>false</tt:InvalidAfterReboot><tt:Timeout>PT0S</tt:Timeout></trt:MediaUri></trt:GetSnapshotUriResponse></s:Body></s:Envelope>
2020-11-23 08:03:58.082 [DEBUG] [amera.internal.onvif.OnvifConnection] - GetSnapshotUri:/onvifsnapshot/media_service/snapshot?channel=1&amp;subtype=0
2020-11-23 08:03:58.094 [TRACE] [amera.internal.onvif.OnvifConnection] - Onvif reply is:<?xml version="1.0" encoding="utf-8" standalone="yes" ?><s:Envelope xmlns:sc="http://www.w3.org/2003/05/soap-encoding" xmlns:s="http://www.w3.org/2003/05/soap-envelope" xmlns:tt="http://www.onvif.org/ver10/schema" xmlns:tptz="http://www.onvif.org/ver20/ptz/wsdl"><s:Header/><s:Body><tptz:GetNodesResponse><tptz:PTZNode FixedHomePosition="false" GeoMove="false" token="00000"><tt:Name>PTZNode_Channel1</tt:Name><tt:SupportedPTZSpaces><tt:AbsolutePanTiltPositionSpace><tt:URI>http://www.onvif.org/ver10/tptz/PanTiltSpaces/PositionGenericSpace</tt:URI><tt:XRange><tt:Min>-1.000000</tt:Min><tt:Max>1.000000</tt:Max></tt:XRange><tt:YRange><tt:Min>-1.000000</tt:Min><tt:Max>1.000000</tt:Max></tt:YRange></tt:AbsolutePanTiltPositionSpace><tt:AbsoluteZoomPositionSpace><tt:URI>http://www.onvif.org/ver10/tptz/ZoomSpaces/PositionGenericSpace</tt:URI><tt:XRange><tt:Min>0.000000</tt:Min><tt:Max>1.000000</tt:Max></tt:XRange></tt:AbsoluteZoomPositionSpace><tt:RelativePanTiltTranslationSpace><tt:URI>http://www.onvif.org/ver10/tptz/PanTiltSpaces/TranslationGenericSpace</tt:URI><tt:XRange><tt:Min>-1.000000</tt:Min><tt:Max>1.000000</tt:Max></tt:XRange><tt:YRange><tt:Min>-1.000000</tt:Min><tt:Max>1.000000</tt:Max></tt:YRange></tt:RelativePanTiltTranslationSpace><tt:RelativePanTiltTranslationSpace><tt:URI>http://www.onvif.org/ver10/tptz/PanTiltSpaces/TranslationSpaceFov</tt:URI><tt:XRange><tt:Min>-1.000000</tt:Min><tt:Max>1.000000</tt:Max></tt:XRange><tt:YRange><tt:Min>-1.000000</tt:Min><tt:Max>1.000000</tt:Max></tt:YRange></tt:RelativePanTiltTranslationSpace><tt:RelativeZoomTranslationSpace><tt:URI>http://www.onvif.org/ver10/tptz/ZoomSpaces/TranslationGenericSpace</tt:URI><tt:XRange><tt:Min>-1.000000</tt:Min><tt:Max>1.000000</tt:Max></tt:XRange></tt:RelativeZoomTranslationSpace><tt:ContinuousPanTiltVelocitySpace><tt:URI>http://www.onvif.org/ver10/tptz/PanTiltSpaces/VelocityGenericSpace</tt:URI><tt:XRange><tt:Min>-1.000000</tt:Min><tt:Max>1.000000</tt:Max></tt:XRange><tt:YRange><tt:Min>-1.000000</tt:Min><tt:Max>1.000000</tt:Max></tt:YRange></tt:ContinuousPanTiltVelocitySpace><tt:ContinuousPanTiltVelocitySpace><tt:URI>http://www.onvif.org/ver10/tptz/PanTiltSpaces/VelocitySpaceDegrees</tt:URI><tt:XRange><tt:Min>-1.000000</tt:Min><tt:Max>1.000000</tt:Max></tt:XRange><tt:YRange><tt:Min>-1.000000</tt:Min><tt:Max>1.000000</tt:Max></tt:YRange></tt:ContinuousPanTiltVelocitySpace><tt:ContinuousZoomVelocitySpace><tt:URI>http://www.onvif.org/ver10/tptz/ZoomSpaces/VelocityGenericSpace</tt:URI><tt:XRange><tt:Min>-1.000000</tt:Min><tt:Max>1.000000</tt:Max></tt:XRange></tt:ContinuousZoomVelocitySpace><tt:PanTiltSpeedSpace><tt:URI>http://www.onvif.org/ver10/tptz/PanTiltSpaces/GenericSpeedSpace</tt:URI><tt:XRange><tt:Min>0.000000</tt:Min><tt:Max>1.000000</tt:Max></tt:XRange></tt:PanTiltSpeedSpace><tt:ZoomSpeedSpace><tt:URI>http://www.onvif.org/ver10/tptz/ZoomSpaces/ZoomGenericSpeedSpace</tt:URI><tt:XRange><tt:Min>0.000000</tt:Min><tt:Max>1.000000</tt:Max></tt:XRange></tt:ZoomSpeedSpace></tt:SupportedPTZSpaces><tt:MaximumNumberOfPresets>25</tt:MaximumNumberOfPresets><tt:HomeSupported>true</tt:HomeSupported><tt:Extension><tt:SupportedPresetTour><tt:MaximumNumberOfPresetTours>8</tt:MaximumNumberOfPresetTours><tt:PTZPresetTourOperation>Start</tt:PTZPresetTourOperation><tt:PTZPresetTourOperation>Stop</tt:PTZPresetTourOperation><tt:PTZPresetTourOperation>Pause</tt:PTZPresetTourOperation></tt:SupportedPresetTour></tt:Extension></tptz:PTZNode></tptz:GetNodesResponse></s:Body></s:Envelope>
2020-11-23 08:03:58.094 [TRACE] [amera.internal.onvif.OnvifConnection] - Sending ONVIF request:GetStatus
2020-11-23 08:03:58.095 [DEBUG] [amera.internal.onvif.OnvifConnection] - ptzNodeToken=00000
2020-11-23 08:03:58.096 [TRACE] [amera.internal.onvif.OnvifConnection] - Sending ONVIF request:GetConfigurations
2020-11-23 08:03:58.148 [TRACE] [amera.internal.onvif.OnvifConnection] - Onvif reply is:<?xml version="1.0" encoding="utf-8" standalone="yes" ?><s:Envelope xmlns:sc="http://www.w3.org/2003/05/soap-encoding" xmlns:s="http://www.w3.org/2003/05/soap-envelope" xmlns:tt="http://www.onvif.org/ver10/schema" xmlns:tptz="http://www.onvif.org/ver20/ptz/wsdl"><s:Header/><s:Body><tptz:GetConfigurationsResponse><tptz:PTZConfiguration token="00000" MoveRamp="0" PresetRamp="0" PresetTourRamp="0"><tt:Name>PTZConfig_Channel1</tt:Name><tt:UseCount>2</tt:UseCount><tt:NodeToken>00000</tt:NodeToken><tt:DefaultAbsolutePantTiltPositionSpace>http://www.onvif.org/ver10/tptz/PanTiltSpaces/PositionGenericSpace</tt:DefaultAbsolutePantTiltPositionSpace><tt:DefaultAbsoluteZoomPositionSpace>http://www.onvif.org/ver10/tptz/ZoomSpaces/PositionGenericSpace</tt:DefaultAbsoluteZoomPositionSpace><tt:DefaultRelativePanTiltTranslationSpace>http://www.onvif.org/ver10/tptz/PanTiltSpaces/TranslationGenericSpace</tt:DefaultRelativePanTiltTranslationSpace><tt:DefaultRelativeZoomTranslationSpace>http://www.onvif.org/ver10/tptz/ZoomSpaces/TranslationGenericSpace</tt:DefaultRelativeZoomTranslationSpace><tt:DefaultContinuousPanTiltVelocitySpace>http://www.onvif.org/ver10/tptz/PanTiltSpaces/VelocityGenericSpace</tt:DefaultContinuousPanTiltVelocitySpace><tt:DefaultContinuousZoomVelocitySpace>http://www.onvif.org/ver10/tptz/ZoomSpaces/VelocityGenericSpace</tt:DefaultContinuousZoomVelocitySpace><tt:DefaultPTZSpeed><tt:PanTilt space="http://www.onvif.org/ver10/tptz/PanTiltSpaces/GenericSpeedSpace" x="0.80000001192092896" y="0.80000001192092896"/><tt:Zoom space="http://www.onvif.org/ver10/tptz/ZoomSpaces/ZoomGenericSpeedSpace" x="0.80000001192092896"/></tt:DefaultPTZSpeed><tt:DefaultPTZTimeout>PT10S</tt:DefaultPTZTimeout><tt:PanTiltLimits><tt:Range><tt:URI>http://www.onvif.org/ver10/tptz/PanTiltSpaces/PositionGenericSpace</tt:URI><tt:XRange><tt:Min>-1.000000</tt:Min><tt:Max>1.000000</tt:Max></tt:XRange><tt:YRange><tt:Min>-1.000000</tt:Min><tt:Max>1.000000</tt:Max></tt:YRange></tt:Range></tt:PanTiltLimits><tt:ZoomLimits><tt:Range><tt:URI>http://www.onvif.org/ver10/tptz/ZoomSpaces/PositionGenericSpace</tt:URI><tt:XRange><tt:Min>0.000000</tt:Min><tt:Max>1.000000</tt:Max></tt:XRange></tt:Range></tt:ZoomLimits></tptz:PTZConfiguration></tptz:GetConfigurationsResponse></s:Body></s:Envelope>
2020-11-23 08:03:58.148 [TRACE] [amera.internal.onvif.OnvifConnection] - Sending ONVIF request:GetPresets
2020-11-23 08:03:58.149 [DEBUG] [amera.internal.onvif.OnvifConnection] - ptzConfigToken=00000
2020-11-23 08:03:58.150 [TRACE] [amera.internal.onvif.OnvifConnection] - Sending ONVIF request:GetConfigurationOptions
2020-11-23 08:03:58.151 [TRACE] [amera.internal.onvif.OnvifConnection] - Onvif reply is:<?xml version="1.0" encoding="utf-8" standalone="yes" ?><s:Envelope xmlns:sc="http://www.w3.org/2003/05/soap-encoding" xmlns:s="http://www.w3.org/2003/05/soap-envelope" xmlns:tt="http://www.onvif.org/ver10/schema" xmlns:tptz="http://www.onvif.org/ver20/ptz/wsdl"><s:Header/><s:Body><tptz:GetStatusResponse><tptz:PTZStatus><tt:Position><tt:PanTilt space="http://www.onvif.org/ver10/tptz/PanTiltSpaces/PositionGenericSpace" x="0.93881019830028323" y="1.0554216867469877"/><tt:Zoom space="http://www.onvif.org/ver10/tptz/ZoomSpaces/PositionGenericSpace" x="0.0078125"/></tt:Position><tt:MoveStatus><tt:PanTilt>IDLE</tt:PanTilt><tt:Zoom>IDLE</tt:Zoom></tt:MoveStatus><tt:UtcTime>2020-11-23T07:03:58Z</tt:UtcTime></tptz:PTZStatus></tptz:GetStatusResponse></s:Body></s:Envelope>
2020-11-23 08:03:58.153 [DEBUG] [amera.internal.onvif.OnvifConnection] - Processing new PTZ location now
2020-11-23 08:03:58.154 [DEBUG] [amera.internal.onvif.OnvifConnection] - Pan is updating to:97 and the cam value is 0.93881017
2020-11-23 08:03:58.154 [DEBUG] [amera.internal.onvif.OnvifConnection] - Tilt is updating to:103 and the cam value is 1.0554217
2020-11-23 08:03:58.154 [DEBUG] [amera.internal.onvif.OnvifConnection] - Zoom is updating to:1 and the cam value is 0.0078125
2020-11-23 08:03:58.174 [TRACE] [amera.internal.onvif.OnvifConnection] - Onvif reply is:<?xml version="1.0" encoding="utf-8" standalone="yes" ?><s:Envelope xmlns:sc="http://www.w3.org/2003/05/soap-encoding" xmlns:s="http://www.w3.org/2003/05/soap-envelope" xmlns:tt="http://www.onvif.org/ver10/schema" xmlns:tptz="http://www.onvif.org/ver20/ptz/wsdl"><s:Header/><s:Body><tptz:GetPresetsResponse><tptz:Preset token="1"><tt:Name>Preset1</tt:Name><tt:PTZPosition><tt:PanTilt space="http://www.onvif.org/ver10/tptz/PanTiltSpaces/PositionGenericSpace" x="0.052691218130311523" y="-156.86265060240964"/><tt:Zoom space="http://www.onvif.org/ver10/tptz/ZoomSpaces/PositionGenericSpace" x="0.007874015748031496"/></tt:PTZPosition></tptz:Preset><tptz:Preset token="2"><tt:Name>Preset2</tt:Name><tt:PTZPosition><tt:PanTilt space="http://www.onvif.org/ver10/tptz/PanTiltSpaces/PositionGenericSpace" x="-0.98866855524079322" y="-156.86265060240964"/><tt:Zoom space="http://www.onvif.org/ver10/tptz/ZoomSpaces/PositionGenericSpace" x="0.007874015748031496"/></tt:PTZPosition></tptz:Preset></tptz:GetPresetsResponse></s:Body></s:Envelope>
2020-11-23 08:03:58.174 [TRACE] [amera.internal.onvif.OnvifConnection] - String was found:1
2020-11-23 08:03:58.174 [TRACE] [amera.internal.onvif.OnvifConnection] - String was found:2
2020-11-23 08:03:58.175 [TRACE] [amera.internal.onvif.OnvifConnection] - String was found:Preset1
2020-11-23 08:03:58.175 [TRACE] [amera.internal.onvif.OnvifConnection] - String was found:Preset2
2020-11-23 08:03:58.195 [TRACE] [amera.internal.onvif.OnvifConnection] - Onvif reply is:<?xml version="1.0" encoding="utf-8" standalone="yes" ?><s:Envelope xmlns:sc="http://www.w3.org/2003/05/soap-encoding" xmlns:s="http://www.w3.org/2003/05/soap-envelope" xmlns:tt="http://www.onvif.org/ver10/schema" xmlns:tptz="http://www.onvif.org/ver20/ptz/wsdl"><s:Header/><s:Body><tptz:GetConfigurationOptionsResponse><tptz:PTZConfigurationOptions><tt:Spaces><tt:AbsolutePanTiltPositionSpace><tt:URI>http://www.onvif.org/ver10/tptz/PanTiltSpaces/PositionGenericSpace</tt:URI><tt:XRange><tt:Min>-1.000000</tt:Min><tt:Max>1.000000</tt:Max></tt:XRange><tt:YRange><tt:Min>-1.000000</tt:Min><tt:Max>1.000000</tt:Max></tt:YRange></tt:AbsolutePanTiltPositionSpace><tt:AbsoluteZoomPositionSpace><tt:URI>http://www.onvif.org/ver10/tptz/ZoomSpaces/PositionGenericSpace</tt:URI><tt:XRange><tt:Min>0.000000</tt:Min><tt:Max>1.000000</tt:Max></tt:XRange></tt:AbsoluteZoomPositionSpace><tt:RelativePanTiltTranslationSpace><tt:URI>http://www.onvif.org/ver10/tptz/PanTiltSpaces/TranslationGenericSpace</tt:URI><tt:XRange><tt:Min>-1.000000</tt:Min><tt:Max>1.000000</tt:Max></tt:XRange><tt:YRange><tt:Min>-1.000000</tt:Min><tt:Max>1.000000</tt:Max></tt:YRange></tt:RelativePanTiltTranslationSpace><tt:RelativePanTiltTranslationSpace><tt:URI>http://www.onvif.org/ver10/tptz/PanTiltSpaces/TranslationSpaceFov</tt:URI><tt:XRange><tt:Min>-1.000000</tt:Min><tt:Max>1.000000</tt:Max></tt:XRange><tt:YRange><tt:Min>-1.000000</tt:Min><tt:Max>1.000000</tt:Max></tt:YRange></tt:RelativePanTiltTranslationSpace><tt:RelativeZoomTranslationSpace><tt:URI>http://www.onvif.org/ver10/tptz/ZoomSpaces/TranslationGenericSpace</tt:URI><tt:XRange><tt:Min>-1.000000</tt:Min><tt:Max>1.000000</tt:Max></tt:XRange></tt:RelativeZoomTranslationSpace><tt:ContinuousPanTiltVelocitySpace><tt:URI>http://www.onvif.org/ver10/tptz/PanTiltSpaces/VelocityGenericSpace</tt:URI><tt:XRange><tt:Min>-1.000000</tt:Min><tt:Max>1.000000</tt:Max></tt:XRange><tt:YRange><tt:Min>-1.000000</tt:Min><tt:Max>1.000000</tt:Max></tt:YRange></tt:ContinuousPanTiltVelocitySpace><tt:ContinuousZoomVelocitySpace><tt:URI>http://www.onvif.org/ver10/tptz/ZoomSpaces/VelocityGenericSpace</tt:URI><tt:XRange><tt:Min>-1.000000</tt:Min><tt:Max>1.000000</tt:Max></tt:XRange></tt:ContinuousZoomVelocitySpace><tt:PanTiltSpeedSpace><tt:URI>http://www.onvif.org/ver10/tptz/PanTiltSpaces/GenericSpeedSpace</tt:URI><tt:XRange><tt:Min>0.000000</tt:Min><tt:Max>1.000000</tt:Max></tt:XRange></tt:PanTiltSpeedSpace><tt:ZoomSpeedSpace><tt:URI>http://www.onvif.org/ver10/tptz/ZoomSpaces/ZoomGenericSpeedSpace</tt:URI><tt:XRange><tt:Min>0.000000</tt:Min><tt:Max>1.000000</tt:Max></tt:XRange></tt:ZoomSpeedSpace></tt:Spaces><tt:PTZTimeout><tt:Min>PT1S</tt:Min><tt:Max>PT250S</tt:Max></tt:PTZTimeout></tptz:PTZConfigurationOptions></tptz:GetConfigurationOptionsResponse></s:Body></s:Envelope>
2020-11-23 08:04:01.906 [TRACE] [era.internal.handler.IpCameraHandler] - Sending camera: GET: http://192.168.0.18:80/cgi-bin/snapshot.cgi?channel=1
2020-11-23 08:04:01.934 [TRACE] [era.internal.handler.IpCameraHandler] - Sending camera: GET: http://192.168.0.18:80/cgi-bin/snapshot.cgi?channel=1
2020-11-23 08:04:02.906 [INFO ] [era.internal.handler.IpCameraHandler] - The alarm stream was not running for camera 192.168.0.18, re-starting it now
2020-11-23 08:04:02.913 [TRACE] [era.internal.handler.IpCameraHandler] - Sending camera: GET: http://192.168.0.18:80/cgi-bin/eventManager.cgi?action=attach&codes=[All]
2020-11-23 08:04:02.932 [TRACE] [era.internal.handler.IpCameraHandler] - Sending camera: GET: http://192.168.0.18:80/cgi-bin/eventManager.cgi?action=attach&codes=[All]
2020-11-23 08:04:52.385 [ERROR] [ore.common.registry.AbstractRegistry] - Cannot inform the listener "org.openhab.core.thing.internal.ChannelLinkNotifier@23c90c74" about the "ADDED" event: Value must be between 0 and 100
java.lang.IllegalArgumentException: Value must be between 0 and 100
	at org.openhab.core.library.types.PercentType.validateValue(PercentType.java:57) ~[bundleFile:?]
	at org.openhab.core.library.types.PercentType.<init>(PercentType.java:42) ~[bundleFile:?]
	at org.openhab.binding.ipcamera.internal.handler.IpCameraHandler.handleCommand(IpCameraHandler.java:1162) ~[?:?]
	at org.openhab.core.thing.binding.BaseThingHandler.channelLinked(BaseThingHandler.java:177) ~[?:?]
	at org.openhab.core.thing.internal.ChannelLinkNotifier.lambda$3(ChannelLinkNotifier.java:72) ~[?:?]
	at org.openhab.core.thing.internal.ChannelLinkNotifier.call(ChannelLinkNotifier.java:99) ~[?:?]
	at org.openhab.core.thing.internal.ChannelLinkNotifier.added(ChannelLinkNotifier.java:72) ~[?:?]
	at org.openhab.core.thing.internal.ChannelLinkNotifier.added(ChannelLinkNotifier.java:1) ~[?:?]
	at org.openhab.core.common.registry.AbstractRegistry.notifyListeners(AbstractRegistry.java:364) [bundleFile:?]
	at org.openhab.core.common.registry.AbstractRegistry.notifyListenersAboutAddedElement(AbstractRegistry.java:397) [bundleFile:?]
	at org.openhab.core.thing.link.ItemChannelLinkRegistry.notifyListenersAboutAddedElement(ItemChannelLinkRegistry.java:126) [bundleFile:?]
	at org.openhab.core.thing.link.ItemChannelLinkRegistry.notifyListenersAboutAddedElement(ItemChannelLinkRegistry.java:1) [bundleFile:?]
	at org.openhab.core.common.registry.AbstractRegistry.added(AbstractRegistry.java:172) [bundleFile:?]
	at org.openhab.core.common.registry.AbstractRegistry.added(AbstractRegistry.java:1) [bundleFile:?]
	at org.openhab.core.common.registry.AbstractProvider.notifyListeners(AbstractProvider.java:60) [bundleFile:?]
	at org.openhab.core.common.registry.AbstractProvider.notifyListeners(AbstractProvider.java:79) [bundleFile:?]
	at org.openhab.core.common.registry.AbstractProvider.notifyListenersAboutAddedElement(AbstractProvider.java:83) [bundleFile:?]
	at org.openhab.core.common.registry.AbstractManagedProvider.add(AbstractManagedProvider.java:67) [bundleFile:?]
	at org.openhab.core.common.registry.AbstractRegistry.add(AbstractRegistry.java:343) [bundleFile:?]
	at org.openhab.core.io.rest.core.internal.link.ItemChannelLinkResource.link(ItemChannelLinkResource.java:157) [bundleFile:?]
	at jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:?]
	at jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[?:?]
	at jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:?]
	at java.lang.reflect.Method.invoke(Method.java:566) ~[?:?]
	at org.apache.cxf.service.invoker.AbstractInvoker.performInvocation(AbstractInvoker.java:179) [bundleFile:1.0.9]
	at org.apache.cxf.service.invoker.AbstractInvoker.invoke(AbstractInvoker.java:96) [bundleFile:1.0.9]
	at org.apache.cxf.jaxrs.JAXRSInvoker.invoke(JAXRSInvoker.java:201) [bundleFile:1.0.9]
	at org.apache.cxf.jaxrs.JAXRSInvoker.invoke(JAXRSInvoker.java:104) [bundleFile:1.0.9]
	at org.apache.cxf.interceptor.ServiceInvokerInterceptor$1.run(ServiceInvokerInterceptor.java:59) [bundleFile:1.0.9]
	at org.apache.cxf.interceptor.ServiceInvokerInterceptor.handleMessage(ServiceInvokerInterceptor.java:96) [bundleFile:1.0.9]
	at org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:308) [bundleFile:1.0.9]
	at org.apache.cxf.transport.ChainInitiationObserver.onMessage(ChainInitiationObserver.java:121) [bundleFile:1.0.9]
	at org.apache.cxf.transport.http.AbstractHTTPDestination.invoke(AbstractHTTPDestination.java:267) [bundleFile:1.0.9]
	at org.apache.cxf.transport.servlet.ServletController.invokeDestination(ServletController.java:234) [bundleFile:1.0.9]
	at org.apache.cxf.transport.servlet.ServletController.invoke(ServletController.java:208) [bundleFile:1.0.9]
	at org.apache.cxf.transport.servlet.ServletController.invoke(ServletController.java:160) [bundleFile:1.0.9]
	at org.apache.cxf.transport.servlet.CXFNonSpringServlet.invoke(CXFNonSpringServlet.java:216) [bundleFile:1.0.9]
	at org.apache.cxf.transport.servlet.AbstractHTTPServlet.handleRequest(AbstractHTTPServlet.java:301) [bundleFile:1.0.9]
	at org.apache.cxf.transport.servlet.AbstractHTTPServlet.doPut(AbstractHTTPServlet.java:237) [bundleFile:1.0.9]
	at javax.servlet.http.HttpServlet.service(HttpServlet.java:710) [bundleFile:3.1.0]
	at org.apache.cxf.transport.servlet.AbstractHTTPServlet.service(AbstractHTTPServlet.java:276) [bundleFile:1.0.9]
	at org.eclipse.jetty.servlet.ServletHolder.handle(ServletHolder.java:852) [bundleFile:9.4.20.v20190813]
	at org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:544) [bundleFile:9.4.20.v20190813]
	at org.ops4j.pax.web.service.jetty.internal.HttpServiceServletHandler.doHandle(HttpServiceServletHandler.java:71) [bundleFile:?]
	at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:143) [bundleFile:9.4.20.v20190813]
	at org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.java:536) [bundleFile:9.4.20.v20190813]
	at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:127) [bundleFile:9.4.20.v20190813]
	at org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHandler.java:235) [bundleFile:9.4.20.v20190813]
	at org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:1581) [bundleFile:9.4.20.v20190813]
	at org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHandler.java:233) [bundleFile:9.4.20.v20190813]
	at org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:1307) [bundleFile:9.4.20.v20190813]
	at org.ops4j.pax.web.service.jetty.internal.HttpServiceContext.doHandle(HttpServiceContext.java:293) [bundleFile:?]
	at org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandler.java:188) [bundleFile:9.4.20.v20190813]
	at org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:482) [bundleFile:9.4.20.v20190813]
	at org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:1549) [bundleFile:9.4.20.v20190813]
	at org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandler.java:186) [bundleFile:9.4.20.v20190813]
	at org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:1204) [bundleFile:9.4.20.v20190813]
	at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:141) [bundleFile:9.4.20.v20190813]
	at org.ops4j.pax.web.service.jetty.internal.JettyServerHandlerCollection.handle(JettyServerHandlerCollection.java:80) [bundleFile:?]
	at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:127) [bundleFile:9.4.20.v20190813]
	at org.eclipse.jetty.server.Server.handle(Server.java:494) [bundleFile:9.4.20.v20190813]
	at org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:374) [bundleFile:9.4.20.v20190813]
	at org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.java:268) [bundleFile:9.4.20.v20190813]
	at org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(AbstractConnection.java:311) [bundleFile:9.4.20.v20190813]
	at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:103) [bundleFile:9.4.20.v20190813]
	at org.eclipse.jetty.io.ChannelEndPoint$2.run(ChannelEndPoint.java:117) [bundleFile:9.4.20.v20190813]
	at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.runTask(EatWhatYouKill.java:336) [bundleFile:9.4.20.v20190813]
	at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.doProduce(EatWhatYouKill.java:313) [bundleFile:9.4.20.v20190813]
	at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.tryProduce(EatWhatYouKill.java:171) [bundleFile:9.4.20.v20190813]
	at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.run(EatWhatYouKill.java:129) [bundleFile:9.4.20.v20190813]
	at org.eclipse.jetty.util.thread.ReservedThreadExecutor$ReservedThread.run(ReservedThreadExecutor.java:367) [bundleFile:9.4.20.v20190813]
	at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:782) [bundleFile:9.4.20.v20190813]
	at org.eclipse.jetty.util.thread.QueuedThreadPool$Runner.run(QueuedThreadPool.java:918) [bundleFile:9.4.20.v20190813]
	at java.lang.Thread.run(Thread.java:834) [?:?]

Tested with OH3M3. Alarm stream was working. Sent a reboot command via python-amcrest, camera reboots and then is available again but alarm stream is dead (no events from the camera anymore). Waited 7 minutes.

2020-11-23 08:05:07.657 [TRACE] [amera.internal.onvif.OnvifConnection] - Sending ONVIF request:GetPresets
2020-11-23 08:05:07.679 [TRACE] [amera.internal.onvif.OnvifConnection] - Onvif reply is:<?xml version="1.0" encoding="utf-8" standalone="yes" ?><s:Envelope xmlns:sc="http://www.w3.org/2003/05/soap-encoding" xmlns:s="http://www.w3.org/2003/05/soap-envelope" xmlns:tt="http://www.onvif.org/ver10/schema" xmlns:tptz="http://www.onvif.org/ver20/ptz/wsdl"><s:Header/><s:Body><tptz:GetPresetsResponse><tptz:Preset token="1"><tt:Name>Preset1</tt:Name><tt:PTZPosition><tt:PanTilt space="http://www.onvif.org/ver10/tptz/PanTiltSpaces/PositionGenericSpace" x="0.052691218130311523" y="-156.86265060240964"/><tt:Zoom space="http://www.onvif.org/ver10/tptz/ZoomSpaces/PositionGenericSpace" x="0.007874015748031496"/></tt:PTZPosition></tptz:Preset><tptz:Preset token="2"><tt:Name>Preset2</tt:Name><tt:PTZPosition><tt:PanTilt space="http://www.onvif.org/ver10/tptz/PanTiltSpaces/PositionGenericSpace" x="-0.98866855524079322" y="-156.86265060240964"/><tt:Zoom space="http://www.onvif.org/ver10/tptz/ZoomSpaces/PositionGenericSpace" x="0.007874015748031496"/></tt:PTZPosition></tptz:Preset></tptz:GetPresetsResponse></s:Body></s:Envelope>
2020-11-23 08:05:07.680 [TRACE] [amera.internal.onvif.OnvifConnection] - String was found:1
2020-11-23 08:05:07.680 [TRACE] [amera.internal.onvif.OnvifConnection] - String was found:2
2020-11-23 08:05:07.680 [TRACE] [amera.internal.onvif.OnvifConnection] - String was found:Preset1
2020-11-23 08:05:07.680 [TRACE] [amera.internal.onvif.OnvifConnection] - String was found:Preset2
2020-11-23 08:07:41.177 [TRACE] [era.internal.handler.IpCameraHandler] - HTTP Result back from camera is 	:--myboundary
Content-Type: text/plain
Content-Length:135

Code=TimeChange;action=Pulse;index=0;data={
   "BeforeModifyTime" : "2020-11-23 08:07:41",
   "ModifiedTime" : "2020-11-23 08:07:41"
}


:
2020-11-23 08:07:41.329 [TRACE] [era.internal.handler.IpCameraHandler] - HTTP Result back from camera is 	:--myboundary
Content-Type: text/plain
Content-Length:137

Code=NTPAdjustTime;action=Pulse;index=0;data={
   "Address" : "clock.isc.org",
   "Before" : "2020-11-23 08:07:35",
   "result" : true
}


:
2020-11-23 08:16:02.814 [TRACE] [era.internal.handler.IpCameraHandler] - HTTP Result back from camera is 	:--myboundary
Content-Type: text/plain
Content-Length:103

Code=LeFunctionStatusSync;action=Pulse;index=0;data={
   "Function" : "LensMask",
   "Status" : true
}


:
2020-11-23 08:16:03.255 [TRACE] [era.internal.handler.IpCameraHandler] - HTTP Result back from camera is 	:--myboundary
Content-Type: text/plain
Content-Length:38

Code=LensMaskOpen;action=Pulse;index=0

:
2020-11-23 08:16:18.251 [TRACE] [era.internal.handler.IpCameraHandler] - HTTP Result back from camera is 	:--myboundary
Content-Type: text/plain
Content-Length:104

Code=LeFunctionStatusSync;action=Pulse;index=0;data={
   "Function" : "LensMask",
   "Status" : false
}


:
2020-11-23 08:16:18.773 [TRACE] [era.internal.handler.IpCameraHandler] - HTTP Result back from camera is 	:--myboundary
Content-Type: text/plain
Content-Length:39

Code=LensMaskClose;action=Pulse;index=0

:
2020-11-23 08:17:41.217 [TRACE] [era.internal.handler.IpCameraHandler] - HTTP Result back from camera is 	:--myboundary
Content-Type: text/plain
Content-Length:135

Code=TimeChange;action=Pulse;index=0;data={
   "BeforeModifyTime" : "2020-11-23 08:17:41",
   "ModifiedTime" : "2020-11-23 08:17:41"
}


:
2020-11-23 08:17:41.360 [TRACE] [era.internal.handler.IpCameraHandler] - HTTP Result back from camera is 	:--myboundary
Content-Type: text/plain
Content-Length:137

Code=NTPAdjustTime;action=Pulse;index=0;data={
   "Address" : "clock.isc.org",
   "Before" : "2020-11-23 08:17:35",
   "result" : true
}


:
2020-11-23 08:17:42.213 [TRACE] [era.internal.handler.IpCameraHandler] - HTTP Result back from camera is 	:--myboundary
Content-Type: text/plain
Content-Length:99

Code=StorageChange;action=Pulse;index=0;data={
   "Group" : "ReadWrite",
   "Path" : "\/mnt\/sd"
}


:
2020-11-23 08:17:42.380 [TRACE] [era.internal.handler.IpCameraHandler] - HTTP Result back from camera is 	:--myboundary
Content-Type: text/plain
Content-Length:32

Code=Reboot;action=Start;index=0

:

Thing is still ONLINE.

I test by pulling the network cable out of the camera, is that possible or is it WIFI?
What may be happening is the thread that does the checking may be crashing and hence it no longer checks the stream is alive. It may be related to the [ERROR] in your logs, as an error is critical and needs to be looked into. I cant really comment more as the logs you provided gave no clues from the moment when the reboot was done.

It is WiFi.

After the reboot, there were no extra lines in the log. Waited 7 minutes. I also enabled/disabled Privacy Mode via the Android App, which normally causes log entries in OH, but did nothing anymore.

You wrote that it is checking every 8 seconds. Should I see these checks in the log with TRACE? Because I don’t.

I do not think it is the error from above because I did not get that error with OH2 and also the alarm thread is not working anymore after reboot of the camera.

Edit:
You are using Netty’s isOpen() to check if the stream is alive. I have changed that to isActive() (and added trace logs to see, if it is actually checking) but that also does not recognize that the stream is dead. Maybe this is not so easy with TCP/IP. Workaround could be to make an actual GET on some other URL to find out if the camera is still there, but maybe it’s not worth it, if it is already working fine for “network lost”.

I need to buy one more camera to place it outside my front door,i am between :
IMOU DAHUA Bullet Lite 4MP
and
HIKVISION DS-2CD2041G1-IDW

In your opinion guys which is more likely to work best with ipcamera binding?

Hello,

I have activate the TRACE logging and I have collected the log bellow. I see that the response code is 302.
Also from the beginning one INFO is regarding the alarm stream that is not run on the XVR.

2020-11-23 16:24:36.703 [INFO ] [era.internal.handler.IpCameraHandler] - The alarm stream was not running for camera 192.168.2.151, re-starting it now

2020-11-23 16:24:44.707 [INFO ] [era.internal.handler.IpCameraHandler] - The alarm stream was not running for camera 192.168.2.151, re-starting it now

2020-11-23 16:24:44.709 [TRACE] [era.internal.handler.IpCameraHandler] - Sending camera: GET: http://192.168.2.151:80/cgi-bin/eventManager.cgi?action=attach&codes=[All]

2020-11-23 16:24:44.718 [DEBUG] [ipcamera.internal.MyNettyAuthHandler] - Camera at IP:192.168.2.151 gave a reply with a response code of :302

2020-11-23 16:24:44.719 [TRACE] [era.internal.handler.IpCameraHandler] - HTTP Result back from camera is 	:<html><head><title>302 Found</title></head><body bgcolor="white"><center><h1>302 Found</h1></center></body></html>:

2020-11-23 16:24:52.711 [INFO ] [era.internal.handler.IpCameraHandler] - The alarm stream was not running for camera 192.168.2.151, re-starting it now

Seems like the URL is not correct (302 = has new location). Either this can be corrected or the binding has to follow the redirect to the new URL.
Seems like Netty could do this automatically: https://github.com/reactor/reactor-netty/issues/522

Hello,

indeed, was an issue with port 80 because I activated the HTTPS. Now I have disable and I can receive image from one camera.
But still not receive on channel Motion Alarm the event.

On TRACE I can see the event that can be the SMD (Smart Motion Detection) on the bellow log.
How can I link with one channel and item?

2020-11-23 17:12:45.124 [TRACE] [era.internal.handler.IpCameraHandler] - HTTP Result back from camera is 	:--myboundary

Content-Type: text/plain

Content-Length:153

Code=SmartMotionHuman;action=Start;index=1;data={

   "object" : [

      {

         "HumanID" : 0,

         "Rect" : [ 29, 103, 171, 920 ]

      }

   ]

}

:

2020-11-23 17:12:57.858 [TRACE] [era.internal.handler.IpCameraHandler] - HTTP Result back from camera is 	:--myboundary

Content-Type: text/plain

Content-Length:76

Code=VideoMotion;action=Stop;index=1;data={

   "SmartMotionEnable" : true

}

:

2020-11-23 17:13:01.121 [TRACE] [era.internal.handler.IpCameraHandler] - HTTP Result back from camera is 	:--myboundary

Content-Type: text/plain

Content-Length:41

Code=SmartMotionHuman;action=Stop;index=1

:

Why is this being set to 1 when enabling motion alarm by the binding?

API Docs:
Alarm signal dejitter seconds. Alarm signal change during this period is ignored.

Wouldn’t greater values make more sense (I am starting to experiment with much greater values and 30 is the default)?

Or why set this at all from the binding? This can be configured in the camera settings.

anyone managed to play hls stream in chrome browser?I installed chrome playhls plugin but i cant play hls at habpanel widget
At android works as it should


No, does not work for me either. I have a workaround with an extra html file, which uses video.js and then integrate this in HABPanel.

the weird is that chrome with hls plugin is playing my .m3u8 link in a new tab,but not in habpanel
can u explain your workaround mate?

I am using an iframe with another html page inside the camera widget written by Matt. But you can also just use a Frame widget in HABPanel and point it to this html file. The html file is inside conf/html and therefore can be accessed via /static/test.html.

test.html:

<html>
<head>
  <link href="https://vjs.zencdn.net/7.8.4/video-js.css" rel="stylesheet" />

  <script src="https://vjs.zencdn.net/ie8/1.1.2/videojs-ie8.min.js"></script>
</head>

<body>
  <video
    id="my-video"
    class="video-js"
    controls
    preload="auto"
    width="1200"
    height=""
    poster=""
    data-setup="{}"
    autoplay
    muted
  >
    <source src="http://192.168.0.7:30001/ipcamera.m3u8" type="application/x-mpegURL" />
    <p class="vjs-no-js">
      To view this video please enable JavaScript, and consider upgrading to a
      web browser that
      <a href="https://videojs.com/html5-video-support/" target="_blank"
        >supports HTML5 video</a
      >
    </p>
  </video>

  <script src="https://vjs.zencdn.net/7.8.4/video.js"></script>
</body>
</html>

nope this does not work when i point to the html file (file://192.168.1.XXX/openHAB-conf/html/cam.html) , it displays nothing.

can u elaborate?

@matt1

On TRACE I can see the event that can be the SMD (Smart Motion Detection) on the bellow log.
How can I link with one channel and item?

2020-11-23 17:12:45.124 [TRACE] [era.internal.handler.IpCameraHandler] - HTTP Result back from camera is 	:--myboundary

Content-Type: text/plain

Content-Length:153

Code=SmartMotionHuman;action=Start;index=1;data={

   "object" : [

      {

         "HumanID" : 0,

         "Rect" : [ 29, 103, 171, 920 ]

      }

   ]

}

:

2020-11-23 17:12:57.858 [TRACE] [era.internal.handler.IpCameraHandler] - HTTP Result back from camera is 	:--myboundary

Content-Type: text/plain

Content-Length:76

Code=VideoMotion;action=Stop;index=1;data={

   "SmartMotionEnable" : true

}

:

2020-11-23 17:13:01.121 [TRACE] [era.internal.handler.IpCameraHandler] - HTTP Result back from camera is 	:--myboundary

Content-Type: text/plain

Content-Length:41

Code=SmartMotionHuman;action=Stop;index=1

:

Yep, sorry, had not tried it in a Frame widget. Same Angular error as when you try to do it directly in a custom widget.

So, 2 possibilities:
a) Use a Template Widget in HABPanel with this content:

 <iframe src="/static/test.html" width="1200" height="675"></iframe>

b) Use Matt’s camera-ptz widget and replace the video tag there with the iframe tag from above.

thnx mate
both workarounds are working
i like matt’s clickable widget a lot cause i can preview my 5 cams in a single habpanel page but with this workaround i have to import 5 different widgets 1 for every cam with its own iframe and html file,if i got it right
I will pass and stay with snapshots for now hoping for a better more simple solution,thnx mate.

Those logs are all I need to add the feature if you can also give a suggestion on how it should work. Does it identify a human with an ID number and how to present this via a channel in the binding? Any youtube videos that show the feature and how to set it up? I dont have a camera with this feature so anything that can help understand it better. Also it would be best to open this as a github issue and summarize the needed data into it as I am flat out at the moment so a github issue makes sure it does not get lost in this massive thread.

1 Like

Since this goto preset fix worked fine, I created a GitHub issue for it, so that it hopefully will make it into OH 3: