Slot (inherits from dataclass)
Description
Represents a single slot on the Jubilee deck. Each slot has a unique index, an (x, y) offset position, and can optionally hold a labware item.
Constructor
python
Slot(slot_index: int, offset: Tuple[float], has_labware: bool, labware: str)Initializes a slot object with position and occupancy information.
Properties
| Property | Type | Description |
|---|---|---|
slot_index | int | Unique identifier for the slot (e.g., 0–5). |
offset | Tuple[float] | X, Y position offset of the slot relative to the deck origin. |
has_labware | bool | Whether the slot currently has labware loaded. |
labware | str | Identifier for the labware loaded into the slot, if any. |
Methods
(No custom methods defined for Slot; all functionality provided through dataclass fields.)
Short Example
python
# Create a new Slot manually
slot0 = Slot(slot_index=0, offset=(0.0, 0.0), has_labware=False, labware=None)
# Check if slot has labware
print(slot0.has_labware) # FalseImportant Notes
- Slot information is generally initialized automatically when loading a
Deckconfiguration. - When a labware is loaded into a slot,
has_labwareis set toTrue, and thelabwarefield holds the loaded object. - Slot offsets are critical for precise labware positioning and must match the physical deck layout.