You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mynewt.apache.org by "kasjer (via GitHub)" <gi...@apache.org> on 2024/06/02 14:04:02 UTC
[PR] stm32/hal_timer: Improve timer power consumption [mynewt-core]
kasjer opened a new pull request, #3238:
URL: https://github.com/apache/mynewt-core/pull/3238
Code allows to disable hal timer after it was running for some time (number over overflows) and it was not used for anything.
This can reduce power consumption without sacrificing usability. This can be useful for cputimer that is required but not used extensively.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@mynewt.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] stm32/hal_timer: Improve timer power consumption [mynewt-core]
Posted by "kasjer (via GitHub)" <gi...@apache.org>.
kasjer commented on code in PR #3238:
URL: https://github.com/apache/mynewt-core/pull/3238#discussion_r1632967980
##########
hw/mcu/stm/stm32_common/syscfg.yml:
##########
@@ -466,5 +466,16 @@ syscfg.defs:
When enabled, OS_TICKS_PER_SEC should be one of 128, 256, 512, 1024.
value: 0
+ STM32_TIMER_AUTO_OFF_COUNT:
+ description: >
+ Turn off hal timer if it is not used for a specific number of overflows.
+ HAL timers are used for high frequency time measurement or delays.
+ Due to high frequency nature of the timer, counter overflows interrupts
+ would interrupt sleep event if timer is not in use.
+ This value when set to value graters then 0 will all to turn off timer
+ after number of overflow events without user code asking for timer value
+ or scheduling event.
+ value: 0
Review Comment:
done
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@mynewt.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] stm32/hal_timer: Improve timer power consumption [mynewt-core]
Posted by "sjanc (via GitHub)" <gi...@apache.org>.
sjanc commented on code in PR #3238:
URL: https://github.com/apache/mynewt-core/pull/3238#discussion_r1632950817
##########
hw/mcu/stm/stm32_common/syscfg.yml:
##########
@@ -466,5 +466,16 @@ syscfg.defs:
When enabled, OS_TICKS_PER_SEC should be one of 128, 256, 512, 1024.
value: 0
+ STM32_TIMER_AUTO_OFF_COUNT:
+ description: >
+ Turn off hal timer if it is not used for a specific number of overflows.
+ HAL timers are used for high frequency time measurement or delays.
+ Due to high frequency nature of the timer, counter overflows interrupts
+ would interrupt sleep event if timer is not in use.
+ This value when set to value graters then 0 will all to turn off timer
+ after number of overflow events without user code asking for timer value
+ or scheduling event.
+ value: 0
Review Comment:
maybe add range here (since uint8_t is used), otherwise looks good to me
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@mynewt.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] stm32/hal_timer: Improve timer power consumption [mynewt-core]
Posted by "kasjer (via GitHub)" <gi...@apache.org>.
kasjer merged PR #3238:
URL: https://github.com/apache/mynewt-core/pull/3238
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@mynewt.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org