AravisProject / aravis

A vision library for genicam based cameras
GNU Lesser General Public License v2.1
899 stars 334 forks source link

Aravis python tests causes no signal display (0hz) in arv-viewer-0.8 #838

Open al397371 opened 1 year ago

al397371 commented 1 year ago

Describe the bug The problem appears when running the python tests because after that the viewer lists the camera but does not output video signal and shows 0hz.

To Reproduce Steps to reproduce the behavior: Run the Python tests. Run the viewer.

Expected behavior I expected the viewer to display video signal properly and the Python tests to run without errors.

Camera description:

Platform description:

Additional context In the python tests it initially showed the error "Namespace Aravis not available", this is temporarily solved by exporting the PATHS: export GI_TYPELIB_PATH=/usr/local/lib/x86_64-linux-gnu/girepository-1.0/:/usr/lib/x86_64-linux-gnu/girepository-1.0/ export LD_LIBRARY_PATH=/usr/local/lib/x86_64-linux-gnu/:/usr/lib/x86_64-linux-gnu/ Next I ran the python tests and then you get an error related to the acquisition frame rate:

~/Documents/aravis-0.8.30/tests/python$ python3.10 arv-camera-test.py 192.168.88.184
Traceback (most recent call last):
  File "/home/equip/Documents/aravis-0.8.30/tests/python/arv-camera-test.py", line 33, in <module>
    camera.set_frame_rate(10.0)
gi.repository.GLib.GError: arv-device-error-quark: [AcquisitionFrameRateAbs:ArvGcIntegerNode] Not a ArvGcFloat (0)

There is the possibility that there is a buffer saturation when calling the camera several times, which could cause the lack of video signal. Each time the Python tests are run, the viewer stops working, but it starts working again after releasing the camera's resources using the camera's own library functions.

Logs of the tests performed are provided and debug from arv-camera-test.py ``` debug.txt logs.txt


`sudo ninja test`
`arv-camera-test-0.8`
`arv-test-0.8`
`arv-tool-0.8`
`arv-tool-0.8 control Width Height OffsetX OffsetY`
EmmanuelP commented 11 months ago

When then python program crashes, it does not release the camera control right it has. You may have to wait a few seconds before being able to control again the camera.