diff --git a/stm32f042c6_flash.ld b/stm32f042c6_flash.ld --- a/stm32f042c6_flash.ld +++ b/stm32f042c6_flash.ld @@ -11,7 +11,8 @@ ENTRY(Reset_Handler) /* Specify the memory areas */ MEMORY { -FLASH (rx) : ORIGIN = 0x8000000, LENGTH = 32K +FLASH (rx) : ORIGIN = 0x8000000, LENGTH = 30K +EEPROM (xrw) : ORIGIN = 0x8007C00, LENGTH = 1K RAM (xrw) : ORIGIN = 0x20000000, LENGTH = 6K } @@ -96,6 +97,7 @@ SECTIONS } >RAM AT> FLASH + /* Uninitialized data section */ . = ALIGN(4); .bss : @@ -123,7 +125,13 @@ SECTIONS . = ALIGN(4); } >RAM - + .eeprom : + { + . = ALIGN(4); + *(.eeprom) + . = ALIGN(4); + } >EEPROM + /* Remove information from the standard libraries */ /DISCARD/ :