Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
E
experiment-control
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
whuie2
experiment-control
Commits
631ea875
Commit
631ea875
authored
3 years ago
by
Yb Tweezer
Browse files
Options
Downloads
Patches
Plain Diff
switch to TimeBase driver and play with CMOT power
parent
db017a1c
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
daily.py
+142
-145
142 additions, 145 deletions
daily.py
with
142 additions
and
145 deletions
daily.py
+
142
−
145
View file @
631ea875
...
@@ -76,8 +76,8 @@ shim_ud = +0.580 # up/down shim; 174: 0.4
...
@@ -76,8 +76,8 @@ shim_ud = +0.580 # up/down shim; 174: 0.4
# CMOT AOM settings
# CMOT AOM settings
f_freqpow
=
90.0
# start of frequency ramp; MHz
f_freqpow
=
90.0
# start of frequency ramp; MHz
p_freqpow_beg
=
29.0
# start of power ramp; dBm
p_freqpow_beg
=
29.0
# start of power ramp; dBm
p_freqpow_end
=
0
.0
# end of ramp; dBm
p_freqpow_end
=
-
11
.0
# end of ramp; dBm
p_image
=
2
3
.0
# power for imaging; dBm
p_image
=
2
7
.0
# power for imaging; dBm
p_image_cmot
=
20.0
# power for imaging with CMOT beams; dBm
p_image_cmot
=
20.0
# power for imaging with CMOT beams; dBm
# PARAMETERS
# PARAMETERS
...
@@ -96,18 +96,27 @@ T_COMP = t0 + tau_comp + np.linspace(0.0, tau_comp_dur, 101) # compression ramp
...
@@ -96,18 +96,27 @@ T_COMP = t0 + tau_comp + np.linspace(0.0, tau_comp_dur, 101) # compression ramp
B_COMP
=
np
.
linspace
(
B_green
,
B_green
*
1.8
,
T_COMP
.
shape
[
0
])
# compression ramp coil vals; s
B_COMP
=
np
.
linspace
(
B_green
,
B_green
*
1.8
,
T_COMP
.
shape
[
0
])
# compression ramp coil vals; s
bits_Bset
=
int
(
20
)
# number of bits to send in a servo setting
bits_Bset
=
int
(
20
)
# number of bits to send in a servo setting
bits_DACset
=
int
(
4
)
# number of bits to send in a DAC-mode setting
bits_DACset
=
int
(
4
)
# number of bits to send in a DAC-mode setting
det_block
=
10.0
# shift the RF on the MOT beams to decouple the fiber; MHz
f_image0
=
aom_fiber_optim
+
det_image0
# (nominal) CMOT final AOM frequency; MHz
f_image0
=
aom_fiber_optim
+
det_image0
# (nominal) CMOT final AOM frequency; MHz
mogramp_N
=
1000
# number of steps in the frequency/power ramp
ramp_N
=
1000
# number of steps in the frequency/power ramp
dailies_config
=
dict
(
dailies_config
=
dict
(
probe_image
=
probe_image
,
probe_image
=
probe_image
,
CMOT_freq
=
f_image0
,
CMOT_freq
=
f_image0
,
CMOT_pow
=
p_freqpow_end
,
CMOT_pow
=
p_freqpow_end
,
)
)
def
make_sequences
(
meas_type
:
DailyMeasType
,
name
:
str
,
def
make_sequence
(
tau_tof
:
float
,
det_image
:
float
,
nu_freqpow
:
float
)
\
meas_type
:
DailyMeasType
,
->
(
SuperSequence
,
MOGTable
):
name
:
str
,
tau_tof
:
float
,
det_image
:
float
,
nu_freqpow
:
float
,
)
->
SuperSequence
:
# ramp_N is the number of steps, not points, so use ramp_N + 1 for number of points
RAMP_T
=
t0
+
np
.
linspace
(
tau_freqpow
,
tau_freqpow
+
tau_freqpow_dur
,
ramp_N
+
1
)
RAMP_F
=
np
.
linspace
(
f_freqpow
,
f_freqpow
+
nu_freqpow
,
ramp_N
+
1
)
RAMP_P
=
np
.
linspace
(
p_freqpow_beg
,
p_freqpow_end
,
ramp_N
+
1
)
if
meas_type
in
{
if
meas_type
in
{
DailyMeasType
.
TOF
,
DailyMeasType
.
TOF
,
DailyMeasType
.
DET
,
DailyMeasType
.
DET
,
...
@@ -135,16 +144,32 @@ def make_sequences(meas_type: DailyMeasType, name: str,
...
@@ -135,16 +144,32 @@ def make_sequences(meas_type: DailyMeasType, name: str,
).
to_sequence
().
with_color
(
"
C0
"
),
).
to_sequence
().
with_color
(
"
C0
"
),
"
Load green MOT
"
:
(
Sequence
()
"
Load green MOT
"
:
(
Sequence
()
+
Sequence
.
digital_hilo
(
+
Sequence
([
# turn on AOM to the right frequency/power
*
C
.
mot3_green_aom
,
Event
.
digital1
(
**
C
.
mot3_green_aom
,
s
=
0
)
# LOW == ON
t0
-
5e-3
,
# the mogtable is triggered on a falling edge
@
(
t0
),
t0
Event
.
digital1
(
**
C
.
mot3_green_sh
,
s
=
1
)
)
@
(
t0
-
3.8e-3
),
# shutter delay
+
Sequence
([
Event
.
analog
(
Event
.
digital1
(
**
C
.
mot3_green_aom_fm
,
**
C
.
mot3_green_sh
,
s
=
1
)
s
=
MOT3_GREEN_AOM_FM
(
RAMP_F
[
0
])
@
(
t0
-
5e-3
)
# open shutter ahead of AOM
)
@
(
t0
),
Event
.
analog
(
**
C
.
mot3_green_aom_am
,
s
=
MOT3_GREEN_AOM_AM
(
RAMP_P
[
0
])
)
@
(
t0
),
])
])
+
Sequence
(
[
# do the frequency ramp
Event
.
analog
(
**
C
.
mot3_green_aom_fm
,
s
=
MOT3_GREEN_AOM_FM
(
f
))
@
(
t
)
for
t
,
f
in
zip
(
RAMP_T
,
RAMP_F
)
]
+
[
# do the power ramp
Event
.
analog
(
**
C
.
mot3_green_aom_am
,
s
=
MOT3_GREEN_AOM_AM
(
p
))
@
(
t
)
for
t
,
p
in
zip
(
RAMP_T
,
RAMP_P
)
]
)
+
Sequence
.
serial_bits_c
(
+
Sequence
.
serial_bits_c
(
C
.
mot3_coils_sig
,
C
.
mot3_coils_sig
,
t0
,
t0
,
...
@@ -184,6 +209,13 @@ def make_sequences(meas_type: DailyMeasType, name: str,
...
@@ -184,6 +209,13 @@ def make_sequences(meas_type: DailyMeasType, name: str,
])).
with_color
(
"
C1
"
),
])).
with_color
(
"
C1
"
),
"
Free space
"
:
(
Sequence
()
"
Free space
"
:
(
Sequence
()
+
Sequence
([
# detune and depower the MOT beams for TOF after the CMOT hold
Event
.
analog
(
**
C
.
mot3_green_aom_fm
,
s
=
MOT3_GREEN_AOM_FM
(
89.0
)
)
@
(
t0
+
tau_ncool
),
Event
.
analog
(
**
C
.
mot3_green_aom_am
,
s
=-
1
)
# s=-1 guarantees minimum power
@
(
t0
+
tau_ncool
)
])
+
Sequence
.
serial_bits_c
(
+
Sequence
.
serial_bits_c
(
C
.
mot3_coils_sig
,
C
.
mot3_coils_sig
,
t0
+
tau_ncool
,
t0
+
tau_ncool
,
...
@@ -216,6 +248,39 @@ def make_sequences(meas_type: DailyMeasType, name: str,
...
@@ -216,6 +248,39 @@ def make_sequences(meas_type: DailyMeasType, name: str,
)
)
)
if
probe_image
else
Sequence
()
)
if
probe_image
else
Sequence
()
)
)
+
(
(
Sequence
.
digital_pulse
(
*
C
.
mot3_green_aom
,
t0
+
tau_ncool
+
tau_tof
,
tau_image
,
invert
=
True
)
+
Sequence
.
digital_pulse
(
*
C
.
mot3_green_sh
,
0.0
,
t0
+
tau_all
)
+
Sequence
([
Event
.
analog
(
**
C
.
mot3_green_aom_fm
,
s
=
MOT3_GREEN_AOM_FM
(
aom_fiber_optim
+
det_image
)
)
@
(
t0
+
tau_ncool
+
tau_tof
),
Event
.
analog
(
**
C
.
mot3_green_aom_am
,
s
=
MOT3_GREEN_AOM_AM
(
p_image_cmot
)
)
@
(
t0
+
tau_ncool
+
tau_tof
),
])
+
Sequence
([
Event
.
analog
(
**
C
.
mot3_green_aom_fm
,
s
=
MOT3_GREEN_AOM_FM
(
89.0
)
)
@
(
t0
+
tau_ncool
+
tau_tof
+
tau_image
),
Event
.
analog
(
**
C
.
mot3_green_aom_am
,
s
=-
1
)
# s=-1 guarantees minimum power
@
(
t0
+
tau_ncool
+
tau_tof
+
tau_image
)
])
)
if
not
probe_image
else
Sequence
()
)
+
(
+
(
Sequence
.
digital_pulse
(
Sequence
.
digital_pulse
(
*
C
.
flir_trig
,
*
C
.
flir_trig
,
...
@@ -357,27 +422,7 @@ def make_sequences(meas_type: DailyMeasType, name: str,
...
@@ -357,27 +422,7 @@ def make_sequences(meas_type: DailyMeasType, name: str,
)
)
sseq
[
"
Sequence
"
]
=
Sequence
.
digital_hilo
(
*
C
.
dummy
,
0.0
,
sseq
.
max_time
()
+
10e-3
).
with_color
(
"
0.25
"
)
sseq
[
"
Sequence
"
]
=
Sequence
.
digital_hilo
(
*
C
.
dummy
,
0.0
,
sseq
.
max_time
()
+
10e-3
).
with_color
(
"
0.25
"
)
# mogramp_N is the number of steps, not points, so use mogramp_N + 1 for number of points
return
sseq
MOGRAMP_T
=
np
.
linspace
(
tau_freqpow
,
tau_freqpow
+
tau_freqpow_dur
,
mogramp_N
+
1
)
MOGRAMP_F
=
np
.
linspace
(
f_freqpow
,
f_freqpow
+
nu_freqpow
,
mogramp_N
+
1
)
MOGRAMP_P
=
np
.
linspace
(
p_freqpow_beg
,
p_freqpow_end
,
mogramp_N
+
1
)
tab
=
MOGTable
()
# make sure the frequency/power is right at t0
tab
<<
MOGEvent
(
frequency
=
MOGRAMP_F
[
0
],
power
=
MOGRAMP_P
[
0
])
@
(
0.0
)
for
t
,
f
,
p
in
zip
(
MOGRAMP_T
,
MOGRAMP_F
,
MOGRAMP_P
):
tab
<<
MOGEvent
(
frequency
=
f
,
power
=
p
)
@
t
# detune and depower the MOT beams for TOF after the CMOT hold
tab
<<
MOGEvent
(
frequency
=
MOGRAMP_F
[
-
1
]
+
det_block
,
power
=-
50.0
)
\
@
(
tau_ncool
+
1.7e-3
)
# unknown source of timing errors
if
not
probe_image
:
(
tab
<<
MOGEvent
(
frequency
=
aom_fiber_optim
+
det_image
,
power
=
p_image_cmot
)
@
(
tau_ncool
+
tau_tof
+
1.7e-3
)
# unknown source of timing errors
<<
MOGEvent
(
frequency
=
aom_fiber_optim
+
det_image
+
det_block
,
power
=-
50.0
)
@
(
tau_ncool
+
tau_tof
+
tau_image
+
1.7e-3
)
# unknown source of timing errors
)
return
sseq
,
tab
## SCRIPT CONTROLLER
## SCRIPT CONTROLLER
class
DailyMeasurement
(
Controller
):
class
DailyMeasurement
(
Controller
):
...
@@ -390,8 +435,6 @@ class DailyMeasurement(Controller):
...
@@ -390,8 +435,6 @@ class DailyMeasurement(Controller):
# self.cam = FLIR.connect()
# self.cam = FLIR.connect()
# self.cam.configure_capture(**flir_config).configure_trigger()
# self.cam.configure_capture(**flir_config).configure_trigger()
self
.
mog
=
MOGRF
.
connect
()
self
.
tb
=
TIMEBASE
.
connect
()
self
.
tb
=
TIMEBASE
.
connect
()
if
probe_image
:
if
probe_image
:
self
.
tb
.
set_frequency
(
aom_fiber_optim
+
det_image0
).
set_amplitude
(
p_image
)
self
.
tb
.
set_frequency
(
aom_fiber_optim
+
det_image0
).
set_amplitude
(
p_image
)
...
@@ -408,18 +451,17 @@ class DailyMeasurement(Controller):
...
@@ -408,18 +451,17 @@ class DailyMeasurement(Controller):
f
"
_
{
rep
}
"
f
"
_
{
rep
}
"
for
rep
,
tau_tof
in
product
(
range
(
reps
),
TAU_TOF
)
for
rep
,
tau_tof
in
product
(
range
(
reps
),
TAU_TOF
)
]
]
self
.
ssequences
,
self
.
mogtables
\
self
.
ssequences
=
[
=
zip
(
*
[
make_sequence
(
make_sequences
(
self
.
mode
,
self
.
mode
,
f
"
tau_tof=
{
tau_tof
:
.
5
f
}
"
f
"
tau_tof=
{
tau_tof
:
.
5
f
}
"
f
"
_det-image=
{
det_image0
:
+
.
5
f
}
"
f
"
_det-image=
{
det_image0
:
+
.
5
f
}
"
f
"
_nu-freqpow=
{
nu_freqpow0
:
+
.
5
f
}
"
,
f
"
_nu-freqpow=
{
nu_freqpow0
:
+
.
5
f
}
"
,
tau_tof
,
tau_tof
,
det_image0
,
det_image0
,
nu_freqpow0
,
nu_freqpow0
,
)
for
tau_tof
in
TAU_TOF
)
for
tau_tof
in
TAU_TOF
]
])
self
.
sequences
=
[
sseq
.
to_sequence
()
for
sseq
in
self
.
ssequences
]
self
.
sequences
=
[
sseq
.
to_sequence
()
for
sseq
in
self
.
ssequences
]
elif
self
.
mode
==
DailyMeasType
.
DET
:
elif
self
.
mode
==
DailyMeasType
.
DET
:
...
@@ -431,18 +473,17 @@ class DailyMeasurement(Controller):
...
@@ -431,18 +473,17 @@ class DailyMeasurement(Controller):
f
"
_
{
rep
}
"
f
"
_
{
rep
}
"
for
rep
,
det_image
in
product
(
range
(
reps
),
DET_IMAGE
)
for
rep
,
det_image
in
product
(
range
(
reps
),
DET_IMAGE
)
]
]
self
.
ssequences
,
self
.
mogtables
\
self
.
ssequences
=
[
=
zip
(
*
[
make_sequence
(
make_sequences
(
self
.
mode
,
self
.
mode
,
f
"
tau-tof=
{
tau_tof0
:
.
5
f
}
"
f
"
tau-tof=
{
tau_tof0
:
.
5
f
}
"
f
"
_det-image=
{
det_image
:
+
.
5
f
}
"
f
"
_det-image=
{
det_image
:
+
.
5
f
}
"
f
"
_nu-freqpow=
{
nu_freqpow0
:
+
.
5
f
}
"
,
f
"
_nu-freqpow=
{
nu_freqpow0
:
+
.
5
f
}
"
,
tau_tof0
,
tau_tof0
,
det_image
,
det_image
,
nu_freqpow0
,
nu_freqpow0
,
)
for
det_image
in
DET_IMAGE
)
for
det_image
in
DET_IMAGE
]
])
self
.
sequences
=
[
sseq
.
to_sequence
()
for
sseq
in
self
.
ssequences
]
self
.
sequences
=
[
sseq
.
to_sequence
()
for
sseq
in
self
.
ssequences
]
elif
self
.
mode
==
DailyMeasType
.
CMOT_DET
:
elif
self
.
mode
==
DailyMeasType
.
CMOT_DET
:
...
@@ -454,18 +495,17 @@ class DailyMeasurement(Controller):
...
@@ -454,18 +495,17 @@ class DailyMeasurement(Controller):
f
"
_
{
rep
}
"
f
"
_
{
rep
}
"
for
rep
,
nu_freqpow
in
product
(
range
(
reps
),
NU_FREQPOW
)
for
rep
,
nu_freqpow
in
product
(
range
(
reps
),
NU_FREQPOW
)
]
]
self
.
ssequences
,
self
.
mogtables
\
self
.
ssequences
=
[
=
zip
(
*
[
make_sequence
(
make_sequences
(
self
.
mode
,
self
.
mode
,
f
"
tau-tof=
{
tau_tof0
:
.
5
f
}
"
f
"
tau-tof=
{
tau_tof0
:
.
5
f
}
"
f
"
_det-image=
{
det_image0
:
+
.
5
f
}
"
f
"
_det-image=
{
det_image0
:
+
.
5
f
}
"
f
"
_nu-freqpow=
{
nu_freqpow
:
+
.
5
f
}
"
,
f
"
_nu-freqpow=
{
nu_freqpow
:
+
.
5
f
}
"
,
tau_tof0
,
tau_tof0
,
det_image0
,
det_image0
,
nu_freqpow
,
nu_freqpow
,
)
for
nu_freqpow
in
NU_FREQPOW
)
for
nu_freqpow
in
NU_FREQPOW
]
])
self
.
sequences
=
[
sseq
.
to_sequence
()
for
sseq
in
self
.
ssequences
]
self
.
sequences
=
[
sseq
.
to_sequence
()
for
sseq
in
self
.
ssequences
]
elif
self
.
mode
==
DailyMeasType
.
BMOT_NUM
:
elif
self
.
mode
==
DailyMeasType
.
BMOT_NUM
:
...
@@ -476,17 +516,16 @@ class DailyMeasurement(Controller):
...
@@ -476,17 +516,16 @@ class DailyMeasurement(Controller):
f
"
_
{
rep
}
"
f
"
_
{
rep
}
"
for
rep
in
range
(
reps
)
for
rep
in
range
(
reps
)
]
]
self
.
ssequences
,
self
.
mogtables
\
self
.
ssequences
=
[
=
zip
(
*
[
make_sequence
(
make_sequences
(
self
.
mode
,
self
.
mode
,
f
"
tau-tof=
{
tau_tof0
:
.
5
f
}
"
f
"
tau-tof=
{
tau_tof0
:
.
5
f
}
"
f
"
_det-image=
{
det_image0
:
+
.
5
f
}
"
,
f
"
_det-image=
{
det_image0
:
+
.
5
f
}
"
,
tau_tof0
,
tau_tof0
,
det_image0
,
det_image0
,
nu_freqpow0
nu_freqpow0
)
)
]
])
self
.
sequences
=
[
sseq
.
to_sequence
()
for
sseq
in
self
.
ssequences
]
self
.
sequences
=
[
sseq
.
to_sequence
()
for
sseq
in
self
.
ssequences
]
elif
self
.
mode
==
DailyMeasType
.
BMOT_DET
:
elif
self
.
mode
==
DailyMeasType
.
BMOT_DET
:
...
@@ -497,17 +536,16 @@ class DailyMeasurement(Controller):
...
@@ -497,17 +536,16 @@ class DailyMeasurement(Controller):
f
"
_
{
rep
}
"
f
"
_
{
rep
}
"
for
rep
,
det_image
in
product
(
range
(
reps
),
DET_IMAGE
)
for
rep
,
det_image
in
product
(
range
(
reps
),
DET_IMAGE
)
]
]
self
.
ssequences
,
self
.
mogtables
\
self
.
ssequences
=
[
=
zip
(
*
[
make_sequence
(
make_sequences
(
self
.
mode
,
self
.
mode
,
f
"
tau-tof=
{
tau_tof0
:
.
5
f
}
"
f
"
tau-tof=
{
tau_tof0
:
.
5
f
}
"
f
"
_det-image=
{
det_image
:
+
.
5
f
}
"
,
f
"
_det-image=
{
det_image
:
+
.
5
f
}
"
,
tau_tof0
,
tau_tof0
,
det_image
,
det_image
,
nu_freqpow0
,
nu_freqpow0
,
)
for
det_image
in
DET_IMAGE
)
for
det_image
in
DET_IMAGE
]
])
self
.
sequences
=
[
sseq
.
to_sequence
()
for
sseq
in
self
.
ssequences
]
self
.
sequences
=
[
sseq
.
to_sequence
()
for
sseq
in
self
.
ssequences
]
else
:
else
:
...
@@ -515,18 +553,10 @@ class DailyMeasurement(Controller):
...
@@ -515,18 +553,10 @@ class DailyMeasurement(Controller):
def
run_sequence
(
self
,
*
args
):
def
run_sequence
(
self
,
*
args
):
for
rep
in
range
(
reps
):
for
rep
in
range
(
reps
):
for
k
,
(
seq
,
tab
)
in
enumerate
(
zip
(
self
.
sequences
,
self
.
mogtables
)
):
for
k
,
seq
in
enumerate
(
self
.
sequences
):
if
self
.
mode
in
{
DailyMeasType
.
DET
,
DailyMeasType
.
BMOT_DET
}:
if
self
.
mode
in
{
DailyMeasType
.
DET
,
DailyMeasType
.
BMOT_DET
}:
self
.
tb
.
set_frequency
(
aom_fiber_optim
+
DET_IMAGE
[
k
])
self
.
tb
.
set_frequency
(
aom_fiber_optim
+
DET_IMAGE
[
k
])
(
self
.
mog
.
set_frequency
(
1
,
90.0
).
set_power
(
1
,
-
50.0
)
# make sure CMOT AOM is off
.
set_mode
(
1
,
"
TSB
"
)
.
table_load
(
1
,
tab
)
.
table_arm
(
1
)
.
set_table_rearm
(
1
,
True
)
)
self
.
comp
.
enqueue
(
seq
).
run
().
clear
()
self
.
comp
.
enqueue
(
seq
).
run
().
clear
()
self
.
mog
.
table_stop
(
1
).
table_clear
(
1
)
if
take_background
:
if
take_background
:
time
.
sleep
(
0.5
)
time
.
sleep
(
0.5
)
...
@@ -546,17 +576,6 @@ class DailyMeasurement(Controller):
...
@@ -546,17 +576,6 @@ class DailyMeasurement(Controller):
self
.
comp
.
clear
().
set_defaults
().
disconnect
()
self
.
comp
.
clear
().
set_defaults
().
disconnect
()
(
self
.
mog
.
table_stop
(
1
)
.
table_clear
(
1
)
.
set_frequency
(
1
,
90.0
).
set_power
(
1
,
29.04
)
.
set_frequency
(
3
,
aom_fiber_optim
+
det_image0
).
set_power
(
3
,
p_image
)
.
set_frequency
(
4
,
aom_fiber_optim
+
det_image0
).
set_power
(
4
,
p_image
)
.
set_mode
(
1
,
"
NSB
"
)
.
set_output
(
1
,
True
)
.
disconnect
()
)
# def run_camera(self, *args):
# def run_camera(self, *args):
# self.frames = self.cam.acquire_frames(
# self.frames = self.cam.acquire_frames(
# num_frames=(
# num_frames=(
...
@@ -604,21 +623,6 @@ class DailyMeasurement(Controller):
...
@@ -604,21 +623,6 @@ class DailyMeasurement(Controller):
# print(f"couldn't disconnect from Flir camera"
# print(f"couldn't disconnect from Flir camera"
# f"\n{type(err).__name__}: {err}")
# f"\n{type(err).__name__}: {err}")
try
:
(
self
.
mog
.
table_stop
(
1
)
.
table_clear
(
1
)
.
set_frequency
(
1
,
90.0
).
set_power
(
1
,
29.04
)
.
set_frequency
(
3
,
aom_fiber_optim
+
det_image0
).
set_power
(
3
,
p_image
)
.
set_frequency
(
4
,
aom_fiber_optim
+
det_image0
).
set_power
(
4
,
p_image
)
.
set_mode
(
1
,
"
NSB
"
)
.
set_output
(
1
,
True
)
.
disconnect
()
)
except
BaseException
as
err
:
print
(
f
"
couldn
'
t reset MOGRF
"
f
"
\n
{
type
(
err
).
__name__
}
:
{
err
}
"
)
def
postcmd
(
self
,
*
args
):
def
postcmd
(
self
,
*
args
):
pass
pass
# names = list()
# names = list()
...
@@ -689,27 +693,20 @@ class DailyMeasurement(Controller):
...
@@ -689,27 +693,20 @@ class DailyMeasurement(Controller):
sys
.
exit
(
0
)
sys
.
exit
(
0
)
self
.
mode
=
run_modes
[
args
[
0
]]
self
.
mode
=
run_modes
[
args
[
0
]]
if
self
.
mode
==
DailyMeasType
.
TOF
:
if
self
.
mode
==
DailyMeasType
.
TOF
:
sseq
,
tab
=
make_sequence
s
(
self
.
mode
,
""
,
TAU_TOF
.
max
(),
det_image0
,
nu_freqpow0
)
sseq
=
make_sequence
(
self
.
mode
,
""
,
TAU_TOF
.
max
(),
det_image0
,
nu_freqpow0
)
elif
self
.
mode
==
DailyMeasType
.
DET
:
elif
self
.
mode
==
DailyMeasType
.
DET
:
sseq
,
tab
=
make_sequence
s
(
self
.
mode
,
""
,
tau_tof0
,
DET_IMAGE
.
max
(),
nu_freqpow0
)
sseq
=
make_sequence
(
self
.
mode
,
""
,
tau_tof0
,
DET_IMAGE
.
max
(),
nu_freqpow0
)
elif
self
.
mode
==
DailyMeasType
.
CMOT_DET
:
elif
self
.
mode
==
DailyMeasType
.
CMOT_DET
:
sseq
,
tab
=
make_sequence
s
(
self
.
mode
,
""
,
tau_tof0
,
det_image0
,
NU_FREQPOW
.
max
())
sseq
=
make_sequence
(
self
.
mode
,
""
,
tau_tof0
,
det_image0
,
NU_FREQPOW
.
max
())
elif
self
.
mode
==
DailyMeasType
.
BMOT_NUM
:
elif
self
.
mode
==
DailyMeasType
.
BMOT_NUM
:
sseq
,
tab
=
make_sequence
s
(
self
.
mode
,
""
,
tau_tof0
,
det_image0
,
nu_freqpow0
)
sseq
=
make_sequence
(
self
.
mode
,
""
,
tau_tof0
,
det_image0
,
nu_freqpow0
)
elif
self
.
mode
==
DailyMeasType
.
BMOT_DET
:
elif
self
.
mode
==
DailyMeasType
.
BMOT_DET
:
sseq
,
tab
=
make_sequence
s
(
self
.
mode
,
""
,
tau_tof0
,
DET_IMAGE
.
max
(),
nu_freqpow0
)
sseq
=
make_sequence
(
self
.
mode
,
""
,
tau_tof0
,
DET_IMAGE
.
max
(),
nu_freqpow0
)
try
:
try
:
tmin
,
tmax
=
float
(
args
[
1
]),
float
(
args
[
2
])
tmin
,
tmax
=
float
(
args
[
1
]),
float
(
args
[
2
])
except
IndexError
:
except
IndexError
:
tmin
,
tmax
=
sseq
.
min_time
(),
sseq
.
max_time
()
tmin
,
tmax
=
sseq
.
min_time
(),
sseq
.
max_time
()
sseq
.
draw_detailed
(
sseq
.
draw_detailed
().
set_xlim
(
tmin
,
tmax
).
show
()
mogtables
=
[
(
tab
.
with_color
(
"
C6
"
),
dict
(
name
=
"
Green MOT AOM
"
,
offset
=
t0
)
),
]
if
self
.
mode
not
in
{
DailyMeasType
.
BMOT_NUM
,
DailyMeasType
.
BMOT_DET
,
}
else
list
()
).
set_xlim
(
tmin
,
tmax
).
show
()
sys
.
exit
(
0
)
sys
.
exit
(
0
)
if
__name__
==
"
__main__
"
:
if
__name__
==
"
__main__
"
:
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment