In my application, linescan cameras are acquiring and sending 2D images to my host PC where they are concatenated. The final image length needs to be as long as the camera trigger photoeye signal is ON. Once the photoeye turns OFF, the camera should complete the final 2D image acquisition. I need the host PC to know when the final 2D image has been sent OR when the Trigger photoeye signal turns OFF so that it can determine the last acquired image and finalize the image concatenation. I can see two possible ways to do this:
- Use an acquisition enable signal (i.e. analyze a Trigger 5 board input signal) to acquire images and send a value out with the 2D images that represents a serial number. All 2D images with the same serial number are considered part of the final image. Increment a counter (i.e. serial number) every time the photoeye signal goes from low to high (i.e. new image). The problem here is that the host PC is still waiting for whatever grabs come from the camera and does not "know" when the final 2D image has been sent until the next low-to-high transition. To overcome this, if there is a way for the framegrabber to send out one last image on a high-to-low transition and signal that it is the final image then the host PC could know that the sequence of images to concatenate is finished. But how to do this?
- Use an event signal in the host PC that monitors the Trigger 5 board input signal of the photoeye. If the photoeye goes from high-to-low (trailing edge of part), then tell the grab worker that image concatenation is complete. If it goes from low-to-high, tell the grab background worker that a image is being acquired. This could be done with serialization/counter as well. But looking at the SDK documentation, I do not see how to capture the IO events from the Trigger 5 board in the host PC.
I appreciate your thoughts on this. Thanks!