Machine Vision

cancel
Showing results for 
Search instead for 
Did you mean: 

Triggering Basler linescan cameras

I am triggering a Basler linescan camera with a rotary encoder, which is being driven indirectly by a conveyor. The linescan camera is mounted over the conveyor looking down onto the product we are inspecting. Each pulse generated by the encoder is being used to trigger a single line.  I have configured the camera to work in trigger mode with line trigger only.   So far so good.  The problem we are experiencing occurs when the product stops mid scan. The encoder stops generating pulses when the product stops and restarts when the conveyor  begins to move. However, are images are being stretched by the additional of extra lines compared to images that are generated with no stoppage. We know that the encoder doesn't stop immediately and generates a few additional pulses, so we know that the image will be affected slightly, but the impact on the image appears to much more severe than we would expect. So either we are getting many more additional pulses than we think when the product stops or the camera is behaving in a strange manner. Has anyone experienced this kind of issue before? I wondered whether we might be getting additional pulses from electrical interference, but I am mystified as to why we would get so many - as much as 500 additional lines or 10% of the scan length.

 

Simon

0 Kudos
Message 1 of 3
(3,117 Views)

My guess is that noise or vibration is creating extra edges that are triggering the camera.

 

Are you using the encoder engine on the Basler camera?  It makes the camera pretty smart, so that it only triggers once for each increment of the encoder, and ignores any false triggers.  It can even be setup to ignore a small reversal of the conveyor, and does not take another line until it gets back to where it left off.  I used this on my last project, and it improved the image quality significantly.  You do have to connect both encoder signals (A and B) for it to work.

 

Another trick is to set the exposure time to the pulse width.  If there are a bunch of dark lines when it stops, they are due to noise or encoder jitter.  They should be fixed by switching to the encoder engine.

 

Bruce

Bruce Ammons
Ammons Engineering
0 Kudos
Message 2 of 3
(3,094 Views)

Hi Bruce,

 

Yes we are using the encoder engine. at least we are using NI MAX configuration settings to set the parameters that you describe. We are triggering using the encoder and using the forward direction only. I am using timed exposure at the moment but I will try out what you suggest about setting the exposure to the pulse width. Other thoughts are noise, as you point out. Another might be the encoder activating slightly before the conveyor starts, due to slack? in the belt. Could the motor stopping and starting generate a series of pulses, or would a single noise pulse be more likely?

Anyway thanks for your input. Appreciate it. 

0 Kudos
Message 3 of 3
(3,080 Views)