适配前吸空气部分

This commit is contained in:
q434343
2026-04-01 11:50:42 +08:00
parent ad66fc1841
commit 8164d990cc
2 changed files with 22 additions and 22 deletions

View File

@@ -1672,25 +1672,25 @@ class LiquidHandlerAbstract(LiquidHandlerMiddleware):
use_channels=use_channels, use_channels=use_channels,
) )
# if blow_out_air_volume_before_vol > 0: if blow_out_air_volume_before_vol > 0:
# source_tracker = getattr(sources[0], "tracker", None) source_tracker = getattr(sources[0], "tracker", None)
# source_tracker_was_disabled = bool(getattr(source_tracker, "is_disabled", False)) source_tracker_was_disabled = bool(getattr(source_tracker, "is_disabled", False))
# try: try:
# if source_tracker is not None and hasattr(source_tracker, "disable"): if source_tracker is not None and hasattr(source_tracker, "disable"):
# source_tracker.disable() source_tracker.disable()
# await self.aspirate( await self.aspirate(
# resources=[sources[0]], resources=[sources[0]],
# vols=[blow_out_air_volume_before_vol], vols=[0],
# use_channels=use_channels, use_channels=use_channels,
# flow_rates=None, flow_rates=None,
# offsets=[Coordinate(x=0, y=0, z=sources[0].get_size_z())], offsets=[Coordinate(x=0, y=0, z=sources[0].get_size_z())],
# liquid_height=None, liquid_height=None,
# blow_out_air_volume=None, blow_out_air_volume=[blow_out_air_volume_before_vol],
# spread="custom", spread="custom",
# ) )
# finally: finally:
# if source_tracker is not None: if source_tracker is not None:
# source_tracker.enable() source_tracker.enable()
await self.aspirate( await self.aspirate(
resources=[sources[0]], resources=[sources[0]],
@@ -1712,9 +1712,7 @@ class LiquidHandlerAbstract(LiquidHandlerMiddleware):
use_channels=use_channels, use_channels=use_channels,
flow_rates=[dis_flow_rates[0]] if dis_flow_rates and len(dis_flow_rates) > 0 else None, flow_rates=[dis_flow_rates[0]] if dis_flow_rates and len(dis_flow_rates) > 0 else None,
offsets=[offsets[0]] if offsets and len(offsets) > 0 else None, offsets=[offsets[0]] if offsets and len(offsets) > 0 else None,
blow_out_air_volume=( blow_out_air_volume=[blow_out_air_volume_vol+blow_out_air_volume_before_vol],
[blow_out_air_volume_vol] if blow_out_air_volume_vol > 0 else None
),
liquid_height=[liquid_height[0]] if liquid_height and len(liquid_height) > 0 else None, liquid_height=[liquid_height[0]] if liquid_height and len(liquid_height) > 0 else None,
spread=spread, spread=spread,
) )

View File

@@ -1816,6 +1816,8 @@ class PRCXI9300Backend(LiquidHandlerBackend):
async def aspirate(self, ops: List[SingleChannelAspiration], use_channels: List[int] = None): async def aspirate(self, ops: List[SingleChannelAspiration], use_channels: List[int] = None):
"""Aspirate liquid from the specified resources.""" """Aspirate liquid from the specified resources."""
if ops[0].blow_out_air_volume and ops[0].volume == 0:
return
if hasattr(use_channels, "tolist"): if hasattr(use_channels, "tolist"):
_use_channels = use_channels.tolist() _use_channels = use_channels.tolist()
else: else: