@@ -7245,18 +7245,23 @@ async def clld_probe_z_height_using_channel(
7245
7245
detection_drop_str = f"{ detection_drop :04} "
7246
7246
post_detection_dist_str = f"{ post_detection_dist_increments :04} "
7247
7247
7248
- await self .send_command (
7249
- module = STAR .channel_id (channel_idx ),
7250
- command = "ZL" ,
7251
- zh = lowest_immers_pos_str , # Lowest immersion position [increment]
7252
- zc = start_pos_search_str , # Start position of LLD search [increment]
7253
- zl = channel_speed_str , # Speed of channel movement
7254
- zr = channel_acc_str , # Acceleration [1000 increment/second^2]
7255
- gt = detection_edge_str , # Edge steepness at capacitive LLD detection
7256
- gl = detection_drop_str , # Offset after capacitive LLD edge detection
7257
- zj = post_detection_trajectory , # Movement of the channel after contacting surface
7258
- zi = post_detection_dist_str , # Distance to move up after detection [increment]
7259
- )
7248
+ try :
7249
+ await self .send_command (
7250
+ module = STAR .channel_id (channel_idx ),
7251
+ command = "ZL" ,
7252
+ zh = lowest_immers_pos_str , # Lowest immersion position [increment]
7253
+ zc = start_pos_search_str , # Start position of LLD search [increment]
7254
+ zl = channel_speed_str , # Speed of channel movement
7255
+ zr = channel_acc_str , # Acceleration [1000 increment/second^2]
7256
+ gt = detection_edge_str , # Edge steepness at capacitive LLD detection
7257
+ gl = detection_drop_str , # Offset after capacitive LLD edge detection
7258
+ zj = post_detection_trajectory , # Movement of the channel after contacting surface
7259
+ zi = post_detection_dist_str , # Distance to move up after detection [increment]
7260
+ )
7261
+ except STARFirmwareError :
7262
+ await self .move_all_channels_in_z_safety ()
7263
+ raise
7264
+
7260
7265
if move_channels_to_save_pos_after :
7261
7266
await self .move_all_channels_in_z_safety ()
7262
7267
0 commit comments