Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(api): connect context to real thermocycler during calibration #4454

Merged
merged 2 commits into from
Nov 15, 2019

Conversation

b-cooper
Copy link
Contributor

The calibration session currently picks up the simulated context from the beginning of the session.
This means that the simulated modules are also usedduring labware calibration. This temporarily
connect the thermocycler during calibration so the session is aware of the lid's open/close state.
This is a short term patch that will be removed in place of better session management to replace the
current RPC over HTTP session communication.

review requests

Please ensure that you are able to proceed to calibrating the labware loaded onto the Thermocycler in these 2 cases (via the run app):

  • Your last protocol step is a call to thermocycler.open_lid()
  • Your last protocol step is a call to thermocycler.close_lid()

stub protocol:


metadata = {"apiLevel": "2.0"}


def run(protocol):
    # Labware Setup
    reagents = protocol.load_labware('usascientific_12_reservoir_22ml', '1')
    p300rack = protocol.load_labware('opentrons_96_tiprack_300ul', '2')

    p300 = protocol.load_instrument(
        'p20_single_gen2', 'right', tip_racks=[p300rack])
    thermocycler = protocol.load_module('thermocycler')

    reaction_plate = thermocycler.load_labware('biorad_96_wellplate_200ul_pcr')

    thermocycler.set_block_temperature(4)
    p300.pick_up_tip()
    p300.aspirate(10, reagents.wells_by_name()['A1'])
    p300.dispense(10, reaction_plate.wells_by_name()['A1'])
    thermocycler.set_lid_temperature(50)
    thermocycler.deactivate_lid()
    thermocycler.set_lid_temperature(90)

    thermocycler.set_block_temperature(40, hold_time_seconds=10)
    thermocycler.deactivate_block()
    thermocycler.set_block_temperature(80, hold_time_minutes=0.5)
    thermocycler.deactivate()
    thermocycler.set_block_temperature(
        60, hold_time_seconds=30, hold_time_minutes=0.5)
    thermocycler.set_lid_temperature(30)

    thermocycler.close_lid()
    #thermocycler.open_lid()

The calibration session currently picks up the simulated context from the beginning of the session.
This means that the simulated modules are also usedduring labware calibration. This temporarily
connect the thermocycler during calibration so the session is aware of the lid's open/close state.
This is a short term patch that will be removed in place of better session management to replace the
current RPC over HTTP session communication.
@b-cooper b-cooper added api Affects the `api` project fix PR fixes a bug labels Nov 14, 2019
@b-cooper b-cooper requested review from sfoster1 and a team November 14, 2019 20:38
Copy link
Member

@sfoster1 sfoster1 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@codecov
Copy link

codecov bot commented Nov 14, 2019

Codecov Report

Merging #4454 into edge will increase coverage by 0.39%.
The diff coverage is n/a.

Impacted file tree graph

@@            Coverage Diff             @@
##             edge    #4454      +/-   ##
==========================================
+ Coverage   55.55%   55.95%   +0.39%     
==========================================
  Files         903      903              
  Lines       26019    26662     +643     
==========================================
+ Hits        14456    14919     +463     
- Misses      11563    11743     +180
Impacted Files Coverage Δ
...designer/src/components/KnowledgeBaseLink/index.js 50% <0%> (-16.67%) ⬇️
opentrons/protocol_api/execute.py 82.85% <0%> (-1.36%) ⬇️
opentrons/protocol_api/contexts.py 86.15% <0%> (-1.15%) ⬇️
...ol-designer/src/components/modules/CrashInfoBox.js 0% <0%> (ø) ⬆️
opentrons/protocol_api/geometry.py 100% <0%> (+0.67%) ⬆️
opentrons/protocol_api/labware.py 91.95% <0%> (+1.67%) ⬆️
.../protocol_api/legacy_wrapper/containers_wrapper.py 31.29% <0%> (+4.78%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 222cf37...78e8c8c. Read the comment docs.

@b-cooper b-cooper merged commit 1d40fd6 into edge Nov 15, 2019
@b-cooper b-cooper deleted the api_fix-calibrate-to-tc branch November 15, 2019 16:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
api Affects the `api` project fix PR fixes a bug
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants