示例#1
0
 def __init__(self, epicsID, epicsIDFieldReader):
     self.magControl = RS232(epicsID)  #set up for driving the motors
     self.hallProb = RS232(epicsIDFieldReader)  #setup for reading hallprob
     self.xField = 0
     self.busy = False
     self.setup_prob()  #setup the terminator and timeout wait
     self.read_field()
示例#2
0
 def __init__(self, epicsID, epicsIDFieldReader):
     self.magControl = RS232(epicsID)  #set up for driving the motors
     self.hallProb = RS232(epicsIDFieldReader)  #setup for reading hallprob
     self.magMotor = [0.0, 0.0, 0.0, 0.0]
     self.update_position()
     self.xField = 0
     self.busy = False
     self.setup_prob()  #setup the terminator and timeout wait
示例#3
0
 def __init__(self, epicsTemp, epicMagCurrent, epicRasorPressure):
     self.magTemp = RS232(epicsTemp)
     self.currentAmp = RS232(epicMagCurrent)
     self.rasorP = RS232(epicRasorPressure)
     self.magT = 0.0
     self.magCurrent = 0.0
     self.rasorPressure = 0.0
     self.update_position()
示例#4
0
 def __init__(self, epicsIDM1, epicsIDBlade, epicsCurrentAmp):
     self.m1 = RS232(epicsIDM1)  #set up for driving the motors
     self.blade = RS232(epicsIDBlade)
     self.currentAmp = RS232(epicsCurrentAmp)
     self.m1Fpitch = 0.0
     self.bladePosition = [0.0, 0.0]  #xsize and y size
     self.bCurrent = [0.0, 0.0, 0.0, 0.0]  # x ring, x hall, y minus, y plus
     self.update_position()
     self.busy = False
示例#5
0
 def __init__(self, epicsID):
     self.magl = RS232(epicsID)  #set up for driving the motors
     self.magMotor = [0.0, 0.0, 0.0]
     self.update_position()
     self.xField = 0
     self.busy = False
     self.setup_prob()  #setup the terminator and timeout wait
示例#6
0
 def __init__(self, epicsCurrentAmp):
     #set up for driving the motors
     self.currentAmp = RS232(epicsCurrentAmp)
     self.bCurrent = [0.0, 0.0, 0.0, 0.0] # x ring, x hall, y minus, y plus
     self.update_position()
     self.busy = False    
示例#7
0
'''
Created on 16 May 2017

@author: wvx67826
'''
from scipy import arange
from Devices.HallProb import HallProb
from RS232.RS232 import RS232

f = open('cal4bars_slotted2.dat', 'w+')

hProbe = HallProb("BL10J-MO-USER-01:", "BL10I-EA-USER-01:SER4.")
hProbe.setup_prob()
mag1 = RS232("ME01D-EA-EMEC-01:")
sx = RS232("ME01D-MO-CRYO-01:")

for j in arange(9, 15, 1):
    sx.set("X.VAL", j)
    sx.motion_wait("X.RBV")

for i in arange(0, 20, 0.25):
    #mag1.set("Y1.VAL", -i)
    mag1.set("Y2.VAL", i)
    mag1.motion_wait("Y2.RBV")
    hProbe.read_field()
    print i, hProbe.xField
    f.write("%f \t" % i + "%f \n" % hProbe.xField)
for i in arange(20, 0, -0.25):
    #mag1.set("Y1.VAL", -i)
    mag1.set("Y2.VAL", i)
    mag1.motion_wait("Y2.RBV")