Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve mag stage #99

Merged
merged 6 commits into from
Mar 25, 2021
Merged

Improve mag stage #99

merged 6 commits into from
Mar 25, 2021

Conversation

gfabbris
Copy link
Contributor

Rebuilds the magnet staging process to use status objects rather than while True loops.

@gfabbris gfabbris added the maintenance work to do label Mar 24, 2021
@gfabbris gfabbris requested review from prjemian, strempfer and CrI3 March 24, 2021 00:41
@gfabbris gfabbris self-assigned this Mar 24, 2021
@gfabbris
Copy link
Contributor Author

One difficulty in this problem is that in each step we want to wait for certain conditions. For example, in the staging process, we first click on the ramp button, then wait for the supply current to match the magnet current, then turn on the switch heater, then wait for the magnet status to change. Currently this is done in a workaround, using the SetSignal that simply returns a subscription status based on an input device and function (Codacy doesn't like SetSignal). Then using abs_set (with wait=True) we can make the RunEngine wait for each step to complete.

I suspect the "best" way to do this is by converting .ramp_button and .switch_heater into PVPositioner. I will try to do it later, for now we can just leave it as is.

@prjemian
Copy link
Contributor

prjemian commented Mar 24, 2021 via email

@gfabbris gfabbris merged commit a22606f into master Mar 25, 2021
@gfabbris gfabbris deleted the 66-improve_mag_stage branch March 25, 2021 20:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
maintenance work to do
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants