add BIOYOND deck assignment and pass all tests

This commit is contained in:
Junhan Chang
2025-09-25 08:41:41 +08:00
parent 63ab1af45d
commit 5c47cd0c8a
5 changed files with 46 additions and 30 deletions

View File

@@ -6,19 +6,21 @@ from unilabos.resources.bioyond.warehouses import bioyond_warehouse_1x4x4, bioyo
class BIOYOND_PolymerReactionStation_Deck(Deck):
def __init__(self, name: str = "PolymerReactionStation_Deck") -> None:
super().__init__(name=name, size_x=2700.0, size_y=1080.0, size_z=1500.0)
self.setup()
def setup(self) -> None:
# 添加仓库
self.warehouses = {
"io_warehouse_left": bioyond_warehouse_1x4x4("io_warehouse_left"),
"io_warehouse_right": bioyond_warehouse_1x4x4("io_warehouse_right"),
"liquid_and_lid_handling": bioyond_warehouse_liquid_and_lid_handling("liquid_and_lid_handling"),
"堆栈1": bioyond_warehouse_1x4x4("堆栈1"),
"堆栈2": bioyond_warehouse_1x4x4("堆栈2"),
"站内试剂存放堆栈": bioyond_warehouse_liquid_and_lid_handling("站内试剂存放堆栈"),
}
self.warehouse_locations = {
"io_warehouse_left": Coordinate(0.0, 650.0, 0.0),
"io_warehouse_right": Coordinate(2550.0, 650.0, 0.0),
"liquid_and_lid_handling": Coordinate(800.0, 475.0, 0.0),
"堆栈1": Coordinate(0.0, 650.0, 0.0),
"堆栈2": Coordinate(2550.0, 650.0, 0.0),
"站内试剂存放堆栈": Coordinate(800.0, 475.0, 0.0),
}
self.warehouses["站内试剂存放堆栈"].rotation = 90.0
for warehouse_name, warehouse in self.warehouses.items():
self.assign_child_resource(warehouse, location=self.warehouse_locations[warehouse_name])