Startup
This commit is contained in:
20
script/RF_phase_scan.py
Normal file
20
script/RF_phase_scan.py
Normal file
@@ -0,0 +1,20 @@
|
||||
rsys = "SINSB01-RSYS"
|
||||
bpm = "SINLH02-DBPM210"
|
||||
phase_start = -175.0
|
||||
phase_stop = 180.0
|
||||
phase_step = 5.0
|
||||
|
||||
rf_phase_setpoint = Channel(rsys + ":SET-VSUM-PHASE")
|
||||
rf_phase_readback = Channel(rsys + ":GET-VSUM-PHASE")
|
||||
rf_ampl_readback = Channel(rsys + ":GET-VSUM-AMPLT")
|
||||
x1 = Channel(bpm + ":X1")
|
||||
|
||||
r = lscan(rf_phase_setpoint, [rf_phase_readback, rf_ampl_readback, x1], phase_start, phase_stop, phase_step, latency=0.5)
|
||||
|
||||
plot(r.getReadable(2), xdata = r.getReadable(0), title = "phase scan")
|
||||
|
||||
(amplitude, angular_frequency, phase, ok, maximum) = hfit(r.getReadable(2), xdata = r.getReadable(0))
|
||||
|
||||
caput(rsys + ":SET-ON-CREST-VSUM-PHASE", maximum)
|
||||
|
||||
set_return(r.print())
|
||||
Reference in New Issue
Block a user