@@ -89,7 +89,8 @@ def on_message(self, message: types.CommandMessage) -> None:
89
89
payload = message ["payload" ]
90
90
91
91
# We cannot handle paired pipette messages
92
- if "instruments" in payload or "locations" in payload :
92
+ # locations also applies to transfer commands
93
+ if "instruments" in payload :
93
94
logger .warning (
94
95
f"Paired pipettes are not supported by the duration estimator. "
95
96
f"Command '{ payload ['text' ]} ' cannot be estimated properly."
@@ -164,6 +165,15 @@ def handle_message( # noqa: C901
164
165
duration = self .on_thermocycler_deactivate_lid (payload = payload )
165
166
elif message_name == types .THERMOCYCLER_OPEN :
166
167
duration = self .on_thermocycler_lid_open (payload = payload )
168
+ elif message_name == types .TRANSFER :
169
+ # Already accounted for in other steps
170
+ pass
171
+ elif message_name == types .DISTRIBUTE :
172
+ pass
173
+ elif message_name == types .CONSOLIDATE :
174
+ pass
175
+ elif message_name == types .COMMENT :
176
+ pass
167
177
else :
168
178
logger .warning (
169
179
f"Command type '{ message_name } ' is not yet supported by the "
@@ -291,7 +301,6 @@ def on_blow_out(self, payload) -> float:
291
301
# So we are defaulting to 0.5 seconds
292
302
duration = 0.5
293
303
logger .info (f"blowing_out_for { duration } seconds, in slot { curr_slot } " )
294
-
295
304
return duration
296
305
297
306
def on_touch_tip (self , payload ) -> float :
@@ -304,7 +313,6 @@ def on_touch_tip(self, payload) -> float:
304
313
# depth = plate['A1'].diameter
305
314
duration = 0.5
306
315
logger .info (f"touch_tip for { duration } seconds" )
307
-
308
316
return duration
309
317
310
318
def on_delay (self , payload ) -> float :
@@ -394,23 +402,20 @@ def on_thermocycler_lid_close(self, payload) -> float:
394
402
duration = 24
395
403
thermoaction = "closing"
396
404
logger .info (f"thermocation = { thermoaction } " )
397
-
398
405
return duration
399
406
400
407
def on_thermocycler_lid_open (self , payload ) -> float :
401
408
# Hardware said ~24 seconds
402
409
duration = 24
403
410
thermoaction = "opening"
404
411
logger .info (f"thermocation = { thermoaction } " )
405
-
406
412
return duration
407
413
408
414
def on_thermocycler_deactivate_lid (self , payload ) -> float :
409
415
# Hardware said ~23 seconds
410
416
duration = 23
411
417
thermoaction = "Deactivating"
412
418
logger .info (f"thermocation = { thermoaction } " )
413
-
414
419
return duration
415
420
416
421
def on_tempdeck_set_temp (self , payload ) -> float :
0 commit comments