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
47536151
Commit
47536151
authored
Dec 21, 2021
by
bliss administrator
Browse files
ID26OffsetShutterChopper logging
parent
e210199a
Changes
1
Hide whitespace changes
Inline
Side-by-side
id26/controllers/auto_offsets.py
View file @
47536151
from
bliss
import
setup_globals
from
bliss.common.logtools
import
log_warning
from
id26.scripts.beamline_settings
import
ID26Settings
...
...
@@ -14,6 +15,11 @@ class ID26OffsetShutterChopper:
if
self
.
state
()
is
not
'OPEN'
:
print
(
'openning chopper '
,
self
.
chopp
.
name
)
self
.
chopp
.
move
(
1
)
if
i
==
2
:
log_warning
(
self
,
'after 4 open request chopper position is {0} (should be 1, or at least >= 0.2)'
.
format
(
self
.
chopp
.
position
)
)
def
close
(
self
):
...
...
@@ -23,6 +29,11 @@ class ID26OffsetShutterChopper:
if
self
.
state
()
is
not
'CLOSED'
:
print
(
'closing chopper '
,
self
.
chopp
.
name
)
self
.
chopp
.
move
(
0
)
if
i
==
2
:
log_warning
(
self
,
'after 4 close request chopper position is {0} (should be 0, or at least < 0.2)'
.
format
(
self
.
chopp
.
position
)
)
def
state
(
self
):
return
'CLOSED'
if
self
.
chopp
.
position
<
0.2
else
'OPEN'
...
...
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