No buffer done callback when using USB async mode

Using latest release 0.8.28 on on Ubuntu 18.04, I did not receive callbacks ARV_STREAM_CALLBACK_TYPE_BUFFER_DONE, however I receive ARV_STREAM_CALLBACK_TYPE_INIT. I realised that default for this release was changed to async and changing back to sync fix the issue. I have libusb 1.0.21.

With 5 buffers pushed, I have these traces:

[17:11:19.193] 🅸 stream-thread> Start async USB3Vision stream thread
[17:11:19.193] 🅳 stream-thread> leader_size = 1024
[17:11:19.193] 🅳 stream-thread> payload_size = 1048576
[17:11:19.193] 🅳 stream-thread> trailer_size = 1024
[17:11:19.203] 🅳 stream-thread> Stream buffer context not found for buffer 0x55bb0fe54150, creating…
Image acquisition started
[17:11:19.226] 🅳 stream-thread> Stream buffer context not found for buffer 0x55bb0fe541e0, creating…
[17:11:19.244] 🅳 stream-thread> Total payload: 15925248 bytes
[17:11:19.428] 🅳 stream-thread> Stream buffer context not found for buffer 0x55bb0fe54270, creating…
[17:11:19.448] 🅳 stream-thread> Total payload: 15925248 bytes
[17:11:19.628] 🅳 stream-thread> Stream buffer context not found for buffer 0x55bb0fe54300, creating…
[17:11:19.647] 🅳 stream-thread> Total payload: 15925248 bytes
[17:11:19.828] 🅳 stream-thread> Stream buffer context not found for buffer 0x55bb0fe54390, creating…
[17:11:19.847] 🅳 stream-thread> Total payload: 15925248 bytes
[17:11:20.048] 🅳 stream-thread> Total payload: 15925248 bytes

Any ideas what could be the cause ?

Philippe

Hi,

There is nothing wrong in the traces. Stream buffer context not found for buffer 0x55bb0fe54150, creating… is expected for each buffer you pushed. What is the output of arv-camera-test-0.8 --duration=5 -d all ?

Hi,

I know that the traces are correct, but my understanding is we receive images and I’m expecting the stream callback to be called with ‘buffer done’ but it is not.
For camera-test, I can not give you the output now as I’m no longer in the office, but it was working. However it registers the callback differently as a kind of slot.

Philippe

Oh, you are right, callback are never called by the async code. I will fix this issue soon, and add a corresponding test in the test suite.

Thanks,

Emmanuel.

1 Like

Please test Issue/stream callback by EmmanuelP · Pull Request #810 · AravisProject/aravis · GitHub

Thanks,

Emmanuel.

Aravis 0.8.29 is released and should fix this issue.

https://github.com/AravisProject/aravis/releases/download/0.8.29/aravis-0.8.29.tar.xz

Cheers.

Hi,

Thanks for the quick fix.

I tested the new version and the async USB mode is now working fine in my application.

I tried the arv-test-0.8 application and noticed some errors, not always the same, but this seems to be the same in 0.8.28:

(base) pleuba@ubuntu:~/dev/bis3/aravis-0.8.29/build/src$ ./arv-test-0.8
Found 1 device
Testing ‘Basler:acA2500-60uc’
Genicam:Load SUCCESS
Genicam:Schema SUCCESS Schema validation disabled
Properties:SensorSizeReadout SUCCESS
Properties:SensorSizeCheck IGNORED
Properties:GainAvailable SUCCESS
Properties:GainReadout SUCCESS
Properties:ExposureTimeAvailable SUCCESS
Properties:ExposureTimeReadout SUCCESS
MultipleAcquisitionA:BufferCheck SUCCESS 10/10
MultipleAcquisitionA:FrameRate SUCCESS 10.00 Hz
SingleAcquisition:BufferCheck SUCCESS
SoftwareTrigger:BufferCheck SUCCESS 5/5
MultipleAcquisitionB:BufferCheck SUCCESS 10/10
MultipleAcquisitionB:FrameRate SUCCESS 5.00 Hz
Chunks:BufferCheck FAILURE OffsetX not found in available chunks
(base) pleuba@ubuntu:~/dev/bis3/aravis-0.8.29/build/src$ ./arv-test-0.8
Found 1 device
Testing ‘Basler:acA2500-60uc’
Genicam:Load SUCCESS
Genicam:Schema SUCCESS Schema validation disabled
Properties:SensorSizeReadout SUCCESS
Properties:SensorSizeCheck IGNORED
Properties:GainAvailable SUCCESS
Properties:GainReadout SUCCESS
Properties:ExposureTimeAvailable SUCCESS
Properties:ExposureTimeReadout SUCCESS
MultipleAcquisitionA:BufferCheck FAILURE 0/10
MultipleAcquisitionA:FrameRate FAILURE
SingleAcquisition:BufferCheck SUCCESS
SoftwareTrigger:BufferCheck SUCCESS 5/5
MultipleAcquisitionB:BufferCheck SUCCESS 10/10
MultipleAcquisitionB:FrameRate SUCCESS 5.00 Hz
Chunks:BufferCheck FAILURE OffsetX not found in available chunks

Please open a bug report on github, with the output of arv-test-0.8 -d all.

Thanks.

1 Like

Bug opened: arv-test-0.8 is producing errors and is not repeatable · Issue #811 · AravisProject/aravis · GitHub