Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
BCU-Vercors
ID26
id26
Commits
2dff4ab0
Commit
2dff4ab0
authored
Mar 17, 2022
by
bliss administrator
Browse files
fscan.reset() : add mono velocity restore, events clearing, WP reset and a flush
parent
adfb2fea
Changes
1
Hide whitespace changes
Inline
Side-by-side
id26/controllers/fscan_controller.py
View file @
2dff4ab0
...
...
@@ -1157,7 +1157,6 @@ class ID26FScanController:
"_cleanup ..."
)
print
(
"FSCAN ENDING"
)
if
self
.
event_trajectory_started
.
is_set
():
...
...
@@ -1341,11 +1340,19 @@ class ID26FScanController:
)
self
.
pm600
.
stop_trajectory
()
self
.
pm600
.
flush
()
self
.
pm600
.
io_command
(
"WP22222221"
,
self
.
mono
.
channel
)
self
.
energy
.
sync_hard
()
self
.
mono
.
velocity
=
self
.
mono
.
config_velocity
self
.
event_trajectory_started
.
clear
()
self
.
event_runtime_error
.
clear
()
self
.
_last_scan
=
{}
self
.
mono
.
trajectory_prog
.
clear
()
self
.
_reset_id_sync
()
if
self
.
fscan_par
[
'id_linked'
]:
self
.
_reset_id_sync
()
if
len
(
self
.
greenlet_id_set_vel
)
>
0
:
gevent
.
joinall
(
list
(
self
.
greenlet_id_set_vel
.
values
()))
...
...
@@ -1369,17 +1376,19 @@ class ID26FScanController:
print
(
'MOVE BACK GREENLET KILLED: fscan motors have stopped'
)
self
.
mono
.
velocity
=
self
.
mono
.
config_velocity
print
(
"- PM600 position:"
,
self
.
mono
.
position
)
print
(
"- PM600 velocity:"
,
self
.
mono
.
velocity
)
print
(
"- musst_enc_pm.energy() : "
,
self
.
enc_pm
.
energy
())
print
(
"- musst_enc_hdh.energy() : "
,
self
.
enc_hdh
.
energy
())
print
(
'- READY for next fscan'
)
log_debug
(
self
,
"move back greenlet killed"
)
print
(
"- PM600 state :"
,
self
.
mono
.
state
)
print
(
"- energy state:"
,
self
.
energy
.
state
)
print
(
"- PM600 velocity:"
,
self
.
mono
.
velocity
)
print
(
"- PM600 position :"
,
self
.
mono
.
position
)
print
(
"- musst_enc_hdh.angle() : "
,
self
.
enc_hdh
.
angle
())
print
(
"- musst_enc_hdh.energy() : "
,
self
.
enc_hdh
.
energy
())
print
(
'- READY for next fscan'
)
log_debug
(
self
,
"reset done."
...
...
Write
Preview
Supports
Markdown
0%
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!
Cancel
Please
register
or
sign in
to comment