PyPylon: Buffer underrun on Basler cameras

aqui_c report abuse

I would like to know if there is any way of detecting a buffer underrun using PyPylon with a basler ACE USB3.0 camera. I couldn't really find information in the documentation. Skipped Frames is not what I am looking for, I really want to know if the buffer ever gets full because I am reading too slowly from the camera.

Answers

mbinev report abuse

Hi, no, there is no BufferUnderrun parameter (also not in the official C++ API), because according to the USB3.0/USB3 Vision standards this cannot happen. That is, in order to grab images from cameras at all, you first allocate buffer memory in your application. This memory is passed down to the xHCI driver that allocated DMA memory. Since USB3.0 is a host-centric protocol, the host tells the camera when to send what kind and how much data. By that, buffer underrun actually cannot happen. SkippedFrames occurs when the host does not allow the camera to send data (does not pick up the data), although the host has announced that. This can happen because of CPU load or thread priorities. If that happen, the camera will fill up the internal buffer and once it is full, it will start skipping new image data - this is also as per the standard when using Bulk transmission mode. GigE Vision is a different protocol with different architecture, which is why you have buffer underrun parameters there.

Hope that helps.

Add Answer

Need support?

Just drop us an email to ... Show more