hamilton-star
БесплатноЗапускает вложенные скриптыНе проверенProgram Hamilton STAR and STARlet liquid handling robots from Python with PyLabRobot 0.2.x (open source, talks to the robot's firmware over USB, no VENUS…
от jkitchin★ 45 звёзд на GitHubОб этом скилле
Hamilton STAR / STARlet with PyLabRobot
Overview
PyLabRobot (PLR) is an MIT-licensed Python SDK that
drives Hamilton STAR and STARlet robots by sending firmware commands over USB. It replaces
Hamilton's VENUS software for the session: you describe the deck in Python, then call
aspirate, dispense, move_plate, etc. The same code runs against a simulator first.
This skill targets pylabrobot 0.2.2, the current stable release (July 2026), and every
example in examples/ was run against it. See "Version note" at the end before using 1.0.
Safety first. This code moves a real robot. Always:
- run the protocol with the simulator (
STARChatterboxBackend) and trackers on before hardware; - check the deck in Python matches the physical deck (carrier type, rail, site, labware);
- keep the front cover closed and someone near the robot for the first hardware run;
- call
await lh.stop()in afinallyso the USB connection is released.
PyLabRobot is not made or supported by Hamilton. Whether using a firmware driver affects your service contract is between you and Hamilton.
When to use something else
- The lab must keep VENUS methods and liquid classes running as-is: use pyhamilton (Windows only, drives VENUS).
- Opentrons robots: see the
opentronsskill. PLR also supports the OT-2, Tecan EVO and Hamilton Vantage with the sameLiquidHandlerAPI but a different backend.
Install
python -m venv env && source env/bin/activate # Windows: .\env\Scripts\activate
pip install "pylabrobot[usb]==0.2.2"
python scripts/check_env.py # version, libusb, robot on USB
- Linux: nothing more.
- macOS:
brew install libusb. (Known issue: some macOS 15 machines don't find the robot.) - Windows: replace the "ML Star" USB driver with libusbK using Zadig, with VENUS closed. VENUS and pyhamilton then stop working until you switch the driver back.
Full steps, switching back to VENUS, and fixes for USB errors: references/install.md.
The workflow
Every protocol has the same shape: build the deck, create a LiquidHandler, setup(), run
steps, stop(). All robot calls are async, so run them with asyncio.run(...) in a script or
top-level await in Jupyter.
import asyncio
from pylabrobot.liquid_handling import LiquidHandler
from pylabrobot.liquid_handling.backends import STARBackend
from pylabrobot.liquid_handling.backends.hamilton.STAR_chatterbox import STARChatterboxBackend
from pylabrobot.resources import (
STARLetDeck,
TIP_CAR_480_A00,
PLT_CAR_L5AC_A00,
hamilton_96_tiprack_300uL_filter,
cor_96_wellplate_360uL_Fb,
set_tip_tracking,
set_volume_tracking,
)
def build_deck():
deck = STARLetDeck() # STARDeck() for a full-size STAR
tip_car = TIP_CAR_480_A00(name="tip_carrier")
tip_car[0] = hamilton_96_tiprack_300uL_filter(name="tips_01") # site 0 = front-most
deck.assign_child_resource(tip_car, rails=1)
plt_car = PLT_CAR_L5AC_A00(name="plate_carrier")
plt_car[0] = cor_96_wellplate_360uL_Fb(name="source")
plt_car[1] = cor_96_wellplate_360uL_Fb(name="dest")
deck.assign_child_resource(plt_car, rails=8)
return deck
async def main(simulate=True):
set_tip_tracking(True) # error on picking up a tip that isn't there
set_volume_tracking(True) # error on aspirating more than a well holds
backend = STARChatterboxBackend() if simulate else STARBackend()
lh = LiquidHandler(backend=backend, deck=build_deck())
await lh.setup() # on hardware: initializes the robot, can take a minute
try:
tips = lh.deck.get_resource("tips_01")
src, dst = lh.deck.get_resource("source"), lh.deck.get_resource("dest")
for w in src["A1:H1"]:
w.tracker.set_volume(200) # what is really in the wells (uL)
await lh.pick_up_tips(tips["A1:H1"]) # one tip per channel, 8 channels
await lh.aspirate(src["A1:H1"], vols=[100] * 8)
await lh.dispense(dst["A1:H1"], vols=[100] * 8)
await lh.return_tips() # or discard_tips() to the trash
finally:
await lh.stop()
asyncio.run(main())
Key concepts
- Deck, carriers, sites. The deck has rails (STARlet 32, STAR 56 in 0.2.x). Carriers sit on a
rail; labware sits in a carrier site,
carrier[i], with site 0 at the front. Names must be unique: you look things up withlh.deck.get_resource("name"). - Wells and tips by name.
plate["A1"],plate["A1:H1"](a column, list of 8),plate["A1:A12"](a row).plate.get_well("A1")returns a single well.plate.get_all_items()returns all 96. - Lists everywhere.
aspirate/dispensetake a list of containers and a list of volumes, one per channel used.use_channels=[0, 2]picks specific channels (channel 0 is the back-most). - Units. Volumes in uL, flow rates in uL/s, distances in mm, `o
Установить hamilton-star в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
*Вложенные файлы
FAQ
Что делает скилл hamilton-star?
Program Hamilton STAR and STARlet liquid handling robots from Python with PyLabRobot 0.2.x (open source, talks to the robot's firmware over USB, no VENUS needed). Covers installing (pip, USB/libusbK drivers, switching back to VENUS), building a deck with carriers, tip racks and plates, simulating protocols, 8-channel and 96-head pipetting, moving plates with the iSWAP or CoRe grippers, liquid-level detection, Hamilton liquid classes and firmware errors. Use whenever the user mentions a Hamilton STAR, STARlet, Microlab STAR, ML STAR, PyLabRobot, pylabrobot, STARBackend, or wants to automate pipetting, plate moves or serial dilutions on a Hamilton robot from Python, even if they don't name the library.
Как установить скилл hamilton-star?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл hamilton-star запускает скрипты?
Да, скилл несёт исполняемые скрипты. Проверь исходник перед установкой.
Похожие скиллы
mcp-builder
Guide for creating high-quality MCP (Model Context Protocol) servers that enable LLMs to interact with external services through well-designed tools. Use when…
от Anthropicclaude-api
Reference for the Claude API / Anthropic SDK — model ids, pricing, params, streaming, tool use, MCP, agents, caching, token counting, model migration. TRIGGER…
от Anthropicalgorithmic-art
Creating algorithmic art using p5.js with seeded randomness and interactive parameter exploration. Use this when users request creating art using code…
от Anthropicmcp-integration
This skill should be used when the user asks to "add MCP server", "integrate MCP", "configure MCP in plugin", "use .mcp.json", "set up Model Context…
от Anthropic