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.
This PR adjusts the way the HAL sets the priorities in the NVIC so that it is compliant to its use w/ an RTOS.
This PR is linked w/ this issue.
So why this PR?
In an attempt to solve the fatal error happening in the above issue I found out that the priorities of some IRQ handlers used in some devices of the DC motor control of the
mc4plus
violates the original design of the HAL. In particular, they change the priority grouping of the NVIC and use an invalid priority which conflicts w/ what is use by the RTOS.In here is a clarification comment I have added to the code of HAL:
Now, I believe that this correction is required.
I also hope that it can solve the sporadic fatal error for reason which I wrote in here.
There is an associated PR for the binaries in here.
The tests done on a dedicated setup have shown that the mc4plus can effectively move a motor w/ yarprobotinterface, so we can safely merge both PRs for use in the robots.