Skip to content

Adjust the main stack of nrf51 targets to the call stack of thesoftdevice. #1898

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

Merged
merged 1 commit into from
Jun 10, 2016
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Adjust the main stack of nrf51 targets to the call stack of the
softdevice.

The call stack of the soft device can be 0x600 (1536) bytes long, by
adjusting the stack to a value of 2048 bytes, their is enough room for
the softdevice and RTX kernel to live together in the main stack.

Random issues due to stack overflow were visible with the previous value.
  • Loading branch information
pan- committed Jun 10, 2016
commit 06e2139e6acdfaf6d27f49b93f10e18ee1cfb02f
4 changes: 3 additions & 1 deletion rtos/rtx/TARGET_CORTEX_M/RTX_Conf_CM.c
Original file line number Diff line number Diff line change
Expand Up @@ -97,8 +97,10 @@
# define OS_MAINSTKSIZE 128
# elif defined(TARGET_STM32F334R8) || defined(TARGET_STM32F303RE) || defined(TARGET_STM32F303K8) || defined(TARGET_STM32F334C8) \
|| defined(TARGET_STM32L031K6) || defined(TARGET_STM32L053R8) || defined(TARGET_STM32L053C8) || defined(TARGET_STM32L073RZ) \
|| defined(TARGET_EFM32HG_STK3400) || defined(TARGET_MCU_NRF51822)
|| defined(TARGET_EFM32HG_STK3400)
# define OS_MAINSTKSIZE 112
# elif defined(TARGET_MCU_NRF51822)
# define OS_MAINSTKSIZE 512
# else
# error "no target defined"
# endif
Expand Down