mirror of https://github.com/ARMmbed/mbed-os.git
Merge pull request #499 from ohagendorf/develop_coide
[EXPORT] NUCLEO_F4x1RE, DISCO_F407VG - export to CoIDEpull/505/head
commit
201bc4a190
|
@ -25,6 +25,9 @@ class CoIDE(Exporter):
|
|||
TARGETS = [
|
||||
'KL25Z',
|
||||
'KL05Z',
|
||||
'DISCO_F407VG',
|
||||
'NUCLEO_F401RE',
|
||||
'NUCLEO_F411RE'
|
||||
]
|
||||
|
||||
# seems like CoIDE currently supports only one type
|
||||
|
@ -33,6 +36,9 @@ class CoIDE(Exporter):
|
|||
'cpp_sources':'1',
|
||||
's_sources':'1'
|
||||
}
|
||||
FILE_TYPES2 = {
|
||||
'headers':'1'
|
||||
}
|
||||
|
||||
def generate(self):
|
||||
self.resources.win_to_unix()
|
||||
|
@ -42,6 +48,12 @@ class CoIDE(Exporter):
|
|||
source_files.append({
|
||||
'name': basename(file), 'type': n, 'path': file
|
||||
})
|
||||
header_files = []
|
||||
for r_type, n in CoIDE.FILE_TYPES2.iteritems():
|
||||
for file in getattr(self.resources, r_type):
|
||||
header_files.append({
|
||||
'name': basename(file), 'type': n, 'path': file
|
||||
})
|
||||
|
||||
libraries = []
|
||||
for lib in self.resources.libraries:
|
||||
|
@ -51,6 +63,7 @@ class CoIDE(Exporter):
|
|||
ctx = {
|
||||
'name': self.program_name,
|
||||
'source_files': source_files,
|
||||
'header_files': header_files,
|
||||
'include_paths': self.resources.inc_dirs,
|
||||
'scatter_file': self.resources.linker_script,
|
||||
'library_paths': self.resources.lib_dirs,
|
||||
|
|
|
@ -0,0 +1,90 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<Project version="2G - 1.7.5" name="{{name}}">
|
||||
<Target name="{{name}}" isCurrent="1">
|
||||
<Device manufacturerId="9" manufacturerName="ST" chipId="344" chipName="STM32F407VG" boardId="" boardName=""/>
|
||||
<BuildOption>
|
||||
<Compile>
|
||||
<Option name="OptimizationLevel" value="4"/>
|
||||
<Option name="UseFPU" value="0"/>
|
||||
<Option name="UserEditCompiler" value="-fno-common; -fmessage-length=0; -Wall; -fno-strict-aliasing; -fno-rtti; -fno-exceptions; -ffunction-sections; -fdata-sections; -std=gnu++98"/>
|
||||
<Option name="FPU" value="1"/>
|
||||
<Option name="SupportCPlusplus" value="1"/>
|
||||
<Includepaths>
|
||||
{% for path in include_paths %} <Includepath path="{{path}}"/> {% endfor %}
|
||||
</Includepaths>
|
||||
<DefinedSymbols>
|
||||
{% for s in symbols %} <Define name="{{s}}"/> {% endfor %}
|
||||
</DefinedSymbols>
|
||||
</Compile>
|
||||
<Link useDefault="0">
|
||||
<Option name="DiscardUnusedSection" value="0"/>
|
||||
<Option name="UserEditLinkder" value=""/>
|
||||
<Option name="UseMemoryLayout" value="0"/>
|
||||
<Option name="LTO" value="0"/>
|
||||
<Option name="IsNewStartupCode" value="1"/>
|
||||
<Option name="Library" value="Not use C Library"/>
|
||||
<Option name="nostartfiles" value="0"/>
|
||||
<Option name="UserEditLinker" value="--specs=nano.specs; -u _printf_float; -u _scanf_float; {% for file in object_files %}
|
||||
${project.path}/{{file}}; {% endfor %} {% for p in library_paths %}-L${project.path}/{{p}}; {% endfor %}"/>
|
||||
<LinkedLibraries>
|
||||
{% for lib in libraries %}
|
||||
<Libset dir="" libs="{{lib}}"/>
|
||||
{% endfor %}
|
||||
<Libset dir="" libs="stdc++"/>
|
||||
<Libset dir="" libs="supc++"/>
|
||||
<Libset dir="" libs="m"/>
|
||||
<Libset dir="" libs="gcc"/>
|
||||
<Libset dir="" libs="c"/>
|
||||
<Libset dir="" libs="nosys"/>
|
||||
</LinkedLibraries>
|
||||
<MemoryAreas debugInFlashNotRAM="1">
|
||||
<Memory name="IROM1" type="ReadOnly" size="0x00100000" startValue="0x08000000"/>
|
||||
<Memory name="IRAM1" type="ReadWrite" size="0x00020000" startValue="0x20000000"/>
|
||||
<Memory name="IROM2" type="ReadOnly" size="" startValue=""/>
|
||||
<Memory name="IRAM2" type="ReadWrite" size="0x00010000" startValue="0x10000000"/>
|
||||
</MemoryAreas>
|
||||
<LocateLinkFile path="{{scatter_file}}" type="0"/>
|
||||
</Link>
|
||||
<Output>
|
||||
<Option name="OutputFileType" value="0"/>
|
||||
<Option name="Path" value="./"/>
|
||||
<Option name="Name" value="{{name}}"/>
|
||||
<Option name="HEX" value="1"/>
|
||||
<Option name="BIN" value="1"/>
|
||||
</Output>
|
||||
<User>
|
||||
<UserRun name="Run#1" type="Before" checked="0" value=""/>
|
||||
<UserRun name="Run#1" type="After" checked="0" value=""/>
|
||||
</User>
|
||||
</BuildOption>
|
||||
<DebugOption>
|
||||
<Option name="org.coocox.codebugger.gdbjtag.core.adapter" value="ST-Link"/>
|
||||
<Option name="org.coocox.codebugger.gdbjtag.core.debugMode" value="SWD"/>
|
||||
<Option name="org.coocox.codebugger.gdbjtag.core.clockDiv" value="1M"/>
|
||||
<Option name="org.coocox.codebugger.gdbjtag.corerunToMain" value="1"/>
|
||||
<Option name="org.coocox.codebugger.gdbjtag.core.jlinkgdbserver" value=""/>
|
||||
<Option name="org.coocox.codebugger.gdbjtag.core.userDefineGDBScript" value=""/>
|
||||
<Option name="org.coocox.codebugger.gdbjtag.core.targetEndianess" value="0"/>
|
||||
<Option name="org.coocox.codebugger.gdbjtag.core.jlinkResetMode" value="Type 0: Normal"/>
|
||||
<Option name="org.coocox.codebugger.gdbjtag.core.resetMode" value="SYSRESETREQ"/>
|
||||
<Option name="org.coocox.codebugger.gdbjtag.core.ifSemihost" value="0"/>
|
||||
<Option name="org.coocox.codebugger.gdbjtag.core.ifCacheRom" value="1"/>
|
||||
<Option name="org.coocox.codebugger.gdbjtag.core.ipAddress" value="127.0.0.1"/>
|
||||
<Option name="org.coocox.codebugger.gdbjtag.core.portNumber" value="2009"/>
|
||||
<Option name="org.coocox.codebugger.gdbjtag.core.autoDownload" value="1"/>
|
||||
<Option name="org.coocox.codebugger.gdbjtag.core.verify" value="1"/>
|
||||
<Option name="org.coocox.codebugger.gdbjtag.core.downloadFuction" value="Erase Effected"/>
|
||||
<Option name="org.coocox.codebugger.gdbjtag.core.defaultAlgorithm" value="stm32f4xx_1024.elf"/>
|
||||
</DebugOption>
|
||||
<ExcludeFile/>
|
||||
</Target>
|
||||
<Components path="./"/>
|
||||
<Files>
|
||||
{% for file in source_files %}
|
||||
<File name="sourcen/{{file.path}}" path="{{file.path}}" type="{{file.type}}"/>
|
||||
{% endfor %}
|
||||
{% for file in header_files %}
|
||||
<File name="includes/{{file.path}}" path="{{file.path}}" type="{{file.type}}"/>
|
||||
{% endfor %}
|
||||
</Files>
|
||||
</Project>
|
|
@ -0,0 +1,90 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<Project version="2G - 1.7.5" name="{{name}}">
|
||||
<Target name="{{name}}" isCurrent="1">
|
||||
<Device manufacturerId="9" manufacturerName="ST" chipId="499" chipName="STM32F401RE" boardId="" boardName=""/>
|
||||
<BuildOption>
|
||||
<Compile>
|
||||
<Option name="OptimizationLevel" value="4"/>
|
||||
<Option name="UseFPU" value="0"/>
|
||||
<Option name="UserEditCompiler" value="-fno-common; -fmessage-length=0; -Wall; -fno-strict-aliasing; -fno-rtti; -fno-exceptions; -ffunction-sections; -fdata-sections; -std=gnu++98"/>
|
||||
<Option name="FPU" value="1"/>
|
||||
<Option name="SupportCPlusplus" value="1"/>
|
||||
<Includepaths>
|
||||
{% for path in include_paths %} <Includepath path="{{path}}"/> {% endfor %}
|
||||
</Includepaths>
|
||||
<DefinedSymbols>
|
||||
{% for s in symbols %} <Define name="{{s}}"/> {% endfor %}
|
||||
</DefinedSymbols>
|
||||
</Compile>
|
||||
<Link useDefault="0">
|
||||
<Option name="DiscardUnusedSection" value="0"/>
|
||||
<Option name="UserEditLinkder" value=""/>
|
||||
<Option name="UseMemoryLayout" value="0"/>
|
||||
<Option name="LTO" value="0"/>
|
||||
<Option name="IsNewStartupCode" value="1"/>
|
||||
<Option name="Library" value="Not use C Library"/>
|
||||
<Option name="nostartfiles" value="0"/>
|
||||
<Option name="UserEditLinker" value="--specs=nano.specs; -u _printf_float; -u _scanf_float; {% for file in object_files %}
|
||||
${project.path}/{{file}}; {% endfor %} {% for p in library_paths %}-L${project.path}/{{p}}; {% endfor %}"/>
|
||||
<LinkedLibraries>
|
||||
{% for lib in libraries %}
|
||||
<Libset dir="" libs="{{lib}}"/>
|
||||
{% endfor %}
|
||||
<Libset dir="" libs="stdc++"/>
|
||||
<Libset dir="" libs="supc++"/>
|
||||
<Libset dir="" libs="m"/>
|
||||
<Libset dir="" libs="gcc"/>
|
||||
<Libset dir="" libs="c"/>
|
||||
<Libset dir="" libs="nosys"/>
|
||||
</LinkedLibraries>
|
||||
<MemoryAreas debugInFlashNotRAM="1">
|
||||
<Memory name="IROM1" type="ReadOnly" size="0x00080000" startValue="0x08000000"/>
|
||||
<Memory name="IRAM1" type="ReadWrite" size="0x00018000" startValue="0x20000000"/>
|
||||
<Memory name="IROM2" type="ReadOnly" size="" startValue=""/>
|
||||
<Memory name="IRAM2" type="ReadWrite" size="" startValue=""/>
|
||||
</MemoryAreas>
|
||||
<LocateLinkFile path="{{scatter_file}}" type="0"/>
|
||||
</Link>
|
||||
<Output>
|
||||
<Option name="OutputFileType" value="0"/>
|
||||
<Option name="Path" value="./"/>
|
||||
<Option name="Name" value="{{name}}"/>
|
||||
<Option name="HEX" value="1"/>
|
||||
<Option name="BIN" value="1"/>
|
||||
</Output>
|
||||
<User>
|
||||
<UserRun name="Run#1" type="Before" checked="0" value=""/>
|
||||
<UserRun name="Run#1" type="After" checked="0" value=""/>
|
||||
</User>
|
||||
</BuildOption>
|
||||
<DebugOption>
|
||||
<Option name="org.coocox.codebugger.gdbjtag.core.adapter" value="ST-Link"/>
|
||||
<Option name="org.coocox.codebugger.gdbjtag.core.debugMode" value="SWD"/>
|
||||
<Option name="org.coocox.codebugger.gdbjtag.core.clockDiv" value="1M"/>
|
||||
<Option name="org.coocox.codebugger.gdbjtag.corerunToMain" value="1"/>
|
||||
<Option name="org.coocox.codebugger.gdbjtag.core.jlinkgdbserver" value=""/>
|
||||
<Option name="org.coocox.codebugger.gdbjtag.core.userDefineGDBScript" value=""/>
|
||||
<Option name="org.coocox.codebugger.gdbjtag.core.targetEndianess" value="0"/>
|
||||
<Option name="org.coocox.codebugger.gdbjtag.core.jlinkResetMode" value="Type 0: Normal"/>
|
||||
<Option name="org.coocox.codebugger.gdbjtag.core.resetMode" value="SYSRESETREQ"/>
|
||||
<Option name="org.coocox.codebugger.gdbjtag.core.ifSemihost" value="0"/>
|
||||
<Option name="org.coocox.codebugger.gdbjtag.core.ifCacheRom" value="1"/>
|
||||
<Option name="org.coocox.codebugger.gdbjtag.core.ipAddress" value="127.0.0.1"/>
|
||||
<Option name="org.coocox.codebugger.gdbjtag.core.portNumber" value="2009"/>
|
||||
<Option name="org.coocox.codebugger.gdbjtag.core.autoDownload" value="1"/>
|
||||
<Option name="org.coocox.codebugger.gdbjtag.core.verify" value="1"/>
|
||||
<Option name="org.coocox.codebugger.gdbjtag.core.downloadFuction" value="Erase Effected"/>
|
||||
<Option name="org.coocox.codebugger.gdbjtag.core.defaultAlgorithm" value="stm32f4xx_512.elf"/>
|
||||
</DebugOption>
|
||||
<ExcludeFile/>
|
||||
</Target>
|
||||
<Components path="./"/>
|
||||
<Files>
|
||||
{% for file in source_files %}
|
||||
<File name="sourcen/{{file.path}}" path="{{file.path}}" type="{{file.type}}"/>
|
||||
{% endfor %}
|
||||
{% for file in header_files %}
|
||||
<File name="includes/{{file.path}}" path="{{file.path}}" type="{{file.type}}"/>
|
||||
{% endfor %}
|
||||
</Files>
|
||||
</Project>
|
|
@ -0,0 +1,90 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<Project version="2G - 1.7.5" name="{{name}}">
|
||||
<Target name="{{name}}" isCurrent="1">
|
||||
<Device manufacturerId="9" manufacturerName="ST" chipId="499" chipName="STM32F411RE" boardId="" boardName=""/>
|
||||
<BuildOption>
|
||||
<Compile>
|
||||
<Option name="OptimizationLevel" value="4"/>
|
||||
<Option name="UseFPU" value="0"/>
|
||||
<Option name="UserEditCompiler" value="-fno-common; -fmessage-length=0; -Wall; -fno-strict-aliasing; -fno-rtti; -fno-exceptions; -ffunction-sections; -fdata-sections; -std=gnu++98"/>
|
||||
<Option name="FPU" value="1"/>
|
||||
<Option name="SupportCPlusplus" value="1"/>
|
||||
<Includepaths>
|
||||
{% for path in include_paths %} <Includepath path="{{path}}"/> {% endfor %}
|
||||
</Includepaths>
|
||||
<DefinedSymbols>
|
||||
{% for s in symbols %} <Define name="{{s}}"/> {% endfor %}
|
||||
</DefinedSymbols>
|
||||
</Compile>
|
||||
<Link useDefault="0">
|
||||
<Option name="DiscardUnusedSection" value="0"/>
|
||||
<Option name="UserEditLinkder" value=""/>
|
||||
<Option name="UseMemoryLayout" value="0"/>
|
||||
<Option name="LTO" value="0"/>
|
||||
<Option name="IsNewStartupCode" value="1"/>
|
||||
<Option name="Library" value="Not use C Library"/>
|
||||
<Option name="nostartfiles" value="0"/>
|
||||
<Option name="UserEditLinker" value="--specs=nano.specs; -u _printf_float; -u _scanf_float; {% for file in object_files %}
|
||||
${project.path}/{{file}}; {% endfor %} {% for p in library_paths %}-L${project.path}/{{p}}; {% endfor %}"/>
|
||||
<LinkedLibraries>
|
||||
{% for lib in libraries %}
|
||||
<Libset dir="" libs="{{lib}}"/>
|
||||
{% endfor %}
|
||||
<Libset dir="" libs="stdc++"/>
|
||||
<Libset dir="" libs="supc++"/>
|
||||
<Libset dir="" libs="m"/>
|
||||
<Libset dir="" libs="gcc"/>
|
||||
<Libset dir="" libs="c"/>
|
||||
<Libset dir="" libs="nosys"/>
|
||||
</LinkedLibraries>
|
||||
<MemoryAreas debugInFlashNotRAM="1">
|
||||
<Memory name="IROM1" type="ReadOnly" size="0x00080000" startValue="0x08000000"/>
|
||||
<Memory name="IRAM1" type="ReadWrite" size="0x00020000" startValue="0x20000000"/>
|
||||
<Memory name="IROM2" type="ReadOnly" size="" startValue=""/>
|
||||
<Memory name="IRAM2" type="ReadWrite" size="" startValue=""/>
|
||||
</MemoryAreas>
|
||||
<LocateLinkFile path="{{scatter_file}}" type="0"/>
|
||||
</Link>
|
||||
<Output>
|
||||
<Option name="OutputFileType" value="0"/>
|
||||
<Option name="Path" value="./"/>
|
||||
<Option name="Name" value="{{name}}"/>
|
||||
<Option name="HEX" value="1"/>
|
||||
<Option name="BIN" value="1"/>
|
||||
</Output>
|
||||
<User>
|
||||
<UserRun name="Run#1" type="Before" checked="0" value=""/>
|
||||
<UserRun name="Run#1" type="After" checked="0" value=""/>
|
||||
</User>
|
||||
</BuildOption>
|
||||
<DebugOption>
|
||||
<Option name="org.coocox.codebugger.gdbjtag.core.adapter" value="ST-Link"/>
|
||||
<Option name="org.coocox.codebugger.gdbjtag.core.debugMode" value="SWD"/>
|
||||
<Option name="org.coocox.codebugger.gdbjtag.core.clockDiv" value="1M"/>
|
||||
<Option name="org.coocox.codebugger.gdbjtag.corerunToMain" value="1"/>
|
||||
<Option name="org.coocox.codebugger.gdbjtag.core.jlinkgdbserver" value=""/>
|
||||
<Option name="org.coocox.codebugger.gdbjtag.core.userDefineGDBScript" value=""/>
|
||||
<Option name="org.coocox.codebugger.gdbjtag.core.targetEndianess" value="0"/>
|
||||
<Option name="org.coocox.codebugger.gdbjtag.core.jlinkResetMode" value="Type 0: Normal"/>
|
||||
<Option name="org.coocox.codebugger.gdbjtag.core.resetMode" value="SYSRESETREQ"/>
|
||||
<Option name="org.coocox.codebugger.gdbjtag.core.ifSemihost" value="0"/>
|
||||
<Option name="org.coocox.codebugger.gdbjtag.core.ifCacheRom" value="1"/>
|
||||
<Option name="org.coocox.codebugger.gdbjtag.core.ipAddress" value="127.0.0.1"/>
|
||||
<Option name="org.coocox.codebugger.gdbjtag.core.portNumber" value="2009"/>
|
||||
<Option name="org.coocox.codebugger.gdbjtag.core.autoDownload" value="1"/>
|
||||
<Option name="org.coocox.codebugger.gdbjtag.core.verify" value="1"/>
|
||||
<Option name="org.coocox.codebugger.gdbjtag.core.downloadFuction" value="Erase Effected"/>
|
||||
<Option name="org.coocox.codebugger.gdbjtag.core.defaultAlgorithm" value="stm32f4xx_512.elf"/>
|
||||
</DebugOption>
|
||||
<ExcludeFile/>
|
||||
</Target>
|
||||
<Components path="./"/>
|
||||
<Files>
|
||||
{% for file in source_files %}
|
||||
<File name="sourcen/{{file.path}}" path="{{file.path}}" type="{{file.type}}"/>
|
||||
{% endfor %}
|
||||
{% for file in header_files %}
|
||||
<File name="includes/{{file.path}}" path="{{file.path}}" type="{{file.type}}"/>
|
||||
{% endfor %}
|
||||
</Files>
|
||||
</Project>
|
|
@ -76,6 +76,10 @@ if __name__ == '__main__':
|
|||
setup_test_user_prj()
|
||||
|
||||
for toolchain, target in [
|
||||
('coide', 'DISCO_F407VG'),
|
||||
('coide', 'NUCLEO_F401RE'),
|
||||
('coide', 'NUCLEO_F411RE'),
|
||||
|
||||
('uvision', 'LPC1768'),
|
||||
('uvision', 'LPC11U24'),
|
||||
('uvision', 'KL25Z'),
|
||||
|
|
Loading…
Reference in New Issue