Skip to content

Commit 5ebce38

Browse files
committed
[NUCLEO_F103RB] Align startup files with other targets
1 parent d44996c commit 5ebce38

File tree

2 files changed

+12
-111
lines changed

2 files changed

+12
-111
lines changed

libraries/mbed/targets/cmsis/TARGET_STM/TARGET_NUCLEO_F103RB/TOOLCHAIN_ARM_MICRO/startup_stm32f10x_md.s

Lines changed: 9 additions & 45 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,7 @@
1-
;******************** (C) COPYRIGHT 2011 STMicroelectronics ********************
1+
;*******************************************************************************
22
;* File Name : startup_stm32f10x_md.s
3-
;* Author : MCD Application Team
4-
;* Version : V3.5.0
5-
;* Date : 11-March-2011
63
;* Description : STM32F10x Medium Density Devices vector table for MDK-ARM
7-
;* toolchain.
8-
;* This module performs:
9-
;* - Set the initial SP
10-
;* - Set the initial PC == Reset_Handler
11-
;* - Set the vector table entries with the exceptions ISR address
12-
;* - Configure the clock system
13-
;* - Branches to __main in the C library (which eventually
14-
;* calls main()).
15-
;* After Reset the CortexM3 processor is in Thread mode,
16-
;* priority is Privileged, and the Stack is set to Main.
4+
;* toolchain + ARM_MICRO compiler
175
;* <<< Use Configuration Wizard in Context Menu >>>
186
;*******************************************************************************
197
; THE PRESENT FIRMWARE WHICH IS FOR GUIDANCE ONLY AIMS AT PROVIDING CUSTOMERS
@@ -33,6 +21,8 @@
3321
Stack_Size EQU 0x00000400
3422

3523
AREA STACK, NOINIT, READWRITE, ALIGN=3
24+
EXPORT __initial_sp
25+
3626
Stack_Mem SPACE Stack_Size
3727
__initial_sp EQU 0x20005000 ; Top of RAM
3828

@@ -41,9 +31,12 @@ __initial_sp EQU 0x20005000 ; Top of RAM
4131
; <o> Heap Size (in Bytes) <0x0-0xFFFFFFFF:8>
4232
; </h>
4333

44-
Heap_Size EQU 0x00000200
34+
Heap_Size EQU 0x00000000
4535

4636
AREA HEAP, NOINIT, READWRITE, ALIGN=3
37+
EXPORT __heap_base
38+
EXPORT __heap_limit
39+
4740
__heap_base
4841
Heap_Mem SPACE Heap_Size
4942
__heap_limit
@@ -275,33 +268,4 @@ USBWakeUp_IRQHandler
275268
ENDP
276269

277270
ALIGN
278-
279-
;*******************************************************************************
280-
; User Stack and Heap initialization
281-
;*******************************************************************************
282-
IF :DEF:__MICROLIB
283-
284-
EXPORT __initial_sp
285-
EXPORT __heap_base
286-
EXPORT __heap_limit
287-
288-
ELSE
289-
290-
IMPORT __use_two_region_memory
291-
EXPORT __user_initial_stackheap
292-
293-
__user_initial_stackheap
294-
295-
LDR R0, = Heap_Mem
296-
LDR R1, =(Stack_Mem + Stack_Size)
297-
LDR R2, = (Heap_Mem + Heap_Size)
298-
LDR R3, = Stack_Mem
299-
BX LR
300-
301-
ALIGN
302-
303-
ENDIF
304-
305-
END
306-
307-
;******************* (C) COPYRIGHT 2011 STMicroelectronics *****END OF FILE*****
271+
END

libraries/mbed/targets/cmsis/TARGET_STM/TARGET_NUCLEO_F103RB/TOOLCHAIN_ARM_STD/startup_stm32f10x_md.s

Lines changed: 3 additions & 66 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,7 @@
1-
;******************** (C) COPYRIGHT 2011 STMicroelectronics ********************
1+
;*******************************************************************************
22
;* File Name : startup_stm32f10x_md.s
3-
;* Author : MCD Application Team
4-
;* Version : V3.5.0
5-
;* Date : 11-March-2011
63
;* Description : STM32F10x Medium Density Devices vector table for MDK-ARM
7-
;* toolchain.
8-
;* This module performs:
9-
;* - Set the initial SP
10-
;* - Set the initial PC == Reset_Handler
11-
;* - Set the vector table entries with the exceptions ISR address
12-
;* - Configure the clock system
13-
;* - Branches to __main in the C library (which eventually
14-
;* calls main()).
15-
;* After Reset the CortexM3 processor is in Thread mode,
16-
;* priority is Privileged, and the Stack is set to Main.
4+
;* toolchain + ARM_STD compiler
175
;* <<< Use Configuration Wizard in Context Menu >>>
186
;*******************************************************************************
197
; THE PRESENT FIRMWARE WHICH IS FOR GUIDANCE ONLY AIMS AT PROVIDING CUSTOMERS
@@ -24,30 +12,8 @@
2412
; INFORMATION CONTAINED HEREIN IN CONNECTION WITH THEIR PRODUCTS.
2513
;*******************************************************************************
2614

27-
; Amount of memory (in bytes) allocated for Stack
28-
; Tailor this value to your application needs
29-
; <h> Stack Configuration
30-
; <o> Stack Size (in Bytes) <0x0-0xFFFFFFFF:8>
31-
; </h>
32-
33-
Stack_Size EQU 0x00000400
34-
35-
AREA STACK, NOINIT, READWRITE, ALIGN=3
36-
Stack_Mem SPACE Stack_Size
3715
__initial_sp EQU 0x20005000 ; Top of RAM
3816

39-
40-
; <h> Heap Configuration
41-
; <o> Heap Size (in Bytes) <0x0-0xFFFFFFFF:8>
42-
; </h>
43-
44-
Heap_Size EQU 0x00000200
45-
46-
AREA HEAP, NOINIT, READWRITE, ALIGN=3
47-
__heap_base
48-
Heap_Mem SPACE Heap_Size
49-
__heap_limit
50-
5117
PRESERVE8
5218
THUMB
5319

@@ -275,33 +241,4 @@ USBWakeUp_IRQHandler
275241
ENDP
276242

277243
ALIGN
278-
279-
;*******************************************************************************
280-
; User Stack and Heap initialization
281-
;*******************************************************************************
282-
IF :DEF:__MICROLIB
283-
284-
EXPORT __initial_sp
285-
EXPORT __heap_base
286-
EXPORT __heap_limit
287-
288-
ELSE
289-
290-
IMPORT __use_two_region_memory
291-
EXPORT __user_initial_stackheap
292-
293-
__user_initial_stackheap
294-
295-
LDR R0, = Heap_Mem
296-
LDR R1, =(Stack_Mem + Stack_Size)
297-
LDR R2, = (Heap_Mem + Heap_Size)
298-
LDR R3, = Stack_Mem
299-
BX LR
300-
301-
ALIGN
302-
303-
ENDIF
304-
305-
END
306-
307-
;******************* (C) COPYRIGHT 2011 STMicroelectronics *****END OF FILE*****
244+
END

0 commit comments

Comments
 (0)