11-08-2019 02:53 PM
Hello,
I'm trying to configure a Basler Ace USB3.0 (acA640-750um), to do triggered burst acquisitions. Eventually I'll use hardward to trigger the acquisitions, but now I'm testing it out using a software trigger. I think I have it working, but I came across something that confused me.
I configured a continuous low level acquisition with 10 buffers. Then I acquire the images using Imaqdx Get Image2 in a subsequent loop, but that loop executes 50 times. I manually trigger the camera 5x to get the 50 images. Initially I thought it would re-use the 10 buffers, but when I look at the buffer number for each image it goes from 1-50. Why is this?
If anyone could explain or point me in the right direction I'd appreciate it. So far I haven't found anything that would explain why this is the case.
Thank!
11-08-2019 05:23 PM
Hello,
Unfortunately I don't think we have good resources that explain this concept, but that's something we've identified as an issue and we're actively working on improving that documentation.
When you call Configure Acquisition with 10 buffers, that is indeed the number of buffers allocated in the driver that will be acquired into by the camera. When you call GetImage, you're copying from one of those internal driver buffers into that separate MainImage that you allocated. The buffer number coming out of GetImage is basically the frame number from the acquisition. We return it like this so that the user can distinguish between an old image and a new image, as no two images will share a buffer number (well, until you overflow the 24-bit buffer number). Otherwise you could have a problem where you could potentially get the correct number, but the numbers would have wrapped around and overwritten the image you thought you were getting. You should be able to use the buffer number % number of buffers to deduce which internal buffer is being used if that's something you're interested in.
I have a few other comments now that I'm looking at your code:
Let me know if you have any other questions.
Hope this helps,
Katie
11-12-2019 10:41 AM
Hi Katie,
That all makes sense.
Thanks!