Hamilton Heater Shaker#
The Hamilton Heater Shaker can be used both through a control box (the HamiltonHeaterShakerBox
, which supports up to 8 heater shakers), or directly plugged into a Hamilton STAR liquid handler (supporting up to 2 heater shakers).
When using the box, a USB B cable is plugged into one of the heater shakers and connected to the host computer. This heater shaker is connected via a serial port to the control box. Other heater shakers are also plugged into the control box using serial cables, but not plugged into the computer. The first heater shakers serves as a gateway.
When using the Hamilton STAR, the heater shaker is connected to the STAR via a serial cable. The STAR is connected to the host computer via a USB A cable. This is no different from using the STAR as a standalone liquid handler. The heater shaker is then controlled through the STAR.
In either case, HamiltonHeaterShakerBackend
will be the backend and HeaterShaker
will be the frontend. Depending on the interface you use, pass a different argument to HamiltonHeaterShakerBackend
.
As multiple heater shakers can be controlled through one USB connection to the computer (the STAR cable when using the STAR, or a cable to HHS 1 when using the control box), the index
of a specific heater shaker needs to be specified. Note that this also requires turing a DIP switch on the bottom of the HHS module.
# Setting up a backend with the HamiltonHeaterShakerBox
from pylabrobot.heating_shaking import HamiltonHeaterShakerBackend, HamiltonHeaterShakerBox
hhs_box = HamiltonHeaterShakerBox()
backend = HamiltonHeaterShakerBackend(index=1, interface=hhs_box)
# Alternative: setting up a backend with a STAR
from pylabrobot.liquid_handling import LiquidHandler, STAR
from pylabrobot.resources import STARDeck
from pylabrobot.heating_shaking import HamiltonHeaterShakerBackend
star_backend = STAR()
lh = LiquidHandler(backend=star_backend, deck=STARDeck())
backend = HamiltonHeaterShakerBackend(index=1, interface=star_backend)
from pylabrobot.heating_shaking import HeaterShaker
from pylabrobot.resources.coordinate import Coordinate
hs = HeaterShaker(
name="Hamilton HeatShaker",
backend=backend,
size_x=146.2,
size_y=103.8,
size_z=74.11,
child_location=Coordinate(x=9.66, y=9.22, z=74.11),
)
Note that for the HHS Box, you will need to call setup
before calling HeaterShaker.setup
. When using a STAR
, just use star.setup()
or, more likely, lh.setup()
. This is opening the USB connection to the device you are using as an interface.
Note that setup should only be called ONCE:
when using a STAR as a liquid handler, just call
lh.setup()
. Do not call it again when using the heater shaker.when using multiple heater shakers with the control box, call
setup
once for the control box, and then callHeaterShaker.setup
for each heater shaker. Do not callsetup
again for the control box.
# when using the HamiltonHeaterShakerBox, you need to call setup() on the box
await hhs_box.setup()
# Alternative: when using the STAR, you need to call setup() on lh
await lh.setup()
After calling setup
on your interface, call HeaterShaker.setup
for each module. This will initialize the module itself.
await hs.setup()
Temperature#
await hs.get_temperature() # middle temperature
26.3
The HHS also supports reading the edge temperature:
await hs.backend.get_edge_temperature()
26.4
await hs.set_temperature(37)
'T1TAid0004er00'
await hs.wait_for_temperature()
await hs.get_temperature()
36.6
Shaking#
await hs.lock_plate()
await hs.shake(
speed=100,
direction=0,
acceleration=1000,
)
await hs.unlock_plate()
await hs.stop_shaking()
Using multiple heater shakers#
When using multiple heater shakers, you can use the HamiltonHeaterShakerBackend
class to control them. This class will automatically handle the communication with the control box and the individual heater shakers.
As above, initialize the HamiltonHeaterShakerBox
class. Then, initialize as many HamiltonHeaterShakerBackend
classes as you want to control, specifying the index for each. Note that each HamiltonHeaterShakerBackend
gets the same instance of the HamiltonHeaterShakerBox
: this is because there is a single USB connection, managed by that instance.
hhs_box = HamiltonHeaterShakerBox()
# HS1
backend1 = HamiltonHeaterShakerBackend(index=1, interface=hhs_box)
hs1 = HeaterShaker(
name="Hamilton HeatShaker",
backend=backend,
size_x=146.2,
size_y=103.8,
size_z=74.11,
child_location=Coordinate(x=9.66, y=9.22, z=74.11),
)
# HS2
backend2 = HamiltonHeaterShakerBackend(index=2, interface=hhs_box)
hs2 = HeaterShaker(
name="Hamilton HeatShaker",
backend=backend,
size_x=146.2,
size_y=103.8,
size_z=74.11,
child_location=Coordinate(x=9.66, y=9.22, z=74.11),
)
For setup, call setup
on the HamiltonHeaterShakerBox
instance. This will setup the USB connection to the control box. Then, call setup
on each HamiltonHeaterShakerBackend
instance. This will setup the individual heater shakers.
await hhs_box.setup()
for hs in [hs1, hs2]:
await hs.setup()