cpu/msp430: implement power management #20613
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.
Contribution description
This implements power management for the MSP430.
Testing procedure
Flash this on any MSP430 board. No regressions should occur, but power consumption should drop. Your mileage may wary, though:
Benchmarks
I attached a power monitor in-between the USB connection to our Olimex MSP430Hxxx breakout board and monitored the power consumption in the following scenarios:
/dev/ttyUSB0
open). This is the baseline, as this power is used even without the MCU actually attachedexmaples/default
frommaster
flashed, and firsthelp
thenps
runexmaples/default
from this PR flashed, and firsthelp
thenps
runBenchmark on the
olimex-msp430h1611
Benchmark on the
olimex-msp430h2618
Conclusion
The power consumption goes down pretty much to the base line for each MCU family while the MCU is not in use, but spikes when there is activity. It looks pretty much like one would expect.
Issues/PRs references