Skip to content

Commit 356de44

Browse files
committed
STM32F7 ARM SCT file update to define correct RAM_SIZE
1 parent 76248b4 commit 356de44

File tree

4 files changed

+98
-135
lines changed

4 files changed

+98
-135
lines changed

targets/TARGET_STM/TARGET_STM32F7/TARGET_STM32F746xG/device/TOOLCHAIN_ARM_STD/stm32f746xg.sct

Lines changed: 22 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -1,32 +1,22 @@
11
#! armcc -E
22
; Scatter-Loading Description File
3-
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
4-
; Copyright (c) 2016, STMicroelectronics
5-
; All rights reserved.
6-
;
7-
; Redistribution and use in source and binary forms, with or without
8-
; modification, are permitted provided that the following conditions are met:
9-
;
10-
; 1. Redistributions of source code must retain the above copyright notice,
11-
; this list of conditions and the following disclaimer.
12-
; 2. Redistributions in binary form must reproduce the above copyright notice,
13-
; this list of conditions and the following disclaimer in the documentation
14-
; and/or other materials provided with the distribution.
15-
; 3. Neither the name of STMicroelectronics nor the names of its contributors
16-
; may be used to endorse or promote products derived from this software
17-
; without specific prior written permission.
18-
;
19-
; THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
20-
; AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
21-
; IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
22-
; DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
23-
; FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
24-
; DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
25-
; SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
26-
; CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
27-
; OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
28-
; OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
29-
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
3+
;******************************************************************************
4+
;* @attention
5+
;*
6+
;* Copyright (c) 2016-2019 STMicroelectronics.
7+
;* All rights reserved.
8+
;*
9+
;* This software component is licensed by ST under BSD 3-Clause license,
10+
;* the "License"; You may not use this file except in compliance with the
11+
;* License. You may obtain a copy of the License at:
12+
;* opensource.org/licenses/BSD-3-Clause
13+
;*
14+
;******************************************************************************
15+
16+
; STM32F746xG:
17+
; FLASH: 1024K (0x100000) @0x08000000
18+
; RAM1: 256K (0x40000) @0x20010000
19+
; RAM2: 64K (0x10000) @0x20000000
3020

3121
#if !defined(MBED_APP_START)
3222
#define MBED_APP_START 0x08000000
@@ -42,16 +32,15 @@
4232

4333
#define Stack_Size MBED_BOOT_STACK_SIZE
4434

45-
#define MBED_RAM_START 0x20000000
46-
#define MBED_RAM_SIZE 0x50000
47-
#define MBED_VECTTABLE_RAM_START (MBED_RAM_START)
35+
#define MBED_RAM_START 0x20010000
36+
#define MBED_RAM_SIZE 0x40000
37+
#define MBED_VECTTABLE_RAM_START 0x20000000
4838
#define MBED_VECTTABLE_RAM_SIZE 0x1C8
4939
#define MBED_CRASH_REPORT_RAM_START (MBED_VECTTABLE_RAM_START + MBED_VECTTABLE_RAM_SIZE)
5040
#define MBED_CRASH_REPORT_RAM_SIZE 0x100
51-
#define MBED_RAM0_START (MBED_CRASH_REPORT_RAM_START + MBED_CRASH_REPORT_RAM_SIZE)
52-
#define MBED_RAM0_SIZE (MBED_RAM_SIZE - MBED_VECTTABLE_RAM_SIZE - MBED_CRASH_REPORT_RAM_SIZE)
41+
#define MBED_RAM0_START (MBED_RAM_START)
42+
#define MBED_RAM0_SIZE (MBED_RAM_SIZE)
5343

54-
; STM32F746xG: 1024 KB FLASH (0x100000) + 320 KB SRAM (0x50000)
5544
LR_IROM1 MBED_APP_START MBED_APP_SIZE { ; load region size_region
5645

5746
ER_IROM1 MBED_APP_START MBED_APP_SIZE { ; load address = execution address
@@ -63,7 +52,6 @@ LR_IROM1 MBED_APP_START MBED_APP_SIZE { ; load region size_region
6352
RW_m_crash_data MBED_CRASH_REPORT_RAM_START EMPTY MBED_CRASH_REPORT_RAM_SIZE { ; RW data
6453
}
6554

66-
; Total: 114 vectors = 456 bytes (0x1C8) to be reserved in RAM
6755
RW_IRAM1 (MBED_RAM0_START) (MBED_RAM0_SIZE-Stack_Size) { ; RW data
6856
.ANY (+RW +ZI)
6957
}

targets/TARGET_STM/TARGET_STM32F7/TARGET_STM32F756xG/device/TOOLCHAIN_ARM_STD/stm32f756xg.sct

Lines changed: 22 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -1,32 +1,22 @@
11
#! armcc -E
22
; Scatter-Loading Description File
3-
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
4-
; Copyright (c) 2016, STMicroelectronics
5-
; All rights reserved.
6-
;
7-
; Redistribution and use in source and binary forms, with or without
8-
; modification, are permitted provided that the following conditions are met:
9-
;
10-
; 1. Redistributions of source code must retain the above copyright notice,
11-
; this list of conditions and the following disclaimer.
12-
; 2. Redistributions in binary form must reproduce the above copyright notice,
13-
; this list of conditions and the following disclaimer in the documentation
14-
; and/or other materials provided with the distribution.
15-
; 3. Neither the name of STMicroelectronics nor the names of its contributors
16-
; may be used to endorse or promote products derived from this software
17-
; without specific prior written permission.
18-
;
19-
; THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
20-
; AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
21-
; IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
22-
; DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
23-
; FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
24-
; DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
25-
; SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
26-
; CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
27-
; OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
28-
; OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
29-
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
3+
;******************************************************************************
4+
;* @attention
5+
;*
6+
;* Copyright (c) 2016-2019 STMicroelectronics.
7+
;* All rights reserved.
8+
;*
9+
;* This software component is licensed by ST under BSD 3-Clause license,
10+
;* the "License"; You may not use this file except in compliance with the
11+
;* License. You may obtain a copy of the License at:
12+
;* opensource.org/licenses/BSD-3-Clause
13+
;*
14+
;******************************************************************************
15+
16+
; STM32F756xG:
17+
; FLASH: 1024K (0x100000) @0x08000000
18+
; RAM1: 256K (0x40000) @0x20010000
19+
; RAM2: 64K (0x10000) @0x20000000
3020

3121
#if !defined(MBED_APP_START)
3222
#define MBED_APP_START 0x08000000
@@ -42,16 +32,15 @@
4232

4333
#define Stack_Size MBED_BOOT_STACK_SIZE
4434

45-
#define MBED_RAM_START 0x20000000
46-
#define MBED_RAM_SIZE 0x50000
47-
#define MBED_VECTTABLE_RAM_START (MBED_RAM_START)
35+
#define MBED_RAM_START 0x20010000
36+
#define MBED_RAM_SIZE 0x40000
37+
#define MBED_VECTTABLE_RAM_START 0x20000000
4838
#define MBED_VECTTABLE_RAM_SIZE 0x1C8
4939
#define MBED_CRASH_REPORT_RAM_START (MBED_VECTTABLE_RAM_START + MBED_VECTTABLE_RAM_SIZE)
5040
#define MBED_CRASH_REPORT_RAM_SIZE 0x100
51-
#define MBED_RAM0_START (MBED_CRASH_REPORT_RAM_START + MBED_CRASH_REPORT_RAM_SIZE)
52-
#define MBED_RAM0_SIZE (MBED_RAM_SIZE - MBED_VECTTABLE_RAM_SIZE - MBED_CRASH_REPORT_RAM_SIZE)
41+
#define MBED_RAM0_START (MBED_RAM_START)
42+
#define MBED_RAM0_SIZE (MBED_RAM_SIZE)
5343

54-
; STM32F746xG: 1024 KB FLASH (0x100000) + 320 KB SRAM (0x50000)
5544
LR_IROM1 MBED_APP_START MBED_APP_SIZE { ; load region size_region
5645

5746
ER_IROM1 MBED_APP_START MBED_APP_SIZE { ; load address = execution address
@@ -63,7 +52,6 @@ LR_IROM1 MBED_APP_START MBED_APP_SIZE { ; load region size_region
6352
RW_m_crash_data MBED_CRASH_REPORT_RAM_START EMPTY MBED_CRASH_REPORT_RAM_SIZE { ; RW data
6453
}
6554

66-
; Total: 114 vectors = 456 bytes (0x1C8) to be reserved in RAM
6755
RW_IRAM1 (MBED_RAM0_START) (MBED_RAM0_SIZE-Stack_Size) { ; RW data
6856
.ANY (+RW +ZI)
6957
}

targets/TARGET_STM/TARGET_STM32F7/TARGET_STM32F767xI/device/TOOLCHAIN_ARM_STD/stm32f767xi.sct

Lines changed: 23 additions & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -1,32 +1,22 @@
11
#! armcc -E
22
; Scatter-Loading Description File
3-
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
4-
; Copyright (c) 2016, STMicroelectronics
5-
; All rights reserved.
6-
;
7-
; Redistribution and use in source and binary forms, with or without
8-
; modification, are permitted provided that the following conditions are met:
9-
;
10-
; 1. Redistributions of source code must retain the above copyright notice,
11-
; this list of conditions and the following disclaimer.
12-
; 2. Redistributions in binary form must reproduce the above copyright notice,
13-
; this list of conditions and the following disclaimer in the documentation
14-
; and/or other materials provided with the distribution.
15-
; 3. Neither the name of STMicroelectronics nor the names of its contributors
16-
; may be used to endorse or promote products derived from this software
17-
; without specific prior written permission.
18-
;
19-
; THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
20-
; AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
21-
; IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
22-
; DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
23-
; FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
24-
; DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
25-
; SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
26-
; CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
27-
; OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
28-
; OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
29-
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
3+
;******************************************************************************
4+
;* @attention
5+
;*
6+
;* Copyright (c) 2016-2019 STMicroelectronics.
7+
;* All rights reserved.
8+
;*
9+
;* This software component is licensed by ST under BSD 3-Clause license,
10+
;* the "License"; You may not use this file except in compliance with the
11+
;* License. You may obtain a copy of the License at:
12+
;* opensource.org/licenses/BSD-3-Clause
13+
;*
14+
;******************************************************************************
15+
16+
; STM32F767xI:
17+
; FLASH: 2048K (0x200000) @0x08000000
18+
; RAM1: 384K (0x60000) @0x20020000
19+
; RAM2: 128K (0x20000) @0x20000000
3020

3121
#if !defined(MBED_APP_START)
3222
#define MBED_APP_START 0x08000000
@@ -42,28 +32,26 @@
4232

4333
#define Stack_Size MBED_BOOT_STACK_SIZE
4434

45-
#define MBED_RAM_START 0x20000000
46-
#define MBED_RAM_SIZE 0x80000
47-
#define MBED_VECTTABLE_RAM_START (MBED_RAM_START)
35+
#define MBED_RAM_START 0x20020000
36+
#define MBED_RAM_SIZE 0x60000
37+
#define MBED_VECTTABLE_RAM_START 0x20000000
4838
#define MBED_VECTTABLE_RAM_SIZE 0x1F8
4939
#define MBED_CRASH_REPORT_RAM_START (MBED_VECTTABLE_RAM_START + MBED_VECTTABLE_RAM_SIZE)
5040
#define MBED_CRASH_REPORT_RAM_SIZE 0x100
51-
#define MBED_RAM0_START (MBED_CRASH_REPORT_RAM_START + MBED_CRASH_REPORT_RAM_SIZE)
52-
#define MBED_RAM0_SIZE (MBED_RAM_SIZE - MBED_VECTTABLE_RAM_SIZE - MBED_CRASH_REPORT_RAM_SIZE)
41+
#define MBED_RAM0_START (MBED_RAM_START)
42+
#define MBED_RAM0_SIZE (MBED_RAM_SIZE)
5343

54-
; STM32F767ZI: 2048 KB FLASH (0x200000) + 512 KB SRAM (0x80000)
5544
LR_IROM1 MBED_APP_START MBED_APP_SIZE { ; load region size_region
5645

5746
ER_IROM1 MBED_APP_START MBED_APP_SIZE { ; load address = execution address
5847
*.o (RESET, +First)
5948
*(InRoot$$Sections)
6049
.ANY (+RO)
6150
}
62-
51+
6352
RW_m_crash_data MBED_CRASH_REPORT_RAM_START EMPTY MBED_CRASH_REPORT_RAM_SIZE { ; RW data
6453
}
6554

66-
; Total: 126 vectors = 504 bytes (0x1F8) to be reserved in RAM
6755
RW_IRAM1 (MBED_RAM0_START) (MBED_RAM0_SIZE-Stack_Size) { ; RW data
6856
.ANY (+RW +ZI)
6957
}
Lines changed: 31 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -1,38 +1,27 @@
11
#! armcc -E
22
; Scatter-Loading Description File
3-
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
4-
; Copyright (c) 2016, STMicroelectronics
5-
; All rights reserved.
6-
;
7-
; Redistribution and use in source and binary forms, with or without
8-
; modification, are permitted provided that the following conditions are met:
9-
;
10-
; 1. Redistributions of source code must retain the above copyright notice,
11-
; this list of conditions and the following disclaimer.
12-
; 2. Redistributions in binary form must reproduce the above copyright notice,
13-
; this list of conditions and the following disclaimer in the documentation
14-
; and/or other materials provided with the distribution.
15-
; 3. Neither the name of STMicroelectronics nor the names of its contributors
16-
; may be used to endorse or promote products derived from this software
17-
; without specific prior written permission.
18-
;
19-
; THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
20-
; AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
21-
; IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
22-
; DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
23-
; FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
24-
; DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
25-
; SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
26-
; CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
27-
; OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
28-
; OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
29-
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
3+
;******************************************************************************
4+
;* @attention
5+
;*
6+
;* Copyright (c) 2016-2019 STMicroelectronics.
7+
;* All rights reserved.
8+
;*
9+
;* This software component is licensed by ST under BSD 3-Clause license,
10+
;* the "License"; You may not use this file except in compliance with the
11+
;* License. You may obtain a copy of the License at:
12+
;* opensource.org/licenses/BSD-3-Clause
13+
;*
14+
;******************************************************************************
15+
16+
; STM32F769xI:
17+
; FLASH: 2048K (0x200000) @0x08000000
18+
; RAM1: 384K (0x60000) @0x20020000
19+
; RAM2: 128K (0x20000) @0x20000000
3020

3121
#if !defined(MBED_APP_START)
3222
#define MBED_APP_START 0x08000000
3323
#endif
3424

35-
; 2048 KB FLASH (0x200000)
3625
#if !defined(MBED_APP_SIZE)
3726
#define MBED_APP_SIZE 0x200000
3827
#endif
@@ -43,6 +32,15 @@
4332

4433
#define Stack_Size MBED_BOOT_STACK_SIZE
4534

35+
#define MBED_RAM_START 0x20020000
36+
#define MBED_RAM_SIZE 0x60000
37+
#define MBED_VECTTABLE_RAM_START 0x20000000
38+
#define MBED_VECTTABLE_RAM_SIZE 0x1F8
39+
#define MBED_CRASH_REPORT_RAM_START (MBED_VECTTABLE_RAM_START + MBED_VECTTABLE_RAM_SIZE)
40+
#define MBED_CRASH_REPORT_RAM_SIZE 0x100
41+
#define MBED_RAM0_START (MBED_RAM_START)
42+
#define MBED_RAM0_SIZE (MBED_RAM_SIZE)
43+
4644
LR_IROM1 MBED_APP_START MBED_APP_SIZE { ; load region size_region
4745

4846
ER_IROM1 MBED_APP_START MBED_APP_SIZE { ; load address = execution address
@@ -51,13 +49,14 @@ LR_IROM1 MBED_APP_START MBED_APP_SIZE { ; load region size_region
5149
.ANY (+RO)
5250
}
5351

54-
; 512KB SRAM (0x80000)
55-
; Total: 126 vectors = 504 bytes (0x1F8 + 0 byte for 8-byte data alignment) to be reserved in RAM
56-
RW_IRAM1 (0x20000000+0x1F8) (0x80000-0x1F8-Stack_Size) { ; RW data
52+
RW_m_crash_data MBED_CRASH_REPORT_RAM_START EMPTY MBED_CRASH_REPORT_RAM_SIZE { ; RW data
53+
}
54+
55+
RW_IRAM1 (MBED_RAM0_START) (MBED_RAM0_SIZE-Stack_Size) { ; RW data
5756
.ANY (+RW +ZI)
5857
}
5958

60-
ARM_LIB_STACK (0x20000000+0x80000) EMPTY -Stack_Size { ; stack
59+
ARM_LIB_STACK (MBED_RAM0_START+MBED_RAM0_SIZE) EMPTY -Stack_Size { ; stack
6160
}
6261
}
6362

0 commit comments

Comments
 (0)