basler / pypylon

The official python wrapper for the pylon Camera Software Suite
http://www.baslerweb.com
BSD 3-Clause "New" or "Revised" License
567 stars 207 forks source link

Camera seems to freeze after changing line height. #303

Open PolymaTh-EE98 opened 3 years ago

PolymaTh-EE98 commented 3 years ago

I am using a linescan (racer) camera and need to change the frame size as product dimensions change. Using the method mentioned in this post causes issues for me. https://github.com/basler/pypylon/issues/145

Here is the relevant part of my code.

`camera.AcquisitionStop.Execute()

camera.TLParamsLocked = False

camera.Height = int(CameraHeight)

camera.TLParamsLocked = True

camera.AcquisitionStart.Execute()`

My work around is to set the line height to large number in pylon then saving this pfs file. If I set the lines from Python with the code above to something smaller than what is in the pfs file the camera stops sending me images. This is a problem as people who are not aware use Pylon Viewer and save the file over mine then the camera quits working with my Python code.

amarnathreddy0201 commented 2 years ago

Hi Sir,

Are you resolved this dynamic Question.

Suggest me how to change parameters on the fly if you resolved this problem.

DxTa commented 2 weeks ago

I seems to have similar issue with AutoFunctionROI's parameters.

I think the camera waits for the trigger signal again (https://docs.baslerweb.com/acquisition-start-stop-and-abort) and if the camera having trigger parameter = off, then it will not trigger automatically. Thus maybe changing trigger to Continuous can solve in some cases (https://docs.baslerweb.com/free-run-image-acquisition).

I will do some more tests on this.