Synchronizing camera acquisition with laser sweeping

I would like to use the Mercury 2 camera (MER-1220-32U3M) from Daheng Imaging to aquire an image of every voltage step of my tunable laser and thus of every wavelength of my tunable laser. This would entail one of the following

(1) A script that is able to synchronize camera acquisition with the laser sweep such that each step triggers a camera acquisition

Or perhaps a little easier

(2) A script that matches the frame rate of the camera to the voltage sweep rate of the laser