File tree Expand file tree Collapse file tree 1 file changed +6
-4
lines changed Expand file tree Collapse file tree 1 file changed +6
-4
lines changed Original file line number Diff line number Diff line change @@ -283,14 +283,16 @@ uint32_t *port_stack_get_top(void) {
283283 return & _estack ;
284284}
285285
286- // Place the word in the uninitialized section so it won't get overwritten.
287- __attribute__((section (".uninitialized" ))) uint32_t _saved_word ;
286+ // Place the word in the first 32k of RAM. This is saved by us and the
287+ // bootloader for the soft device. We only use it before the soft device uses
288+ // that memory.
289+ #define SAVED_WORD ((uint32_t *)(0x20008000 - 4))
288290void port_set_saved_word (uint32_t value ) {
289- _saved_word = value ;
291+ * SAVED_WORD = value ;
290292}
291293
292294uint32_t port_get_saved_word (void ) {
293- return _saved_word ;
295+ return * SAVED_WORD ;
294296}
295297
296298uint64_t port_get_raw_ticks (uint8_t * subticks ) {
You can’t perform that action at this time.
0 commit comments