"Fix critical shutdown bug in spintend ubox" #766
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.
In 6.02 there was #ifdef HW_SHUTDOWN_HOLD_ON in shutdown.c. In hw_ubox_100_core.h we do not define HW_SHUTDOWN_HOLD_ON so none of that shutdown code is included.
In 6.05 this was changed to split up sections in shutdown.c for HW_SHUTDOWN_HOLD_ON and then an else statement for latching switches (to support COMM_SHUTDOWN I assume).
Therefore in 6.05, the ubox still doesn’t have HW_SHUTDOWN_HOLD_ON defined, but since there’s an else statement in shutdown.c it will now include that code which completely fucks up the ubox implementation.
I have resolved this by Including a #ifdef HW_SHUTDOWN_CUSTOM in shutdown.c and then refactoring a few functions in hw_ubox_100_core.c so they are compatible with how shutdown_init() and do_shutdown() are called now in the rest of the code to support COMM_SHUTDOWN.