Skip to content

Instantly share code, notes, and snippets.

@SimplyAhmazing
Last active April 27, 2017 18:38
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save SimplyAhmazing/04ac02c659e38a02864de2ec4d934421 to your computer and use it in GitHub Desktop.
Save SimplyAhmazing/04ac02c659e38a02864de2ec4d934421 to your computer and use it in GitHub Desktop.
Smart Modules API

Smart Modules API (sample)

Instruments (attached to the robot)

Pipette

pump = instruments.Pipette(axis='a', ...)
pump.dispense(volume, <location>)

Pump:

pump = instruments.Pump(axis='a')
pump.dispense(volume, <location>, flowrate=X(ul/s))

Smart Modules

  • All smart modules need to have the ability to run synchrononously or asynchronously in a protocol

Mag Deck:

magdeck = smart_modules.MagDeck()
magdeck.engage()  # stays engaged forever
magdeck.engage(time=5) # stays engaged for 5 mins, then shuts off
magdeck.disengage()

Centrifuge:

centrifuge = smart_modules.Centrifuge()
centrifuge.run(time=5, rpm=5000)  # time in mins

Weight Scale:

weightscale = smart_modules.WeightScale()
weightscale.read() -> returns weight in mg
weightscale.read(path='path/to/file.txt', "{{ count }}, {{ reading }}", "p10") -> returns weight in mg
weightscale.tare()
  • What type of weight scale do we support? Ones that do automatic/smart averaging or direct reading.

HeatDeck (or ColdDeck):

heatdeck = smart_modules.HeatDeck()
heatdeck.temperature(80)

Associating a smart module on the deck with a plate

Note: This is no longer being pursued until hardware spec/plan is finalized.

Flavor 1:

plate1 = containers.load('96-flat', 'A1', 'my-plate', smartmodule=magdeck)
plate2 = containers.load('96-flat', 'A2', 'my-plate2', smartmodule=heatdeck)

Flavor 2:

magdeck = smart_modules.MagDeck()
plate = containers.load('96-flat', 'A1', 'my-plate')
plate.add_module(magdeck)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment