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

close shutter at end of run #6

Open
wants to merge 3 commits into
base: deprecated-master
Choose a base branch
from

Conversation

CJ-Wright
Copy link
Contributor

No description provided.

@CJ-Wright
Copy link
Contributor Author

@DanOlds This needs testing

@danielballan
Copy link

Assigning lambdas to variables is discouraged. Even monkey-patching a proper def ... function like this has bad code smell. It would be clearer to subclass EpicsSignal so that it's clear this has special behavior on stop, and not significantly more work to do.

@CJ-Wright
Copy link
Contributor Author

I was hoping to test this first and then make it prettier, since I'd like to make certain that the fix will work.

@danielballan
Copy link

That's fair. I worry about the next person wondering, "Why is this EpicsSignal doing weird things?" No objections to using this approach for testing.

@CJ-Wright
Copy link
Contributor Author

My bigger problem is that we haven't declared what open and close are for set, so I'm guessing that 1 is closed.

@danielballan
Copy link

I see. Maybe it's worth setting up a caproto IOC that exposes one shutter PV with the enum states "Open" and "Closed" and then does the mapping to 0 or 1 internally.

@DanOlds
Copy link
Contributor

DanOlds commented Mar 7, 2019 via email

@CJ-Wright
Copy link
Contributor Author

It hasn't gone in, this is the PR proposing the fix. It needs to be accepted pulled down to the local machine and tested.

@CJ-Wright
Copy link
Contributor Author

@DanOlds in the .ipython/profile_collection directory run the following commands to get this branch

git remote add CJ-Wright https://github.com/CJ-Wright/profile_collection.git
git fetch CJ-Wright
git checkout auto_close

Then you can run the test of the shutter action.
Once you are done you can use git checkout <name of previous branch> (hint: it is most likely stage_jank) to return to your previously state.

@DanOlds
Copy link
Contributor

DanOlds commented Mar 12, 2019 via email

@CJ-Wright
Copy link
Contributor Author

@DanOlds I think this is ready for review/merge

@CJ-Wright
Copy link
Contributor Author

@DanOlds I think this is ready for review/merge

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants