[Silicon Labs] Bugfixes to using bootloader with Series 1 devices.

pull/4482/head
Aksel Skauge Mellbye 2017-03-30 10:53:51 +01:00 committed by Kevin Gilbert
parent 8d6bc1d47d
commit b30e665fc7
5 changed files with 13 additions and 12 deletions

View File

@ -211,5 +211,5 @@ SECTIONS
ASSERT(__StackLimit >= __HeapLimit, "region RAM overflowed with stack")
/* Check if FLASH usage exceeds FLASH size */
ASSERT( LENGTH(FLASH) >= (__etext + SIZEOF(.data)), "FLASH memory overflowed !")
ASSERT(ORIGIN(FLASH) + LENGTH(FLASH) >= (__etext + SIZEOF(.data)), "FLASH memory overflowed !")
}

View File

@ -211,5 +211,5 @@ SECTIONS
ASSERT(__StackLimit >= __HeapLimit, "region RAM overflowed with stack")
/* Check if FLASH usage exceeds FLASH size */
ASSERT( LENGTH(FLASH) >= (__etext + SIZEOF(.data)), "FLASH memory overflowed !")
ASSERT(ORIGIN(FLASH) + LENGTH(FLASH) >= (__etext + SIZEOF(.data)), "FLASH memory overflowed !")
}

View File

@ -211,5 +211,5 @@ SECTIONS
ASSERT(__StackLimit >= __HeapLimit, "region RAM overflowed with stack")
/* Check if FLASH usage exceeds FLASH size */
ASSERT( LENGTH(FLASH) >= (__etext + SIZEOF(.data)), "FLASH memory overflowed !")
ASSERT( ORIGIN(FLASH) + LENGTH(FLASH) >= (__etext + SIZEOF(.data)), "FLASH memory overflowed !")
}

View File

@ -211,5 +211,5 @@ SECTIONS
ASSERT(__StackLimit >= __HeapLimit, "region RAM overflowed with stack")
/* Check if FLASH usage exceeds FLASH size */
ASSERT( LENGTH(FLASH) >= (__etext + SIZEOF(.data)), "FLASH memory overflowed !")
ASSERT(ORIGIN(FLASH) + LENGTH(FLASH) >= (__etext + SIZEOF(.data)), "FLASH memory overflowed !")
}

View File

@ -38,19 +38,20 @@ void mbed_sdk_init()
{
CHIP_Init();
#if defined(_SILICON_LABS_32B_PLATFORM_2)
#if defined(_SILICON_LABS_32B_SERIES_1)
EMU_DCDCInit_TypeDef dcdcInit = EMU_DCDCINIT_DEFAULT;
EMU_DCDCInit(&dcdcInit);
#if (CORE_CLOCK_SOURCE == HFXO)
// Only init HFXO if not already done (e.g. by bootloader)
if (CMU_ClockSelectGet(cmuClock_HF) != cmuSelect_HFXO) {
#if defined(_EFR_DEVICE)
CMU_HFXOInit_TypeDef hfxoInit = CMU_HFXOINIT_WSTK_DEFAULT;
// Initialize the HFXO using the settings from the WSTK bspconfig.h
// Note: This configures things like the capacitive tuning CTUNE variable
// which can vary based on your hardware design.
CMU_HFXOInit(&hfxoInit);
#else
CMU_HFXOInit_TypeDef hfxoInit = CMU_HFXOINIT_STK_DEFAULT;
#endif
CMU_HFXOInit(&hfxoInit);
}
#endif
#endif