Skip to content

Commit

Permalink
Add device id choice to DM startup - not to be merged in catkit2
Browse files Browse the repository at this point in the history
  • Loading branch information
THD2-team committed Feb 12, 2025
1 parent d94e276 commit 4147fec
Showing 1 changed file with 2 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ class BmcDeformableMirrorHardware(BmcDeformableMirror):
def __init__(self, service_type='bmc_deformable_mirror_hardware'):
super().__init__(service_type)

self.device_id = self.config.get('device_id')
self.device_command_index = self.config.get('device_command_index', 0)
self.enable_high_resolution = self.config.get('enable_high_resolution', False)

Expand All @@ -31,6 +32,7 @@ def __init__(self, service_type='bmc_deformable_mirror_hardware'):

def open(self):
self.device = bmc.BmcDm()
status1 = self.device.set_device_id(self.device_id)
status = self.device.open_dm(self.serial_number)

if status != bmc.NO_ERR:
Expand Down

0 comments on commit 4147fec

Please sign in to comment.