diff --git a/flir_repo/flir/__pycache__/driver.cpython-38.pyc b/flir_repo/flir/__pycache__/driver.cpython-38.pyc index 2d7a24c..ea625c2 100644 Binary files a/flir_repo/flir/__pycache__/driver.cpython-38.pyc and b/flir_repo/flir/__pycache__/driver.cpython-38.pyc differ diff --git a/flir_repo/flir/driver.py b/flir_repo/flir/driver.py index a689a32..1fb4cd3 100644 --- a/flir_repo/flir/driver.py +++ b/flir_repo/flir/driver.py @@ -140,7 +140,7 @@ def get_image(self,num_of_im): images=[] for i in range(num_of_im): # print("Before GetNextImage") - image = self.cam_1.GetNextImage(10000) #timeout (ms) 10000 + image = self.cam_1.GetNextImage(20000) #timeout (ms) 10000 # print("Picture Successfully taken at: ",time.strftime("%d %b %Y %H:%M:%S", time.localtime())) images.append(np.array(image.GetData(),dtype="uint16").reshape((image.GetHeight(),image.GetWidth()))) #convert PySpin ImagePtr into numpy array image.Release() diff --git a/picomotor_repo/picomotor/__pycache__/picomotor_driver.cpython-38.pyc b/picomotor_repo/picomotor/__pycache__/picomotor_driver.cpython-38.pyc index b3186b6..7c3ff2c 100644 Binary files a/picomotor_repo/picomotor/__pycache__/picomotor_driver.cpython-38.pyc and b/picomotor_repo/picomotor/__pycache__/picomotor_driver.cpython-38.pyc differ diff --git a/picomotor_repo/picomotor/picomotor_driver.py b/picomotor_repo/picomotor/picomotor_driver.py index 964509a..19701c8 100644 --- a/picomotor_repo/picomotor/picomotor_driver.py +++ b/picomotor_repo/picomotor/picomotor_driver.py @@ -6,13 +6,14 @@ import numpy as np #import os +# 'sipyco_rpctool ::1 3210 list-methods' will list the methods of this driver. use 'sipyco_rpctool ::1 3210 call ' e.g. sipyco_rpctool ::1 3210 call move 'MOTx_x' class picomotor: axis_names = { "MOTz_x": "112", "MOTz_y": "122", "MOTy_x": "232", "MOTy_y": "242", "MOTx_x": "212", "MOTx_y": "222"} - steps_in_turn = { "MOTz_x": [45650/3, 48500/3], "MOTz_y":[58000/3, 59400/3], "MOTy_x": [90150/3, 69000/3], "MOTy_y": [87400/3, 62500/3], + steps_in_turn = { "MOTz_x": [45650/3, 48500/3], "MOTz_y":[58000/3, 71400/3], "MOTy_x": [90150/3, 69000/3], "MOTy_y": [65500/3, 62500/3], "MOTx_x": [45300/3, 51000/3], "MOTx_y": [51100/3, 51900/3]} # [CW, CCW] number of steps for 1 turn, using numbers from OneNote 2/8/20 calibration - - + # Original MOTY values: "MOTy_x": [90150/3, 69000/3], "MOTy_y": [87400/3, 62500/3], + # "MOTz_y":[58000/3, 59400/3] [58000/3, 69400/3] def __init__(self, COM_port): """Open serial connection for NewFocus 8732 controller""" """COM_port: ie 'COM3' (check device manager) """ @@ -68,7 +69,7 @@ def move(self, axis="MOTx_x", steps=1000, velocity=1500): cmd4 = ":SOUR:PULS:COUN " + str(round(abs(steps))) cmd = cmd1 + "; " + cmd2 + "; " + cmd3 #+ "; " + cmd4 - print(cmd) + # print(cmd) self.sendreceive(cmd) time.sleep(0.01) self.sendreceive(cmd4) @@ -108,7 +109,7 @@ def wait_for_move(self): """ Wait for picomotor to finish moving """ timeout = 120 # timeout seconds moving = 0 - print("ran wait successfully") + # print("ran wait successfully") while moving==0: #OPC returns 1 if all channels are finished time.sleep(0.2) text = self.sendreceive("*OPC?")