hw_pid: delete initial set_direction #703
Merged
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.
Delete initial hwp rotation direction setting of hwp_pid agent to resolve the hwp rotation direction ambiguities.
Description
The "direction" in the hwp_pid memory register doesn't reflect the actual action of pid agent until hwp_pid.tune_freq is called. The default setting of "direction" on the agent startup lead to the ambiguity of hwp rotation direction. This PR delete the default setting.
As long as we use
hwp_supervisor.pid_to_freq
, we can avoid this issue.socs/socs/agents/hwp_supervisor/agent.py
Lines 739 to 750 in 4902d3b
However, if
hwp_supervisor.pid_to_freq
fails in the middle of its command sequence, we may still have a potential ambiguity in rotation direction, so maybe we should make it more robust?Motivation and Context
https://github.com/simonsobs/chwp-discussions/discussions/24
How Has This Been Tested?
This has been tested by daq-dev for satp3. Confirmed that the restart of hwp_pid agent doen't lead to the direction ambiguity in both directions.
Types of changes
Checklist: