-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathrobot_method.py
More file actions
59 lines (42 loc) · 2.11 KB
/
robot_method.py
File metadata and controls
59 lines (42 loc) · 2.11 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
from pyhamilton import *
import pandas as pd
df = pd.read_csv('combined_list_map.csv')
liq_class = 'StandardVolumeFilter_Water_DispenseJet_Empty'
lmgr = LayoutManager('Test_1.lay')
old_plates = []
new_plates= []
tip_racks = []
old_plate_wells = {}
new_plate_wells = {}
#assign plate values
for x in range(5):
old_plates.append(layout_item(lmgr, Plate96, 'Nun_96_Fl_HB_000%s_Orig'%(x+1)))
new_plates.append(layout_item(lmgr, Plate96, 'Nun_96_Fl_HB_000%s_New'%(x+1)))
for plate in old_plates:
for i in range(95):
old_plate_wells.append((plate, i))
print(old_plate_wells[0])
#assign tip rack values
for x in range(6):
tip_racks.append(layout_item(lmgr, Tip96, 'HT_L_000%s'%(x+1)))
tips = [(tip_racks[0], x) for x in range(8)]
wells_1 = [(plate_1, x) for x in range(8)]
wells_3 = [(plate_3, x) for x in range(8)]
vols = [30 for x in range(8)]
# a = serial.Serial("COM5", 9600, timeout=1)
if __name__ == '__main__':
with HamiltonInterface(simulate=True) as ham_int:
normal_logging(ham_int, os.getcwd())
initialize(ham_int)
tip_pick_up(ham_int, [(tip_carrier, 0)])
aspirate(ham_int, [(plate_1, 0)], [30], liquidClass="HighVolume_Water_DispenseJet_Empty")
dispense(ham_int, [(plate_1, 1)], [30], liquidClass="HighVolume_Water_DispenseJet_Empty")
tip_eject(ham_int, tips)
# move_plate(ham_int, plate_1, plate_2, gripHeight=10.0, gripWidth=80.0, gripMode=0, widthBefore = 100.0)
# grip_height=6.0, gripWidth=80.0, gripMode=0, widthBefore = 100.0
# a.write(bytes('mv:ts 010\r', encoding='utf-8'))
# requests.post(url, data='go_right')
# move_plate(ham_int, plate_2, plate_1, gripHeight=10.0, gripWidth=80.0, gripMode=0, widthBefore = 100.0)
# aspirate(ham_int, wells_1, vols, liquidClass="HighVolume_Water_DispenseJet_Empty")
# dispense(ham_int, wells_3, vols, liquidClass="HighVolume_Water_DispenseJet_Empty")
# move_by_seq(ham_int, 'Nun_96_FL_HB_0004_lid', 'Nun_96_FL_HB_0001_lid', grip_height=6.0, gripWidth=80.0, gripMode=0, widthBefore = 100.0)