# Support script for repeatability tests # Moves the system to the position to tare it import scansupport as ss from repeat_config import * ss.motorPositions() ss.commandMotor(0.0, repeat_tare_pos)
#!/usr/bin/python # -*- coding: utf-8 -*- # Forces the motors to move the window to the center position of the FoV import scanconfig import scansupport as sws #### START EXECUTION ###### if (scanconfig.cte_disable_motors_first): sws.disableMotors() print("Check initial motor positions") sws.motorPositions() if (scanconfig.cte_enable_motors_first): sws.enableMotors() # Calculate the center position of the window over the FoV lsx = 0.0 lsy = 0.0 print("lsx: " + str(lsx)) print("lsy: " + str(lsy)) sws.commandMotor(lsx, lsy) print("Check motor positions after resets") sws.motorPositions() sws.motorClose()
#!/usr/bin/python # -*- coding: utf-8 -*- # Forces ONLY the X and Y motors to move the window to the center of the FoV. Comp is not commanded. import scanconfig import scansupport as sws #### START EXECUTION ###### if (scanconfig.cte_disable_motors_first): sws.disableMotors() print("Check initial motor positions") sws.motorPositions() if (scanconfig.cte_enable_motors_first): sws.enableMotors() # Calculate the center position of the window over the FoV lsx = 0.0 lsy = 0.0 print("lsx: "+str(lsx)) print("lsy: "+str(lsy)) sws.commandMotorWindow(lsx, lsy) print("Check motor positions after resets") sws.motorPositions()
print("* Vertical: " + str(cam.get(cv2.CAP_PROP_FRAME_HEIGHT))) # subprocess.check_call("exit 1", shell=True) if scanconfig.cte_disable_motors_first: sws.disableMotors() if scanconfig.cte_enable_motors_first: sws.enableMotors() if scanconfig.cte_reset_motors_first: sws.resetMotors() if scanconfig.cte_verbose: print("Check motor positions after resets") sleep(scanconfig.cte_stabilization_time) sws.motorPositions() elif scanconfig.cte_home_motors_first: sws.homeMotors() if scanconfig.cte_verbose: print("Check motor positions after resets") sleep(scanconfig.cte_stabilization_time) sws.motorPositions() else: if scanconfig.cte_verbose: print("Check initial motor positions") sleep(scanconfig.cte_stabilization_time) sws.motorPositions() # Prepare the Database db = sqlite3.connect('./db/log.sqlite3') if not db:
print ("* Vertical: " + str(cam.get(cv2.CAP_PROP_FRAME_HEIGHT))) # subprocess.check_call("exit 1", shell=True) if scanconfig.cte_disable_motors_first: sws.disableMotors() if scanconfig.cte_enable_motors_first: sws.enableMotors() if scanconfig.cte_reset_motors_first: sws.resetMotors() if scanconfig.cte_verbose: print("Check motor positions after resets") sleep(scanconfig.cte_stabilization_time) sws.motorPositions() elif scanconfig.cte_home_motors_first: sws.homeMotors() if scanconfig.cte_verbose: print("Check motor positions after resets") sleep(scanconfig.cte_stabilization_time) sws.motorPositions() else: if scanconfig.cte_verbose: print("Check initial motor positions") sleep(scanconfig.cte_stabilization_time) sws.motorPositions() # Prepare the Database db = sqlite3.connect('./db/log.sqlite3') if not db: