
The RAM base address is needed during SoftDevice initialization. So far, the same magic value has been used in aykevl/go-bluetooth and in TinyGo, but this should be configured in only one place. This will have additional benefits in the future: * It is currently set to 0x39c0, which is around 14.5kB. Most nrf51822 chips have only 16kB of RAM, so this is way too much for those chips. * LLD in LLVM 11 allows expressions in the MEMORY part of linker scripts, which will allow overriding the SoftDevice RAM area with a linker flag, which might come in handy.
13 строки
305 Б
Text
13 строки
305 Б
Text
|
|
MEMORY
|
|
{
|
|
FLASH_TEXT (rw) : ORIGIN = 0x00000000 + 0x00027000, LENGTH = 1M - 0x00027000
|
|
RAM (xrw) : ORIGIN = 0x20000000 + 0x000039c0, LENGTH = 256K - 0x000039c0
|
|
}
|
|
|
|
_stack_size = 4K;
|
|
|
|
/* This value is needed by the Nordic SoftDevice. */
|
|
__app_ram_base = ORIGIN(RAM);
|
|
|
|
INCLUDE "targets/arm.ld"
|