If I setup ONVIF (to get PTZ in Frigate) for my camera, it does not work. The "control panel" just keeps loading:
2024-02-03 17:48:39.977630877 [2024-02-03 14:48:39] frigate.http ERROR : Exception on /rua/ptz/info [GET]
2024-02-03 17:48:39.977636505 Traceback (most recent call last):
2024-02-03 17:48:39.977645109 File "/usr/local/lib/python3.9/dist-packages/urllib3/response.py", line 737, in _error_catcher
2024-02-03 17:48:39.977647593 yield
2024-02-03 17:48:39.977650027 File "/usr/local/lib/python3.9/dist-packages/urllib3/response.py", line 873, in _raw_read
2024-02-03 17:48:39.977653187 raise IncompleteRead(self._fp_bytes_read, self.length_remaining)
2024-02-03 17:48:39.977656134 urllib3.exceptions.IncompleteRead: IncompleteRead(9348 bytes read, 5924668 more expected)
2024-02-03 17:48:39.977708571
2024-02-03 17:48:39.977711405 The above exception was the direct cause of the following exception:
2024-02-03 17:48:39.977713418
2024-02-03 17:48:39.977715201 Traceback (most recent call last):
2024-02-03 17:48:39.977717563 File "/usr/local/lib/python3.9/dist-packages/requests/models.py", line 816, in generate
2024-02-03 17:48:39.977771754 yield from self.raw.stream(chunk_size, decode_content=True)
2024-02-03 17:48:39.977774871 File "/usr/local/lib/python3.9/dist-packages/urllib3/response.py", line 1033, in stream
2024-02-03 17:48:39.977804344 data = self.read(amt=amt, decode_content=decode_content)
2024-02-03 17:48:39.977807480 File "/usr/local/lib/python3.9/dist-packages/urllib3/response.py", line 953, in read
2024-02-03 17:48:39.977809559 data = self._raw_read(amt)
2024-02-03 17:48:39.977812021 File "/usr/local/lib/python3.9/dist-packages/urllib3/response.py", line 881, in _raw_read
2024-02-03 17:48:39.977813664 self._fp.close()
2024-02-03 17:48:39.977815957 File "/usr/lib/python3.9/contextlib.py", line 135, in __exit__
2024-02-03 17:48:39.977817853 self.gen.throw(type, value, traceback)
2024-02-03 17:48:39.977820357 File "/usr/local/lib/python3.9/dist-packages/urllib3/response.py", line 754, in _error_catcher
2024-02-03 17:48:39.977851961 raise ProtocolError(f"Connection broken: {e!r}", e) from e
2024-02-03 17:48:39.977857225 urllib3.exceptions.ProtocolError: ('Connection broken: IncompleteRead(9348 bytes read, 5924668 more expected)', IncompleteRead(9348 bytes read, 5924668 more expected))
2024-02-03 17:48:39.977858896
2024-02-03 17:48:39.977860999 During handling of the above exception, another exception occurred:
2024-02-03 17:48:39.977862415
2024-02-03 17:48:39.977864103 Traceback (most recent call last):
2024-02-03 17:48:39.977866394 File "/usr/local/lib/python3.9/dist-packages/onvif/client.py", line 23, in wrapped
2024-02-03 17:48:39.977910325 return func(*args, **kwargs)
2024-02-03 17:48:39.977913398 File "/usr/local/lib/python3.9/dist-packages/onvif/client.py", line 153, in wrapped
2024-02-03 17:48:39.977915114 return call(params, callback)
2024-02-03 17:48:39.977917433 File "/usr/local/lib/python3.9/dist-packages/onvif/client.py", line 140, in call
2024-02-03 17:48:39.977919492 ret = func(**params)
2024-02-03 17:48:39.977921696 File "/usr/local/lib/python3.9/dist-packages/zeep/proxy.py", line 46, in __call__
2024-02-03 17:48:39.977923423 return self._proxy._binding.send(
2024-02-03 17:48:39.977925868 File "/usr/local/lib/python3.9/dist-packages/zeep/wsdl/bindings/soap.py", line 127, in send
2024-02-03 17:48:39.977928110 response = client.transport.post_xml(options["address"], envelope, http_headers)
2024-02-03 17:48:39.977930621 File "/usr/local/lib/python3.9/dist-packages/zeep/transports.py", line 108, in post_xml
2024-02-03 17:48:39.977932486 return self.post(address, message, headers)
2024-02-03 17:48:39.977934760 File "/usr/local/lib/python3.9/dist-packages/zeep/transports.py", line 74, in post
2024-02-03 17:48:39.977936492 response = self.session.post(
2024-02-03 17:48:39.977938777 File "/usr/local/lib/python3.9/dist-packages/requests/sessions.py", line 637, in post
2024-02-03 17:48:39.977991040 return self.request("POST", url, data=data, json=json, **kwargs)
2024-02-03 17:48:39.977994179 File "/usr/local/lib/python3.9/dist-packages/requests/sessions.py", line 589, in request
2024-02-03 17:48:39.977996029 resp = self.send(prep, **send_kwargs)
2024-02-03 17:48:39.977998387 File "/usr/local/lib/python3.9/dist-packages/requests/sessions.py", line 747, in send
2024-02-03 17:48:39.977999987 r.content
2024-02-03 17:48:39.978002369 File "/usr/local/lib/python3.9/dist-packages/requests/models.py", line 899, in content
2024-02-03 17:48:39.978004920 self._content = b"".join(self.iter_content(CONTENT_CHUNK_SIZE)) or b""
2024-02-03 17:48:39.978007244 File "/usr/local/lib/python3.9/dist-packages/requests/models.py", line 818, in generate
2024-02-03 17:48:39.978009006 raise ChunkedEncodingError(e)
2024-02-03 17:48:39.978012185 requests.exceptions.ChunkedEncodingError: ('Connection broken: IncompleteRead(9348 bytes read, 5924668 more expected)', IncompleteRead(9348 bytes read, 5924668 more expected))
2024-02-03 17:48:39.978013597
2024-02-03 17:48:39.978015619 During handling of the above exception, another exception occurred:
2024-02-03 17:48:39.978060406
2024-02-03 17:48:39.978062856 Traceback (most recent call last):
2024-02-03 17:48:39.978065148 File "/usr/local/lib/python3.9/dist-packages/flask/app.py", line 2190, in wsgi_app
2024-02-03 17:48:39.978066955 response = self.full_dispatch_request()
2024-02-03 17:48:39.978069370 File "/usr/local/lib/python3.9/dist-packages/flask/app.py", line 1486, in full_dispatch_request
2024-02-03 17:48:39.978071213 rv = self.handle_user_exception(e)
2024-02-03 17:48:39.978073564 File "/usr/local/lib/python3.9/dist-packages/flask/app.py", line 1484, in full_dispatch_request
2024-02-03 17:48:39.978075331 rv = self.dispatch_request()
2024-02-03 17:48:39.978078053 File "/usr/local/lib/python3.9/dist-packages/flask/app.py", line 1469, in dispatch_request
2024-02-03 17:48:39.978080265 return self.ensure_sync(self.view_functions[rule.endpoint])(**view_args)
2024-02-03 17:48:39.978082421 File "/opt/frigate/frigate/http.py", line 1414, in camera_ptz_info
2024-02-03 17:48:39.978084456 return jsonify(current_app.onvif.get_camera_info(camera_name))
2024-02-03 17:48:39.978086605 File "/opt/frigate/frigate/ptz/onvif.py", line 485, in get_camera_info
2024-02-03 17:48:39.978088332 self._init_onvif(camera_name)
2024-02-03 17:48:39.978090411 File "/opt/frigate/frigate/ptz/onvif.py", line 79, in _init_onvif
2024-02-03 17:48:39.978092266 configs = ptz.GetConfigurations(request)[0]
2024-02-03 17:48:39.978094709 File "/usr/local/lib/python3.9/dist-packages/onvif/client.py", line 26, in wrapped
2024-02-03 17:48:39.978096321 raise ONVIFError(err)
2024-02-03 17:48:39.978099752 onvif.exceptions.ONVIFError: Unknown error: ('Connection broken: IncompleteRead(9348 bytes read, 5924668 more expected)', IncompleteRead(9348 bytes read, 5924668 more expected))
The ONVIF Home Assistant integration works just fine for PTZ controls, that's what I'm using for now.
Describe the problem you are having
If I setup ONVIF (to get PTZ in Frigate) for my camera, it does not work. The "control panel" just keeps loading:
Version
0.13.1-34FB1C2
Frigate config file
Relevant log output
FFprobe output from your camera
Frigate stats
N/AOperating system
HassOS
Install method
HassOS Addon
Coral version
PCIe
Network connection
Wired
Camera make and model
INQMega PTZ381
Any other information that may be helpful
The ONVIF Home Assistant integration works just fine for PTZ controls, that's what I'm using for now.