Startup
This commit is contained in:
12
script/example1_dv.py
Normal file
12
script/example1_dv.py
Normal file
@@ -0,0 +1,12 @@
|
||||
knob = Channel("SARUN20-MCRX080:I-SET")
|
||||
sensor1 = Channel("SINEG01-DICT215:B1_CHARGE")
|
||||
sensor2 = Channel("S10DI01-DICT025:B1_CHARGE")
|
||||
|
||||
start = -1.0
|
||||
stop = 1.0
|
||||
nstep = 10
|
||||
lat = 0.5
|
||||
|
||||
r = lscan(knob, (sensor1, sensor2), start, stop, nstep, lat)
|
||||
|
||||
plot(r.getReadable(0), name = 'plotname', xdata = r.getReadable(1))
|
||||
11
script/example2_dv.py
Normal file
11
script/example2_dv.py
Normal file
@@ -0,0 +1,11 @@
|
||||
knob = Channel("SARUN20-MCRX080:I-SET")
|
||||
sensor1 = Channel("SINEG01-DICT215:B1_CHARGE")
|
||||
sensor2 = Channel("S10DI01-DICT025:B1_CHARGE")
|
||||
|
||||
start = -0.5
|
||||
stop = 0.5
|
||||
nstep = 10
|
||||
lat = 0.5
|
||||
|
||||
av = create_averager(sensor1, 10, 0.1)
|
||||
lscan(knob, (av, sensor2), start, stop, nstep, lat)
|
||||
4
script/example3_dv.py
Normal file
4
script/example3_dv.py
Normal file
@@ -0,0 +1,4 @@
|
||||
data = tscan(Channel('SINEG01-DICT215:B1_CHARGE'), 100, 0.1)
|
||||
samples = data.getReadable(0)
|
||||
print "mean=", mean(samples)
|
||||
print "stdev=", stdev (samples)
|
||||
@@ -1,12 +0,0 @@
|
||||
knob = Channel("SARUN20-MCRX080:I-SET")
|
||||
sensor1 = Channel("SINEG01-DICT210:B1_CHARGE")
|
||||
sensor2 = Channel("SINEG01-DICT215:B1_CHARGE")
|
||||
|
||||
start = -0.6
|
||||
stop = -0.4
|
||||
nstep = 10
|
||||
lat = 0.5
|
||||
|
||||
r = lscan(knob, (sensor1, sensor2), start, stop, nstep, lat)
|
||||
|
||||
#plot(r.getReadable(0), r.getReadable(1), xdata = r.getPositions(0))
|
||||
14
script/test/bs2.py
Normal file
14
script/test/bs2.py
Normal file
@@ -0,0 +1,14 @@
|
||||
st1 = Stream("st1", dispatcher)
|
||||
add_device(st1, force = True)
|
||||
st1.addScalar("mcpu", "SINDI01-RLLE-STA:MASTER-CPUTIMER", 10, 0)
|
||||
st1.addScalar("scpu", "SINDI01-RLLE-STA:SLAVE1-CPUTIMER", 10, 0)
|
||||
#st1.addWaveform("phase", "SINXB01-RWVG100-DCP10:FOR-PHASE", 10, 0, 2048)
|
||||
#st1.addWaveform("amplt", "SINXB01-RWVG100-DCP10:FOR-AMPLT", 10, 0, 2048)
|
||||
st1.initialize()
|
||||
st1.start()
|
||||
try:
|
||||
#bscan (st1, 10, title="bscan")
|
||||
tscan (st1.getReadables(), 10, 1, title="tscan")
|
||||
x = st1.take()
|
||||
finally:
|
||||
st1.close()
|
||||
Reference in New Issue
Block a user