I am relatively new to this, and I hope my question hasn’t been asked already. We have the OT-2 in our laboratory and are planning to use it for some tests in our routine testing (for example, LaCar testing). I am working with the Python API.
I understand the basics of programming and have already written a functional program. My question is: Is there a way in the Opentrons app to make the program automatically adjust to different numbers of samples, or do I need to write separate programs for each sample count? This seems a bit unintuitive to me.
I would greatly appreciate any help or tips.
If you want users to input a different sample amount, there’s no native function for this.
I have it set up so the user fills in a google sheet and then we pull the csv data from that using the gspread library and parse out variables and values. So then whenever the user updates the google sheet, the robot will load a different number of plates
Alternatively, a simple solution is just have your python script locally on your opentrons PC and just set a variable, say, NUM_PLATES = 3 at the top (or NUM_TUBES, whatever).
Then just change and upload a new protocol each time you run your program.
If you do it in a way where the python file itself pulls from somewhere else, you don’t need to keep uploading new protocols.
Genie LabOS is now natively integrated with the OT-2 and Flex. Defining parameters and having a user input information at run time is now available, along with many other features/benefits (like error handling). Feel free to reach out to me email@example.com to learn how to make this possible for your lab.
Thank you everyone for your responses, they were truly helpful! I managed to resolve the issue by uploading a file to the Opentrons system. The script then retrieves the necessary information. Admittedly, this isn’t the ideal solution as it somewhat hinders the workflow, but it works for now