Importing A Gnu17 Version 2 Project - Epson S5U1C17001C Manual

Cmos 16-bit single chip microcontroller (c compiler package for s1c17 family) (ver. 3.2)
Hide thumbs Also See for S5U1C17001C:
Table of Contents

Advertisement

3.3.6

Importing a GNU17 Version 2 Project

All project properties need to be reset if you build a project created using GNU17 Version 2 (such as GNU17 v2.3.0) with this
package. This function eliminates the need to reset all properties.
(1) Select [Import...] from the [File] menu.
Select "GNU17 v2 Project" in the import dialog box to proceed. The "GNU17 v2 Project Import Wizard" will start.
(2) Select the existing project folder, then select [Finish].
The source file for the existing project is copied to the src folder of the new project.
(3) Select the Target CPU for the imported project.
View GNU17 Setting in the [Properties] dialog to confirm the Target CPU.
(4) Rename the interrupt processing function.
Startup Processing Library crt0.o contains an interrupt vector table and processes from when the target MCU is reset until the
main function is invoked. As described in Section 3.3.4, "Interrupt Vector and Boot Processing Descriptions," with crt0.o, the
name of the interrupt handler function is fixed at _vectorXX_handler. Refer to the interrupt vector table in the imported project.
Rename the interrupt handler function registered in the interrupt vector; assign a name that corresponds to the interrupt vector
number.
(5) Delete the processing in the existing source file that duplicates crt0.o.
The following processing that duplicates crt0.o should be deleted from the existing source file:
• Vector table
• Copying to data section RAM and bss section initialization (_init_section)
• Standard library initialization (_init_lib and _init_sys)
The contents of crt0.o can be checked in the utility/lib_src/crt0/crt0.c source code included in this package.
(6) Manage boot processing.
Manage the boot processing contents defined in the existing source file in accordance with Section 3.3.4, "Interrupt Vector and
Boot Processing Descriptions" and define the stack pointer initial value.
If you are not using the startup processing library crt0.o, you can omit steps (4), (5), and (6). Note that you must do the following
instead:
(a)
Add a linker script file to the project.
Copy an existing linker script file and add it to the project. Specify the linker script file added in [Other options] for
linker options in the project properties.
(b)
Delink crt0.o.
Select the linker option [Do not use standard start files] in the project properties to delink crt0.o.
(c)
Edit the linker script file in accordance with the existing project definition.
Edit the following settings for the existing linker script:
• Register the reset interrupt handler function for the entry point (ENTRY).
• Place the interrupt vector table (often contained in the .rodata section of boot.o or vector.o) in the .vector section.
• Exclude the interrupt vector table placed in the .vector section from the .rodata section.
(d)
Edit the GDB command file.
If gdbsim.ini includes the c17 ttbr command, edit this so that it points to the interrupt vector table. For example, if the
interrupt vector table is the vector array, write this as c17 ttbr &vector.
(7) Build the project.
Build the project and check the build results in the [Console] view.
S5U1C17001C Manual
(Rev. 1.0)
Seiko Epson Corporation
3 GNU17 IDE
3-7

Advertisement

Table of Contents
loading

Table of Contents