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

Add explicit Mover.Reset() method #57

Open
pswift066 opened this issue Nov 7, 2024 · 2 comments
Open

Add explicit Mover.Reset() method #57

pswift066 opened this issue Nov 7, 2024 · 2 comments
Assignees

Comments

@pswift066
Copy link
Collaborator

While this is possible now via a Disable > ReEnable loop, adding Reset explicitly will be more intuitive for new users

@netbymatt
Copy link
Collaborator

After reviewing the enable/disable methods and the way they interact with the state machine there are a few considerations.

  • The enable and disable methods only operate when the mover state machine is in a defined state
  • Should disable be allowed to work from any state which would necessitate some additional cleanup in the state machine to make sure FBs are reset when "the rug is pulled out from under them"
  • After a reset, what state should the mover return to. Trying to maintain the last state it was in before error at first glance is doable, but what happens when reset is mashed several times... it was in RUN, but on the second button mash it was in Enabling... where to go in this situation?
  • Maybe the proper solution is to make disable work at all times... and reset is just an alias of disable. Then both would require a re-enable afterwards explicitly defining states and workflows for these methods.

@netbymatt
Copy link
Collaborator

The reset block is intended to be an immediate call to MC_Reset with execute true and then false. McPower will typically stay on and re-enable the mover, and the state will remain in run.

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

No branches or pull requests

2 participants