Flint API to monitor Lima camera
This MR provide an API usable by BLISS to allow to start and stop monitoring of a Lima detector.
Related to #1602
- It will create a widget if none are available
- Or it will reuse the widget used to display the scans from the detector
- Flint stop the monitoring if a scan is started in the same widget (requesting to stop it with the API will then fail)
- Restarting the monitoring on the same widget will stop and restart a new one
- The exposure time represent the time between 2 images in the detector (the min time to wait before reaching a new image)
- If unset it will be reached from the detector
- The GUI provides a tool to update live/stop and exposure time
# Display the Lima detector widget
SCAN_DISPLAY.auto = True
loopscan(1, 1 ,lima_tomo_simulator)
# The info for the monitoring
channel_name = lima_tomo_simulator.image.fullname
tango_address = lima_tomo_simulator.proxy.name()
# Start the monitoring
from bliss.common import plot as plot_mdl
flint = plot_mdl.get_flint()
flint.start_image_monitoring(channel_name, tango_address)
# OR
flint.start_image_monitoring(channel_name, tango_address, exposure_time=5)
...
# Stop the monitoring
try:
flint.stop_image_monitoring(channel_name)
except:
# Make it safe in case it was already stopped by Flint (cause of a new scan)
pass