Skip to content

Initial stage position #294

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 8 commits into from
Jan 3, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
38 changes: 0 additions & 38 deletions src/aslm/config/configuration.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -132,10 +132,7 @@ microscopes:
type: PI
serial_number: 119060508
axes: [x, y, z, theta, f]
y_unload_position: 10000
y_load_position: 90000

startfocus: 75000
x_max: 33500
x_min: 16000
y_max: 100000
Expand All @@ -147,29 +144,13 @@ microscopes:
theta_max: 360
theta_min: 0

x_rot_position: 2000
y_rot_position: 2000
z_rot_position: 2000

x_step: 500
y_step: 500
z_step: 500
theta_step: 30
f_step: 500

position:
x_pos: 25250
y_pos: 40000
z_pos: 40000
f_pos: 70000
theta_pos: 0
velocity: 1000

x_offset: 0
y_offset: 0
z_offset: 0
f_offset: 0
theta_offset: 0
zoom:
hardware:
name: zoom
Expand Down Expand Up @@ -360,10 +341,7 @@ microscopes:
type: Thorlabs
serial_number: 74000375
axes: [f]
y_unload_position: 10000
y_load_position: 90000

startfocus: 75000
x_max: 33500
x_min: 16000
y_max: 100000
Expand All @@ -375,29 +353,13 @@ microscopes:
theta_max: 360
theta_min: 0

x_rot_position: 2000
y_rot_position: 2000
z_rot_position: 2000

x_step: 500
y_step: 500
z_step: 500
theta_step: 30
f_step: 500

position:
x_pos: 25250
y_pos: 40000
z_pos: 40000
f_pos: 0
theta_pos: 0
velocity: 1000

x_offset: 1500
y_offset: 1720
z_offset: -14311
f_offset: 0
theta_offset: 0
zoom:
position:
N/A: 0
Expand Down
4 changes: 2 additions & 2 deletions src/aslm/model/device_startup_functions.py
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,7 @@ def load_camera_connection(configuration,
# Locally Import Hamamatsu API and Initialize Camera Controller
HamamatsuController = importlib.import_module('aslm.model.devices.APIs.hamamatsu.HamamatsuAPI')
return auto_redial(HamamatsuController.DCAM, (camera_id,), exception=Exception)
elif cam_type.lower() == 'syntheticcamera' or device_type.lower() == 'synthetic':
elif cam_type.lower() == 'syntheticcamera' or cam_type.lower() == 'synthetic':
from aslm.model.devices.camera.camera_synthetic import SyntheticCameraController
return SyntheticCameraController()
else:
Expand Down Expand Up @@ -169,7 +169,7 @@ def start_camera(microscope_name,
if cam_type == 'HamamatsuOrca':
from aslm.model.devices.camera.camera_hamamatsu import HamamatsuOrca
return HamamatsuOrca(microscope_name, device_connection, configuration)
elif cam_type.lower() == 'syntheticcamera' or device_type.lower() == 'synthetic':
elif cam_type.lower() == 'syntheticcamera' or cam_type.lower() == 'synthetic':
from aslm.model.devices.camera.camera_synthetic import SyntheticCamera
return SyntheticCamera(microscope_name, device_connection, configuration)
else:
Expand Down
15 changes: 15 additions & 0 deletions src/aslm/model/devices/camera/camera_synthetic.py
Original file line number Diff line number Diff line change
Expand Up @@ -266,4 +266,19 @@ def get_minimum_waiting_time(self):
"""
return 0.01

def calculate_readout_time(self):
r""" Calculate duration of time needed to readout an image.
Calculates the readout time and maximum frame rate according to the camera configuration settings.

Returns
-------
readout_time : float
Duration of time needed to readout an image.
max_frame_rate : float
Maximum framerate for a given camera acquisition mode.

"""
exposure_time = self.camera_controller.get_property_value('exposure_time')
readout_time = 0.01 # 10 milliseconds.
max_frame_rate = 1 / (exposure_time + readout_time)
return readout_time, max_frame_rate
Loading