Repository navigation
Add the PDF fast shutter (fs) to the profile - #7
Merged
Anthony Sligar (sligara7) merged 1 commit intoOct 23, 2026
Merged
Anthony Sligar (sligara7) merged 1 commit into
Anthony Sligar (sligara7) merged 1 commit into
Conversation
FastShutter drives the inverted Cmd/Sts enum records (OFF opens, ON closes); mv(fs, 1)/'Open' and mv(fs, 0)/'Close' work as in pdf-profile-collection 12-optics, and a move waits for the Sts readback. Assisted-by: copilot:claude-opus-5-5
There was a problem hiding this comment.
🔵 Needs a closer look
Inverted hardware shutter control has only mock validation and needs beamline-owner review before approval.
No open issues 🎉
What changed in this PR
Adds the PDF fast shutter to the collection profile, exposing fs for existing plans with inverted hardware command mapping.
Changes:
- Implements
FastShutterwith numeric/string move targets, readable state, readback confirmation, and settling delay. - Registers
fswith the beamline PV prefix. - Adds mock tests for command mapping, readback timeout, invalid values, and profile startup.
| File | Description |
|---|---|
tests/test_utils.py |
Checks that fs connects during mock profile startup. |
tests/test_shutter.py |
Tests inverted commands, state readings, timeout, and value rejection. |
src/pdftools/shutter.py |
Implements the shutter device and move completion behavior. |
src/pdftools/profiles/collection.py |
Instantiates fs in the collection profile. |
Review effort: Balanced
Anthony Sligar (sligara7)
merged commit Oct 23, 2026
dd55477
into
NSLS2:pdf-profile-conversion
4 checks passed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds
pdftools.shutter.FastShutterandfs(XF:28ID1B-OP{PSh:1-Det:2}) to the profile, ported from pdf-profile-collection12-optics.py.Cmd/Stsare OFF/ON enum records and the shutter is inverted: OFF opens, ON closes (records read withcaget -d DBR_CTRL_ENUM, 2026-10-23).mv(fs, 1)/'Open'opens andmv(fs, 0)/'Close'closes, as the existing plans call it. A move finishes whenStsmatches, then waitssettle_time(0.1 s, as before).fs.statereadsOpen/Close.Verified: mock tests only (inverted mapping, readback wait and timeout, rejected values; profile boots in mock mode with
fs). Not run on the beamline.