mirror of https://github.com/rusefi/openblt.git
Refs #816. Reintegrating branch where the S32K14 port was developed.
git-svn-id: https://svn.code.sf.net/p/openblt/code/trunk@762 5dc33758-31d5-4daf-9ae8-b24bf3d40d73
This commit is contained in:
parent
e117009d0e
commit
eca185dd01
|
@ -0,0 +1,170 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<?fileVersion 4.0.0?><cproject storage_type_id="org.eclipse.cdt.core.XmlProjectDescriptionStorage">
|
||||
<storageModule moduleId="org.eclipse.cdt.core.settings">
|
||||
<cconfiguration id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.debug.1114796322">
|
||||
<storageModule buildSystemId="org.eclipse.cdt.managedbuilder.core.configurationDataProvider" id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.debug.1114796322" moduleId="org.eclipse.cdt.core.settings" name="Debug">
|
||||
<externalSettings/>
|
||||
<extensions>
|
||||
<extension id="org.eclipse.cdt.core.ELF" point="org.eclipse.cdt.core.BinaryParser"/>
|
||||
<extension id="org.eclipse.cdt.core.GASErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
|
||||
<extension id="org.eclipse.cdt.core.GmakeErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
|
||||
<extension id="com.freescale.s32ds.cdt.core.errorParsers.S32DSGNULinkerErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
|
||||
<extension id="org.eclipse.cdt.core.GCCErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
|
||||
</extensions>
|
||||
</storageModule>
|
||||
<storageModule moduleId="cdtBuildSystem" version="4.0.0">
|
||||
<configuration artifactExtension="elf" artifactName="openblt_s32k144" buildArtefactType="com.nxp.s32ds.cle.arm.mbs.arm32.bare.buildArtefact.exe" buildProperties="org.eclipse.cdt.build.core.buildArtefactType=com.nxp.s32ds.cle.arm.mbs.arm32.bare.buildArtefact.exe,org.eclipse.cdt.build.core.buildType=org.eclipse.cdt.build.core.buildType.debug" description="" id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.debug.1114796322" name="Debug" parent="com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.debug">
|
||||
<folderInfo id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.debug.1114796322." name="/" resourcePath="">
|
||||
<toolChain id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.toolchain.debug.153006687" name="ARM Bare-Metal 32-bit Target Binary Toolchain" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.toolchain.debug">
|
||||
<option defaultValue="true" id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.option.addtools.printsize.1905262318" name="Print size" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.option.addtools.printsize" valueType="boolean"/>
|
||||
<option id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.option.target.libraries.651480840" name="Libraries support" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.option.target.libraries" value="com.nxp.s32ds.cle.arm.mbs.arm32.bare.option.target.libraries.newlib_nano_noio" valueType="enumerated"/>
|
||||
<option id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.option.target.fpu.abi.42354465" name="Float ABI" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.option.target.fpu.abi" value="com.nxp.s32ds.cle.arm.mbs.arm32.bare.option.target.fpu.abi.hard" valueType="enumerated"/>
|
||||
<option id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.option.target.fpu.unit.908063630" name="FPU Type" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.option.target.fpu.unit" value="com.nxp.s32ds.cle.arm.mbs.arm32.bare.option.target.fpu.unit.fpv4spd16" valueType="enumerated"/>
|
||||
<option id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.option.target.mcpu.1968039617" name="ARM family" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.option.target.mcpu" value="com.nxp.s32ds.cle.arm.mbs.arm32.bare.option.target.mcpu.cortex-m4" valueType="enumerated"/>
|
||||
<option id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.option.addtools.createflash.1136837679" name="Create flash image" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.option.addtools.createflash" value="true" valueType="boolean"/>
|
||||
<targetPlatform archList="all" binaryParser="org.eclipse.cdt.core.ELF" id="cdt.managedbuild.targetPlatform.gnu.cross.1028717915" isAbstract="false" osList="all" superClass="cdt.managedbuild.targetPlatform.gnu.cross"/>
|
||||
<builder buildPath="${workspace_loc:/Boot}/Debug_FLASH" id="com.freescale.s32ds.cross.gnu.builder.584425595" keepEnvironmentInBuildfile="false" managedBuildOn="true" name="FSL Make Builder" superClass="com.freescale.s32ds.cross.gnu.builder"/>
|
||||
<tool id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.compiler.504606987" name="Standard S32DS C Compiler" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.compiler">
|
||||
<option defaultValue="gnu.c.optimization.level.none" id="gnu.c.compiler.option.optimization.level.1290893599" name="Optimization Level" superClass="gnu.c.compiler.option.optimization.level" useByScannerDiscovery="false" value="gnu.c.optimization.level.optimize" valueType="enumerated"/>
|
||||
<option id="gnu.c.compiler.option.debugging.level.451375534" name="Debug Level" superClass="gnu.c.compiler.option.debugging.level" useByScannerDiscovery="false" value="gnu.c.debugging.level.max" valueType="enumerated"/>
|
||||
<option id="com.freescale.s32ds.cross.gnu.tool.c.compiler.option.optimization.functionsections.268129408" name="Function sections (-ffunction-sections)" superClass="com.freescale.s32ds.cross.gnu.tool.c.compiler.option.optimization.functionsections" useByScannerDiscovery="true" value="true" valueType="boolean"/>
|
||||
<option id="com.freescale.s32ds.cross.gnu.tool.c.compiler.option.optimization.datasections.428171903" name="Data sections (-fdata-sections)" superClass="com.freescale.s32ds.cross.gnu.tool.c.compiler.option.optimization.datasections" useByScannerDiscovery="true" value="true" valueType="boolean"/>
|
||||
<option id="com.freescale.s32ds.cross.gnu.tool.c.compiler.option.debugging.format.17081156" name="Debug format" superClass="com.freescale.s32ds.cross.gnu.tool.c.compiler.option.debugging.format" useByScannerDiscovery="true"/>
|
||||
<option id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.compiler.option.target.libraries.174976031" name="Libraries support" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.compiler.option.target.libraries" useByScannerDiscovery="false" value="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.compiler.option.target.libraries.newlib_nano_noio" valueType="enumerated"/>
|
||||
<option id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.compiler.option.target.sysroot.382554857" name="Sysroot" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.compiler.option.target.sysroot" useByScannerDiscovery="false" value="--sysroot="${S32DS_ARM32_NEWLIB_DIR}"" valueType="string"/>
|
||||
<option id="gnu.c.compiler.option.include.paths.2024519543" name="Include paths (-I)" superClass="gnu.c.compiler.option.include.paths" useByScannerDiscovery="false" valueType="includePath">
|
||||
<listOptionValue builtIn="false" value=""${ProjDirPath}""/>
|
||||
<listOptionValue builtIn="false" value=""${ProjDirPath}/lib""/>
|
||||
<listOptionValue builtIn="false" value=""${ProjDirPath}/../../../Source""/>
|
||||
<listOptionValue builtIn="false" value=""${ProjDirPath}/../../../Source/ARMCM4_S32K14""/>
|
||||
</option>
|
||||
<option id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.compiler.option.target.fpu.abi.468758466" name="Float ABI" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.compiler.option.target.fpu.abi" useByScannerDiscovery="true" value="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.compiler.option.target.fpu.abi.hard" valueType="enumerated"/>
|
||||
<option id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.compiler.option.target.fpu.unit.734871119" name="FPU Type" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.compiler.option.target.fpu.unit" useByScannerDiscovery="true" value="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.compiler.option.target.fpu.unit.fpv4spd16" valueType="enumerated"/>
|
||||
<option id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.compiler.option.target.mcpu.809490615" name="ARM family" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.compiler.option.target.mcpu" useByScannerDiscovery="true" value="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.compiler.option.target.mcpu.cortex-m4" valueType="enumerated"/>
|
||||
<option id="gnu.c.compiler.option.preprocessor.def.symbols.718611003" name="Defined symbols (-D)" superClass="gnu.c.compiler.option.preprocessor.def.symbols" useByScannerDiscovery="false" valueType="definedSymbols">
|
||||
<listOptionValue builtIn="false" value="CPU_S32K144HFT0VLLT"/>
|
||||
</option>
|
||||
<option id="gnu.c.compiler.option.dialect.std.1190301962" name="Language standard" superClass="gnu.c.compiler.option.dialect.std" useByScannerDiscovery="true" value="gnu.c.compiler.dialect.default" valueType="enumerated"/>
|
||||
<option id="com.freescale.s32ds.cross.gnu.tool.c.compiler.option.warnings.other.984039722" name="Other warning flags" superClass="com.freescale.s32ds.cross.gnu.tool.c.compiler.option.warnings.other" useByScannerDiscovery="true" value="-Wno-strict-aliasing" valueType="string"/>
|
||||
<inputType id="cdt.managedbuild.tool.gnu.c.compiler.input.177592545" superClass="cdt.managedbuild.tool.gnu.c.compiler.input"/>
|
||||
</tool>
|
||||
<tool id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.cpp.compiler.1822313129" name="Standard S32DS C++ Compiler" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.cpp.compiler">
|
||||
<option id="gnu.cpp.compiler.option.optimization.level.1978011936" name="Optimization Level" superClass="gnu.cpp.compiler.option.optimization.level" useByScannerDiscovery="false" value="gnu.cpp.compiler.optimization.level.none" valueType="enumerated"/>
|
||||
<option id="gnu.cpp.compiler.option.debugging.level.1491265174" name="Debug Level" superClass="gnu.cpp.compiler.option.debugging.level" useByScannerDiscovery="false" value="gnu.cpp.compiler.debugging.level.max" valueType="enumerated"/>
|
||||
<option id="com.freescale.s32ds.cross.gnu.tool.cpp.compiler.option.optimization.functionsections.664419985" name="Function sections (-ffunction-sections)" superClass="com.freescale.s32ds.cross.gnu.tool.cpp.compiler.option.optimization.functionsections" useByScannerDiscovery="true" value="true" valueType="boolean"/>
|
||||
<option id="com.freescale.s32ds.cross.gnu.tool.cpp.compiler.option.optimization.datasections.1307199986" name="Data sections (-fdata-sections)" superClass="com.freescale.s32ds.cross.gnu.tool.cpp.compiler.option.optimization.datasections" useByScannerDiscovery="true" value="true" valueType="boolean"/>
|
||||
<option id="com.freescale.s32ds.cross.gnu.tool.cpp.compiler.option.debugging.format.607079921" name="Debug format" superClass="com.freescale.s32ds.cross.gnu.tool.cpp.compiler.option.debugging.format" useByScannerDiscovery="true"/>
|
||||
<option id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.cpp.compiler.option.target.sysroot.574035712" name="Sysroot" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.cpp.compiler.option.target.sysroot" useByScannerDiscovery="false" value="--sysroot="${S32DS_ARM32_NEWLIB_DIR}"" valueType="string"/>
|
||||
<option id="gnu.cpp.compiler.option.include.paths.732095332" name="Include paths (-I)" superClass="gnu.cpp.compiler.option.include.paths" useByScannerDiscovery="false" valueType="includePath">
|
||||
<listOptionValue builtIn="false" value=""${ProjDirPath}/include""/>
|
||||
</option>
|
||||
<option id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.cpp.compiler.option.target.fpu.abi.2100284907" name="Float ABI" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.cpp.compiler.option.target.fpu.abi" useByScannerDiscovery="true" value="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.cpp.compiler.option.target.fpu.abi.hard" valueType="enumerated"/>
|
||||
<option id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.cpp.compiler.option.target.fpu.unit.1197398857" name="FPU Type" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.cpp.compiler.option.target.fpu.unit" useByScannerDiscovery="true" value="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.cpp.compiler.option.target.fpu.unit.fpv4spd16" valueType="enumerated"/>
|
||||
<option id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.cpp.compiler.option.target.mcpu.1603622095" name="ARM family" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.cpp.compiler.option.target.mcpu" useByScannerDiscovery="true" value="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.cpp.compiler.option.target.mcpu.cortex-m4" valueType="enumerated"/>
|
||||
<option id="gnu.cpp.compiler.option.preprocessor.def.146705593" name="Defined symbols (-D)" superClass="gnu.cpp.compiler.option.preprocessor.def" useByScannerDiscovery="false" valueType="definedSymbols">
|
||||
<listOptionValue builtIn="false" value="CPU_S32K144HFT0VLLT"/>
|
||||
</option>
|
||||
</tool>
|
||||
<tool id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.linker.966794671" name="Standard S32DS C Linker" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.linker">
|
||||
<option id="com.freescale.s32ds.cross.gnu.tool.c.linker.option.gcsections.1838041153" name="Remove unused sections (-Xlinker --gc-sections)" superClass="com.freescale.s32ds.cross.gnu.tool.c.linker.option.gcsections" value="true" valueType="boolean"/>
|
||||
<option id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.linker.option.target.libraries.1972871412" name="Libraries support" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.linker.option.target.libraries" value="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.linker.option.target.libraries.newlib_nano_noio" valueType="enumerated"/>
|
||||
<option id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.linker.option.target.sysroot.67166554" name="Sysroot" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.linker.option.target.sysroot" value="--sysroot="${S32DS_ARM32_NEWLIB_DIR}"" valueType="string"/>
|
||||
<option id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.linker.option.target.fpu.abi.529036728" name="Float ABI" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.linker.option.target.fpu.abi" value="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.linker.option.target.fpu.abi.hard" valueType="enumerated"/>
|
||||
<option id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.linker.option.target.fpu.unit.329320770" name="FPU Type" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.linker.option.target.fpu.unit" value="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.linker.option.target.fpu.unit.fpv4spd16" valueType="enumerated"/>
|
||||
<option id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.linker.option.target.mcpu.1262434396" name="ARM family" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.linker.option.target.mcpu" value="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.linker.option.target.mcpu.cortex-m4" valueType="enumerated"/>
|
||||
<option id="com.freescale.s32ds.cross.gnu.tool.c.linker.option.scriptfile.2125527303" name="Script files (-T)" superClass="com.freescale.s32ds.cross.gnu.tool.c.linker.option.scriptfile" useByScannerDiscovery="false" valueType="stringList">
|
||||
<listOptionValue builtIn="false" value=""${ProjDirPath}/S32K144_64_flash.ld""/>
|
||||
</option>
|
||||
<inputType id="com.freescale.s32ds.cross.gnu.tool.c.linker.inputType.scriptfile.1796157928" superClass="com.freescale.s32ds.cross.gnu.tool.c.linker.inputType.scriptfile"/>
|
||||
</tool>
|
||||
<tool id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.cpp.linker.1474314776" name="Standard S32DS C++ Linker" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.cpp.linker">
|
||||
<option id="com.freescale.s32ds.cross.gnu.tool.cpp.linker.option.gcsections.1679588389" name="Remove unused sections (-Xlinker --gc-sections)" superClass="com.freescale.s32ds.cross.gnu.tool.cpp.linker.option.gcsections" value="true" valueType="boolean"/>
|
||||
<option id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.cpp.linker.option.target.libraries.394192023" name="Libraries support" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.cpp.linker.option.target.libraries" value="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.cpp.linker.option.target.libraries.newlib_nano_noio" valueType="enumerated"/>
|
||||
<option id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.cpp.linker.option.target.sysroot.361370893" name="Sysroot" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.cpp.linker.option.target.sysroot" value="--sysroot="${S32DS_ARM32_NEWLIB_DIR}"" valueType="string"/>
|
||||
<option id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.cpp.linker.option.target.fpu.abi.1932808083" name="Float ABI" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.cpp.linker.option.target.fpu.abi" value="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.cpp.linker.option.target.fpu.abi.hard" valueType="enumerated"/>
|
||||
<option id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.cpp.linker.option.target.fpu.unit.1007810897" name="FPU Type" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.cpp.linker.option.target.fpu.unit" value="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.cpp.linker.option.target.fpu.unit.fpv4spd16" valueType="enumerated"/>
|
||||
<option id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.cpp.linker.option.target.mcpu.1525198649" name="ARM family" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.cpp.linker.option.target.mcpu" value="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.cpp.linker.option.target.mcpu.cortex-m4" valueType="enumerated"/>
|
||||
<option id="com.freescale.s32ds.cross.gnu.tool.cpp.linker.option.scriptfile.1843593318" name="Script files (-T)" superClass="com.freescale.s32ds.cross.gnu.tool.cpp.linker.option.scriptfile" valueType="stringList">
|
||||
<listOptionValue builtIn="false" value=""${ProjDirPath}/Project_Settings/Linker_Files/S32K144_64_flash.ld""/>
|
||||
</option>
|
||||
</tool>
|
||||
<tool id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.archiver.1775204993" name="Standard S32DS Archiver" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.archiver"/>
|
||||
<tool id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.assembler.13374493" name="Standard S32DS Assembler" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.assembler">
|
||||
<option id="com.freescale.s32ds.cross.gnu.tool.assembler.usepreprocessor.404870544" name="Use preprocessor" superClass="com.freescale.s32ds.cross.gnu.tool.assembler.usepreprocessor" value="true" valueType="boolean"/>
|
||||
<option id="com.freescale.s32ds.cross.gnu.tool.assembler.option.debugging.level.1072272733" name="Debug Level" superClass="com.freescale.s32ds.cross.gnu.tool.assembler.option.debugging.level" value="gnu.c.debugging.level.max" valueType="enumerated"/>
|
||||
<option id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.assembler.option.target.libraries.908186168" name="Libraries support" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.assembler.option.target.libraries" value="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.assembler.option.target.libraries.newlib_nano_noio" valueType="enumerated"/>
|
||||
<option id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.assembler.option.target.sysroot.1903986024" name="Sysroot" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.assembler.option.target.sysroot" value="--sysroot="${S32DS_ARM32_NEWLIB_DIR}"" valueType="string"/>
|
||||
<option id="gnu.both.asm.option.include.paths.1983539531" name="Include paths (-I)" superClass="gnu.both.asm.option.include.paths" useByScannerDiscovery="false"/>
|
||||
<option id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.assembler.option.target.fpu.abi.679863770" name="Float ABI" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.assembler.option.target.fpu.abi" value="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.assembler.option.target.fpu.abi.hard" valueType="enumerated"/>
|
||||
<option id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.assembler.option.target.fpu.unit.1034448998" name="FPU Type" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.assembler.option.target.fpu.unit" value="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.assembler.option.target.fpu.unit.fpv4spd16" valueType="enumerated"/>
|
||||
<option id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.assembler.option.target.mcpu.942301259" name="ARM family" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.assembler.option.target.mcpu" value="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.assembler.option.target.mcpu.cortex-m4" valueType="enumerated"/>
|
||||
<option id="com.freescale.s32ds.cross.gnu.tool.assembler.option.defs.1818527031" name="Defined symbols (-D)" superClass="com.freescale.s32ds.cross.gnu.tool.assembler.option.defs" valueType="definedSymbols">
|
||||
<listOptionValue builtIn="false" value="START_FROM_FLASH"/>
|
||||
</option>
|
||||
<inputType id="cdt.managedbuild.tool.gnu.assembler.input.953972897" superClass="cdt.managedbuild.tool.gnu.assembler.input"/>
|
||||
<inputType id="com.freescale.s32ds.cross.gnu.tool.assembler.inputType.asmfile.990103661" superClass="com.freescale.s32ds.cross.gnu.tool.assembler.inputType.asmfile"/>
|
||||
</tool>
|
||||
<tool id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.createflash.952588019" name="Standard S32DS Create Flash Image" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.createflash"/>
|
||||
<tool id="com.freescale.s32ds.cross.gnu.tool.createlisting.976039654" name="Standard S32DS Create Listing" superClass="com.freescale.s32ds.cross.gnu.tool.createlisting">
|
||||
<option id="com.freescale.s32ds.cross.gnu.option.createlisting.source.1268134568" name="Display source (--source|-S)" superClass="com.freescale.s32ds.cross.gnu.option.createlisting.source" value="true" valueType="boolean"/>
|
||||
<option id="com.freescale.s32ds.cross.gnu.option.createlisting.allheaders.329665463" name="Display all headers (--all-headers|-x)" superClass="com.freescale.s32ds.cross.gnu.option.createlisting.allheaders" value="true" valueType="boolean"/>
|
||||
<option id="com.freescale.s32ds.cross.gnu.option.createlisting.demangle.263807117" name="Demangle names (--demangle|-C)" superClass="com.freescale.s32ds.cross.gnu.option.createlisting.demangle" value="true" valueType="boolean"/>
|
||||
<option id="com.freescale.s32ds.cross.gnu.option.createlisting.linenumbers.1828332953" name="Display line numbers (--line-numbers|-l)" superClass="com.freescale.s32ds.cross.gnu.option.createlisting.linenumbers" value="true" valueType="boolean"/>
|
||||
<option id="com.freescale.s32ds.cross.gnu.option.createlisting.wide.1510128084" name="Wide lines (--wide|-w)" superClass="com.freescale.s32ds.cross.gnu.option.createlisting.wide" value="true" valueType="boolean"/>
|
||||
</tool>
|
||||
<tool id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.printsize.2043140614" name="Standard S32DS Print Size" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.printsize">
|
||||
<option id="com.freescale.s32ds.cross.gnu.option.printsize.format.1555766113" name="Size format" superClass="com.freescale.s32ds.cross.gnu.option.printsize.format"/>
|
||||
</tool>
|
||||
<tool id="com.freescale.s32ds.cross.gnu.c.preprocessor.1948150017" name="Standard S32DS C Preprocessor" superClass="com.freescale.s32ds.cross.gnu.c.preprocessor"/>
|
||||
<tool id="com.freescale.s32ds.cross.gnu.cpp.preprocessor.72929413" name="Standard S32DS C++ Preprocessor" superClass="com.freescale.s32ds.cross.gnu.cpp.preprocessor"/>
|
||||
<tool id="com.freescale.s32ds.cross.gnu.disassembler.1224866984" name="Standard S32DS Disassembler" superClass="com.freescale.s32ds.cross.gnu.disassembler"/>
|
||||
</toolChain>
|
||||
</folderInfo>
|
||||
<sourceEntries>
|
||||
<entry excluding="Project_Settings|include|src" flags="VALUE_WORKSPACE_PATH" kind="sourcePath" name=""/>
|
||||
</sourceEntries>
|
||||
</configuration>
|
||||
</storageModule>
|
||||
<storageModule moduleId="org.eclipse.cdt.core.externalSettings"/>
|
||||
</cconfiguration>
|
||||
</storageModule>
|
||||
<storageModule moduleId="cdtBuildSystem" version="4.0.0">
|
||||
<project id="Boot.com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.1043932079" name="ARM32 Executable" projectType="com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe"/>
|
||||
</storageModule>
|
||||
<storageModule moduleId="scannerConfiguration">
|
||||
<autodiscovery enabled="true" problemReportingEnabled="true" selectedProfileId=""/>
|
||||
<scannerConfigBuildInfo instanceId="com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.debug.ram.305184792;com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.debug.ram.305184792.;com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.compiler.144709220;cdt.managedbuild.tool.gnu.c.compiler.input.1783199954">
|
||||
<autodiscovery enabled="true" problemReportingEnabled="true" selectedProfileId=""/>
|
||||
</scannerConfigBuildInfo>
|
||||
<scannerConfigBuildInfo instanceId="com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.release.1815311679;com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.release.1815311679.;com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.compiler.1434629833;cdt.managedbuild.tool.gnu.c.compiler.input.1701945615">
|
||||
<autodiscovery enabled="true" problemReportingEnabled="true" selectedProfileId=""/>
|
||||
</scannerConfigBuildInfo>
|
||||
<scannerConfigBuildInfo instanceId="com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.release.ram.503025150;com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.release.ram.503025150.;com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.compiler.73837653;cdt.managedbuild.tool.gnu.c.compiler.input.270271911">
|
||||
<autodiscovery enabled="true" problemReportingEnabled="true" selectedProfileId=""/>
|
||||
</scannerConfigBuildInfo>
|
||||
<scannerConfigBuildInfo instanceId="com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.debug.1114796322;com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.debug.1114796322.;com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.compiler.504606987;cdt.managedbuild.tool.gnu.c.compiler.input.177592545">
|
||||
<autodiscovery enabled="true" problemReportingEnabled="true" selectedProfileId=""/>
|
||||
</scannerConfigBuildInfo>
|
||||
</storageModule>
|
||||
<storageModule moduleId="org.eclipse.cdt.core.LanguageSettingsProviders"/>
|
||||
<storageModule moduleId="org.eclipse.embsys" parent_project="true" register_architecture="" register_board="--- none ---" register_chip="" register_core="" register_vendor=""/>
|
||||
<storageModule moduleId="org.eclipse.cdt.make.core.buildtargets"/>
|
||||
<storageModule moduleId="refreshScope" versionNumber="2">
|
||||
<configuration configurationName="Release_FLASH">
|
||||
<resource resourceType="PROJECT" workspacePath="/Boot"/>
|
||||
</configuration>
|
||||
<configuration configurationName="Release_RAM">
|
||||
<resource resourceType="PROJECT" workspacePath="/Boot"/>
|
||||
</configuration>
|
||||
<configuration configurationName="Debug_FLASH">
|
||||
<resource resourceType="PROJECT" workspacePath="/Boot"/>
|
||||
</configuration>
|
||||
<configuration configurationName="Debug_RAM">
|
||||
<resource resourceType="PROJECT" workspacePath="/Boot"/>
|
||||
</configuration>
|
||||
<configuration configurationName="Debug">
|
||||
<resource resourceType="PROJECT" workspacePath="/Boot"/>
|
||||
</configuration>
|
||||
</storageModule>
|
||||
<storageModule moduleId="org.eclipse.cdt.internal.ui.text.commentOwnerProjectMappings"/>
|
||||
</cproject>
|
|
@ -0,0 +1,59 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<projectDescription>
|
||||
<name>Boot</name>
|
||||
<comment></comment>
|
||||
<projects>
|
||||
</projects>
|
||||
<buildSpec>
|
||||
<buildCommand>
|
||||
<name>org.eclipse.cdt.managedbuilder.core.genmakebuilder</name>
|
||||
<triggers>clean,full,incremental,</triggers>
|
||||
<arguments>
|
||||
</arguments>
|
||||
</buildCommand>
|
||||
<buildCommand>
|
||||
<name>org.eclipse.cdt.managedbuilder.core.ScannerConfigBuilder</name>
|
||||
<triggers>full,incremental,</triggers>
|
||||
<arguments>
|
||||
</arguments>
|
||||
</buildCommand>
|
||||
</buildSpec>
|
||||
<natures>
|
||||
<nature>org.eclipse.cdt.core.cnature</nature>
|
||||
<nature>org.eclipse.cdt.managedbuilder.core.managedBuildNature</nature>
|
||||
<nature>org.eclipse.cdt.managedbuilder.core.ScannerConfigNature</nature>
|
||||
</natures>
|
||||
<linkedResources>
|
||||
<link>
|
||||
<name>core</name>
|
||||
<type>2</type>
|
||||
<locationURI>OPENBLT_ROOT</locationURI>
|
||||
</link>
|
||||
</linkedResources>
|
||||
<filteredResources>
|
||||
<filter>
|
||||
<id>1583960353573</id>
|
||||
<name>core</name>
|
||||
<type>9</type>
|
||||
<matcher>
|
||||
<id>org.eclipse.ui.ide.multiFilter</id>
|
||||
<arguments>1.0-name-matches-false-false-ARMCM4_S32K14</arguments>
|
||||
</matcher>
|
||||
</filter>
|
||||
<filter>
|
||||
<id>1583960371701</id>
|
||||
<name>core/ARMCM4_S32K14</name>
|
||||
<type>9</type>
|
||||
<matcher>
|
||||
<id>org.eclipse.ui.ide.multiFilter</id>
|
||||
<arguments>1.0-name-matches-false-false-GCC</arguments>
|
||||
</matcher>
|
||||
</filter>
|
||||
</filteredResources>
|
||||
<variableList>
|
||||
<variable>
|
||||
<name>OPENBLT_ROOT</name>
|
||||
<value>$%7BPARENT-3-PROJECT_LOC%7D/Source</value>
|
||||
</variable>
|
||||
</variableList>
|
||||
</projectDescription>
|
|
@ -0,0 +1,8 @@
|
|||
com.nxp.s32ds.cle.runtime.component.registry.archetype.id=application
|
||||
com.nxp.s32ds.cle.runtime.component.registry.archetype.platform.id=
|
||||
com.nxp.s32ds.cle.runtime.hardware.registry.core.id=CortexM4F
|
||||
com.nxp.s32ds.cle.runtime.hardware.registry.device.id=S32K144
|
||||
com.nxp.s32ds.cle.runtime.hardware.registry.deviceCore.id=S32K144_M4F
|
||||
com.nxp.s32ds.cle.runtime.hardware.registry.family.id=S32K1
|
||||
com.nxp.s32ds.cle.runtime.lang.registry.lang.id=c
|
||||
eclipse.preferences.version=1
|
|
@ -0,0 +1,2 @@
|
|||
eclipse.preferences.version=1
|
||||
versionGenerated/versionGenerated=1.8.4.RT7_b1743-0713
|
|
@ -0,0 +1,14 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<project>
|
||||
<configuration id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.debug.1114796322" name="Debug">
|
||||
<extension point="org.eclipse.cdt.core.LanguageSettingsProvider">
|
||||
<provider copy-of="extension" id="org.eclipse.cdt.ui.UserLanguageSettingsProvider"/>
|
||||
<provider-reference id="org.eclipse.cdt.core.ReferencedProjectsLanguageSettingsProvider" ref="shared-provider"/>
|
||||
<provider-reference id="org.eclipse.cdt.managedbuilder.core.MBSLanguageSettingsProvider" ref="shared-provider"/>
|
||||
<provider class="com.freescale.s32ds.cross.gnu.CrossGCCBuiltinSpecsDetector" console="false" env-hash="1558180218410665839" id="com.freescale.s32ds.cross.gnu.CrossGCCBuiltinSpecsDetector" keep-relative-paths="false" name="CDT S32DS Built-in Compiler Settings" parameter="${COMMAND} ${FLAGS} -E -P -v -dD "${INPUTS}"" prefer-non-shared="true">
|
||||
<language-scope id="org.eclipse.cdt.core.gcc"/>
|
||||
<language-scope id="org.eclipse.cdt.core.g++"/>
|
||||
</provider>
|
||||
</extension>
|
||||
</configuration>
|
||||
</project>
|
|
@ -0,0 +1,3 @@
|
|||
eclipse.preferences.version=1
|
||||
inEditor=false
|
||||
onBuild=false
|
|
@ -0,0 +1,21 @@
|
|||
eclipse.preferences.version=1
|
||||
environment/project/com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.debug.1114796322/PATH/delimiter=;
|
||||
environment/project/com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.debug.1114796322/PATH/operation=prepend
|
||||
environment/project/com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.debug.1114796322/PATH/value=
|
||||
environment/project/com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.debug.1114796322/append=true
|
||||
environment/project/com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.debug.1114796322/appendContributed=true
|
||||
environment/project/com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.debug.ram.305184792/PATH/delimiter=;
|
||||
environment/project/com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.debug.ram.305184792/PATH/operation=prepend
|
||||
environment/project/com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.debug.ram.305184792/PATH/value=
|
||||
environment/project/com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.debug.ram.305184792/append=true
|
||||
environment/project/com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.debug.ram.305184792/appendContributed=true
|
||||
environment/project/com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.release.1815311679/PATH/delimiter=;
|
||||
environment/project/com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.release.1815311679/PATH/operation=prepend
|
||||
environment/project/com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.release.1815311679/PATH/value=
|
||||
environment/project/com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.release.1815311679/append=true
|
||||
environment/project/com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.release.1815311679/appendContributed=true
|
||||
environment/project/com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.release.ram.503025150/PATH/delimiter=;
|
||||
environment/project/com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.release.ram.503025150/PATH/operation=prepend
|
||||
environment/project/com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.release.ram.503025150/PATH/value=
|
||||
environment/project/com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.release.ram.503025150/append=true
|
||||
environment/project/com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.release.ram.503025150/appendContributed=true
|
|
@ -0,0 +1,217 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<launchConfiguration type="com.pemicro.debug.gdbjtag.pne.launchConfigurationType">
|
||||
<stringAttribute key="com.nxp.s32ds.ext.cdt.debug.svd.svd_path" value=""/>
|
||||
<booleanAttribute key="com.nxp.s32ds.ext.cdt.debug.svd.use_default" value="true"/>
|
||||
<listAttribute key="com.pemicro.debug.gdbjtag.pne.ELVES"/>
|
||||
<listAttribute key="com.pemicro.debug.gdbjtag.pne.ELVES_OFFSET"/>
|
||||
<intAttribute key="com.pemicro.debug.gdbjtag.pne.NUMBER_ELVES" value="0"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.PE.BUSERR" value="true"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.PE.CHKERR" value="true"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.PE.CORERESET" value="true"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.PE.DEVICE_NAME" value="NXP_S32K1xx_S32K144F512M15"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.PE.GDB_OPTIONS" value=""/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.PE.HARDERR" value="true"/>
|
||||
<intAttribute key="com.pemicro.debug.gdbjtag.pne.PE.HARDWARE_INTERFACE" value="0"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.PE.INTERR" value="true"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.PE.LAST_ATTRIBUTE_HEADER" value="com.pemicro.debug.gdbjtag.pne.ml."/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.PE.MMERR" value="true"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.PE.NOCPERR" value="true"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.PE.STATERR" value="true"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.PE.STREAMING_ENABLE_PORT1" value="true"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.PE.STREAMING_SERVER_PORT1" value="10224"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.PE.USE_EXTERNAL_SERVER" value="true"/>
|
||||
<intAttribute key="com.pemicro.debug.gdbjtag.pne.algorithmIndex" value="0"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.alternativeAlgorithmPath" value=""/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.attachToRunning" value="false"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.customTrimFrequency" value="0"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_eth.ALWAYS_ERASE" value="false"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_eth.CYCLONE_IP" value=""/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_eth.DO_RESET_DELAY" value="false"/>
|
||||
<intAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_eth.INTERFACE_PORT" value="0"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_eth.INTERFACE_PORT_STRING" value=""/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_eth.NETWORK_CARD_IP" value=""/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_eth.POWER_DOWN_DELAY" value="250"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_eth.POWER_OFF" value="false"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_eth.POWER_UP_DELAY" value="250"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_eth.PROVIDE_POWER" value="true"/>
|
||||
<intAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_eth.REGULATOR_VOLTAGE" value="0"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_eth.RESET_DELAY" value="0"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_eth.SHIFT_FREQ" value="5000"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_eth.SPECIFY_IP" value="false"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_eth.SPECIFY_NETWORK_CARD" value="false"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_eth.STARTUP_USE_SWD" value="true"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_ser.ALWAYS_ERASE" value="false"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_ser.CYCLONE_IP" value=""/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_ser.DO_RESET_DELAY" value="false"/>
|
||||
<intAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_ser.INTERFACE_PORT" value="0"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_ser.INTERFACE_PORT_STRING" value=""/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_ser.NETWORK_CARD_IP" value=""/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_ser.POWER_DOWN_DELAY" value="250"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_ser.POWER_OFF" value="false"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_ser.POWER_UP_DELAY" value="250"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_ser.PROVIDE_POWER" value="true"/>
|
||||
<intAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_ser.REGULATOR_VOLTAGE" value="0"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_ser.RESET_DELAY" value="0"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_ser.SHIFT_FREQ" value="5000"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_ser.SPECIFY_IP" value="false"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_ser.SPECIFY_NETWORK_CARD" value="false"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_ser.STARTUP_USE_SWD" value="true"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_usb.ALWAYS_ERASE" value="false"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_usb.CYCLONE_IP" value=""/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_usb.DO_RESET_DELAY" value="false"/>
|
||||
<intAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_usb.INTERFACE_PORT" value="0"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_usb.INTERFACE_PORT_STRING" value=""/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_usb.NETWORK_CARD_IP" value=""/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_usb.POWER_DOWN_DELAY" value="250"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_usb.POWER_OFF" value="false"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_usb.POWER_UP_DELAY" value="250"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_usb.PROVIDE_POWER" value="true"/>
|
||||
<intAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_usb.REGULATOR_VOLTAGE" value="0"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_usb.RESET_DELAY" value="0"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_usb.SHIFT_FREQ" value="5000"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_usb.SPECIFY_IP" value="false"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_usb.SPECIFY_NETWORK_CARD" value="false"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_usb.STARTUP_USE_SWD" value="true"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.doContinue" value="true"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.doGdbServerAllocateSemihostingConsole" value="true"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.doPartitioning" value="false"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.enableSemihosting" value="true"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.enableSemihostingIoclientGdbClient" value="false"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.enableSemihostingIoclientTelnet" value="true"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.eraseCommandParam" value="EM"/>
|
||||
<intAttribute key="com.pemicro.debug.gdbjtag.pne.eraseOptionIndex" value="0"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.eraseOptionsenabled" value="false"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.executeUnlockCommand" value="false"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.gdbClientOtherCommands" value="set mem inaccessible-by-default off set tcp auto-retry on set tcp connect-timeout 240 set remotetimeout 60"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.gdbClientOtherOptions" value=""/>
|
||||
<intAttribute key="com.pemicro.debug.gdbjtag.pne.gdbServerTelnetPortNumber" value="51794"/>
|
||||
<intAttribute key="com.pemicro.debug.gdbjtag.pne.gdbmiPortNumber" value="6224"/>
|
||||
<intAttribute key="com.pemicro.debug.gdbjtag.pne.jtagPreIrBits" value="0"/>
|
||||
<intAttribute key="com.pemicro.debug.gdbjtag.pne.jtagTapNumber" value="0"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.macScript" value=""/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.macScriptEnable" value="false"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.ml.ALWAYS_ERASE" value="false"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.ml.CYCLONE_IP" value=""/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.ml.DO_RESET_DELAY" value="false"/>
|
||||
<intAttribute key="com.pemicro.debug.gdbjtag.pne.ml.INTERFACE_PORT" value="0"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.ml.INTERFACE_PORT_STRING" value=""/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.ml.NETWORK_CARD_IP" value=""/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.ml.POWER_DOWN_DELAY" value="250"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.ml.POWER_OFF" value="false"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.ml.POWER_UP_DELAY" value="1000"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.ml.PROVIDE_POWER" value="true"/>
|
||||
<intAttribute key="com.pemicro.debug.gdbjtag.pne.ml.REGULATOR_VOLTAGE" value="0"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.ml.RESET_DELAY" value="0"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.ml.SHIFT_FREQ" value="5000"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.ml.SPECIFY_IP" value="false"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.ml.SPECIFY_NETWORK_CARD" value="false"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.ml.STARTUP_USE_SWD" value="true"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.ml.SWO_BAUDRATE_SWITCH_MULTILINK_VALUE" value="-1.000000"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.ml.SWO_BAUDRATE_SWITCH_TARGET_VALUE" value="-1.000000"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.otherRunCommands" value=""/>
|
||||
<intAttribute key="com.pemicro.debug.gdbjtag.pne.partitionParam" value="0"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.preserveMemory0" value="false"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.preserveMemory1" value="false"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.preserveMemory2" value="false"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.preserveMemoryFrom0" value="0"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.preserveMemoryFrom1" value="0"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.preserveMemoryFrom2" value="0"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.preserveMemoryTo0" value="3"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.preserveMemoryTo1" value="3"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.preserveMemoryTo2" value="3"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.preservePartioning" value="false"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.programtrim" value="false"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.sda.ALWAYS_ERASE" value="false"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.sda.CYCLONE_IP" value=""/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.sda.DO_RESET_DELAY" value="false"/>
|
||||
<intAttribute key="com.pemicro.debug.gdbjtag.pne.sda.INTERFACE_PORT" value="0"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.sda.INTERFACE_PORT_STRING" value="USB1"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.sda.NETWORK_CARD_IP" value=""/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.sda.POWER_DOWN_DELAY" value=""/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.sda.POWER_OFF" value="false"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.sda.POWER_UP_DELAY" value=""/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.sda.PROVIDE_POWER" value="true"/>
|
||||
<intAttribute key="com.pemicro.debug.gdbjtag.pne.sda.REGULATOR_VOLTAGE" value="0"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.sda.RESET_DELAY" value="0"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.sda.SHIFT_FREQ" value="5000"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.sda.SPECIFY_IP" value="false"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.sda.SPECIFY_NETWORK_CARD" value="false"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.sda.STARTUP_USE_SWD" value="true"/>
|
||||
<intAttribute key="com.pemicro.debug.gdbjtag.pne.selectedCoreNumber" value="1"/>
|
||||
<intAttribute key="com.pemicro.debug.gdbjtag.pne.serverPortNumber" value="7224"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.trc_eth.ALWAYS_ERASE" value="false"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.trc_eth.CYCLONE_IP" value=""/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.trc_eth.DO_RESET_DELAY" value="false"/>
|
||||
<intAttribute key="com.pemicro.debug.gdbjtag.pne.trc_eth.INTERFACE_PORT" value="0"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.trc_eth.INTERFACE_PORT_STRING" value=""/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.trc_eth.NETWORK_CARD_IP" value=""/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.trc_eth.POWER_DOWN_DELAY" value="250"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.trc_eth.POWER_OFF" value="false"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.trc_eth.POWER_UP_DELAY" value="250"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.trc_eth.PROVIDE_POWER" value="true"/>
|
||||
<intAttribute key="com.pemicro.debug.gdbjtag.pne.trc_eth.REGULATOR_VOLTAGE" value="0"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.trc_eth.RESET_DELAY" value="0"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.trc_eth.SHIFT_FREQ" value="5000"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.trc_eth.SPECIFY_IP" value="false"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.trc_eth.SPECIFY_NETWORK_CARD" value="false"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.trc_eth.STARTUP_USE_SWD" value="true"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.trc_usb.ALWAYS_ERASE" value="false"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.trc_usb.CYCLONE_IP" value=""/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.trc_usb.DO_RESET_DELAY" value="false"/>
|
||||
<intAttribute key="com.pemicro.debug.gdbjtag.pne.trc_usb.INTERFACE_PORT" value="0"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.trc_usb.INTERFACE_PORT_STRING" value=""/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.trc_usb.NETWORK_CARD_IP" value=""/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.trc_usb.POWER_DOWN_DELAY" value="250"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.trc_usb.POWER_OFF" value="false"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.trc_usb.POWER_UP_DELAY" value="250"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.trc_usb.PROVIDE_POWER" value="true"/>
|
||||
<intAttribute key="com.pemicro.debug.gdbjtag.pne.trc_usb.REGULATOR_VOLTAGE" value="0"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.trc_usb.RESET_DELAY" value="0"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.trc_usb.SHIFT_FREQ" value="5000"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.trc_usb.SPECIFY_IP" value="false"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.trc_usb.SPECIFY_NETWORK_CARD" value="false"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.trc_usb.STARTUP_USE_SWD" value="true"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.useAlternativeAlgorithm" value="false"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.useCustomTrim" value="false"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.useDaisyChain" value="false"/>
|
||||
<stringAttribute key="org.eclipse.cdt.debug.gdbjtag.core.imageFileName" value=""/>
|
||||
<stringAttribute key="org.eclipse.cdt.debug.gdbjtag.core.imageOffset" value=""/>
|
||||
<stringAttribute key="org.eclipse.cdt.debug.gdbjtag.core.ipAddress" value="localhost"/>
|
||||
<stringAttribute key="org.eclipse.cdt.debug.gdbjtag.core.jtagDevice" value="GNU ARM PEMicro Interface"/>
|
||||
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.loadImage" value="true"/>
|
||||
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.loadSymbols" value="true"/>
|
||||
<stringAttribute key="org.eclipse.cdt.debug.gdbjtag.core.pcRegister" value=""/>
|
||||
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.setPcRegister" value="false"/>
|
||||
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.setResume" value="false"/>
|
||||
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.setStopAt" value="true"/>
|
||||
<stringAttribute key="org.eclipse.cdt.debug.gdbjtag.core.stopAt" value="main"/>
|
||||
<stringAttribute key="org.eclipse.cdt.debug.gdbjtag.core.symbolsFileName" value=""/>
|
||||
<stringAttribute key="org.eclipse.cdt.debug.gdbjtag.core.symbolsOffset" value=""/>
|
||||
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.useFileForImage" value="false"/>
|
||||
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.useFileForSymbols" value="false"/>
|
||||
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.useProjBinaryForImage" value="true"/>
|
||||
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.useProjBinaryForSymbols" value="true"/>
|
||||
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.useRemoteTarget" value="true"/>
|
||||
<stringAttribute key="org.eclipse.cdt.debug.mi.core.commandFactory" value="Standard (Windows)"/>
|
||||
<stringAttribute key="org.eclipse.cdt.debug.mi.core.protocol" value="mi"/>
|
||||
<booleanAttribute key="org.eclipse.cdt.debug.mi.core.verboseMode" value="false"/>
|
||||
<stringAttribute key="org.eclipse.cdt.dsf.gdb.DEBUG_NAME" value="${S32DS_ARM32_TOOLCHAIN_DIR}/bin/${arm32_cross_prefix}gdb${arm32_cross_suffix}"/>
|
||||
<booleanAttribute key="org.eclipse.cdt.dsf.gdb.UPDATE_THREADLIST_ON_SUSPEND" value="false"/>
|
||||
<intAttribute key="org.eclipse.cdt.launch.ATTR_BUILD_BEFORE_LAUNCH_ATTR" value="2"/>
|
||||
<stringAttribute key="org.eclipse.cdt.launch.COREFILE_PATH" value=""/>
|
||||
<stringAttribute key="org.eclipse.cdt.launch.DEBUGGER_REGISTER_GROUPS" value=""/>
|
||||
<stringAttribute key="org.eclipse.cdt.launch.PROGRAM_NAME" value="Debug/openblt_s32k144.elf"/>
|
||||
<stringAttribute key="org.eclipse.cdt.launch.PROJECT_ATTR" value="Boot"/>
|
||||
<booleanAttribute key="org.eclipse.cdt.launch.PROJECT_BUILD_CONFIG_AUTO_ATTR" value="false"/>
|
||||
<stringAttribute key="org.eclipse.cdt.launch.PROJECT_BUILD_CONFIG_ID_ATTR" value="com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.debug.1114796322"/>
|
||||
<listAttribute key="org.eclipse.debug.core.MAPPED_RESOURCE_PATHS">
|
||||
<listEntry value="/Boot"/>
|
||||
</listAttribute>
|
||||
<listAttribute key="org.eclipse.debug.core.MAPPED_RESOURCE_TYPES">
|
||||
<listEntry value="4"/>
|
||||
</listAttribute>
|
||||
<stringAttribute key="org.eclipse.debug.core.source_locator_id" value="org.eclipse.cdt.debug.core.sourceLocator"/>
|
||||
<stringAttribute key="org.eclipse.debug.core.source_locator_memento" value="<?xml version="1.0" encoding="UTF-8" standalone="no"?> <sourceLookupDirector> <sourceContainers duplicates="false"> <container memento="&lt;?xml version=&quot;1.0&quot; encoding=&quot;UTF-8&quot; standalone=&quot;no&quot;?&gt;&#13;&#10;&lt;mapping backend_enabled=&quot;true&quot; name=&quot;EWL&quot;&gt;&#13;&#10;&lt;mapEntry memento=&quot;&amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;UTF-8&amp;quot; standalone=&amp;quot;no&amp;quot;?&amp;gt;&amp;#13;&amp;#10;&amp;lt;mapEntry backendPath=&amp;quot;arm32_ewl2&amp;quot; localPath=&amp;quot;C:\NXP\S32DS_ARM_v2.2\S32DS\build_tools\gcc_v6.3\arm32_ewl2&amp;quot;/&amp;gt;&amp;#13;&amp;#10;&quot;/&gt;&#13;&#10;&lt;/mapping&gt;&#13;&#10;" typeId="org.eclipse.cdt.debug.core.containerType.mapping"/> <container memento="&lt;?xml version=&quot;1.0&quot; encoding=&quot;UTF-8&quot; standalone=&quot;no&quot;?&gt;&#13;&#10;&lt;default/&gt;&#13;&#10;" typeId="org.eclipse.debug.core.containerType.default"/> </sourceContainers> </sourceLookupDirector> "/>
|
||||
<stringAttribute key="org.eclipse.dsf.launch.MEMORY_BLOCKS" value="<?xml version="1.0" encoding="UTF-8" standalone="no"?> <memoryBlockExpressionList context="reserved-for-future-use"> <gdbmemoryBlockExpression address="28672" label="0x7000"/> </memoryBlockExpressionList> "/>
|
||||
<stringAttribute key="process_factory_id" value="org.eclipse.cdt.dsf.gdb.GdbProcessFactory"/>
|
||||
</launchConfiguration>
|
Binary file not shown.
|
@ -0,0 +1,462 @@
|
|||
S01700006F70656E626C745F7333326B3134342E73726563DE
|
||||
S11300000070002029050000910500009105000002
|
||||
S1130010910500009105000091050000000000001A
|
||||
S11300200000000000000000000000009105000036
|
||||
S113003091050000000000009105000091050000FA
|
||||
S11300409105000091050000910500009105000054
|
||||
S11300509105000091050000910500009105000044
|
||||
S11300609105000091050000910500009105000034
|
||||
S11300709105000091050000910500009105000024
|
||||
S11300809105000091050000910500009105000014
|
||||
S11300909105000091050000910500009105000004
|
||||
S11300A091050000910500009105000091050000F4
|
||||
S11300B091050000910500009105000091050000E4
|
||||
S11300C091050000910500009105000091050000D4
|
||||
S11300D091050000910500009105000091050000C4
|
||||
S11300E091050000910500009105000091050000B4
|
||||
S11300F091050000910500009105000091050000A4
|
||||
S11301009105000091050000910500009105000093
|
||||
S11301109105000091050000910500009105000083
|
||||
S11301209105000091050000910500009105000073
|
||||
S11301309105000091050000910500009105000063
|
||||
S11301409105000091050000910500009105000053
|
||||
S11301509105000091050000910500009105000043
|
||||
S11301609105000091050000910500009105000033
|
||||
S11301709105000091050000910500009105000023
|
||||
S11301809105000091050000910500009105000013
|
||||
S11301909105000091050000910500009105000003
|
||||
S11301A091050000910500009105000091050000F3
|
||||
S11301B091050000910500009105000091050000E3
|
||||
S11301C091050000910500009105000091050000D3
|
||||
S11301D091050000910500009105000091050000C3
|
||||
S11301E091050000910500009105000091050000B3
|
||||
S11301F091050000910500009105000091050000A3
|
||||
S11302009105000091050000910500009105000092
|
||||
S11302109105000091050000910500009105000082
|
||||
S11302209105000091050000910500009105000072
|
||||
S11302309105000091050000910500009105000062
|
||||
S11302409105000091050000910500009105000052
|
||||
S11302509105000091050000910500009105000042
|
||||
S11302609105000091050000910500009105000032
|
||||
S11302709105000091050000910500009105000022
|
||||
S11302809105000091050000910500009105000012
|
||||
S11302909105000091050000910500009105000002
|
||||
S11302A091050000910500009105000091050000F2
|
||||
S11302B091050000910500009105000091050000E2
|
||||
S11302C091050000910500009105000091050000D2
|
||||
S11302D091050000910500009105000091050000C2
|
||||
S11302E091050000910500009105000091050000B2
|
||||
S11302F091050000910500009105000091050000A2
|
||||
S11303009105000091050000910500009105000091
|
||||
S11303109105000091050000910500009105000081
|
||||
S11303209105000091050000910500009105000071
|
||||
S11303309105000091050000910500009105000061
|
||||
S11303409105000091050000910500009105000051
|
||||
S11303509105000091050000910500009105000041
|
||||
S11303609105000091050000910500009105000031
|
||||
S11303709105000091050000910500009105000021
|
||||
S11303809105000091050000910500009105000011
|
||||
S11303909105000091050000910500009105000001
|
||||
S11303A091050000910500009105000091050000F1
|
||||
S11303B091050000910500009105000091050000E1
|
||||
S11303C091050000910500009105000091050000D1
|
||||
S11303D091050000910500009105000091050000C1
|
||||
S11303E091050000910500009105000091050000B1
|
||||
S11303F0910500009105000091050000FFFFFFFF3B
|
||||
S1130400FFFFFFFFFFFFFFFFFFFFFFFFFE7FFFFF79
|
||||
S1130410044B05481B1A062B02D9044B03B1184799
|
||||
S1130420704700BF6F84FF1F6C84FF1F0000000033
|
||||
S113043005490648091A891001EBD171491002D007
|
||||
S1130440034B03B1184770476C84FF1F6C84FF1F74
|
||||
S11304500000000010B5064C237843B9FFF7D8FF1D
|
||||
S1130460044B13B10448AFF300800123237010BD83
|
||||
S11304700000002000000000DC1B000008B5084B51
|
||||
S11304801BB108490848AFF300800848036813B952
|
||||
S1130490BDE80840CCE7064B002BF9D09847F7E7B6
|
||||
S11304A00000000004000020DC1B00006884FF1F23
|
||||
S11304B000000000154B002B08BF134B9D46A3F50D
|
||||
S11304C0803A00218B460F461348144A121A01F051
|
||||
S11304D08FFA0F4B002B00D098470E4B002B00D007
|
||||
S11304E098470020002104000D000D48002802D088
|
||||
S11304F00C48AFF3008001F057FA2000290000F007
|
||||
S1130500ADF801F03DFA00BF0000080000700020C3
|
||||
S1130510000000000000000000000020140900207A
|
||||
S1130520000000000000000072B64FF000014FF020
|
||||
S113053000024FF000034FF000044FF000054FF0AD
|
||||
S113054000064FF00007B846B946BA46BB46BC465B
|
||||
S11305500A490B4A521A013A05DD002004230860B7
|
||||
S11305601944043AFBDA0748854607488047074898
|
||||
S1130570804762B6FFF79EFFFEE700000080FF1F82
|
||||
S11305800070002000700020ED170000A918000082
|
||||
S1130590FFF7FEBF08B5054B1B6913F4805F01D05C
|
||||
S11305A0002008BD00F052F8012008BD80F00F4083
|
||||
S11305B008B5642000F006F808BD08B500F01AF884
|
||||
S11305C008BD0000084A136843F480731360074BA6
|
||||
S11305D05A6942F001025A615A6842F001025A60B3
|
||||
S11305E0034B1880704700BF00C00440C0F00F40A8
|
||||
S11305F01C00002008B500F05DFE104B1B689842FB
|
||||
S113060011D30F4B1B787BB901220D4B1A700D4A85
|
||||
S1130610936843F00103936000F04CFE0A4B1B887F
|
||||
S11306201844064B186008BD0022054B1A70054A91
|
||||
S1130630536843F001035360EEE700BF200000203D
|
||||
S11306401E000020C0F00F401C000020024A536826
|
||||
S113065043F0010353607047C0F00F4008B5464BA8
|
||||
S113066040F20112C3F804212422C3F80821D3F86C
|
||||
S1130670002112F4000FFAD101223F4BC3F80021EC
|
||||
S1130680D3F8002112F0807FFAD03B4BD3F8002638
|
||||
S113069012F4000FFAD1384BD3F8002622F00102ED
|
||||
S11306A0C3F80026D3F8042642F4407242F0020252
|
||||
S11306B0C3F804264FF4C012C3F80826D3F8002662
|
||||
S11306C012F4000FFAD12C4AD2F8003643F0010399
|
||||
S11306D0C2F800361346D3F8002612F0807FFAD011
|
||||
S11306E0254B40F20112C3F80422244A5A611A46E7
|
||||
S11306F01369C3F30363062BFAD101F095F8204B79
|
||||
S1130700D3F82C2142F08042C3F82C21D3F83021B5
|
||||
S113071042F08042C3F83021D3F8342142F08042C1
|
||||
S1130720C3F83421A3F5D0331A6B42F480721A63F0
|
||||
S11307301A6B22F002021A63124A516921F48051A1
|
||||
S11307405161916921F4805191619A6942F4007276
|
||||
S11307509A61DA6942F40072DA6103F500531A69A6
|
||||
S113076042F4A0621A615A6942F4A0625A6100F02C
|
||||
S1130770EBFD00F0F7FDFCE7004006401200010627
|
||||
S11307800050064080F00F4072B6704762B6704762
|
||||
S113079038B50D4B1B68002B00DB38BD0A4A1368C3
|
||||
S11307A023F00043136000F085FD00F1FA05064CC8
|
||||
S11307B0236813F4801FF0D000F061FE00F07AFD8E
|
||||
S11307C08542F5D2E9E700BF0040024038B5114B3D
|
||||
S11307D01B68002B18DB0F4B1A6842F080421A602A
|
||||
S11307E01A6842F080521A6000F064FD00F1FA05C4
|
||||
S11307F0084C236813F0807F05D100F040FE00F020
|
||||
S113080059FD8542F5D238BDDE21034800F05AFD7A
|
||||
S1130810E1E700BF00400240041A000070B582B056
|
||||
S1130820914AD2F8903043F08043C2F89030FFF7F9
|
||||
S1130830AFFFFFF7CBFF8D4B1B68002B13DB8B4AFD
|
||||
S1130840136843F00043136000F034FD00F1FA052F
|
||||
S1130850864C236813F4801F05D100F010FE00F0CD
|
||||
S113086029FD8542F5D2814A536823F4005353602D
|
||||
S1130870FFF78EFFFFF7AAFF00238DF80030012356
|
||||
S11308808DF8013002238DF8023004238DF80330F3
|
||||
S113089008238DF8043010238DF8053020238DF8BB
|
||||
S11308A0063040238DF80730714BD3F80431C3F37D
|
||||
S11308B002232BB94FF480726D4BC3F8042101233A
|
||||
S11308C002AA134413F8083C4FF4FA50B0FBF3F0B7
|
||||
S11308D000221446674E4FF4FA7502E00132122AE0
|
||||
S11308E01CD016F8223005FB03F3B0FBF3F103FB35
|
||||
S11308F011010029F2D1B0FBF3F39CB2631E9BB249
|
||||
S1130900FF2BEBD85B4B03EB820250789178D378C2
|
||||
S11309100CE0FE21584800F0D5FC7CE040F2871141
|
||||
S1130920554800F0CFFC002108460B464F4A556855
|
||||
S113093025F087052D042D0C55605568013C45EACA
|
||||
S1130940046454605468013800F007002043506088
|
||||
S11309505468481EC00400F460102043506050687E
|
||||
S1130960013B1B0403F4E023034353605068042950
|
||||
S113097028BF04214B1E9B0503F44003034353602B
|
||||
S1130980536843F08003536000231046194603F173
|
||||
S1130990200240F822100133802BF8D10023334881
|
||||
S11309A0194603F5087240F822100133202BF8D1C0
|
||||
S11309B02E4B1A6822F07F0242F01F021A601A6856
|
||||
S11309C042F400321A601A6842F480321A601A68DB
|
||||
S11309D022F000521A606FF02042C3F8A4284FF0AE
|
||||
S11309E08062C3F81021254AC3F8142100229A62B8
|
||||
S11309F04FF0FF321A63224A1A621A6822F4000284
|
||||
S1130A001A605A6822F4805222F008025A601B6865
|
||||
S1130A10002BFFF67EAF154B1A6822F080421A6055
|
||||
S1130A201A6822F080521A6000F044FC00F1FA05C2
|
||||
S1130A300E4C236813F0807F05D000F020FD00F0F9
|
||||
S1130A4039FC8542F5D200F035FC00F1FA05074C7B
|
||||
S1130A50236813F0006F05D000F011FD00F02AFCAC
|
||||
S1130A608542F5D202B070BD0050064000400240FD
|
||||
S1130A7000400640481A0000041A000000009C19B7
|
||||
S1130A8006003B0038B5264B4FF480721A63D3F846
|
||||
S1130A90002122F06042C3F80021D3F8002122F49F
|
||||
S1130AA04012C3F80021D3F8002142F48002C3F8B5
|
||||
S1130AB00021D3F8002122F47022C3F80021D3F8D6
|
||||
S1130AC000410A0402F470222243C3F8002161B1F8
|
||||
S1130AD001380023134D10F8014F83F00302D2B202
|
||||
S1130AE054550133DAB29142F5D80D4B0E4AC3F88E
|
||||
S1130AF00421D3F8002142F04062C3F8002100F041
|
||||
S1130B00D9FB00F13205064C236B13F4807F05D129
|
||||
S1130B1000F0B5FC00F0CEFB8542F5D238BD00BF35
|
||||
S1130B2000400240084102400000841F124B1B6B2E
|
||||
S1130B3013F4007F1DD010B40F4BD3F81031C3F35E
|
||||
S1130B4003430B7053B100230C4C83F00302125D7A
|
||||
S1130B50C2540133DBB20A789A42F6D8064B4FF4FA
|
||||
S1130B6000721A639A68064B1A6001205DF8044B00
|
||||
S1130B7070470020704700BF004002401841024007
|
||||
S1130B802400002008B5FFF7FFFD08BD08B500F0FC
|
||||
S1130B905AFA00B908BDFFF7FDFC0028FAD000F0AE
|
||||
S1130BA025FC00F073FB00F052FA20F0604020F0C6
|
||||
S1130BB07F004FF0E023C3F8080DFFF7E7FD00F0D6
|
||||
S1130BC046FA43689847E5E772B170B50D46531E7F
|
||||
S1130BD09BB2441E1E1815F8013B04F8013F00F0B7
|
||||
S1130BE04EFCB442F7D170BD70470000F8B506461C
|
||||
S1130BF00A4D002403E001340C35152C0AD0E7B269
|
||||
S1130C0000F03DFC2B68B342F5D86A6813449E4259
|
||||
S1130C10F1D200E0FF273846F8BD00BF901A00006B
|
||||
S1130C202DE9F04F83B081460068FFF7DFFFFF280E
|
||||
S1130C3005D100230193019803B0BDE8F08FCA46A3
|
||||
S1130C4009F5806B4E4601230193284D07E00023EC
|
||||
S1130C50019301E00023019308365E45EBD0A6EB37
|
||||
S1130C600A08D9F8007008EB070400F008FC2B7898
|
||||
S1130C7013F0800F33D04FF070032B704FF0070345
|
||||
S1130C80EB71C4F30743AB71C4F307236B71E3B295
|
||||
S1130C902B7133792B7273796B72B379AB72F379ED
|
||||
S1130CA0EB72337A2B73737A6B73B37AAB73F37A15
|
||||
S1130CB0EB7300F0A1FF2B7813F0710F12D118F829
|
||||
S1130CC0072033799A42C2D1331DE01D14F8011F65
|
||||
S1130CD013F8012F9142BDD18442F7D1BCE7002320
|
||||
S1130CE00193A8E700230193A5E700BF0000024099
|
||||
S1130CF038B50D46114B98420BD00446B1F5005F50
|
||||
S1130D0009D0FFF78DFF10B134B9204638BD00205B
|
||||
S1130D1038BD0B4C00E0094CC5F3090363B92368E3
|
||||
S1130D209D4207D0204640F8045B4FF48062294678
|
||||
S1130D30FFF74AFF204638BD002038BD2C040020B0
|
||||
S1130D40280000202DE9F04106460C4617461D46B2
|
||||
S1130D5021F47F7828F003080368B3F1FF3F0BD038
|
||||
S1130D603368984510D041463046FFF7C1FF064628
|
||||
S1130D7050B90020BDE8F08140F8048B4FF4806244
|
||||
S1130D804146FFF721FFEBE704343368E41A3444A7
|
||||
S1130D9008F5806805E017F8013B04F8013B013DC4
|
||||
S1130DA00ED000F06CFB331DE31AB3F5806FF2D361
|
||||
S1130DB041463046FFF79CFF064620B1041DEAE792
|
||||
S1130DC00120BDE8F0810020BDE8F0814FF0FF3341
|
||||
S1130DD0024A1360024A1360704700BF28000020D3
|
||||
S1130DE02C04002070B54B1EC0F5FF2404F2FF74E0
|
||||
S1130DF0A34201D9002070BD16460D460446FFF7F4
|
||||
S1130E00F5FEFF28F6D0601E2844FFF7EFFEFF280A
|
||||
S1130E10F0D024F47F7323F00303B3F5005F06D00E
|
||||
S1130E202B46324621460548FFF78CFF70BD2B4602
|
||||
S1130E30324621460248FFF785FF70BD2800002096
|
||||
S1130E402C0400204A1EC0F5FF2303F2FF739A42CC
|
||||
S1130E5001D9002070472DE9F0470D460446FFF7FD
|
||||
S1130E60C5FE0646601E2844FFF7C0FEFF2E66D06E
|
||||
S1130E70FF2864D0864202D90020BDE8F0871428F8
|
||||
S1130E804ED8324A06EB460902EB8909711C831BD2
|
||||
S1130E9051FA83F303EB430302EB830A2C4C4FF028
|
||||
S1130EA0700803E009F10C09CA4536D000F0E7FAEE
|
||||
S1130EB0D9F80050D9F80430B5F1FF3F33D0ABB3C3
|
||||
S1130EC0C5F30B02AABBC3F30B02AABBC3F30733DC
|
||||
S1130ED0002BE7D0013BDBB205F5805606EB033669
|
||||
S1130EE0092700F0CCFA237813F0800F2AD084F875
|
||||
S1130EF00080E771C5F30743A371C5F3072363714A
|
||||
S1130F00EBB2237100F078FE237813F0710F19D13E
|
||||
S1130F1005F58055AE42E4D1C4E70120BDE8F08771
|
||||
S1130F200020BDE8F0870020BDE8F0870020BDE880
|
||||
S1130F30F0870020BDE8F0870020BDE8F08700209E
|
||||
S1130F40BDE8F0870020BDE8F08700BF901A0000DC
|
||||
S1130F5000000240114B1B68B3F1FF3F1BD000B5EA
|
||||
S1130F6083B00E4A536891680B44D1680B441169ED
|
||||
S1130F700B4451690B4491690B44D26913445B429D
|
||||
S1130F8002AA42F8043D042142F2F830FFF72AFF96
|
||||
S1130F9003B05DF804FB0120704700BF2C0400205F
|
||||
S1130FA04FF400531B6842F204021268134442F2E5
|
||||
S1130FB008021268134442F20C021268134442F20B
|
||||
S1130FC010021268134442F214021268134442F2EB
|
||||
S1130FD018021268134442F2F8321268D3420CBF6A
|
||||
S1130FE0012000207047000008B50D4B1B68B3F1C9
|
||||
S1130FF0FF3F06D00A48FFF713FE034608B9184618
|
||||
S113100008BD084B1B68B3F1FF3F06D00548FFF746
|
||||
S113101007FE031C18BF0123F1E70123EFE700BF1C
|
||||
S11310202C040020280000204FF40050704708B51D
|
||||
S1131030FFF7CCFE08BD08B5FFF7D4FE08BD08B520
|
||||
S1131040FFF700FF08BD08B5FFF7AAFF08BD08B504
|
||||
S1131050FFF7EAFF08BD08B5FFF77CFF034608B9B0
|
||||
S1131060184608BDFFF7C0FF0346F9E738B5094B3A
|
||||
S1131070D86100F01FF900F10A05064C636913F406
|
||||
S1131080000F05D100F0FBF900F014F98542F5D208
|
||||
S113109038BD00BF00B0064082B000238DF8003098
|
||||
S11310A001238DF8013002238DF8023004238DF8DA
|
||||
S11310B0033008238DF8043010238DF805302023E5
|
||||
S11310C08DF8063040238DF80730254BD3F8AC213A
|
||||
S11310D022F08042C3F8AC21D3F8AC2142F0844220
|
||||
S11310E0C3F8AC21A3F58053D3F80422C2F302223F
|
||||
S11310F03AB91A46D3F8043243F48073C2F804327E
|
||||
S11311000122184BD3F8081201F001011648174BBD
|
||||
S1131110002908BF034602A90A4412F8082CB3FBAD
|
||||
S1131120F2F3134AA2FB0323DB0B0733C3F3CC0311
|
||||
S113113043F0E0630F4A13610F4B53610023936143
|
||||
S1131140136253624FF470339362936A43F08803DB
|
||||
S113115093620123D3624FF44023936102B070473A
|
||||
S1131160005006400040064080841E0000127A00B1
|
||||
S1131170C5B3A29100B0064000C01FC070B50646BA
|
||||
S11311800D46402911D82846FFF770FFADB25DB176
|
||||
S1131190741E013D16FA85F500F071F914F8010F7B
|
||||
S11311A0FFF764FFAC42F7D170BDC821014800F0DD
|
||||
S11311B089F8E8E78C1B000070B5254B1C78C4B98E
|
||||
S11311C0244B5B6913F4001F27D0224BDB69DBB28D
|
||||
S11311D0214A1370013BDBB23F2B1ED800F06AF8A2
|
||||
S11311E01E4B186000221E4B1A700122184B1A70F5
|
||||
S11311F013E00D46174B5B6913F4001F1AD018490E
|
||||
S11312000A78144BDE69144B9C1866700132D2B212
|
||||
S11312100A701B78934202D00024204670BD114905
|
||||
S1131220FFF7D2FC00220A4B1A700D4B1B782B706F
|
||||
S11312300124F2E700F03EF8084B1B68643398423F
|
||||
S113124003D90024024B1C70E7E70024E5E700BF44
|
||||
S11312507108002000B00640300800207408002007
|
||||
S11312607208002031080020054B00221A6005494D
|
||||
S113127059609A6005211960034B1A60704700BFDA
|
||||
S113128010E000E07F380100780800200022014BC4
|
||||
S11312901A60704710E000E0044B1B6813F4803FB1
|
||||
S11312A003D0034A136801331360704710E000E071
|
||||
S11312B07808002008B5FFF7EFFF014B186808BD58
|
||||
S11312C07808002008B500F0DAF8FCE708B500F06B
|
||||
S11312D0CBF8012803D00B4B1B78012B00D008BDA1
|
||||
S11312E0FFF7E8FF084B1B68084A1268134403F52C
|
||||
S11312F0FA739842F3D30022024B1A70FFF746FCAC
|
||||
S1131300EDE700BF800800207C080020840800204E
|
||||
S113131008B5054B1B78012B00D008BDFFF7CAFFA9
|
||||
S1131320024B1860F9E700BF800800208408002001
|
||||
S113133008B50122034B1A70FFF7EAFFFFF7C6FF57
|
||||
S113134008BD00BF8008002008B5FFF71BFC00F0B3
|
||||
S113135092F8FFF789FFFFF76AFE00F00DF8FFF738
|
||||
S1131360E7FF08BD08B500F08AF8FFF795FF00F025
|
||||
S113137013F8FFF7ABFF08BD10B500F08FF8FFF7C7
|
||||
S11313804DFA044C01232370FFF786FE00232370DB
|
||||
S113139010BD00BF0084FF1F00B583B00DF107012D
|
||||
S11313A01048FFF7C3FB012809D00DF107010D48D0
|
||||
S11313B0FFF702FF01280BD003B05DF804FB012204
|
||||
S11313C0094B1A709DF80710064800F085F8ECE701
|
||||
S11313D00022054B1A709DF80710024800F07CF8B3
|
||||
S11313E0EAE700BF880800200084FF1F7047000060
|
||||
S11313F038B504460D46094B1B78012B05D0074B25
|
||||
S11314001B7833B100F060F838BDC9B2FFF73AFB7E
|
||||
S1131410F5E7E9B22046FFF7B1FEF3E70084FF1FCA
|
||||
S1131420074B1B78022B06D0032B06D0012B0CBFD5
|
||||
S1131430082040207047002070470020704700BFFC
|
||||
S11314400084FF1F074B1B78022B06D0032B06D00A
|
||||
S1131450012B0CBF0820402070470020704700205B
|
||||
S1131460704700BF0084FF1F08B500F025F8003066
|
||||
S113147018BF012008BD08B5FFF79AF808BD08B5E4
|
||||
S1131480FFF79BF808BD0000034BFE22DA701871C9
|
||||
S11314900222A3F844207047C8080020054B00220C
|
||||
S11314A01A709A6483F84320A3F844209A705A70FF
|
||||
S11314B0704700BFC8080020024B1878003018BFDE
|
||||
S11314C001207047C80800200022024B83F8432003
|
||||
S11314D0704700BFC808002070B50378FF2B05D003
|
||||
S11314E00446AC4A1278012A27D070BDA94C0023C7
|
||||
S11314F0637001252570FF22E2701022227163714E
|
||||
S1131500FFF78EFFA071FFF79DFFE071FFF79AFFD1
|
||||
S1131510000A20726572A5720823A4F84430FFF70C
|
||||
S113152086FD9C4B93F84330012B00F05981994B75
|
||||
S1131530B3F944100029D8DD83E0C93B352B00F210
|
||||
S11315404B81DFE813F0D10049014901450149010C
|
||||
S113155049013C01EC002B011701490149014901F2
|
||||
S11315604901490149014901490149014901490127
|
||||
S11315704901490149014901490149014901490117
|
||||
S11315804901490149014901490149014901490107
|
||||
S113159049014901490149014901870051003600C7
|
||||
S11315A06D00490149014901A5004901B500B9008F
|
||||
S11315B0C7004578FFF734FF0138854210DC754DCC
|
||||
S11315C06278A96C281DFFF7FFFAFF23EB7062789D
|
||||
S11315D0AB6C1344AB6463780133A5F84430A0E7E3
|
||||
S11315E02220FFF751FF9CE74578FFF719FF0138E8
|
||||
S11315F0854211DC6168674DA9646278281DFFF794
|
||||
S1131600E3FAFF23EB706278AB6C1344AB6463784A
|
||||
S11316100133A5F8443084E72220FFF735FF80E743
|
||||
S11316205C4BFF22DA7042689A640122A3F84420DA
|
||||
S1131630584B93F84330012B00F0D280554BB3F94B
|
||||
S113164044105448012380F8433089B20330FFF733
|
||||
S1131650CFFE70BD4F4BFF22DA709D6C4668AEB171
|
||||
S11316602E44002415F8013B1C44E4B2FFF707FFA5
|
||||
S1131670B542F7D1474BC3F8074001221A71002243
|
||||
S11316805A719A710822A3F84420D1E70024F1E7A3
|
||||
S1131690404BFF22DA70404A9A6400221A715A7150
|
||||
S11316A09A710722C3F807200822A3F84420BFE751
|
||||
S11316B00020FFF7E9FE34E7364BFF22DA70002200
|
||||
S11316C01A71597859719A71DA711A720622A3F84B
|
||||
S11316D04420ADE72F4B00221A705A70FF22DA70B3
|
||||
S11316E00122A3F84420A3E72A4B9D6CFFF798FE40
|
||||
S11316F0621C411E2846FFF79EFC60B1254CFF2367
|
||||
S1131700E370FFF78DFE0138A36C0344A364012347
|
||||
S1131710A4F844308CE73120FFF7B6FE01E74578A2
|
||||
S1131720FFF77EFE0238854210DC1A4BFF22DA7086
|
||||
S11317300122A3F84420617861B9FFF78CFC0028EA
|
||||
S11317407FF4EFAE3120FFF79FFEEAE62220FFF799
|
||||
S11317509BFEE6E6A21C0F4B986CFFF76CFC28B1CD
|
||||
S11317600C4A6178936C0B449364DAE63120FFF7FA
|
||||
S11317708BFED6E6074CFF23E370002525716571C7
|
||||
S1131780FFF74EFEA071E571257265720723A4F878
|
||||
S113179044304DE7C8080020D01B00004168124BBC
|
||||
S11317A0986CFFF74CFC30B10F4BFF22DA7001222A
|
||||
S11317B0A3F844203CE73120FFF766FEB1E6FFF7CB
|
||||
S11317C0E5F9094BFF22DA700122A3F844202FE740
|
||||
S11317D03120FFF759FEA4E62020FFF755FEA0E6CE
|
||||
S11317E01020FFF751FEA2E6C80800204FF0E023C6
|
||||
S11317F0D3F8882D42F47002C3F8882DD3F8342F1F
|
||||
S113180022F08042C3F8342F054B064A5A605A68C6
|
||||
S113181042F220121A604FF6FF729A60704700BFBE
|
||||
S11318200020054020C528D91B4B1A691B69C3F346
|
||||
S11318300363013B052B2ED8DFE803F025030D2DB0
|
||||
S11318402D12154BD3F8083203F00103002B134972
|
||||
S113185018BF0B4618E0104BD3F80833104B13E0B5
|
||||
S11318600D4BD3F80816D3F80836C3F3044303F139
|
||||
S113187010000A4B03FB00F3C1F3022101314900BC
|
||||
S1131880B3FBF1F300E0054BC2F303420132B3FBB7
|
||||
S1131890F2F3044A136070470040064000127A00D5
|
||||
S11318A0006CDC020484FF1F264B274A9A4208D0AE
|
||||
S11318B013462448254A13F8011B02F8011B9842D9
|
||||
S11318C0F9D1234B234A9A4208D013462048224A8E
|
||||
S11318D013F8011B02F8011B8342F9D11F4B204A64
|
||||
S11318E09A4206D0134600211C4A03F8011B934276
|
||||
S11318F0FBD11C4B1C4A9A4208D0134619481B4A78
|
||||
S113190013F8011B02F8011B8342F9D1184B194A41
|
||||
S11319109A4212D010B4184CA40808D019460023D7
|
||||
S113192051F8040B42F8040B0133A342F8D1134BD2
|
||||
S1131930104A1A605DF8044B7047104B0C4A1A6049
|
||||
S1131940704700BF7C1C0000101C00000084FF1FB7
|
||||
S1131950941C00007C1C00006C84FF1F14090020F0
|
||||
S113196000000020941C0000941C000000000020D3
|
||||
S1131970000000000080FF1F0004000008ED00E0EC
|
||||
S113198008B5074B044613B10021AFF30080054BA3
|
||||
S11319901868836A03B19847204600F031F800BF05
|
||||
S11319A000000000D81B000070B50D4E0D4CA41BA8
|
||||
S11319B0A4100025A54209D10B4E0C4C00F00EF9E1
|
||||
S11319C0A41BA4100025A54205D170BD56F82530EE
|
||||
S11319D098470135EEE756F8253098470135F2E788
|
||||
S11319E0081C0000081C0000081C00000C1C00005F
|
||||
S11319F002440346934200D1704703F8011BF9E700
|
||||
S1131A00FEE70000433A2F576F726B2F736F6674B3
|
||||
S1131A10776172652F4F70656E424C545F53333259
|
||||
S1131A204B31342F5461726765742F536F75726331
|
||||
S1131A30652F41524D434D345F5333324B31342F74
|
||||
S1131A4063616E2E630000000803020209030302AF
|
||||
S1131A500A0303030B0403030C0404030D0504032A
|
||||
S1131A600E0504040F0604041006050411070504FA
|
||||
S1131A7012070505130805051408060515080705CA
|
||||
S1131A80160807061708080618080807190808089A
|
||||
S1131A9000200000001000000200000000300000E0
|
||||
S1131AA000100000030000000040000000100000CF
|
||||
S1131AB004000000005000000010000005000000B9
|
||||
S1131AC0006000000010000006000000007000002C
|
||||
S1131AD000100000070000000080000000800000EB
|
||||
S1131AE00800000000000100008000000900000060
|
||||
S1131AF000800100008000000A00000000000200D5
|
||||
S1131B00008000000B000000008002000080000044
|
||||
S1131B100C00000000000300008000000D00000025
|
||||
S1131B2000800300008000000E000000000004009C
|
||||
S1131B30008000000F00000000800400008000000E
|
||||
S1131B4010000000000005000080000011000000EB
|
||||
S1131B500080050000800000120000000000060064
|
||||
S1131B6000800000130000000080060000800000D8
|
||||
S1131B7014000000000007000080000015000000B1
|
||||
S1131B80008007000080000016000000433A2F5731
|
||||
S1131B906F726B2F736F6674776172652F4F706508
|
||||
S1131BA06E424C545F5333324B31342F546172675D
|
||||
S1131BB065742F536F757263652F41524D434D34D5
|
||||
S1131BC05F5333324B31342F72733233322E63000E
|
||||
S1131BD04F70656E424C54000884FF1FF8B500BF77
|
||||
S1131BE0F8BC08BC9E467047F8B500BFF8BC08BCFA
|
||||
S1131BF09E467047000000005FF800F06D84FF1FF0
|
||||
S10B1C00B4E8FF7F01000000BD
|
||||
S1071C087D04000053
|
||||
S1071C0C5504000077
|
||||
S1131C1004000000006CDC02000000000000000072
|
||||
S1131C2000000000000000000000000000000000B0
|
||||
S1131C3000000000000000000000000000000000A0
|
||||
S1131C400000000000000000000000000000000090
|
||||
S1131C500000000000000000000000000000000080
|
||||
S1131C600000000000000000000000000000000070
|
||||
S10F1C7000000000000000000000000064
|
||||
S1131C7C044A137843F080031370137813F0800F25
|
||||
S10B1C8CFBD070470000024088
|
||||
S9030529CE
|
|
@ -0,0 +1,280 @@
|
|||
/*
|
||||
** ###################################################################
|
||||
** Processor: S32K144 with 64 KB SRAM
|
||||
** Compiler: GNU C Compiler
|
||||
**
|
||||
** Abstract:
|
||||
** Linker file for the GNU C Compiler
|
||||
**
|
||||
** Copyright (c) 2015-2016 Freescale Semiconductor, Inc.
|
||||
** Copyright 2017 NXP
|
||||
** All rights reserved.
|
||||
**
|
||||
** THIS SOFTWARE IS PROVIDED BY NXP "AS IS" AND ANY EXPRESSED OR
|
||||
** IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
|
||||
** OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
|
||||
** IN NO EVENT SHALL NXP OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
|
||||
** INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
|
||||
** (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
|
||||
** SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
||||
** HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
|
||||
** STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING
|
||||
** IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
|
||||
** THE POSSIBILITY OF SUCH DAMAGE.
|
||||
**
|
||||
** http: www.freescale.com
|
||||
** mail: support@freescale.com
|
||||
**
|
||||
** ###################################################################
|
||||
*/
|
||||
|
||||
/* Entry Point */
|
||||
ENTRY(Reset_Handler)
|
||||
/*
|
||||
To use "new" operator with EWL in C++ project the following symbol shall be defined
|
||||
*/
|
||||
/*EXTERN(_ZN10__cxxabiv119__terminate_handlerE)*/
|
||||
|
||||
|
||||
HEAP_SIZE = DEFINED(__heap_size__) ? __heap_size__ : 0x00000400;
|
||||
STACK_SIZE = DEFINED(__stack_size__) ? __stack_size__ : 0x00000400;
|
||||
|
||||
/* If symbol __flash_vector_table__=1 is defined at link time
|
||||
* the interrupt vector will not be copied to RAM.
|
||||
* Warning: Using the interrupt vector from Flash will not allow
|
||||
* INT_SYS_InstallHandler because the section is Read Only.
|
||||
*/
|
||||
M_VECTOR_RAM_SIZE = DEFINED(__flash_vector_table__) ? 0x0 : 0x0400;
|
||||
|
||||
/* Specify the memory areas */
|
||||
MEMORY
|
||||
{
|
||||
/* Flash */
|
||||
m_interrupts (RX) : ORIGIN = 0x00000000, LENGTH = 0x00000400
|
||||
m_flash_config (RX) : ORIGIN = 0x00000400, LENGTH = 0x00000010
|
||||
m_text (RX) : ORIGIN = 0x00000410, LENGTH = 0x00001BF0
|
||||
|
||||
/* SRAM_L */
|
||||
m_data (RW) : ORIGIN = 0x1FFF8000, LENGTH = 0x00008000
|
||||
|
||||
/* SRAM_U */
|
||||
m_data_2 (RW) : ORIGIN = 0x20000000, LENGTH = 0x00007000
|
||||
}
|
||||
|
||||
/* Define output sections */
|
||||
SECTIONS
|
||||
{
|
||||
/* The startup code goes first into internal flash */
|
||||
.interrupts :
|
||||
{
|
||||
__VECTOR_TABLE = .;
|
||||
__interrupts_start__ = .;
|
||||
. = ALIGN(4);
|
||||
KEEP(*(.isr_vector)) /* Startup code */
|
||||
__interrupts_end__ = .;
|
||||
. = ALIGN(4);
|
||||
} > m_interrupts
|
||||
|
||||
.flash_config :
|
||||
{
|
||||
. = ALIGN(4);
|
||||
KEEP(*(.FlashConfig)) /* Flash Configuration Field (FCF) */
|
||||
. = ALIGN(4);
|
||||
} > m_flash_config
|
||||
|
||||
/* The program code and other data goes into internal flash */
|
||||
.text :
|
||||
{
|
||||
. = ALIGN(4);
|
||||
*(.text) /* .text sections (code) */
|
||||
*(.text*) /* .text* sections (code) */
|
||||
*(.rodata) /* .rodata sections (constants, strings, etc.) */
|
||||
*(.rodata*) /* .rodata* sections (constants, strings, etc.) */
|
||||
*(.glue_7) /* glue arm to thumb code */
|
||||
*(.glue_7t) /* glue thumb to arm code */
|
||||
*(.eh_frame)
|
||||
KEEP (*(.init))
|
||||
KEEP (*(.fini))
|
||||
. = ALIGN(4);
|
||||
} > m_text
|
||||
|
||||
.ARM.extab :
|
||||
{
|
||||
*(.ARM.extab* .gnu.linkonce.armextab.*)
|
||||
} > m_text
|
||||
|
||||
.ARM :
|
||||
{
|
||||
__exidx_start = .;
|
||||
*(.ARM.exidx*)
|
||||
__exidx_end = .;
|
||||
} > m_text
|
||||
|
||||
.ctors :
|
||||
{
|
||||
__CTOR_LIST__ = .;
|
||||
/* gcc uses crtbegin.o to find the start of
|
||||
the constructors, so we make sure it is
|
||||
first. Because this is a wildcard, it
|
||||
doesn't matter if the user does not
|
||||
actually link against crtbegin.o; the
|
||||
linker won't look for a file to match a
|
||||
wildcard. The wildcard also means that it
|
||||
doesn't matter which directory crtbegin.o
|
||||
is in. */
|
||||
KEEP (*crtbegin.o(.ctors))
|
||||
KEEP (*crtbegin?.o(.ctors))
|
||||
/* We don't want to include the .ctor section from
|
||||
from the crtend.o file until after the sorted ctors.
|
||||
The .ctor section from the crtend file contains the
|
||||
end of ctors marker and it must be last */
|
||||
KEEP (*(EXCLUDE_FILE(*crtend?.o *crtend.o) .ctors))
|
||||
KEEP (*(SORT(.ctors.*)))
|
||||
KEEP (*(.ctors))
|
||||
__CTOR_END__ = .;
|
||||
} > m_text
|
||||
|
||||
.dtors :
|
||||
{
|
||||
__DTOR_LIST__ = .;
|
||||
KEEP (*crtbegin.o(.dtors))
|
||||
KEEP (*crtbegin?.o(.dtors))
|
||||
KEEP (*(EXCLUDE_FILE(*crtend?.o *crtend.o) .dtors))
|
||||
KEEP (*(SORT(.dtors.*)))
|
||||
KEEP (*(.dtors))
|
||||
__DTOR_END__ = .;
|
||||
} > m_text
|
||||
|
||||
.preinit_array :
|
||||
{
|
||||
PROVIDE_HIDDEN (__preinit_array_start = .);
|
||||
KEEP (*(.preinit_array*))
|
||||
PROVIDE_HIDDEN (__preinit_array_end = .);
|
||||
} > m_text
|
||||
|
||||
.init_array :
|
||||
{
|
||||
PROVIDE_HIDDEN (__init_array_start = .);
|
||||
KEEP (*(SORT(.init_array.*)))
|
||||
KEEP (*(.init_array*))
|
||||
PROVIDE_HIDDEN (__init_array_end = .);
|
||||
} > m_text
|
||||
|
||||
.fini_array :
|
||||
{
|
||||
PROVIDE_HIDDEN (__fini_array_start = .);
|
||||
KEEP (*(SORT(.fini_array.*)))
|
||||
KEEP (*(.fini_array*))
|
||||
PROVIDE_HIDDEN (__fini_array_end = .);
|
||||
} > m_text
|
||||
|
||||
__etext = .; /* Define a global symbol at end of code. */
|
||||
__DATA_ROM = .; /* Symbol is used by startup for data initialization. */
|
||||
.interrupts_ram :
|
||||
{
|
||||
. = ALIGN(4);
|
||||
__VECTOR_RAM__ = .;
|
||||
__RAM_START = .;
|
||||
__interrupts_ram_start__ = .; /* Create a global symbol at data start. */
|
||||
*(.m_interrupts_ram) /* This is a user defined section. */
|
||||
. += M_VECTOR_RAM_SIZE;
|
||||
. = ALIGN(4);
|
||||
__interrupts_ram_end__ = .; /* Define a global symbol at data end. */
|
||||
} > m_data
|
||||
|
||||
__VECTOR_RAM = DEFINED(__flash_vector_table__) ? ORIGIN(m_interrupts) : __VECTOR_RAM__ ;
|
||||
__RAM_VECTOR_TABLE_SIZE = DEFINED(__flash_vector_table__) ? 0x0 : (__interrupts_ram_end__ - __interrupts_ram_start__) ;
|
||||
|
||||
.data : AT(__DATA_ROM)
|
||||
{
|
||||
. = ALIGN(4);
|
||||
__DATA_RAM = .;
|
||||
__data_start__ = .; /* Create a global symbol at data start. */
|
||||
*(.data) /* .data sections */
|
||||
*(.data*) /* .data* sections */
|
||||
KEEP(*(.jcr*))
|
||||
. = ALIGN(4);
|
||||
__data_end__ = .; /* Define a global symbol at data end. */
|
||||
} > m_data
|
||||
|
||||
__DATA_END = __DATA_ROM + (__data_end__ - __data_start__);
|
||||
__CODE_ROM = __DATA_END; /* Symbol is used by code initialization. */
|
||||
.code : AT(__CODE_ROM)
|
||||
{
|
||||
. = ALIGN(4);
|
||||
__CODE_RAM = .;
|
||||
__code_start__ = .; /* Create a global symbol at code start. */
|
||||
__code_ram_start__ = .;
|
||||
*(.code_ram) /* Custom section for storing code in RAM */
|
||||
. = ALIGN(4);
|
||||
__code_end__ = .; /* Define a global symbol at code end. */
|
||||
__code_ram_end__ = .;
|
||||
} > m_data
|
||||
|
||||
__CODE_END = __CODE_ROM + (__code_end__ - __code_start__);
|
||||
__CUSTOM_ROM = __CODE_END;
|
||||
|
||||
/* Custom Section Block that can be used to place data at absolute address. */
|
||||
/* Use __attribute__((section (".customSection"))) to place data here. */
|
||||
.customSectionBlock ORIGIN(m_data_2) : AT(__CUSTOM_ROM)
|
||||
{
|
||||
__customSection_start__ = .;
|
||||
KEEP(*(.customSection)) /* Keep section even if not referenced. */
|
||||
__customSection_end__ = .;
|
||||
} > m_data_2
|
||||
__CUSTOM_END = __CUSTOM_ROM + (__customSection_end__ - __customSection_start__);
|
||||
|
||||
/* Uninitialized data section. */
|
||||
.bss :
|
||||
{
|
||||
/* This is used by the startup in order to initialize the .bss section. */
|
||||
. = ALIGN(4);
|
||||
__BSS_START = .;
|
||||
__bss_start__ = .;
|
||||
*(.bss)
|
||||
*(.bss*)
|
||||
*(COMMON)
|
||||
. = ALIGN(4);
|
||||
__bss_end__ = .;
|
||||
__BSS_END = .;
|
||||
} > m_data_2
|
||||
|
||||
.heap :
|
||||
{
|
||||
. = ALIGN(8);
|
||||
__end__ = .;
|
||||
__heap_start__ = .;
|
||||
PROVIDE(end = .);
|
||||
PROVIDE(_end = .);
|
||||
PROVIDE(__end = .);
|
||||
__HeapBase = .;
|
||||
. += HEAP_SIZE;
|
||||
__HeapLimit = .;
|
||||
__heap_limit = .;
|
||||
__heap_end__ = .;
|
||||
} > m_data_2
|
||||
|
||||
/* Initializes stack on the end of block */
|
||||
__StackTop = ORIGIN(m_data_2) + LENGTH(m_data_2);
|
||||
__StackLimit = __StackTop - STACK_SIZE;
|
||||
PROVIDE(__stack = __StackTop);
|
||||
__RAM_END = __StackTop;
|
||||
|
||||
.stack __StackLimit :
|
||||
{
|
||||
. = ALIGN(8);
|
||||
__stack_start__ = .;
|
||||
. += STACK_SIZE;
|
||||
__stack_end__ = .;
|
||||
} > m_data_2
|
||||
|
||||
/* Labels required by EWL */
|
||||
__START_BSS = __BSS_START;
|
||||
__END_BSS = __BSS_END;
|
||||
__SP_INIT = __StackTop;
|
||||
|
||||
.ARM.attributes 0 : { *(.ARM.attributes) }
|
||||
|
||||
ASSERT(__StackLimit >= __HeapLimit, "region m_data_2 overflowed with stack and heap")
|
||||
}
|
||||
|
|
@ -0,0 +1,176 @@
|
|||
/************************************************************************************//**
|
||||
* \file Demo/ARMCM4_S32K14_S32K144EVB_GCC/Boot/blt_conf.h
|
||||
* \brief Bootloader configuration header file.
|
||||
* \ingroup Boot_ARMCM4_S32K14_S32K144EVB_GCC
|
||||
* \internal
|
||||
*----------------------------------------------------------------------------------------
|
||||
* C O P Y R I G H T
|
||||
*----------------------------------------------------------------------------------------
|
||||
* Copyright (c) 2020 by Feaser http://www.feaser.com All rights reserved
|
||||
*
|
||||
*----------------------------------------------------------------------------------------
|
||||
* L I C E N S E
|
||||
*----------------------------------------------------------------------------------------
|
||||
* This file is part of OpenBLT. OpenBLT is free software: you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as published by the Free
|
||||
* Software Foundation, either version 3 of the License, or (at your option) any later
|
||||
* version.
|
||||
*
|
||||
* OpenBLT is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
|
||||
* without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
|
||||
* PURPOSE. See the GNU General Public License for more details.
|
||||
*
|
||||
* You have received a copy of the GNU General Public License along with OpenBLT. It
|
||||
* should be located in ".\Doc\license.html". If not, contact Feaser to obtain a copy.
|
||||
*
|
||||
* \endinternal
|
||||
****************************************************************************************/
|
||||
#ifndef BLT_CONF_H
|
||||
#define BLT_CONF_H
|
||||
|
||||
/****************************************************************************************
|
||||
* C P U D R I V E R C O N F I G U R A T I O N
|
||||
****************************************************************************************/
|
||||
/* To properly initialize the baudrate clocks of the communication interface, typically
|
||||
* the speed of the crystal oscillator and/or the speed at which the system runs is
|
||||
* needed. Set these through configurables BOOT_CPU_XTAL_SPEED_KHZ and
|
||||
* BOOT_CPU_SYSTEM_SPEED_KHZ, respectively. To enable data exchange with the host that is
|
||||
* not dependent on the targets architecture, the byte ordering needs to be known.
|
||||
* Setting BOOT_CPU_BYTE_ORDER_MOTOROLA to 1 selects big endian mode and 0 selects
|
||||
* little endian mode.
|
||||
*
|
||||
* Set BOOT_CPU_USER_PROGRAM_START_HOOK to 1 if you would like a hook function to be
|
||||
* called the moment the user program is about to be started. This could be used to
|
||||
* de-initialize application specific parts, for example to stop blinking an LED, etc.
|
||||
*/
|
||||
/** \brief Frequency of the external crystal oscillator. */
|
||||
#define BOOT_CPU_XTAL_SPEED_KHZ (8000)
|
||||
/** \brief Desired system speed. */
|
||||
#define BOOT_CPU_SYSTEM_SPEED_KHZ (80000)
|
||||
/** \brief Motorola or Intel style byte ordering. */
|
||||
#define BOOT_CPU_BYTE_ORDER_MOTOROLA (0)
|
||||
/** \brief Enable/disable hook function call right before user program start. */
|
||||
#define BOOT_CPU_USER_PROGRAM_START_HOOK (1)
|
||||
|
||||
|
||||
/****************************************************************************************
|
||||
* C O M M U N I C A T I O N I N T E R F A C E C O N F I G U R A T I O N
|
||||
****************************************************************************************/
|
||||
/* The UART communication interface is selected by setting the BOOT_COM_UART_ENABLE
|
||||
* configurable to 1. Configurable BOOT_COM_UART_BAUDRATE selects the communication speed
|
||||
* in bits/second. The maximum amount of data bytes in a message for data transmission
|
||||
* and reception is set through BOOT_COM_UART_TX_MAX_DATA and BOOT_COM_UART_RX_MAX_DATA,
|
||||
* respectively. It is common for a microcontroller to have more than 1 UART interface
|
||||
* on board. The zero-based BOOT_COM_UART_CHANNEL_INDEX selects the UART interface.
|
||||
*
|
||||
*/
|
||||
/** \brief Enable/disable UART transport layer. */
|
||||
#define BOOT_COM_RS232_ENABLE (1)
|
||||
/** \brief Configure the desired communication speed. */
|
||||
#define BOOT_COM_RS232_BAUDRATE (57600)
|
||||
/** \brief Configure number of bytes in the target->host data packet. */
|
||||
#define BOOT_COM_RS232_TX_MAX_DATA (64)
|
||||
/** \brief Configure number of bytes in the host->target data packet. */
|
||||
#define BOOT_COM_RS232_RX_MAX_DATA (64)
|
||||
/** \brief Select the desired UART peripheral as a zero based index. */
|
||||
#define BOOT_COM_RS232_CHANNEL_INDEX (1)
|
||||
|
||||
/* The CAN communication interface is selected by setting the BOOT_COM_CAN_ENABLE
|
||||
* configurable to 1. Configurable BOOT_COM_CAN_BAUDRATE selects the communication speed
|
||||
* in bits/second. Two CAN messages are reserved for communication with the host. The
|
||||
* message identifier for sending data from the target to the host is configured with
|
||||
* BOOT_COM_CAN_TXMSG_ID. The one for receiving data from the host is configured with
|
||||
* BOOT_COM_CAN_RXMSG_ID. Note that an extended 29-bit CAN identifier is configured by
|
||||
* OR-ing with mask 0x80000000. The maximum amount of data bytes in a message for data
|
||||
* transmission and reception is set through BOOT_COM_CAN_TX_MAX_DATA and
|
||||
* BOOT_COM_CAN_RX_MAX_DATA, respectively. It is common for a microcontroller to have more
|
||||
* than 1 CAN controller on board. The zero-based BOOT_COM_CAN_CHANNEL_INDEX selects the
|
||||
* CAN controller channel.
|
||||
*
|
||||
*/
|
||||
/** \brief Enable/disable CAN transport layer. */
|
||||
#define BOOT_COM_CAN_ENABLE (1)
|
||||
/** \brief Configure the desired CAN baudrate. */
|
||||
#define BOOT_COM_CAN_BAUDRATE (500000)
|
||||
/** \brief Configure CAN message ID target->host. */
|
||||
#define BOOT_COM_CAN_TX_MSG_ID (0x7E1 /*| 0x80000000*/)
|
||||
/** \brief Configure number of bytes in the target->host CAN message. */
|
||||
#define BOOT_COM_CAN_TX_MAX_DATA (8)
|
||||
/** \brief Configure CAN message ID host->target. */
|
||||
#define BOOT_COM_CAN_RX_MSG_ID (0x667 /*| 0x80000000*/)
|
||||
/** \brief Configure number of bytes in the host->target CAN message. */
|
||||
#define BOOT_COM_CAN_RX_MAX_DATA (8)
|
||||
/** \brief Select the desired CAN peripheral as a zero based index. */
|
||||
#define BOOT_COM_CAN_CHANNEL_INDEX (0)
|
||||
|
||||
|
||||
/****************************************************************************************
|
||||
* B A C K D O O R E N T R Y C O N F I G U R A T I O N
|
||||
****************************************************************************************/
|
||||
/* It is possible to implement an application specific method to force the bootloader to
|
||||
* stay active after a reset. Such a backdoor entry into the bootloader is desired in
|
||||
* situations where the user program does not run properly and therefore cannot
|
||||
* reactivate the bootloader. By enabling these hook functions, the application can
|
||||
* implement the backdoor, which overrides the default backdoor entry that is programmed
|
||||
* into the bootloader. When desired for security purposes, these hook functions can
|
||||
* also be implemented in a way that disables the backdoor entry altogether.
|
||||
*/
|
||||
/** \brief Enable/disable the backdoor override hook functions. */
|
||||
#define BOOT_BACKDOOR_HOOKS_ENABLE (0)
|
||||
|
||||
|
||||
/****************************************************************************************
|
||||
* N O N - V O L A T I L E M E M O R Y D R I V E R C O N F I G U R A T I O N
|
||||
****************************************************************************************/
|
||||
/* The NVM driver typically supports erase and program operations of the internal memory
|
||||
* present on the microcontroller. Through these hook functions the NVM driver can be
|
||||
* extended to support additional memory types such as external flash memory and serial
|
||||
* eeproms. The size of the internal memory in kilobytes is specified with configurable
|
||||
* BOOT_NVM_SIZE_KB. If desired the internal checksum writing and verification method can
|
||||
* be overridden with a application specific method by enabling configuration switch
|
||||
* BOOT_NVM_CHECKSUM_HOOKS_ENABLE.
|
||||
*/
|
||||
/** \brief Enable/disable the NVM hook function for supporting additional memory devices. */
|
||||
#define BOOT_NVM_HOOKS_ENABLE (0)
|
||||
/** \brief Configure the size of the default memory device (typically flash EEPROM). */
|
||||
#define BOOT_NVM_SIZE_KB (512)
|
||||
/** \brief Enable/disable hooks functions to override the user program checksum handling. */
|
||||
#define BOOT_NVM_CHECKSUM_HOOKS_ENABLE (0)
|
||||
|
||||
|
||||
/****************************************************************************************
|
||||
* W A T C H D O G D R I V E R C O N F I G U R A T I O N
|
||||
****************************************************************************************/
|
||||
/* The COP driver cannot be configured internally in the bootloader, because its use
|
||||
* and configuration is application specific. The bootloader does need to service the
|
||||
* watchdog in case it is used. When the application requires the use of a watchdog,
|
||||
* set BOOT_COP_HOOKS_ENABLE to be able to initialize and service the watchdog through
|
||||
* hook functions.
|
||||
*/
|
||||
/** \brief Enable/disable the hook functions for controlling the watchdog. */
|
||||
#define BOOT_COP_HOOKS_ENABLE (1)
|
||||
|
||||
|
||||
/****************************************************************************************
|
||||
* S E E D / K E Y S E C U R I T Y C O N F I G U R A T I O N
|
||||
****************************************************************************************/
|
||||
/* A security mechanism can be enabled in the bootloader's XCP module by setting configu-
|
||||
* rable BOOT_XCP_SEED_KEY_ENABLE to 1. Before any memory erase or programming
|
||||
* operations can be performed, access to this resource need to be unlocked.
|
||||
* In the Microboot settings on tab "XCP Protection" you need to specify a DLL that
|
||||
* implements the unlocking algorithm. The demo programs are configured for the (simple)
|
||||
* algorithm in "libseednkey.dll". The source code for this DLL is available so it can be
|
||||
* customized to your needs.
|
||||
* During the unlock sequence, Microboot requests a seed from the bootloader, which is in
|
||||
* the format of a byte array. Using this seed the unlock algorithm in the DLL computes
|
||||
* a key, which is also a byte array, and sends this back to the bootloader. The
|
||||
* bootloader then verifies this key to determine if programming and erase operations are
|
||||
* permitted.
|
||||
* After enabling this feature the hook functions XcpGetSeedHook() and XcpVerifyKeyHook()
|
||||
* are called by the bootloader to obtain the seed and to verify the key, respectively.
|
||||
*/
|
||||
#define BOOT_XCP_SEED_KEY_ENABLE (0)
|
||||
|
||||
|
||||
#endif /* BLT_CONF_H */
|
||||
/*********************************** end of blt_conf.h *********************************/
|
|
@ -0,0 +1,7 @@
|
|||
/**
|
||||
\defgroup Boot_ARMCM4_S32K14_S32K144EVB_GCC Bootloader
|
||||
\brief Bootloader.
|
||||
\ingroup ARMCM4_S32K14_S32K144EVB_GCC
|
||||
*/
|
||||
|
||||
|
|
@ -0,0 +1,307 @@
|
|||
/************************************************************************************//**
|
||||
* \file Demo/ARMCM4_S32K14_S32K144EVB_GCC/Boot/hooks.c
|
||||
* \brief Bootloader callback source file.
|
||||
* \ingroup Boot_ARMCM4_S32K14_S32K144EVB_GCC
|
||||
* \internal
|
||||
*----------------------------------------------------------------------------------------
|
||||
* C O P Y R I G H T
|
||||
*----------------------------------------------------------------------------------------
|
||||
* Copyright (c) 2020 by Feaser http://www.feaser.com All rights reserved
|
||||
*
|
||||
*----------------------------------------------------------------------------------------
|
||||
* L I C E N S E
|
||||
*----------------------------------------------------------------------------------------
|
||||
* This file is part of OpenBLT. OpenBLT is free software: you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as published by the Free
|
||||
* Software Foundation, either version 3 of the License, or (at your option) any later
|
||||
* version.
|
||||
*
|
||||
* OpenBLT is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
|
||||
* without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
|
||||
* PURPOSE. See the GNU General Public License for more details.
|
||||
*
|
||||
* You have received a copy of the GNU General Public License along with OpenBLT. It
|
||||
* should be located in ".\Doc\license.html". If not, contact Feaser to obtain a copy.
|
||||
*
|
||||
* \endinternal
|
||||
****************************************************************************************/
|
||||
|
||||
/****************************************************************************************
|
||||
* Include files
|
||||
****************************************************************************************/
|
||||
#include "boot.h" /* bootloader generic header */
|
||||
#include "led.h" /* LED driver header */
|
||||
#include "device_registers.h" /* device registers */
|
||||
|
||||
|
||||
/****************************************************************************************
|
||||
* B A C K D O O R E N T R Y H O O K F U N C T I O N S
|
||||
****************************************************************************************/
|
||||
|
||||
#if (BOOT_BACKDOOR_HOOKS_ENABLE > 0)
|
||||
/************************************************************************************//**
|
||||
** \brief Initializes the backdoor entry option.
|
||||
** \return none.
|
||||
**
|
||||
****************************************************************************************/
|
||||
void BackDoorInitHook(void)
|
||||
{
|
||||
} /*** end of BackDoorInitHook ***/
|
||||
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief Checks if a backdoor entry is requested.
|
||||
** \return BLT_TRUE if the backdoor entry is requested, BLT_FALSE otherwise.
|
||||
**
|
||||
****************************************************************************************/
|
||||
blt_bool BackDoorEntryHook(void)
|
||||
{
|
||||
/* default implementation always activates the bootloader after a reset */
|
||||
return BLT_TRUE;
|
||||
} /*** end of BackDoorEntryHook ***/
|
||||
#endif /* BOOT_BACKDOOR_HOOKS_ENABLE > 0 */
|
||||
|
||||
|
||||
/****************************************************************************************
|
||||
* C P U D R I V E R H O O K F U N C T I O N S
|
||||
****************************************************************************************/
|
||||
|
||||
#if (BOOT_CPU_USER_PROGRAM_START_HOOK > 0)
|
||||
/************************************************************************************//**
|
||||
** \brief Callback that gets called when the bootloader is about to exit and
|
||||
** hand over control to the user program. This is the last moment that
|
||||
** some final checking can be performed and if necessary prevent the
|
||||
** bootloader from activiting the user program.
|
||||
** \return BLT_TRUE if it is okay to start the user program, BLT_FALSE to keep
|
||||
** keep the bootloader active.
|
||||
**
|
||||
****************************************************************************************/
|
||||
blt_bool CpuUserProgramStartHook(void)
|
||||
{
|
||||
/* additional and optional backdoor entry through the pushbutton (SW2) on the board. to
|
||||
* force the bootloader to stay active after reset, keep it pressed during reset.
|
||||
*/
|
||||
if ((PTC->PDIR & GPIO_PDIR_PDI(1 << 12U)) != 0U)
|
||||
{
|
||||
/* pushbutton pressed, so do not start the user program and keep the
|
||||
* bootloader active instead.
|
||||
*/
|
||||
return BLT_FALSE;
|
||||
}
|
||||
|
||||
/* clean up the LED driver */
|
||||
LedBlinkExit();
|
||||
|
||||
/* okay to start the user program */
|
||||
return BLT_TRUE;
|
||||
} /*** end of CpuUserProgramStartHook ***/
|
||||
#endif /* BOOT_CPU_USER_PROGRAM_START_HOOK > 0 */
|
||||
|
||||
|
||||
/****************************************************************************************
|
||||
* W A T C H D O G D R I V E R H O O K F U N C T I O N S
|
||||
****************************************************************************************/
|
||||
|
||||
#if (BOOT_COP_HOOKS_ENABLE > 0)
|
||||
/************************************************************************************//**
|
||||
** \brief Callback that gets called at the end of the internal COP driver
|
||||
** initialization routine. It can be used to configure and enable the
|
||||
** watchdog.
|
||||
** \return none.
|
||||
**
|
||||
****************************************************************************************/
|
||||
void CopInitHook(void)
|
||||
{
|
||||
/* this function is called upon initialization. might as well use it to initialize
|
||||
* the LED driver. It is kind of a visual watchdog anyways.
|
||||
*/
|
||||
LedBlinkInit(100);
|
||||
} /*** end of CopInitHook ***/
|
||||
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief Callback that gets called at the end of the internal COP driver
|
||||
** service routine. This gets called upon initialization and during
|
||||
** potential long lasting loops and routine. It can be used to service
|
||||
** the watchdog to prevent a watchdog reset.
|
||||
** \return none.
|
||||
**
|
||||
****************************************************************************************/
|
||||
void CopServiceHook(void)
|
||||
{
|
||||
/* run the LED blink task. this is a better place to do it than in the main() program
|
||||
* loop. certain operations such as flash erase can take a long time, which would cause
|
||||
* a blink interval to be skipped. this function is also called during such operations,
|
||||
* so no blink intervals will be skipped when calling the LED blink task here.
|
||||
*/
|
||||
LedBlinkTask();
|
||||
} /*** end of CopServiceHook ***/
|
||||
#endif /* BOOT_COP_HOOKS_ENABLE > 0 */
|
||||
|
||||
|
||||
/****************************************************************************************
|
||||
* N O N - V O L A T I L E M E M O R Y D R I V E R H O O K F U N C T I O N S
|
||||
****************************************************************************************/
|
||||
|
||||
#if (BOOT_NVM_HOOKS_ENABLE > 0)
|
||||
/************************************************************************************//**
|
||||
** \brief Callback that gets called at the start of the internal NVM driver
|
||||
** initialization routine.
|
||||
** \return none.
|
||||
**
|
||||
****************************************************************************************/
|
||||
void NvmInitHook(void)
|
||||
{
|
||||
} /*** end of NvmInitHook ***/
|
||||
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief Callback that gets called at the start of a firmware update to reinitialize
|
||||
** the NVM driver.
|
||||
** \return none.
|
||||
**
|
||||
****************************************************************************************/
|
||||
void NvmReinitHook(void)
|
||||
{
|
||||
} /*** end of NvmReinitHook ***/
|
||||
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief Callback that gets called at the start of the NVM driver write
|
||||
** routine. It allows additional memory to be operated on. If the address
|
||||
** is not within the range of the additional memory, then
|
||||
** BLT_NVM_NOT_IN_RANGE must be returned to indicate that the data hasn't
|
||||
** been written yet.
|
||||
** \param addr Start address.
|
||||
** \param len Length in bytes.
|
||||
** \param data Pointer to the data buffer.
|
||||
** \return BLT_NVM_OKAY if successful, BLT_NVM_NOT_IN_RANGE if the address is
|
||||
** not within the supported memory range, or BLT_NVM_ERROR is the write
|
||||
** operation failed.
|
||||
**
|
||||
****************************************************************************************/
|
||||
blt_int8u NvmWriteHook(blt_addr addr, blt_int32u len, blt_int8u *data)
|
||||
{
|
||||
return BLT_NVM_NOT_IN_RANGE;
|
||||
} /*** end of NvmWriteHook ***/
|
||||
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief Callback that gets called at the start of the NVM driver erase
|
||||
** routine. It allows additional memory to be operated on. If the address
|
||||
** is not within the range of the additional memory, then
|
||||
** BLT_NVM_NOT_IN_RANGE must be returned to indicate that the memory
|
||||
** hasn't been erased yet.
|
||||
** \param addr Start address.
|
||||
** \param len Length in bytes.
|
||||
** \return BLT_NVM_OKAY if successful, BLT_NVM_NOT_IN_RANGE if the address is
|
||||
** not within the supported memory range, or BLT_NVM_ERROR is the erase
|
||||
** operation failed.
|
||||
**
|
||||
****************************************************************************************/
|
||||
blt_int8u NvmEraseHook(blt_addr addr, blt_int32u len)
|
||||
{
|
||||
return BLT_NVM_NOT_IN_RANGE;
|
||||
} /*** end of NvmEraseHook ***/
|
||||
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief Callback that gets called at the end of the NVM programming session.
|
||||
** \return BLT_TRUE is successful, BLT_FALSE otherwise.
|
||||
**
|
||||
****************************************************************************************/
|
||||
blt_bool NvmDoneHook(void)
|
||||
{
|
||||
return BLT_TRUE;
|
||||
} /*** end of NvmDoneHook ***/
|
||||
#endif /* BOOT_NVM_HOOKS_ENABLE > 0 */
|
||||
|
||||
|
||||
#if (BOOT_NVM_CHECKSUM_HOOKS_ENABLE > 0)
|
||||
/************************************************************************************//**
|
||||
** \brief Verifies the checksum, which indicates that a valid user program is
|
||||
** present and can be started.
|
||||
** \return BLT_TRUE if successful, BLT_FALSE otherwise.
|
||||
**
|
||||
****************************************************************************************/
|
||||
blt_bool NvmVerifyChecksumHook(void)
|
||||
{
|
||||
return BLT_TRUE;
|
||||
} /*** end of NvmVerifyChecksum ***/
|
||||
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief Writes a checksum of the user program to non-volatile memory. This is
|
||||
** performed once the entire user program has been programmed. Through
|
||||
** the checksum, the bootloader can check if a valid user programming is
|
||||
** present and can be started.
|
||||
** \return BLT_TRUE if successful, BLT_FALSE otherwise.
|
||||
**
|
||||
****************************************************************************************/
|
||||
blt_bool NvmWriteChecksumHook(void)
|
||||
{
|
||||
return BLT_TRUE;
|
||||
}
|
||||
#endif /* BOOT_NVM_CHECKSUM_HOOKS_ENABLE > 0 */
|
||||
|
||||
|
||||
/****************************************************************************************
|
||||
* S E E D / K E Y S E C U R I T Y H O O K F U N C T I O N S
|
||||
****************************************************************************************/
|
||||
|
||||
#if (BOOT_XCP_SEED_KEY_ENABLE > 0)
|
||||
/************************************************************************************//**
|
||||
** \brief Provides a seed to the XCP master that will be used for the key
|
||||
** generation when the master attempts to unlock the specified resource.
|
||||
** Called by the GET_SEED command.
|
||||
** \param resource Resource that the seed if requested for (XCP_RES_XXX).
|
||||
** \param seed Pointer to byte buffer wher the seed will be stored.
|
||||
** \return Length of the seed in bytes.
|
||||
**
|
||||
****************************************************************************************/
|
||||
blt_int8u XcpGetSeedHook(blt_int8u resource, blt_int8u *seed)
|
||||
{
|
||||
/* request seed for unlocking ProGraMming resource */
|
||||
if ((resource & XCP_RES_PGM) != 0)
|
||||
{
|
||||
seed[0] = 0x55;
|
||||
}
|
||||
|
||||
/* return seed length */
|
||||
return 1;
|
||||
} /*** end of XcpGetSeedHook ***/
|
||||
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief Called by the UNLOCK command and checks if the key to unlock the
|
||||
** specified resource was correct. If so, then the resource protection
|
||||
** will be removed.
|
||||
** \param resource resource to unlock (XCP_RES_XXX).
|
||||
** \param key pointer to the byte buffer holding the key.
|
||||
** \param len length of the key in bytes.
|
||||
** \return 1 if the key was correct, 0 otherwise.
|
||||
**
|
||||
****************************************************************************************/
|
||||
blt_int8u XcpVerifyKeyHook(blt_int8u resource, blt_int8u *key, blt_int8u len)
|
||||
{
|
||||
/* suppress compiler warning for unused parameter */
|
||||
len = len;
|
||||
|
||||
/* the example key algorithm in "libseednkey.dll" works as follows:
|
||||
* - PGM will be unlocked if key = seed - 1
|
||||
*/
|
||||
|
||||
/* check key for unlocking ProGraMming resource */
|
||||
if ((resource == XCP_RES_PGM) && (key[0] == (0x55-1)))
|
||||
{
|
||||
/* correct key received for unlocking PGM resource */
|
||||
return 1;
|
||||
}
|
||||
|
||||
/* still here so key incorrect */
|
||||
return 0;
|
||||
} /*** end of XcpVerifyKeyHook ***/
|
||||
#endif /* BOOT_XCP_SEED_KEY_ENABLE > 0 */
|
||||
|
||||
|
||||
/*********************************** end of hooks.c ************************************/
|
|
@ -0,0 +1,108 @@
|
|||
/************************************************************************************//**
|
||||
* \file Demo/ARMCM4_S32K14_S32K144EVB_GCC/Boot/led.c
|
||||
* \brief LED driver source file.
|
||||
* \ingroup Boot_ARMCM4_S32K14_S32K144EVB_GCC
|
||||
* \internal
|
||||
*----------------------------------------------------------------------------------------
|
||||
* C O P Y R I G H T
|
||||
*----------------------------------------------------------------------------------------
|
||||
* Copyright (c) 2020 by Feaser http://www.feaser.com All rights reserved
|
||||
*
|
||||
*----------------------------------------------------------------------------------------
|
||||
* L I C E N S E
|
||||
*----------------------------------------------------------------------------------------
|
||||
* This file is part of OpenBLT. OpenBLT is free software: you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as published by the Free
|
||||
* Software Foundation, either version 3 of the License, or (at your option) any later
|
||||
* version.
|
||||
*
|
||||
* OpenBLT is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
|
||||
* without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
|
||||
* PURPOSE. See the GNU General Public License for more details.
|
||||
*
|
||||
* You have received a copy of the GNU General Public License along with OpenBLT. It
|
||||
* should be located in ".\Doc\license.html". If not, contact Feaser to obtain a copy.
|
||||
*
|
||||
* \endinternal
|
||||
****************************************************************************************/
|
||||
|
||||
/****************************************************************************************
|
||||
* Include files
|
||||
****************************************************************************************/
|
||||
#include "boot.h" /* bootloader generic header */
|
||||
#include "led.h" /* module header */
|
||||
#include "device_registers.h" /* device registers */
|
||||
|
||||
|
||||
/****************************************************************************************
|
||||
* Local data declarations
|
||||
****************************************************************************************/
|
||||
/** \brief Holds the desired LED blink interval time. */
|
||||
static blt_int16u ledBlinkIntervalMs;
|
||||
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief Initializes the LED blink driver.
|
||||
** \param interval_ms Specifies the desired LED blink interval time in milliseconds.
|
||||
** \return none.
|
||||
**
|
||||
****************************************************************************************/
|
||||
void LedBlinkInit(blt_int16u interval_ms)
|
||||
{
|
||||
/* LED GPIO pin configuration. PD0 = GPIO, MUX = ALT1. */
|
||||
PORTD->PCR[0] |= PORT_PCR_MUX(1);
|
||||
/* configure Port D pin 0 GPIO as digital output */
|
||||
PTD->PDDR |= GPIO_PDDR_PDD(0x00000001);
|
||||
/* turn the LED off on Port D pin 0 */
|
||||
PTD->PSOR |= GPIO_PSOR_PTSO(0x00000001);
|
||||
/* store the interval time between LED toggles */
|
||||
ledBlinkIntervalMs = interval_ms;
|
||||
} /*** end of LedBlinkInit ***/
|
||||
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief Task function for blinking the LED as a fixed timer interval.
|
||||
** \return none.
|
||||
**
|
||||
****************************************************************************************/
|
||||
void LedBlinkTask(void)
|
||||
{
|
||||
static blt_bool ledOn = BLT_FALSE;
|
||||
static blt_int32u nextBlinkEvent = 0;
|
||||
|
||||
/* check for blink event */
|
||||
if (TimerGet() >= nextBlinkEvent)
|
||||
{
|
||||
/* toggle the LED state */
|
||||
if (ledOn == BLT_FALSE)
|
||||
{
|
||||
ledOn = BLT_TRUE;
|
||||
/* Turn the LED on. */
|
||||
PTD->PCOR |= GPIO_PCOR_PTCO(0x00000001);
|
||||
}
|
||||
else
|
||||
{
|
||||
ledOn = BLT_FALSE;
|
||||
/* Turn the LED off. */
|
||||
PTD->PSOR |= GPIO_PSOR_PTSO(0x00000001);
|
||||
}
|
||||
/* schedule the next blink event */
|
||||
nextBlinkEvent = TimerGet() + ledBlinkIntervalMs;
|
||||
}
|
||||
} /*** end of LedBlinkTask ***/
|
||||
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief Cleans up the LED blink driver. This is intended to be used upon program
|
||||
** exit.
|
||||
** \return none.
|
||||
**
|
||||
****************************************************************************************/
|
||||
void LedBlinkExit(void)
|
||||
{
|
||||
/* Turn the LED off. */
|
||||
PTD->PSOR |= GPIO_PSOR_PTSO(0x00000001);
|
||||
} /*** end of LedBlinkExit ***/
|
||||
|
||||
|
||||
/*********************************** end of led.c **************************************/
|
|
@ -0,0 +1,40 @@
|
|||
/************************************************************************************//**
|
||||
* \file Demo/ARMCM4_S32K14_S32K144EVB_GCC/Boot/led.h
|
||||
* \brief LED driver header file.
|
||||
* \ingroup Boot_ARMCM4_S32K14_S32K144EVB_GCC
|
||||
* \internal
|
||||
*----------------------------------------------------------------------------------------
|
||||
* C O P Y R I G H T
|
||||
*----------------------------------------------------------------------------------------
|
||||
* Copyright (c) 2020 by Feaser http://www.feaser.com All rights reserved
|
||||
*
|
||||
*----------------------------------------------------------------------------------------
|
||||
* L I C E N S E
|
||||
*----------------------------------------------------------------------------------------
|
||||
* This file is part of OpenBLT. OpenBLT is free software: you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as published by the Free
|
||||
* Software Foundation, either version 3 of the License, or (at your option) any later
|
||||
* version.
|
||||
*
|
||||
* OpenBLT is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
|
||||
* without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
|
||||
* PURPOSE. See the GNU General Public License for more details.
|
||||
*
|
||||
* You have received a copy of the GNU General Public License along with OpenBLT. It
|
||||
* should be located in ".\Doc\license.html". If not, contact Feaser to obtain a copy.
|
||||
*
|
||||
* \endinternal
|
||||
****************************************************************************************/
|
||||
#ifndef LED_H
|
||||
#define LED_H
|
||||
|
||||
/****************************************************************************************
|
||||
* Function prototypes
|
||||
****************************************************************************************/
|
||||
void LedBlinkInit(blt_int16u interval_ms);
|
||||
void LedBlinkTask(void);
|
||||
void LedBlinkExit(void);
|
||||
|
||||
|
||||
#endif /* LED_H */
|
||||
/*********************************** end of led.h **************************************/
|
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
|
@ -0,0 +1,84 @@
|
|||
/*
|
||||
* Copyright (c) 2015, Freescale Semiconductor, Inc.
|
||||
* Copyright 2016-2017 NXP
|
||||
* All rights reserved.
|
||||
*
|
||||
* THIS SOFTWARE IS PROVIDED BY NXP "AS IS" AND ANY EXPRESSED OR
|
||||
* IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
|
||||
* OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
|
||||
* IN NO EVENT SHALL NXP OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
|
||||
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
|
||||
* (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
|
||||
* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
||||
* HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
|
||||
* STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING
|
||||
* IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
|
||||
* THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
#ifndef DEVASSERT_H
|
||||
#define DEVASSERT_H
|
||||
|
||||
#include <stdbool.h>
|
||||
|
||||
/**
|
||||
* @page misra_violations MISRA-C:2012 violations
|
||||
*
|
||||
* @section [global]
|
||||
* Violates MISRA 2012 Advisory Rule 2.5, global macro not referenced.
|
||||
* The macro is defined to be used by drivers to validate input parameters and can be disabled.
|
||||
*
|
||||
* @section [global]
|
||||
* Violates MISRA 2012 Advisory Directive 4.9, Function-like macro defined.
|
||||
* The macros are used to validate input parameters to driver functions.
|
||||
*
|
||||
*/
|
||||
|
||||
/**
|
||||
\page Error_detection_and_reporting Error detection and reporting
|
||||
|
||||
S32 SDK drivers can use a mechanism to validate data coming from upper software layers (application code) by performing
|
||||
a number of checks on input parameters' range or other invariants that can be statically checked (not dependent on
|
||||
runtime conditions). A failed validation is indicative of a software bug in application code, therefore it is important
|
||||
to use this mechanism during development.
|
||||
|
||||
The validation is performed by using DEV_ASSERT macro.
|
||||
A default implementation of this macro is provided in this file. However, application developers can provide their own
|
||||
implementation in a custom file. This requires defining the CUSTOM_DEVASSERT symbol with the specific file name in the
|
||||
project configuration (for example: -DCUSTOM_DEVASSERT="custom_devassert.h")
|
||||
|
||||
The default implementation accommodates two behaviors, based on DEV_ERROR_DETECT symbol:
|
||||
- When DEV_ERROR_DETECT symbol is defined in the project configuration (for example: -DDEV_ERROR_DETECT), the validation
|
||||
performed by the DEV_ASSERT macro is enabled, and a failed validation triggers a software breakpoint and further execution is
|
||||
prevented (application spins in an infinite loop)
|
||||
This configuration is recommended for development environments, as it prevents further execution and allows investigating
|
||||
potential problems from the point of error detection.
|
||||
- When DEV_ERROR_DETECT symbol is not defined, the DEV_ASSERT macro is implemented as no-op, therefore disabling all validations.
|
||||
This configuration can be used to eliminate the overhead of development-time checks.
|
||||
|
||||
It is the application developer's responsibility to decide the error detection strategy for production code: one can opt to
|
||||
disable development-time checking altogether (by not defining DEV_ERROR_DETECT symbol), or one can opt to keep the checks
|
||||
in place and implement a recovery mechanism in case of a failed validation, by defining CUSTOM_DEVASSERT to point
|
||||
to the file containing the custom implementation.
|
||||
*/
|
||||
|
||||
#if defined (CUSTOM_DEVASSERT)
|
||||
/* If the CUSTOM_DEVASSERT symbol is defined, then add the custom implementation */
|
||||
#include CUSTOM_DEVASSERT
|
||||
#elif defined (DEV_ERROR_DETECT)
|
||||
/* Implement default assert macro */
|
||||
static inline void DevAssert(volatile bool x)
|
||||
{
|
||||
if(x) { } else { BKPT_ASM; for(;;) {} }
|
||||
}
|
||||
#define DEV_ASSERT(x) DevAssert(x)
|
||||
#else
|
||||
/* Assert macro does nothing */
|
||||
#define DEV_ASSERT(x) ((void)0)
|
||||
#endif
|
||||
|
||||
#endif /* DEVASSERT_H */
|
||||
|
||||
/*******************************************************************************
|
||||
* EOF
|
||||
******************************************************************************/
|
|
@ -0,0 +1,70 @@
|
|||
/*
|
||||
** ###################################################################
|
||||
** Abstract:
|
||||
** Common include file for CMSIS register access layer headers.
|
||||
**
|
||||
** Copyright (c) 2015 Freescale Semiconductor, Inc.
|
||||
** Copyright 2016-2017 NXP
|
||||
** All rights reserved.
|
||||
**
|
||||
** THIS SOFTWARE IS PROVIDED BY NXP "AS IS" AND ANY EXPRESSED OR
|
||||
** IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
|
||||
** OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
|
||||
** IN NO EVENT SHALL NXP OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
|
||||
** INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
|
||||
** (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
|
||||
** SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
||||
** HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
|
||||
** STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING
|
||||
** IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
|
||||
** THE POSSIBILITY OF SUCH DAMAGE.
|
||||
**
|
||||
** http: www.nxp.com
|
||||
** mail: support@nxp.com
|
||||
** ###################################################################
|
||||
*/
|
||||
|
||||
#ifndef DEVICE_REGISTERS_H
|
||||
#define DEVICE_REGISTERS_H
|
||||
|
||||
/**
|
||||
* @page misra_violations MISRA-C:2012 violations
|
||||
*
|
||||
* @section [global]
|
||||
* Violates MISRA 2012 Advisory Rule 2.5, global macro not referenced.
|
||||
* The macro defines the device currently in use and may be used by components for specific checks.
|
||||
*
|
||||
*/
|
||||
|
||||
|
||||
/*
|
||||
* Include the cpu specific register header files.
|
||||
*
|
||||
* The CPU macro should be declared in the project or makefile.
|
||||
*/
|
||||
|
||||
#if (defined(CPU_S32K144HFT0VLLT) || defined(CPU_S32K144LFT0MLLT))
|
||||
|
||||
#define S32K14x_SERIES
|
||||
|
||||
/* Specific core definitions */
|
||||
#include "s32_core_cm4.h"
|
||||
|
||||
#define S32K144_SERIES
|
||||
|
||||
/* Register definitions */
|
||||
#include "S32K144.h"
|
||||
/* CPU specific feature definitions */
|
||||
#include "S32K144_features.h"
|
||||
|
||||
#else
|
||||
#error "No valid CPU defined!"
|
||||
#endif
|
||||
|
||||
#include "devassert.h"
|
||||
|
||||
#endif /* DEVICE_REGISTERS_H */
|
||||
|
||||
/*******************************************************************************
|
||||
* EOF
|
||||
******************************************************************************/
|
|
@ -0,0 +1,209 @@
|
|||
/*
|
||||
* Copyright (c) 2015-2016 Freescale Semiconductor, Inc.
|
||||
* Copyright 2016-2017 NXP
|
||||
* All rights reserved.
|
||||
*
|
||||
* THIS SOFTWARE IS PROVIDED BY NXP "AS IS" AND ANY EXPRESSED OR
|
||||
* IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
|
||||
* OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
|
||||
* IN NO EVENT SHALL NXP OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
|
||||
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
|
||||
* (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
|
||||
* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
||||
* HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
|
||||
* STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING
|
||||
* IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
|
||||
* THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*
|
||||
*/
|
||||
/*!
|
||||
* @file s32_core_cm4.h
|
||||
*
|
||||
* @page misra_violations MISRA-C:2012 violations
|
||||
*
|
||||
* @section [global]
|
||||
* Violates MISRA 2012 Advisory Directive 4.9, Function-like macro
|
||||
* Function-like macros are used instead of inline functions in order to ensure
|
||||
* that the performance will not be decreased if the functions will not be
|
||||
* inlined by the compiler.
|
||||
*
|
||||
* @section [global]
|
||||
* Violates MISRA 2012 Advisory Rule 2.5, Global macro not referenced.
|
||||
* The macros defined are used only on some of the drivers, so this might be reported
|
||||
* when the analysis is made only on one driver.
|
||||
*/
|
||||
|
||||
/*
|
||||
* Tool Chains:
|
||||
* GNUC flag is defined also by ARM compiler - it shows the current major version of the compatible GCC version
|
||||
* __GNUC__ : GNU Compiler Collection
|
||||
* __ghs__ : Green Hills ARM Compiler
|
||||
* __ICCARM__ : IAR ARM Compiler
|
||||
* __DCC__ : Wind River Diab Compiler
|
||||
* __ARMCC_VERSION: ARM Compiler
|
||||
*/
|
||||
|
||||
#if !defined (CORE_CM4_H)
|
||||
#define CORE_CM4_H
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
/** \brief BKPT_ASM
|
||||
*
|
||||
* Macro to be used to trigger an debug interrupt
|
||||
*/
|
||||
#define BKPT_ASM __asm("BKPT #0\n\t")
|
||||
|
||||
|
||||
/** \brief Enable FPU
|
||||
*
|
||||
* ENABLE_FPU indicates whether SystemInit will enable the Floating point unit (FPU)
|
||||
*/
|
||||
#if defined (__GNUC__) || defined (__ARMCC_VERSION)
|
||||
#if defined (__VFP_FP__) && !defined (__SOFTFP__)
|
||||
#define ENABLE_FPU
|
||||
#endif
|
||||
|
||||
#elif defined (__ICCARM__)
|
||||
#if defined __ARMVFP__
|
||||
#define ENABLE_FPU
|
||||
#endif
|
||||
|
||||
#elif defined (__ghs__) || defined (__DCC__)
|
||||
#if defined (__VFP__)
|
||||
#define ENABLE_FPU
|
||||
#endif
|
||||
#endif /* if defined (__GNUC__) */
|
||||
|
||||
/** \brief Enable interrupts
|
||||
*/
|
||||
#if defined (__GNUC__)
|
||||
#define ENABLE_INTERRUPTS() __asm volatile ("cpsie i" : : : "memory");
|
||||
#else
|
||||
#define ENABLE_INTERRUPTS() __asm("cpsie i")
|
||||
#endif
|
||||
|
||||
|
||||
/** \brief Disable interrupts
|
||||
*/
|
||||
#if defined (__GNUC__)
|
||||
#define DISABLE_INTERRUPTS() __asm volatile ("cpsid i" : : : "memory");
|
||||
#else
|
||||
#define DISABLE_INTERRUPTS() __asm("cpsid i")
|
||||
#endif
|
||||
|
||||
|
||||
/** \brief Enter low-power standby state
|
||||
* WFI (Wait For Interrupt) makes the processor suspend execution (Clock is stopped) until an IRQ interrupts.
|
||||
*/
|
||||
#if defined (__GNUC__)
|
||||
#define STANDBY() __asm volatile ("wfi")
|
||||
#else
|
||||
#define STANDBY() __asm("wfi")
|
||||
#endif
|
||||
|
||||
/** \brief No-op
|
||||
*/
|
||||
#define NOP() __asm volatile ("nop")
|
||||
|
||||
/** \brief Reverse byte order in a word.
|
||||
*/
|
||||
#if defined (__GNUC__) || defined (__ICCARM__) || defined (__ghs__) || defined (__ARMCC_VERSION)
|
||||
#define REV_BYTES_32(a, b) __asm volatile ("rev %0, %1" : "=r" (b) : "r" (a))
|
||||
#else
|
||||
#define REV_BYTES_32(a, b) (b = ((a & 0xFF000000U) >> 24U) | ((a & 0xFF0000U) >> 8U) \
|
||||
| ((a & 0xFF00U) << 8U) | ((a & 0xFFU) << 24U))
|
||||
#endif
|
||||
|
||||
/** \brief Reverse byte order in each halfword independently.
|
||||
*/
|
||||
#if defined (__GNUC__) || defined (__ICCARM__) || defined (__ghs__) || defined (__ARMCC_VERSION)
|
||||
#define REV_BYTES_16(a, b) __asm volatile ("rev16 %0, %1" : "=r" (b) : "r" (a))
|
||||
#else
|
||||
#define REV_BYTES_16(a, b) (b = ((a & 0xFF000000U) >> 8U) | ((a & 0xFF0000U) << 8U) \
|
||||
| ((a & 0xFF00U) >> 8U) | ((a & 0xFFU) << 8U))
|
||||
#endif
|
||||
|
||||
/** \brief Places a function in RAM.
|
||||
*/
|
||||
#if defined ( __GNUC__ ) || defined (__ARMCC_VERSION)
|
||||
#define START_FUNCTION_DECLARATION_RAMSECTION
|
||||
#define END_FUNCTION_DECLARATION_RAMSECTION __attribute__((section (".code_ram")));
|
||||
#elif defined ( __ghs__ )
|
||||
#define START_FUNCTION_DECLARATION_RAMSECTION _Pragma("ghs callmode=far")
|
||||
#define END_FUNCTION_DECLARATION_RAMSECTION __attribute__((section (".code_ram")));\
|
||||
_Pragma("ghs callmode=default")
|
||||
#elif defined ( __ICCARM__ )
|
||||
#define START_FUNCTION_DECLARATION_RAMSECTION __ramfunc
|
||||
#define END_FUNCTION_DECLARATION_RAMSECTION ;
|
||||
#elif defined ( __DCC__ )
|
||||
#define START_FUNCTION_DECLARATION_RAMSECTION _Pragma("section CODE \".code_ram\"") \
|
||||
_Pragma("use_section CODE")
|
||||
#define END_FUNCTION_DECLARATION_RAMSECTION ; \
|
||||
_Pragma("section CODE \".text\"")
|
||||
#else
|
||||
/* Keep compatibility with software analysis tools */
|
||||
#define START_FUNCTION_DECLARATION_RAMSECTION
|
||||
#define END_FUNCTION_DECLARATION_RAMSECTION ;
|
||||
#endif
|
||||
|
||||
/* For GCC, IAR, GHS, Diab and ARMC there is no need to specify the section when
|
||||
defining a function, it is enough to specify it at the declaration. This
|
||||
also enables compatibility with software analysis tools. */
|
||||
#define START_FUNCTION_DEFINITION_RAMSECTION
|
||||
#define END_FUNCTION_DEFINITION_RAMSECTION
|
||||
|
||||
#if defined (__ICCARM__)
|
||||
#define DISABLE_CHECK_RAMSECTION_FUNCTION_CALL _Pragma("diag_suppress=Ta022")
|
||||
#define ENABLE_CHECK_RAMSECTION_FUNCTION_CALL _Pragma("diag_default=Ta022")
|
||||
#else
|
||||
#define DISABLE_CHECK_RAMSECTION_FUNCTION_CALL
|
||||
#define ENABLE_CHECK_RAMSECTION_FUNCTION_CALL
|
||||
#endif
|
||||
|
||||
/** \brief Get Core ID
|
||||
*
|
||||
* GET_CORE_ID returns the processor identification number for cm4
|
||||
*/
|
||||
#define GET_CORE_ID() 0U
|
||||
|
||||
/** \brief Data alignment.
|
||||
*/
|
||||
#if defined ( __GNUC__ ) || defined ( __ghs__ ) || defined ( __DCC__ ) || defined (__ARMCC_VERSION)
|
||||
#define ALIGNED(x) __attribute__((aligned(x)))
|
||||
#elif defined ( __ICCARM__ )
|
||||
#define stringify(s) tostring(s)
|
||||
#define tostring(s) #s
|
||||
#define ALIGNED(x) _Pragma(stringify(data_alignment=x))
|
||||
#else
|
||||
/* Keep compatibility with software analysis tools */
|
||||
#define ALIGNED(x)
|
||||
#endif
|
||||
|
||||
/** \brief Section placement.
|
||||
*/
|
||||
#if defined ( __GNUC__ ) || defined ( __ghs__ ) || defined ( __DCC__ ) || defined (__ARMCC_VERSION)
|
||||
#define PLACE_IN_SECTION(x) __attribute__((section(x)))
|
||||
#elif defined ( __ICCARM__ )
|
||||
#define PLACE_IN_SECTION(x) _Pragma(stringify(section=x))
|
||||
#else
|
||||
/* Keep compatibility with software analysis tools */
|
||||
#define PLACE_IN_SECTION(x)
|
||||
#endif
|
||||
|
||||
/** \brief Endianness.
|
||||
*/
|
||||
#define CORE_LITTLE_ENDIAN
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* CORE_CM4_H */
|
||||
|
||||
/*******************************************************************************
|
||||
* EOF
|
||||
******************************************************************************/
|
|
@ -0,0 +1,197 @@
|
|||
/*
|
||||
* Copyright (c) 2015 Freescale Semiconductor, Inc.
|
||||
* Copyright 2016-2017 NXP
|
||||
* All rights reserved.
|
||||
*
|
||||
* THIS SOFTWARE IS PROVIDED BY NXP "AS IS" AND ANY EXPRESSED OR
|
||||
* IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
|
||||
* OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
|
||||
* IN NO EVENT SHALL NXP OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
|
||||
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
|
||||
* (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
|
||||
* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
||||
* HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
|
||||
* STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING
|
||||
* IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
|
||||
* THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
/**
|
||||
* @page misra_violations MISRA-C:2012 violations
|
||||
*
|
||||
* @section [global]
|
||||
* Violates MISRA 2012 Advisory Rule 8.9, An object should be defined at block
|
||||
* scope if its identifier only appears in a single function.
|
||||
* An object with static storage duration declared at block scope cannot be
|
||||
* accessed directly from outside the block.
|
||||
*
|
||||
* @section [global]
|
||||
* Violates MISRA 2012 Advisory Rule 11.4, A conversion should not be performed
|
||||
* between a pointer to object and an integer type.
|
||||
* The cast is required to initialize a pointer with an unsigned int define,
|
||||
* representing an address.
|
||||
*
|
||||
* @section [global]
|
||||
* Violates MISRA 2012 Required Rule 11.6, A cast shall not be performed
|
||||
* between pointer to void and an arithmetic type.
|
||||
* The cast is required to initialize a pointer with an unsigned int define,
|
||||
* representing an address.
|
||||
*
|
||||
* @section [global]
|
||||
* Violates MISRA 2012 Advisory Rule 8.7, External could be made static.
|
||||
* Function is defined for usage by application code.
|
||||
*
|
||||
*/
|
||||
|
||||
#include "device_registers.h"
|
||||
#include "system_S32K144.h"
|
||||
#include "stdbool.h"
|
||||
|
||||
/* ----------------------------------------------------------------------------
|
||||
-- Core clock
|
||||
---------------------------------------------------------------------------- */
|
||||
|
||||
uint32_t SystemCoreClock = DEFAULT_SYSTEM_CLOCK;
|
||||
|
||||
/*FUNCTION**********************************************************************
|
||||
*
|
||||
* Function Name : SystemInit
|
||||
* Description : This function disables the watchdog, enables FPU
|
||||
* and the power mode protection if the corresponding feature macro
|
||||
* is enabled. SystemInit is called from startup_device file.
|
||||
*
|
||||
* Implements : SystemInit_Activity
|
||||
*END**************************************************************************/
|
||||
void SystemInit(void)
|
||||
{
|
||||
/**************************************************************************/
|
||||
/* FPU ENABLE*/
|
||||
/**************************************************************************/
|
||||
#ifdef ENABLE_FPU
|
||||
/* Enable CP10 and CP11 coprocessors */
|
||||
S32_SCB->CPACR |= (S32_SCB_CPACR_CP10_MASK | S32_SCB_CPACR_CP11_MASK);
|
||||
#ifdef ERRATA_E6940
|
||||
/* Disable lazy context save of floating point state by clearing LSPEN bit
|
||||
* Workaround for errata e6940 */
|
||||
S32_SCB->FPCCR &= ~(S32_SCB_FPCCR_LSPEN_MASK);
|
||||
#endif
|
||||
#endif /* ENABLE_FPU */
|
||||
|
||||
/**************************************************************************/
|
||||
/* WDOG DISABLE*/
|
||||
/**************************************************************************/
|
||||
|
||||
#if (DISABLE_WDOG)
|
||||
/* Write of the WDOG unlock key to CNT register, must be done in order to allow any modifications*/
|
||||
WDOG->CNT = (uint32_t ) FEATURE_WDOG_UNLOCK_VALUE;
|
||||
/* The dummy read is used in order to make sure that the WDOG registers will be configured only
|
||||
* after the write of the unlock value was completed. */
|
||||
(void)WDOG->CNT;
|
||||
|
||||
/* Initial write of WDOG configuration register:
|
||||
* enables support for 32-bit refresh/unlock command write words,
|
||||
* clock select from LPO, update enable, watchdog disabled */
|
||||
WDOG->CS = (uint32_t ) ( (1UL << WDOG_CS_CMD32EN_SHIFT) |
|
||||
(FEATURE_WDOG_CLK_FROM_LPO << WDOG_CS_CLK_SHIFT) |
|
||||
(0U << WDOG_CS_EN_SHIFT) |
|
||||
(1U << WDOG_CS_UPDATE_SHIFT) );
|
||||
|
||||
/* Configure timeout */
|
||||
WDOG->TOVAL = (uint32_t )0xFFFF;
|
||||
#endif /* (DISABLE_WDOG) */
|
||||
|
||||
/**************************************************************************/
|
||||
/* ENABLE CACHE */
|
||||
/**************************************************************************/
|
||||
#if defined(I_CACHE) && (ICACHE_ENABLE == 1)
|
||||
/* Invalidate and enable code cache */
|
||||
LMEM->PCCCR = LMEM_PCCCR_INVW0(1) | LMEM_PCCCR_INVW1(1) | LMEM_PCCCR_GO(1) | LMEM_PCCCR_ENCACHE(1);
|
||||
#endif /* defined(I_CACHE) && (ICACHE_ENABLE == 1) */
|
||||
}
|
||||
|
||||
/*FUNCTION**********************************************************************
|
||||
*
|
||||
* Function Name : SystemCoreClockUpdate
|
||||
* Description : This function must be called whenever the core clock is changed
|
||||
* during program execution. It evaluates the clock register settings and calculates
|
||||
* the current core clock.
|
||||
*
|
||||
* Implements : SystemCoreClockUpdate_Activity
|
||||
*END**************************************************************************/
|
||||
void SystemCoreClockUpdate(void)
|
||||
{
|
||||
uint32_t SCGOUTClock = 0U; /* Variable to store output clock frequency of the SCG module */
|
||||
uint32_t regValue; /* Temporary variable */
|
||||
uint32_t divider, prediv, multi;
|
||||
bool validSystemClockSource = true;
|
||||
static const uint32_t fircFreq[] = {
|
||||
FEATURE_SCG_FIRC_FREQ0,
|
||||
};
|
||||
|
||||
divider = ((SCG->CSR & SCG_CSR_DIVCORE_MASK) >> SCG_CSR_DIVCORE_SHIFT) + 1U;
|
||||
|
||||
switch ((SCG->CSR & SCG_CSR_SCS_MASK) >> SCG_CSR_SCS_SHIFT) {
|
||||
case 0x1:
|
||||
/* System OSC */
|
||||
SCGOUTClock = CPU_XTAL_CLK_HZ;
|
||||
break;
|
||||
case 0x2:
|
||||
/* Slow IRC */
|
||||
regValue = (SCG->SIRCCFG & SCG_SIRCCFG_RANGE_MASK) >> SCG_SIRCCFG_RANGE_SHIFT;
|
||||
|
||||
if (regValue != 0U)
|
||||
{
|
||||
SCGOUTClock = FEATURE_SCG_SIRC_HIGH_RANGE_FREQ;
|
||||
}
|
||||
|
||||
break;
|
||||
case 0x3:
|
||||
/* Fast IRC */
|
||||
regValue = (SCG->FIRCCFG & SCG_FIRCCFG_RANGE_MASK) >> SCG_FIRCCFG_RANGE_SHIFT;
|
||||
SCGOUTClock= fircFreq[regValue];
|
||||
break;
|
||||
case 0x6:
|
||||
/* System PLL */
|
||||
SCGOUTClock = CPU_XTAL_CLK_HZ;
|
||||
prediv = ((SCG->SPLLCFG & SCG_SPLLCFG_PREDIV_MASK) >> SCG_SPLLCFG_PREDIV_SHIFT) + 1U;
|
||||
multi = ((SCG->SPLLCFG & SCG_SPLLCFG_MULT_MASK) >> SCG_SPLLCFG_MULT_SHIFT) + 16U;
|
||||
SCGOUTClock = SCGOUTClock * multi / (prediv * 2U);
|
||||
break;
|
||||
default:
|
||||
validSystemClockSource = false;
|
||||
break;
|
||||
}
|
||||
|
||||
if (validSystemClockSource == true) {
|
||||
SystemCoreClock = (SCGOUTClock / divider);
|
||||
}
|
||||
}
|
||||
|
||||
/*FUNCTION**********************************************************************
|
||||
*
|
||||
* Function Name : SystemSoftwareReset
|
||||
* Description : This function is used to initiate a system reset
|
||||
*
|
||||
* Implements : SystemSoftwareReset_Activity
|
||||
*END**************************************************************************/
|
||||
void SystemSoftwareReset(void)
|
||||
{
|
||||
uint32_t regValue;
|
||||
|
||||
/* Read Application Interrupt and Reset Control Register */
|
||||
regValue = S32_SCB->AIRCR;
|
||||
|
||||
/* Clear register key */
|
||||
regValue &= ~( S32_SCB_AIRCR_VECTKEY_MASK);
|
||||
|
||||
/* Configure System reset request bit and Register Key */
|
||||
regValue |= S32_SCB_AIRCR_VECTKEY(FEATURE_SCB_VECTKEY);
|
||||
regValue |= S32_SCB_AIRCR_SYSRESETREQ(0x1u);
|
||||
|
||||
/* Write computed register value */
|
||||
S32_SCB->AIRCR = regValue;
|
||||
}
|
||||
|
||||
/*******************************************************************************
|
||||
* EOF
|
||||
******************************************************************************/
|
|
@ -0,0 +1,111 @@
|
|||
/*
|
||||
* Copyright (c) 2015 Freescale Semiconductor, Inc.
|
||||
* Copyright 2016-2017 NXP
|
||||
* All rights reserved.
|
||||
*
|
||||
* THIS SOFTWARE IS PROVIDED BY NXP "AS IS" AND ANY EXPRESSED OR
|
||||
* IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
|
||||
* OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
|
||||
* IN NO EVENT SHALL NXP OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
|
||||
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
|
||||
* (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
|
||||
* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
||||
* HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
|
||||
* STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING
|
||||
* IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
|
||||
* THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
|
||||
/*! @addtogroup soc_support_S32K144*/
|
||||
/*! @{*/
|
||||
|
||||
/*!
|
||||
* @file system_S32K144.h
|
||||
* @brief Device specific configuration file for S32K144
|
||||
*/
|
||||
|
||||
#ifndef SYSTEM_S32K144_H_
|
||||
#define SYSTEM_S32K144_H_ /**< Symbol preventing repeated inclusion */
|
||||
|
||||
#include <stdint.h>
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
/******************************************************************************
|
||||
* CPU Settings.
|
||||
*****************************************************************************/
|
||||
|
||||
/* Watchdog disable */
|
||||
#ifndef DISABLE_WDOG
|
||||
#define DISABLE_WDOG 1
|
||||
#endif
|
||||
|
||||
/* Cache enablement */
|
||||
#ifndef ICACHE_ENABLE
|
||||
#define ICACHE_ENABLE 0
|
||||
#endif
|
||||
|
||||
/* Value of the external crystal or oscillator clock frequency in Hz */
|
||||
#ifndef CPU_XTAL_CLK_HZ
|
||||
#define CPU_XTAL_CLK_HZ 8000000u
|
||||
#endif
|
||||
|
||||
/* Value of the fast internal oscillator clock frequency in Hz */
|
||||
#ifndef CPU_INT_FAST_CLK_HZ
|
||||
#define CPU_INT_FAST_CLK_HZ 48000000u
|
||||
#endif
|
||||
|
||||
/* Default System clock value */
|
||||
#ifndef DEFAULT_SYSTEM_CLOCK
|
||||
#define DEFAULT_SYSTEM_CLOCK 48000000u
|
||||
#endif
|
||||
|
||||
/**
|
||||
* @brief System clock frequency (core clock)
|
||||
*
|
||||
* The system clock frequency supplied to the SysTick timer and the processor
|
||||
* core clock. This variable can be used by the user application to setup the
|
||||
* SysTick timer or configure other parameters. It may also be used by debugger to
|
||||
* query the frequency of the debug timer or configure the trace clock speed
|
||||
* SystemCoreClock is initialized with a correct predefined value.
|
||||
*/
|
||||
extern uint32_t SystemCoreClock;
|
||||
|
||||
/**
|
||||
* @brief Setup the SoC.
|
||||
*
|
||||
* This function disables the watchdog, enables FPU.
|
||||
* if the corresponding feature macro is enabled.
|
||||
* SystemInit is called from startup_device file.
|
||||
*/
|
||||
void SystemInit(void);
|
||||
|
||||
/**
|
||||
* @brief Updates the SystemCoreClock variable.
|
||||
*
|
||||
* It must be called whenever the core clock is changed during program
|
||||
* execution. SystemCoreClockUpdate() evaluates the clock register settings and calculates
|
||||
* the current core clock.
|
||||
* This function must be called when user does not want to use clock manager component.
|
||||
* If clock manager is used, the CLOCK_SYS_GetFreq function must be used with CORE_CLOCK
|
||||
* parameter.
|
||||
*
|
||||
*/
|
||||
void SystemCoreClockUpdate(void);
|
||||
|
||||
/**
|
||||
* @brief Initiates a system reset.
|
||||
*
|
||||
* This function is used to initiate a system reset
|
||||
*/
|
||||
void SystemSoftwareReset(void);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
/*! @}*/
|
||||
#endif /* #if !defined(SYSTEM_S32K144_H_) */
|
|
@ -0,0 +1,211 @@
|
|||
/************************************************************************************//**
|
||||
* \file Demo/ARMCM4_S32K14_S32K144EVB_GCC/Boot/main.c
|
||||
* \brief Bootloader application source file.
|
||||
* \ingroup Boot_ARMCM4_S32K14_S32K144EVB_GCC
|
||||
* \internal
|
||||
*----------------------------------------------------------------------------------------
|
||||
* C O P Y R I G H T
|
||||
*----------------------------------------------------------------------------------------
|
||||
* Copyright (c) 2020 by Feaser http://www.feaser.com All rights reserved
|
||||
*
|
||||
*----------------------------------------------------------------------------------------
|
||||
* L I C E N S E
|
||||
*----------------------------------------------------------------------------------------
|
||||
* This file is part of OpenBLT. OpenBLT is free software: you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as published by the Free
|
||||
* Software Foundation, either version 3 of the License, or (at your option) any later
|
||||
* version.
|
||||
*
|
||||
* OpenBLT is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
|
||||
* without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
|
||||
* PURPOSE. See the GNU General Public License for more details.
|
||||
*
|
||||
* You have received a copy of the GNU General Public License along with OpenBLT. It
|
||||
* should be located in ".\Doc\license.html". If not, contact Feaser to obtain a copy.
|
||||
*
|
||||
* \endinternal
|
||||
****************************************************************************************/
|
||||
|
||||
/****************************************************************************************
|
||||
* Include files
|
||||
****************************************************************************************/
|
||||
#include "boot.h" /* bootloader generic header */
|
||||
#include "device_registers.h" /* device registers */
|
||||
#include "system_S32K144.h" /* device sconfiguration */
|
||||
|
||||
|
||||
/****************************************************************************************
|
||||
* Function prototypes
|
||||
****************************************************************************************/
|
||||
static void Init(void);
|
||||
static void SystemClockConfig(void);
|
||||
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief This is the entry point for the bootloader application and is called
|
||||
** by the reset interrupt vector after the C-startup routines executed.
|
||||
** \return Program return code.
|
||||
**
|
||||
****************************************************************************************/
|
||||
int main(void)
|
||||
{
|
||||
/* Initialize the microcontroller. */
|
||||
Init();
|
||||
/* Initialize the bootloader. */
|
||||
BootInit();
|
||||
|
||||
/* Start the infinite program loop. */
|
||||
while (1)
|
||||
{
|
||||
/* Run the bootloader task. */
|
||||
BootTask();
|
||||
}
|
||||
|
||||
/* Program should never get here. */
|
||||
return 0;
|
||||
} /*** end of main ***/
|
||||
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief Initializes the microcontroller.
|
||||
** \return none.
|
||||
**
|
||||
****************************************************************************************/
|
||||
static void Init(void)
|
||||
{
|
||||
/* Configure the system clock. */
|
||||
SystemClockConfig();
|
||||
/* Enable the peripheral clock for the ports that are used. */
|
||||
PCC->PCCn[PCC_PORTC_INDEX] |= PCC_PCCn_CGC_MASK;
|
||||
PCC->PCCn[PCC_PORTD_INDEX] |= PCC_PCCn_CGC_MASK;
|
||||
PCC->PCCn[PCC_PORTE_INDEX] |= PCC_PCCn_CGC_MASK;
|
||||
/* Configure SW2 (PC12) GPIO pin for (optional) backdoor entry input. */
|
||||
/* Input GPIO pin configuration. PC12 = GPIO, MUX = ALT1. */
|
||||
PORTC->PCR[12] |= PORT_PCR_MUX(1);
|
||||
/* Disable pull device, as SW2 already has a pull down resistor on the board. */
|
||||
PORTC->PCR[12] &= ~PORT_PCR_PE(1);
|
||||
/* Configure and enable Port C pin 12 GPIO as digital input */
|
||||
PTC->PDDR &= ~GPIO_PDDR_PDD(1 << 12U);
|
||||
PTC->PIDR &= ~GPIO_PIDR_PID(1 << 12U);
|
||||
#if (BOOT_COM_RS232_ENABLE > 0)
|
||||
/* UART RX GPIO pin configuration. PC6 = UART1 RX, MUX = ALT2. */
|
||||
PORTC->PCR[6] |= PORT_PCR_MUX(2);
|
||||
/* UART TX GPIO pin configuration. PC7 = UART1 TX, MUX = ALT2. */
|
||||
PORTC->PCR[7] |= PORT_PCR_MUX(2);
|
||||
#endif
|
||||
#if (BOOT_COM_CAN_ENABLE > 0)
|
||||
/* CAN RX GPIO pin configuration. PE4 = CAN0 RX, MUX = ALT5. */
|
||||
PORTE->PCR[4] |= PORT_PCR_MUX(5);
|
||||
/* CAN TX GPIO pin configuration. PE5 = CAN0 TX, MUX = ALT5. */
|
||||
PORTE->PCR[5] |= PORT_PCR_MUX(5);
|
||||
#endif
|
||||
} /*** end of Init ***/
|
||||
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief System Clock Configuration. This code was derived from a S32 Design Studio
|
||||
** example program. It uses the 8 MHz external crystal as a source for the
|
||||
** PLL and configures the normal RUN mode for the following clock settings:
|
||||
** - SPLL_CLK = 160 MHz
|
||||
** - CORE_CLK = 80 MHz
|
||||
** - SYS_CLK = 80 MHz
|
||||
** - BUS_CLK = 40 MHz
|
||||
** - FLASH_CLK = 26.67 MHz
|
||||
** - SIRCDIV1_CLK = 8 MHz
|
||||
** - SIRCDIV2_CLK = 8 MHz
|
||||
** \return none.
|
||||
**
|
||||
****************************************************************************************/
|
||||
static void SystemClockConfig(void)
|
||||
{
|
||||
/* --------- SOSC Initialization (8 MHz) ------------------------------------------- */
|
||||
/* SOSCDIV1 & SOSCDIV2 =1: divide by 1. */
|
||||
SCG->SOSCDIV = SCG_SOSCDIV_SOSCDIV1(1) | SCG_SOSCDIV_SOSCDIV2(1);
|
||||
/* Range=2: Medium freq (SOSC betw 1MHz-8MHz).
|
||||
* HGO=0: Config xtal osc for low power.
|
||||
* EREFS=1: Input is external XTAL.
|
||||
*/
|
||||
SCG->SOSCCFG = SCG_SOSCCFG_RANGE(2) | SCG_SOSCCFG_EREFS_MASK;
|
||||
/* Ensure SOSCCSR unlocked. */
|
||||
while (SCG->SOSCCSR & SCG_SOSCCSR_LK_MASK)
|
||||
{
|
||||
;
|
||||
}
|
||||
/* LK=0: SOSCCSR can be written.
|
||||
* SOSCCMRE=0: OSC CLK monitor IRQ if enabled.
|
||||
* SOSCCM=0: OSC CLK monitor disabled.
|
||||
* SOSCERCLKEN=0: Sys OSC 3V ERCLK output clk disabled.
|
||||
* SOSCLPEN=0: Sys OSC disabled in VLP modes.
|
||||
* SOSCSTEN=0: Sys OSC disabled in Stop modes.
|
||||
* SOSCEN=1: Enable oscillator.
|
||||
*/
|
||||
SCG->SOSCCSR = SCG_SOSCCSR_SOSCEN_MASK;
|
||||
/* Wait for system OSC clock to become valid. */
|
||||
while (!(SCG->SOSCCSR & SCG_SOSCCSR_SOSCVLD_MASK))
|
||||
{
|
||||
;
|
||||
}
|
||||
|
||||
/* --------- SPLL Initialization (160 MHz) ----------------------------------------- */
|
||||
/* Ensure SPLLCSR is unlocked. */
|
||||
while (SCG->SPLLCSR & SCG_SPLLCSR_LK_MASK)
|
||||
{
|
||||
;
|
||||
}
|
||||
/* SPLLEN=0: SPLL is disabled (default). */
|
||||
SCG->SPLLCSR &= ~SCG_SPLLCSR_SPLLEN_MASK;
|
||||
/* SPLLDIV1 divide by 2 and SPLLDIV2 divide by 4. */
|
||||
SCG->SPLLDIV |= SCG_SPLLDIV_SPLLDIV1(2) | SCG_SPLLDIV_SPLLDIV2(3);
|
||||
/* PREDIV=0: Divide SOSC_CLK by 0+1=1.
|
||||
* MULT=24: Multiply sys pll by 4+24=40.
|
||||
* SPLL_CLK = 8MHz / 1 * 40 / 2 = 160 MHz.
|
||||
*/
|
||||
SCG->SPLLCFG = SCG_SPLLCFG_MULT(24);
|
||||
/* Ensure SPLLCSR is unlocked. */
|
||||
while (SCG->SPLLCSR & SCG_SPLLCSR_LK_MASK)
|
||||
{
|
||||
;
|
||||
}
|
||||
/* LK=0: SPLLCSR can be written.
|
||||
* SPLLCMRE=0: SPLL CLK monitor IRQ if enabled.
|
||||
* SPLLCM=0: SPLL CLK monitor disabled.
|
||||
* SPLLSTEN=0: SPLL disabled in Stop modes.
|
||||
* SPLLEN=1: Enable SPLL.
|
||||
*/
|
||||
SCG->SPLLCSR |= SCG_SPLLCSR_SPLLEN_MASK;
|
||||
/* Wait for SPLL to become valid. */
|
||||
while (!(SCG->SPLLCSR & SCG_SPLLCSR_SPLLVLD_MASK))
|
||||
{
|
||||
;
|
||||
}
|
||||
|
||||
/* --------- SIRC Initialization --------------------------------------------------- */
|
||||
/* Slow IRC is enabled with high range (8 MHz) in reset. Enable SIRCDIV2_CLK and
|
||||
* SIRCDIV1_CLK, divide by 1 = 8MHz asynchronous clock source.
|
||||
*/
|
||||
SCG->SIRCDIV = SCG_SIRCDIV_SIRCDIV1(1) | SCG_SIRCDIV_SIRCDIV2(1);
|
||||
|
||||
/* --------- Change to normal RUN mode with 8MHz SOSC, 80 MHz PLL ------------------ */
|
||||
/* Note that flash memory should not be programmed or erased when the microcontroller
|
||||
* is operating in VLPr or HSRUN mode. Therefore normal RUN mode is configured.
|
||||
*/
|
||||
/* Select PLL as clock source.
|
||||
* DIVCORE=1, div. by 2: Core clock = 160/2 MHz = 80 MHz.
|
||||
* DIVBUS=1, div. by 2: bus clock = 40 MHz.
|
||||
* DIVSLOW=2, div. by 2: SCG slow, flash clock= 26 2/3 MHz.
|
||||
*/
|
||||
SCG->RCCR= SCG_RCCR_SCS(6) | SCG_RCCR_DIVCORE(0b01) | SCG_RCCR_DIVBUS(0b01) |
|
||||
SCG_RCCR_DIVSLOW(0b10);
|
||||
/* Wait until system clock source is SPLL. */
|
||||
while (((SCG->CSR & SCG_CSR_SCS_MASK) >> SCG_CSR_SCS_SHIFT ) != 6U)
|
||||
{
|
||||
;
|
||||
}
|
||||
/* Evaluate the clock register settings and calculates the current core clock. This
|
||||
* function must be called when the clock manager component is not used.
|
||||
*/
|
||||
SystemCoreClockUpdate();
|
||||
} /*** end of SystemClockConfig ***/
|
||||
|
||||
|
||||
/*********************************** end of main.c *************************************/
|
|
@ -0,0 +1,248 @@
|
|||
/*
|
||||
* Copyright (c) 2013 - 2014, Freescale Semiconductor, Inc.
|
||||
* Copyright 2016-2018 NXP
|
||||
* All rights reserved.
|
||||
*
|
||||
* THIS SOFTWARE IS PROVIDED BY NXP "AS IS" AND ANY EXPRESSED OR
|
||||
* IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
|
||||
* OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
|
||||
* IN NO EVENT SHALL NXP OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
|
||||
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
|
||||
* (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
|
||||
* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
||||
* HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
|
||||
* STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING
|
||||
* IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
|
||||
* THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
/**
|
||||
* @page misra_violations MISRA-C:2012 violations
|
||||
*
|
||||
* @section [global]
|
||||
* Violates MISRA 2012 Advisory Rule 8.9, An object should be defined at block
|
||||
* scope if its identifier only appears in a single function.
|
||||
* All variables with this problem are defined in the linker files.
|
||||
*
|
||||
* @section [global]
|
||||
* Violates MISRA 2012 Advisory Rule 8.11, When an array with external linkage
|
||||
* is declared, its size should be explicitly specified.
|
||||
* The size of the arrays can not be explicitly determined.
|
||||
*
|
||||
* @section [global]
|
||||
* Violates MISRA 2012 Advisory Rule 11.4, A conversion should not be performed
|
||||
* between a pointer to object and an integer type.
|
||||
* The cast is required to initialize a pointer with an unsigned int define,
|
||||
* representing an address.
|
||||
*
|
||||
* @section [global]
|
||||
* Violates MISRA 2012 Required Rule 11.6, A cast shall not be performed
|
||||
* between pointer to void and an arithmetic type.
|
||||
* The cast is required to initialize a pointer with an unsigned int define,
|
||||
* representing an address.
|
||||
*
|
||||
* @section [global]
|
||||
* Violates MISRA 2012 Required Rule 2.1, A project shall not contain unreachable
|
||||
* code.
|
||||
* The condition compares two address defined in linker files that can be different.
|
||||
*
|
||||
* @section [global]
|
||||
* Violates MISRA 2012 Advisory Rule 8.7, External could be made static.
|
||||
* Function is defined for usage by application code.
|
||||
*
|
||||
* @section [global]
|
||||
* Violates MISRA 2012 Mandatory Rule 17.3, Symbol 'MFSPR' undeclared, assumed
|
||||
* to return int.
|
||||
* This is an e200 Power Architecture Assembly instruction used to retrieve
|
||||
* the core number.
|
||||
*
|
||||
*/
|
||||
|
||||
#include "startup.h"
|
||||
#include <stdint.h>
|
||||
|
||||
|
||||
/*******************************************************************************
|
||||
* Static Variables
|
||||
******************************************************************************/
|
||||
static volatile uint32_t * const s_vectors[NUMBER_OF_CORES] = FEATURE_INTERRUPT_INT_VECTORS;
|
||||
|
||||
/*******************************************************************************
|
||||
* Code
|
||||
******************************************************************************/
|
||||
|
||||
/*FUNCTION**********************************************************************
|
||||
*
|
||||
* Function Name : init_data_bss
|
||||
* Description : Make necessary initializations for RAM.
|
||||
* - Copy the vector table from ROM to RAM.
|
||||
* - Copy initialized data from ROM to RAM.
|
||||
* - Copy code that should reside in RAM from ROM
|
||||
* - Clear the zero-initialized data section.
|
||||
*
|
||||
* Tool Chains:
|
||||
* __GNUC__ : GNU Compiler Collection
|
||||
* __ghs__ : Green Hills ARM Compiler
|
||||
* __ICCARM__ : IAR ARM Compiler
|
||||
* __DCC__ : Wind River Diab Compiler
|
||||
* __ARMCC_VERSION : ARMC Compiler
|
||||
*
|
||||
* Implements : init_data_bss_Activity
|
||||
*END**************************************************************************/
|
||||
void init_data_bss(void)
|
||||
{
|
||||
uint32_t n;
|
||||
uint8_t coreId;
|
||||
/* For ARMC we are using the library method of initializing DATA, Custom Section and
|
||||
* Code RAM sections so the below variables are not needed */
|
||||
#if !defined(__ARMCC_VERSION)
|
||||
/* Declare pointers for various data sections. These pointers
|
||||
* are initialized using values pulled in from the linker file */
|
||||
uint8_t * data_ram;
|
||||
uint8_t * code_ram;
|
||||
uint8_t * bss_start;
|
||||
uint8_t * custom_ram;
|
||||
const uint8_t * data_rom, * data_rom_end;
|
||||
const uint8_t * code_rom, * code_rom_end;
|
||||
const uint8_t * bss_end;
|
||||
const uint8_t * custom_rom, * custom_rom_end;
|
||||
#endif
|
||||
/* Addresses for VECTOR_TABLE and VECTOR_RAM come from the linker file */
|
||||
|
||||
#if defined(__ARMCC_VERSION)
|
||||
extern uint32_t __RAM_VECTOR_TABLE_SIZE;
|
||||
extern uint32_t __VECTOR_ROM;
|
||||
extern uint32_t __VECTOR_RAM;
|
||||
#else
|
||||
extern uint32_t __RAM_VECTOR_TABLE_SIZE[];
|
||||
extern uint32_t __VECTOR_TABLE[];
|
||||
extern uint32_t __VECTOR_RAM[];
|
||||
#endif
|
||||
/* Get section information from linker files */
|
||||
#if defined(__ICCARM__)
|
||||
/* Data */
|
||||
data_ram = __section_begin(".data");
|
||||
data_rom = __section_begin(".data_init");
|
||||
data_rom_end = __section_end(".data_init");
|
||||
|
||||
/* CODE RAM */
|
||||
#pragma section = "__CODE_ROM"
|
||||
#pragma section = "__CODE_RAM"
|
||||
code_ram = __section_begin("__CODE_RAM");
|
||||
code_rom = __section_begin("__CODE_ROM");
|
||||
code_rom_end = __section_end("__CODE_ROM");
|
||||
|
||||
/* BSS */
|
||||
bss_start = __section_begin(".bss");
|
||||
bss_end = __section_end(".bss");
|
||||
|
||||
custom_ram = __section_begin(".customSection");
|
||||
custom_rom = __section_begin(".customSection_init");
|
||||
custom_rom_end = __section_end(".customSection_init");
|
||||
|
||||
#elif defined (__ARMCC_VERSION)
|
||||
/* VECTOR TABLE*/
|
||||
uint8_t * vector_table_size = (uint8_t *)__RAM_VECTOR_TABLE_SIZE;
|
||||
uint32_t * vector_rom = (uint32_t *)__VECTOR_ROM;
|
||||
uint32_t * vector_ram = (uint32_t *)__VECTOR_RAM;
|
||||
#else
|
||||
extern uint32_t __DATA_ROM[];
|
||||
extern uint32_t __DATA_RAM[];
|
||||
extern uint32_t __DATA_END[];
|
||||
|
||||
extern uint32_t __CODE_RAM[];
|
||||
extern uint32_t __CODE_ROM[];
|
||||
extern uint32_t __CODE_END[];
|
||||
|
||||
extern uint32_t __BSS_START[];
|
||||
extern uint32_t __BSS_END[];
|
||||
|
||||
extern uint32_t __CUSTOM_ROM[];
|
||||
extern uint32_t __CUSTOM_END[];
|
||||
|
||||
/* Data */
|
||||
data_ram = (uint8_t *)__DATA_RAM;
|
||||
data_rom = (uint8_t *)__DATA_ROM;
|
||||
data_rom_end = (uint8_t *)__DATA_END;
|
||||
/* CODE RAM */
|
||||
code_ram = (uint8_t *)__CODE_RAM;
|
||||
code_rom = (uint8_t *)__CODE_ROM;
|
||||
code_rom_end = (uint8_t *)__CODE_END;
|
||||
/* BSS */
|
||||
bss_start = (uint8_t *)__BSS_START;
|
||||
bss_end = (uint8_t *)__BSS_END;
|
||||
|
||||
/* Custom section */
|
||||
custom_ram = CUSTOMSECTION_SECTION_START;
|
||||
custom_rom = (uint8_t *)__CUSTOM_ROM;
|
||||
custom_rom_end = (uint8_t *)__CUSTOM_END;
|
||||
|
||||
#endif
|
||||
|
||||
#if !defined(__ARMCC_VERSION)
|
||||
/* Copy initialized data from ROM to RAM */
|
||||
while (data_rom_end != data_rom)
|
||||
{
|
||||
*data_ram = *data_rom;
|
||||
data_ram++;
|
||||
data_rom++;
|
||||
}
|
||||
|
||||
/* Copy functions from ROM to RAM */
|
||||
while (code_rom_end != code_rom)
|
||||
{
|
||||
*code_ram = *code_rom;
|
||||
code_ram++;
|
||||
code_rom++;
|
||||
}
|
||||
|
||||
/* Clear the zero-initialized data section */
|
||||
while(bss_end != bss_start)
|
||||
{
|
||||
*bss_start = 0;
|
||||
bss_start++;
|
||||
}
|
||||
|
||||
/* Copy customsection rom to ram */
|
||||
while(custom_rom_end != custom_rom)
|
||||
{
|
||||
*custom_ram = *custom_rom;
|
||||
custom_rom++;
|
||||
custom_ram++;
|
||||
}
|
||||
#endif
|
||||
coreId = (uint8_t)GET_CORE_ID();
|
||||
#if defined (__ARMCC_VERSION)
|
||||
/* Copy the vector table from ROM to RAM */
|
||||
/* Workaround */
|
||||
for (n = 0; n < (((uint32_t)(vector_table_size))/sizeof(uint32_t)); n++)
|
||||
{
|
||||
vector_ram[n] = vector_rom[n];
|
||||
}
|
||||
/* Point the VTOR to the position of vector table */
|
||||
*s_vectors[coreId] = (uint32_t) __VECTOR_RAM;
|
||||
#else
|
||||
/* Check if VECTOR_TABLE copy is needed */
|
||||
if (__VECTOR_RAM != __VECTOR_TABLE)
|
||||
{
|
||||
/* Copy the vector table from ROM to RAM */
|
||||
for (n = 0; n < (((uint32_t)__RAM_VECTOR_TABLE_SIZE)/sizeof(uint32_t)); n++)
|
||||
{
|
||||
__VECTOR_RAM[n] = __VECTOR_TABLE[n];
|
||||
}
|
||||
/* Point the VTOR to the position of vector table */
|
||||
*s_vectors[coreId] = (uint32_t)__VECTOR_RAM;
|
||||
}
|
||||
else
|
||||
{
|
||||
/* Point the VTOR to the position of vector table */
|
||||
*s_vectors[coreId] = (uint32_t)__VECTOR_TABLE;
|
||||
}
|
||||
#endif
|
||||
|
||||
}
|
||||
|
||||
/*******************************************************************************
|
||||
* EOF
|
||||
******************************************************************************/
|
||||
|
|
@ -0,0 +1,133 @@
|
|||
/*
|
||||
* Copyright (c) 2013 - 2014, Freescale Semiconductor, Inc.
|
||||
* Copyright 2016-2019 NXP
|
||||
* All rights reserved.
|
||||
*
|
||||
* THIS SOFTWARE IS PROVIDED BY NXP "AS IS" AND ANY EXPRESSED OR
|
||||
* IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
|
||||
* OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
|
||||
* IN NO EVENT SHALL NXP OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
|
||||
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
|
||||
* (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
|
||||
* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
||||
* HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
|
||||
* STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING
|
||||
* IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
|
||||
* THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
#ifndef STARTUP_H
|
||||
#define STARTUP_H
|
||||
|
||||
#include <stdint.h>
|
||||
#include "device_registers.h"
|
||||
/**
|
||||
* @page misra_violations MISRA-C:2012 violations
|
||||
*
|
||||
* @section [global]
|
||||
* Violates MISRA 2012 Advisory Rule 2.5, Local macro not referenced.
|
||||
* The defined macro is used as include guard.
|
||||
*
|
||||
* @section [global]
|
||||
* Violates MISRA 2012 Advisory Rule 8.9, An object should be defined at block
|
||||
* scope if its identifier only appears in a single function.
|
||||
* All variables with this problem are defined in the linker files.
|
||||
*
|
||||
*/
|
||||
|
||||
/*******************************************************************************
|
||||
* API
|
||||
******************************************************************************/
|
||||
|
||||
/*!
|
||||
* @brief define symbols that specific start and end addres of some basic sections.
|
||||
*/
|
||||
#if (defined(S32K14x_SERIES) || defined(S32K11x_SERIES) || defined(S32V234_SERIES) || defined(MPC574x_SERIES) || defined(S32R_SERIES) || defined(S32MTV_SERIES) || defined(SJA1110_SERIES)) || defined (S32K144W_M4_SERIES)
|
||||
#if (defined(__ICCARM__))
|
||||
#define INTERRUPTS_SECTION_START __section_begin(".intvec")
|
||||
#define INTERRUPTS_SECTION_END __section_end(".intvec")
|
||||
#define BSS_SECTION_START __section_begin(".bss")
|
||||
#define BSS_SECTION_END __section_end(".bss")
|
||||
#define DATA_SECTION_START __section_begin(".data")
|
||||
#define DATA_SECTION_END __section_end(".data")
|
||||
#define CUSTOMSECTION_SECTION_START __section_begin(".customSection")
|
||||
#define CUSTOMSECTION_SECTION_END __section_end(".customSection")
|
||||
#define CODE_RAM_SECTION_START __section_begin("__CODE_RAM")
|
||||
#define CODE_RAM_SECTION_END __section_end("__CODE_RAM")
|
||||
#define DATA_INIT_SECTION_START __section_begin(".data_init")
|
||||
#define DATA_INIT_SECTION_END __section_end(".data_init")
|
||||
#define CODE_ROM_SECTION_START __section_begin("__CODE_ROM")
|
||||
#define CODE_ROM_SECTION_END __section_end("__CODE_ROM")
|
||||
|
||||
#elif (defined(__ARMCC_VERSION))
|
||||
#define INTERRUPTS_SECTION_START (uint8_t *)__VECTOR_ROM_START
|
||||
#define INTERRUPTS_SECTION_END (uint8_t *)__VECTOR_ROM_END
|
||||
#define BSS_SECTION_START (uint8_t *)__BSS_START
|
||||
#define BSS_SECTION_END (uint8_t *)__BSS_END
|
||||
#define DATA_SECTION_START (uint8_t *)__DATA_RAM_START
|
||||
#define DATA_SECTION_END (uint8_t *)__DATA_RAM_END
|
||||
#define CUSTOMSECTION_SECTION_START (uint8_t *)__CUSTOM_SECTION_START
|
||||
#define CUSTOMSECTION_SECTION_END (uint8_t *)__CUSTOM_SECTION_END
|
||||
#define CODE_RAM_SECTION_START (uint8_t *)__CODE_RAM_START
|
||||
#define CODE_RAM_SECTION_END (uint8_t *)__CODE_RAM_END
|
||||
|
||||
extern uint32_t __VECTOR_ROM_START;
|
||||
extern uint32_t __VECTOR_ROM_END;
|
||||
extern uint32_t __BSS_START;
|
||||
extern uint32_t __BSS_END;
|
||||
extern uint32_t __DATA_RAM_START;
|
||||
extern uint32_t __DATA_RAM_END;
|
||||
extern uint32_t __CUSTOM_SECTION_START;
|
||||
extern uint32_t __CUSTOM_SECTION_END;
|
||||
extern uint32_t __CODE_RAM_START;
|
||||
extern uint32_t __CODE_RAM_END;
|
||||
#else
|
||||
#define INTERRUPTS_SECTION_START (uint8_t *)&__interrupts_start__
|
||||
#define INTERRUPTS_SECTION_END (uint8_t *)&__interrupts_end__
|
||||
#define BSS_SECTION_START (uint8_t *)&__bss_start__
|
||||
#define BSS_SECTION_END (uint8_t *)&__bss_end__
|
||||
#define DATA_SECTION_START (uint8_t *)&__data_start__
|
||||
#define DATA_SECTION_END (uint8_t *)&__data_end__
|
||||
#define CUSTOMSECTION_SECTION_START (uint8_t *)&__customSection_start__
|
||||
#define CUSTOMSECTION_SECTION_END (uint8_t *)&__customSection_end__
|
||||
#define CODE_RAM_SECTION_START (uint8_t *)&__code_ram_start__
|
||||
#define CODE_RAM_SECTION_END (uint8_t *)&__code_ram_end__
|
||||
|
||||
extern uint32_t __interrupts_start__;
|
||||
extern uint32_t __interrupts_end__;
|
||||
extern uint32_t __bss_start__;
|
||||
extern uint32_t __bss_end__;
|
||||
extern uint32_t __data_start__;
|
||||
extern uint32_t __data_end__;
|
||||
extern uint32_t __customSection_start__;
|
||||
extern uint32_t __customSection_end__;
|
||||
extern uint32_t __code_ram_start__;
|
||||
extern uint32_t __code_ram_end__;
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#if (defined(__ICCARM__))
|
||||
#pragma section = ".data"
|
||||
#pragma section = ".data_init"
|
||||
#pragma section = ".bss"
|
||||
#pragma section = ".intvec"
|
||||
#pragma section = ".customSection"
|
||||
#pragma section = ".customSection_init"
|
||||
#pragma section = "__CODE_RAM"
|
||||
#pragma section = "__CODE_ROM"
|
||||
#endif
|
||||
|
||||
/*!
|
||||
* @brief Make necessary initializations for RAM.
|
||||
*
|
||||
* - Copy initialized data from ROM to RAM.
|
||||
* - Clear the zero-initialized data section.
|
||||
* - Copy the vector table from ROM to RAM. This could be an option.
|
||||
*/
|
||||
void init_data_bss(void);
|
||||
|
||||
#endif /* STARTUP_H*/
|
||||
/*******************************************************************************
|
||||
* EOF
|
||||
******************************************************************************/
|
||||
|
|
@ -0,0 +1,531 @@
|
|||
/* ---------------------------------------------------------------------------------------*/
|
||||
/* @file: startup_S32K144.s */
|
||||
/* @purpose: GNU Compiler Collection Startup File */
|
||||
/* S32K144 */
|
||||
/* @version: 2.0 */
|
||||
/* @date: 2017-1-10 */
|
||||
/* @build: b170107 */
|
||||
/* ---------------------------------------------------------------------------------------*/
|
||||
/* */
|
||||
/* Copyright (c) 1997 - 2016 , Freescale Semiconductor, Inc. */
|
||||
/* Copyright 2016-2017 NXP */
|
||||
/* All rights reserved. */
|
||||
/* */
|
||||
/* THIS SOFTWARE IS PROVIDED BY NXP "AS IS" AND ANY EXPRESSED OR */
|
||||
/* IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES */
|
||||
/* OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. */
|
||||
/* IN NO EVENT SHALL NXP OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, */
|
||||
/* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES */
|
||||
/* (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR */
|
||||
/* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) */
|
||||
/* HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, */
|
||||
/* STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING */
|
||||
/* IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF */
|
||||
/* THE POSSIBILITY OF SUCH DAMAGE. */
|
||||
/*****************************************************************************/
|
||||
/* Version: GNU Compiler Collection */
|
||||
/*****************************************************************************/
|
||||
.syntax unified
|
||||
.arch armv7-m
|
||||
|
||||
.section .isr_vector, "a"
|
||||
.align 2
|
||||
.globl __isr_vector
|
||||
__isr_vector:
|
||||
.long __StackTop /* Top of Stack */
|
||||
.long Reset_Handler /* Reset Handler */
|
||||
.long NMI_Handler /* NMI Handler*/
|
||||
.long HardFault_Handler /* Hard Fault Handler*/
|
||||
.long MemManage_Handler /* MPU Fault Handler*/
|
||||
.long BusFault_Handler /* Bus Fault Handler*/
|
||||
.long UsageFault_Handler /* Usage Fault Handler*/
|
||||
.long 0 /* Reserved*/
|
||||
.long 0 /* Reserved*/
|
||||
.long 0 /* Reserved*/
|
||||
.long 0 /* Reserved*/
|
||||
.long SVC_Handler /* SVCall Handler*/
|
||||
.long DebugMon_Handler /* Debug Monitor Handler*/
|
||||
.long 0 /* Reserved*/
|
||||
.long PendSV_Handler /* PendSV Handler*/
|
||||
.long SysTick_Handler /* SysTick Handler*/
|
||||
|
||||
/* External Interrupts*/
|
||||
.long DMA0_IRQHandler /* DMA channel 0 transfer complete*/
|
||||
.long DMA1_IRQHandler /* DMA channel 1 transfer complete*/
|
||||
.long DMA2_IRQHandler /* DMA channel 2 transfer complete*/
|
||||
.long DMA3_IRQHandler /* DMA channel 3 transfer complete*/
|
||||
.long DMA4_IRQHandler /* DMA channel 4 transfer complete*/
|
||||
.long DMA5_IRQHandler /* DMA channel 5 transfer complete*/
|
||||
.long DMA6_IRQHandler /* DMA channel 6 transfer complete*/
|
||||
.long DMA7_IRQHandler /* DMA channel 7 transfer complete*/
|
||||
.long DMA8_IRQHandler /* DMA channel 8 transfer complete*/
|
||||
.long DMA9_IRQHandler /* DMA channel 9 transfer complete*/
|
||||
.long DMA10_IRQHandler /* DMA channel 10 transfer complete*/
|
||||
.long DMA11_IRQHandler /* DMA channel 11 transfer complete*/
|
||||
.long DMA12_IRQHandler /* DMA channel 12 transfer complete*/
|
||||
.long DMA13_IRQHandler /* DMA channel 13 transfer complete*/
|
||||
.long DMA14_IRQHandler /* DMA channel 14 transfer complete*/
|
||||
.long DMA15_IRQHandler /* DMA channel 15 transfer complete*/
|
||||
.long DMA_Error_IRQHandler /* DMA error interrupt channels 0-15*/
|
||||
.long MCM_IRQHandler /* FPU sources*/
|
||||
.long FTFC_IRQHandler /* FTFC Command complete*/
|
||||
.long Read_Collision_IRQHandler /* FTFC Read collision*/
|
||||
.long LVD_LVW_IRQHandler /* PMC Low voltage detect interrupt*/
|
||||
.long FTFC_Fault_IRQHandler /* FTFC Double bit fault detect*/
|
||||
.long WDOG_EWM_IRQHandler /* Single interrupt vector for WDOG and EWM*/
|
||||
.long RCM_IRQHandler /* RCM Asynchronous Interrupt*/
|
||||
.long LPI2C0_Master_IRQHandler /* LPI2C0 Master Interrupt*/
|
||||
.long LPI2C0_Slave_IRQHandler /* LPI2C0 Slave Interrupt*/
|
||||
.long LPSPI0_IRQHandler /* LPSPI0 Interrupt*/
|
||||
.long LPSPI1_IRQHandler /* LPSPI1 Interrupt*/
|
||||
.long LPSPI2_IRQHandler /* LPSPI2 Interrupt*/
|
||||
.long Reserved45_IRQHandler /* Reserved Interrupt 45*/
|
||||
.long Reserved46_IRQHandler /* Reserved Interrupt 46*/
|
||||
.long LPUART0_RxTx_IRQHandler /* LPUART0 Transmit / Receive Interrupt*/
|
||||
.long Reserved48_IRQHandler /* Reserved Interrupt 48*/
|
||||
.long LPUART1_RxTx_IRQHandler /* LPUART1 Transmit / Receive Interrupt*/
|
||||
.long Reserved50_IRQHandler /* Reserved Interrupt 50*/
|
||||
.long LPUART2_RxTx_IRQHandler /* LPUART2 Transmit / Receive Interrupt*/
|
||||
.long Reserved52_IRQHandler /* Reserved Interrupt 52*/
|
||||
.long Reserved53_IRQHandler /* Reserved Interrupt 53*/
|
||||
.long Reserved54_IRQHandler /* Reserved Interrupt 54*/
|
||||
.long ADC0_IRQHandler /* ADC0 interrupt request.*/
|
||||
.long ADC1_IRQHandler /* ADC1 interrupt request.*/
|
||||
.long CMP0_IRQHandler /* CMP0 interrupt request*/
|
||||
.long Reserved58_IRQHandler /* Reserved Interrupt 58*/
|
||||
.long Reserved59_IRQHandler /* Reserved Interrupt 59*/
|
||||
.long ERM_single_fault_IRQHandler /* ERM single bit error correction*/
|
||||
.long ERM_double_fault_IRQHandler /* ERM double bit error non-correctable*/
|
||||
.long RTC_IRQHandler /* RTC alarm interrupt*/
|
||||
.long RTC_Seconds_IRQHandler /* RTC seconds interrupt*/
|
||||
.long LPIT0_Ch0_IRQHandler /* LPIT0 channel 0 overflow interrupt*/
|
||||
.long LPIT0_Ch1_IRQHandler /* LPIT0 channel 1 overflow interrupt*/
|
||||
.long LPIT0_Ch2_IRQHandler /* LPIT0 channel 2 overflow interrupt*/
|
||||
.long LPIT0_Ch3_IRQHandler /* LPIT0 channel 3 overflow interrupt*/
|
||||
.long PDB0_IRQHandler /* PDB0 interrupt*/
|
||||
.long Reserved69_IRQHandler /* Reserved Interrupt 69*/
|
||||
.long Reserved70_IRQHandler /* Reserved Interrupt 70*/
|
||||
.long Reserved71_IRQHandler /* Reserved Interrupt 71*/
|
||||
.long Reserved72_IRQHandler /* Reserved Interrupt 72*/
|
||||
.long SCG_IRQHandler /* SCG bus interrupt request*/
|
||||
.long LPTMR0_IRQHandler /* LPTIMER interrupt request*/
|
||||
.long PORTA_IRQHandler /* Port A pin detect interrupt*/
|
||||
.long PORTB_IRQHandler /* Port B pin detect interrupt*/
|
||||
.long PORTC_IRQHandler /* Port C pin detect interrupt*/
|
||||
.long PORTD_IRQHandler /* Port D pin detect interrupt*/
|
||||
.long PORTE_IRQHandler /* Port E pin detect interrupt*/
|
||||
.long SWI_IRQHandler /* Software interrupt*/
|
||||
.long Reserved81_IRQHandler /* Reserved Interrupt 81*/
|
||||
.long Reserved82_IRQHandler /* Reserved Interrupt 82*/
|
||||
.long Reserved83_IRQHandler /* Reserved Interrupt 83*/
|
||||
.long PDB1_IRQHandler /* PDB1 interrupt*/
|
||||
.long FLEXIO_IRQHandler /* FlexIO Interrupt*/
|
||||
.long Reserved86_IRQHandler /* Reserved Interrupt 86*/
|
||||
.long Reserved87_IRQHandler /* Reserved Interrupt 87*/
|
||||
.long Reserved88_IRQHandler /* Reserved Interrupt 88*/
|
||||
.long Reserved89_IRQHandler /* Reserved Interrupt 89*/
|
||||
.long Reserved90_IRQHandler /* Reserved Interrupt 90*/
|
||||
.long Reserved91_IRQHandler /* Reserved Interrupt 91*/
|
||||
.long Reserved92_IRQHandler /* Reserved Interrupt 92*/
|
||||
.long Reserved93_IRQHandler /* Reserved Interrupt 93*/
|
||||
.long CAN0_ORed_IRQHandler /* CAN0 OR'ed [Bus Off OR Transmit Warning OR Receive Warning]*/
|
||||
.long CAN0_Error_IRQHandler /* CAN0 Interrupt indicating that errors were detected on the CAN bus*/
|
||||
.long CAN0_Wake_Up_IRQHandler /* CAN0 Interrupt asserted when Pretended Networking operation is enabled, and a valid message matches the selected filter criteria during Low Power mode*/
|
||||
.long CAN0_ORed_0_15_MB_IRQHandler /* CAN0 OR'ed Message buffer (0-15)*/
|
||||
.long CAN0_ORed_16_31_MB_IRQHandler /* CAN0 OR'ed Message buffer (16-31)*/
|
||||
.long Reserved99_IRQHandler /* Reserved Interrupt 99*/
|
||||
.long Reserved100_IRQHandler /* Reserved Interrupt 100*/
|
||||
.long CAN1_ORed_IRQHandler /* CAN1 OR'ed [Bus Off OR Transmit Warning OR Receive Warning]*/
|
||||
.long CAN1_Error_IRQHandler /* CAN1 Interrupt indicating that errors were detected on the CAN bus*/
|
||||
.long Reserved103_IRQHandler /* Reserved Interrupt 103*/
|
||||
.long CAN1_ORed_0_15_MB_IRQHandler /* CAN1 OR'ed Interrupt for Message buffer (0-15)*/
|
||||
.long Reserved105_IRQHandler /* Reserved Interrupt 105*/
|
||||
.long Reserved106_IRQHandler /* Reserved Interrupt 106*/
|
||||
.long Reserved107_IRQHandler /* Reserved Interrupt 107*/
|
||||
.long CAN2_ORed_IRQHandler /* CAN2 OR'ed [Bus Off OR Transmit Warning OR Receive Warning]*/
|
||||
.long CAN2_Error_IRQHandler /* CAN2 Interrupt indicating that errors were detected on the CAN bus*/
|
||||
.long Reserved110_IRQHandler /* Reserved Interrupt 110*/
|
||||
.long CAN2_ORed_0_15_MB_IRQHandler /* CAN2 OR'ed Message buffer (0-15)*/
|
||||
.long Reserved112_IRQHandler /* Reserved Interrupt 112*/
|
||||
.long Reserved113_IRQHandler /* Reserved Interrupt 113*/
|
||||
.long Reserved114_IRQHandler /* Reserved Interrupt 114*/
|
||||
.long FTM0_Ch0_Ch1_IRQHandler /* FTM0 Channel 0 and 1 interrupt*/
|
||||
.long FTM0_Ch2_Ch3_IRQHandler /* FTM0 Channel 2 and 3 interrupt*/
|
||||
.long FTM0_Ch4_Ch5_IRQHandler /* FTM0 Channel 4 and 5 interrupt*/
|
||||
.long FTM0_Ch6_Ch7_IRQHandler /* FTM0 Channel 6 and 7 interrupt*/
|
||||
.long FTM0_Fault_IRQHandler /* FTM0 Fault interrupt*/
|
||||
.long FTM0_Ovf_Reload_IRQHandler /* FTM0 Counter overflow and Reload interrupt*/
|
||||
.long FTM1_Ch0_Ch1_IRQHandler /* FTM1 Channel 0 and 1 interrupt*/
|
||||
.long FTM1_Ch2_Ch3_IRQHandler /* FTM1 Channel 2 and 3 interrupt*/
|
||||
.long FTM1_Ch4_Ch5_IRQHandler /* FTM1 Channel 4 and 5 interrupt*/
|
||||
.long FTM1_Ch6_Ch7_IRQHandler /* FTM1 Channel 6 and 7 interrupt*/
|
||||
.long FTM1_Fault_IRQHandler /* FTM1 Fault interrupt*/
|
||||
.long FTM1_Ovf_Reload_IRQHandler /* FTM1 Counter overflow and Reload interrupt*/
|
||||
.long FTM2_Ch0_Ch1_IRQHandler /* FTM2 Channel 0 and 1 interrupt*/
|
||||
.long FTM2_Ch2_Ch3_IRQHandler /* FTM2 Channel 2 and 3 interrupt*/
|
||||
.long FTM2_Ch4_Ch5_IRQHandler /* FTM2 Channel 4 and 5 interrupt*/
|
||||
.long FTM2_Ch6_Ch7_IRQHandler /* FTM2 Channel 6 and 7 interrupt*/
|
||||
.long FTM2_Fault_IRQHandler /* FTM2 Fault interrupt*/
|
||||
.long FTM2_Ovf_Reload_IRQHandler /* FTM2 Counter overflow and Reload interrupt*/
|
||||
.long FTM3_Ch0_Ch1_IRQHandler /* FTM3 Channel 0 and 1 interrupt*/
|
||||
.long FTM3_Ch2_Ch3_IRQHandler /* FTM3 Channel 2 and 3 interrupt*/
|
||||
.long FTM3_Ch4_Ch5_IRQHandler /* FTM3 Channel 4 and 5 interrupt*/
|
||||
.long FTM3_Ch6_Ch7_IRQHandler /* FTM3 Channel 6 and 7 interrupt*/
|
||||
.long FTM3_Fault_IRQHandler /* FTM3 Fault interrupt*/
|
||||
.long FTM3_Ovf_Reload_IRQHandler /* FTM3 Counter overflow and Reload interrupt*/
|
||||
.long DefaultISR /* 139*/
|
||||
.long DefaultISR /* 140*/
|
||||
.long DefaultISR /* 141*/
|
||||
.long DefaultISR /* 142*/
|
||||
.long DefaultISR /* 143*/
|
||||
.long DefaultISR /* 144*/
|
||||
.long DefaultISR /* 145*/
|
||||
.long DefaultISR /* 146*/
|
||||
.long DefaultISR /* 147*/
|
||||
.long DefaultISR /* 148*/
|
||||
.long DefaultISR /* 149*/
|
||||
.long DefaultISR /* 150*/
|
||||
.long DefaultISR /* 151*/
|
||||
.long DefaultISR /* 152*/
|
||||
.long DefaultISR /* 153*/
|
||||
.long DefaultISR /* 154*/
|
||||
.long DefaultISR /* 155*/
|
||||
.long DefaultISR /* 156*/
|
||||
.long DefaultISR /* 157*/
|
||||
.long DefaultISR /* 158*/
|
||||
.long DefaultISR /* 159*/
|
||||
.long DefaultISR /* 160*/
|
||||
.long DefaultISR /* 161*/
|
||||
.long DefaultISR /* 162*/
|
||||
.long DefaultISR /* 163*/
|
||||
.long DefaultISR /* 164*/
|
||||
.long DefaultISR /* 165*/
|
||||
.long DefaultISR /* 166*/
|
||||
.long DefaultISR /* 167*/
|
||||
.long DefaultISR /* 168*/
|
||||
.long DefaultISR /* 169*/
|
||||
.long DefaultISR /* 170*/
|
||||
.long DefaultISR /* 171*/
|
||||
.long DefaultISR /* 172*/
|
||||
.long DefaultISR /* 173*/
|
||||
.long DefaultISR /* 174*/
|
||||
.long DefaultISR /* 175*/
|
||||
.long DefaultISR /* 176*/
|
||||
.long DefaultISR /* 177*/
|
||||
.long DefaultISR /* 178*/
|
||||
.long DefaultISR /* 179*/
|
||||
.long DefaultISR /* 180*/
|
||||
.long DefaultISR /* 181*/
|
||||
.long DefaultISR /* 182*/
|
||||
.long DefaultISR /* 183*/
|
||||
.long DefaultISR /* 184*/
|
||||
.long DefaultISR /* 185*/
|
||||
.long DefaultISR /* 186*/
|
||||
.long DefaultISR /* 187*/
|
||||
.long DefaultISR /* 188*/
|
||||
.long DefaultISR /* 189*/
|
||||
.long DefaultISR /* 190*/
|
||||
.long DefaultISR /* 191*/
|
||||
.long DefaultISR /* 192*/
|
||||
.long DefaultISR /* 193*/
|
||||
.long DefaultISR /* 194*/
|
||||
.long DefaultISR /* 195*/
|
||||
.long DefaultISR /* 196*/
|
||||
.long DefaultISR /* 197*/
|
||||
.long DefaultISR /* 198*/
|
||||
.long DefaultISR /* 199*/
|
||||
.long DefaultISR /* 200*/
|
||||
.long DefaultISR /* 201*/
|
||||
.long DefaultISR /* 202*/
|
||||
.long DefaultISR /* 203*/
|
||||
.long DefaultISR /* 204*/
|
||||
.long DefaultISR /* 205*/
|
||||
.long DefaultISR /* 206*/
|
||||
.long DefaultISR /* 207*/
|
||||
.long DefaultISR /* 208*/
|
||||
.long DefaultISR /* 209*/
|
||||
.long DefaultISR /* 210*/
|
||||
.long DefaultISR /* 211*/
|
||||
.long DefaultISR /* 212*/
|
||||
.long DefaultISR /* 213*/
|
||||
.long DefaultISR /* 214*/
|
||||
.long DefaultISR /* 215*/
|
||||
.long DefaultISR /* 216*/
|
||||
.long DefaultISR /* 217*/
|
||||
.long DefaultISR /* 218*/
|
||||
.long DefaultISR /* 219*/
|
||||
.long DefaultISR /* 220*/
|
||||
.long DefaultISR /* 221*/
|
||||
.long DefaultISR /* 222*/
|
||||
.long DefaultISR /* 223*/
|
||||
.long DefaultISR /* 224*/
|
||||
.long DefaultISR /* 225*/
|
||||
.long DefaultISR /* 226*/
|
||||
.long DefaultISR /* 227*/
|
||||
.long DefaultISR /* 228*/
|
||||
.long DefaultISR /* 229*/
|
||||
.long DefaultISR /* 230*/
|
||||
.long DefaultISR /* 231*/
|
||||
.long DefaultISR /* 232*/
|
||||
.long DefaultISR /* 233*/
|
||||
.long DefaultISR /* 234*/
|
||||
.long DefaultISR /* 235*/
|
||||
.long DefaultISR /* 236*/
|
||||
.long DefaultISR /* 237*/
|
||||
.long DefaultISR /* 238*/
|
||||
.long DefaultISR /* 239*/
|
||||
.long DefaultISR /* 240*/
|
||||
.long DefaultISR /* 241*/
|
||||
.long DefaultISR /* 242*/
|
||||
.long DefaultISR /* 243*/
|
||||
.long DefaultISR /* 244*/
|
||||
.long DefaultISR /* 245*/
|
||||
.long DefaultISR /* 246*/
|
||||
.long DefaultISR /* 247*/
|
||||
.long DefaultISR /* 248*/
|
||||
.long DefaultISR /* 249*/
|
||||
.long DefaultISR /* 250*/
|
||||
.long DefaultISR /* 251*/
|
||||
.long DefaultISR /* 252*/
|
||||
.long DefaultISR /* 253*/
|
||||
.long DefaultISR /* 254*/
|
||||
.long 0xFFFFFFFF /* Reserved for user TRIM value*/
|
||||
|
||||
.size __isr_vector, . - __isr_vector
|
||||
|
||||
/* Flash Configuration */
|
||||
.section .FlashConfig, "a"
|
||||
.long 0xFFFFFFFF /* 8 bytes backdoor comparison key */
|
||||
.long 0xFFFFFFFF /* */
|
||||
.long 0xFFFFFFFF /* 4 bytes program flash protection bytes */
|
||||
.long 0xFFFF7FFE /* FDPROT:FEPROT:FOPT:FSEC(0xFE = unsecured) */
|
||||
|
||||
.text
|
||||
.thumb
|
||||
|
||||
/* Reset Handler */
|
||||
|
||||
.thumb_func
|
||||
.align 2
|
||||
.globl Reset_Handler
|
||||
.weak Reset_Handler
|
||||
.type Reset_Handler, %function
|
||||
Reset_Handler:
|
||||
cpsid i /* Mask interrupts */
|
||||
|
||||
/* Init the rest of the registers */
|
||||
ldr r1,=0
|
||||
ldr r2,=0
|
||||
ldr r3,=0
|
||||
ldr r4,=0
|
||||
ldr r5,=0
|
||||
ldr r6,=0
|
||||
ldr r7,=0
|
||||
mov r8,r7
|
||||
mov r9,r7
|
||||
mov r10,r7
|
||||
mov r11,r7
|
||||
mov r12,r7
|
||||
|
||||
#ifdef START_FROM_FLASH
|
||||
|
||||
/* Init ECC RAM */
|
||||
|
||||
ldr r1, =__RAM_START
|
||||
ldr r2, =__RAM_END
|
||||
|
||||
subs r2, r1
|
||||
subs r2, #1
|
||||
ble .LC5
|
||||
|
||||
movs r0, 0
|
||||
movs r3, #4
|
||||
.LC4:
|
||||
str r0, [r1]
|
||||
add r1, r1, r3
|
||||
subs r2, 4
|
||||
bge .LC4
|
||||
.LC5:
|
||||
#endif
|
||||
|
||||
/* Initialize the stack pointer */
|
||||
ldr r0,=__StackTop
|
||||
mov r13,r0
|
||||
|
||||
#ifndef __NO_SYSTEM_INIT
|
||||
/* Call the system init routine */
|
||||
ldr r0,=SystemInit
|
||||
blx r0
|
||||
#endif
|
||||
|
||||
/* Init .data and .bss sections */
|
||||
ldr r0,=init_data_bss
|
||||
blx r0
|
||||
cpsie i /* Unmask interrupts */
|
||||
|
||||
#ifndef __START
|
||||
#ifdef __EWL__
|
||||
#define __START __thumb_startup
|
||||
#else
|
||||
#define __START _start
|
||||
#endif
|
||||
#endif
|
||||
bl __START
|
||||
|
||||
JumpToSelf:
|
||||
b JumpToSelf
|
||||
|
||||
.pool
|
||||
.size Reset_Handler, . - Reset_Handler
|
||||
|
||||
.align 1
|
||||
.thumb_func
|
||||
.weak DefaultISR
|
||||
.type DefaultISR, %function
|
||||
DefaultISR:
|
||||
b DefaultISR
|
||||
.size DefaultISR, . - DefaultISR
|
||||
|
||||
/* Macro to define default handlers. Default handler
|
||||
* will be weak symbol and just dead loops. They can be
|
||||
* overwritten by other handlers */
|
||||
.macro def_irq_handler handler_name
|
||||
.weak \handler_name
|
||||
.set \handler_name, DefaultISR
|
||||
.endm
|
||||
|
||||
/* Exception Handlers */
|
||||
def_irq_handler NMI_Handler
|
||||
def_irq_handler HardFault_Handler
|
||||
def_irq_handler MemManage_Handler
|
||||
def_irq_handler BusFault_Handler
|
||||
def_irq_handler UsageFault_Handler
|
||||
def_irq_handler SVC_Handler
|
||||
def_irq_handler DebugMon_Handler
|
||||
def_irq_handler PendSV_Handler
|
||||
def_irq_handler SysTick_Handler
|
||||
def_irq_handler DMA0_IRQHandler
|
||||
def_irq_handler DMA1_IRQHandler
|
||||
def_irq_handler DMA2_IRQHandler
|
||||
def_irq_handler DMA3_IRQHandler
|
||||
def_irq_handler DMA4_IRQHandler
|
||||
def_irq_handler DMA5_IRQHandler
|
||||
def_irq_handler DMA6_IRQHandler
|
||||
def_irq_handler DMA7_IRQHandler
|
||||
def_irq_handler DMA8_IRQHandler
|
||||
def_irq_handler DMA9_IRQHandler
|
||||
def_irq_handler DMA10_IRQHandler
|
||||
def_irq_handler DMA11_IRQHandler
|
||||
def_irq_handler DMA12_IRQHandler
|
||||
def_irq_handler DMA13_IRQHandler
|
||||
def_irq_handler DMA14_IRQHandler
|
||||
def_irq_handler DMA15_IRQHandler
|
||||
def_irq_handler DMA_Error_IRQHandler
|
||||
def_irq_handler MCM_IRQHandler
|
||||
def_irq_handler FTFC_IRQHandler
|
||||
def_irq_handler Read_Collision_IRQHandler
|
||||
def_irq_handler LVD_LVW_IRQHandler
|
||||
def_irq_handler FTFC_Fault_IRQHandler
|
||||
def_irq_handler WDOG_EWM_IRQHandler
|
||||
def_irq_handler RCM_IRQHandler
|
||||
def_irq_handler LPI2C0_Master_IRQHandler
|
||||
def_irq_handler LPI2C0_Slave_IRQHandler
|
||||
def_irq_handler LPSPI0_IRQHandler
|
||||
def_irq_handler LPSPI1_IRQHandler
|
||||
def_irq_handler LPSPI2_IRQHandler
|
||||
def_irq_handler Reserved45_IRQHandler
|
||||
def_irq_handler Reserved46_IRQHandler
|
||||
def_irq_handler LPUART0_RxTx_IRQHandler
|
||||
def_irq_handler Reserved48_IRQHandler
|
||||
def_irq_handler LPUART1_RxTx_IRQHandler
|
||||
def_irq_handler Reserved50_IRQHandler
|
||||
def_irq_handler LPUART2_RxTx_IRQHandler
|
||||
def_irq_handler Reserved52_IRQHandler
|
||||
def_irq_handler Reserved53_IRQHandler
|
||||
def_irq_handler Reserved54_IRQHandler
|
||||
def_irq_handler ADC0_IRQHandler
|
||||
def_irq_handler ADC1_IRQHandler
|
||||
def_irq_handler CMP0_IRQHandler
|
||||
def_irq_handler Reserved58_IRQHandler
|
||||
def_irq_handler Reserved59_IRQHandler
|
||||
def_irq_handler ERM_single_fault_IRQHandler
|
||||
def_irq_handler ERM_double_fault_IRQHandler
|
||||
def_irq_handler RTC_IRQHandler
|
||||
def_irq_handler RTC_Seconds_IRQHandler
|
||||
def_irq_handler LPIT0_Ch0_IRQHandler
|
||||
def_irq_handler LPIT0_Ch1_IRQHandler
|
||||
def_irq_handler LPIT0_Ch2_IRQHandler
|
||||
def_irq_handler LPIT0_Ch3_IRQHandler
|
||||
def_irq_handler PDB0_IRQHandler
|
||||
def_irq_handler Reserved69_IRQHandler
|
||||
def_irq_handler Reserved70_IRQHandler
|
||||
def_irq_handler Reserved71_IRQHandler
|
||||
def_irq_handler Reserved72_IRQHandler
|
||||
def_irq_handler SCG_IRQHandler
|
||||
def_irq_handler LPTMR0_IRQHandler
|
||||
def_irq_handler PORTA_IRQHandler
|
||||
def_irq_handler PORTB_IRQHandler
|
||||
def_irq_handler PORTC_IRQHandler
|
||||
def_irq_handler PORTD_IRQHandler
|
||||
def_irq_handler PORTE_IRQHandler
|
||||
def_irq_handler SWI_IRQHandler
|
||||
def_irq_handler Reserved81_IRQHandler
|
||||
def_irq_handler Reserved82_IRQHandler
|
||||
def_irq_handler Reserved83_IRQHandler
|
||||
def_irq_handler PDB1_IRQHandler
|
||||
def_irq_handler FLEXIO_IRQHandler
|
||||
def_irq_handler Reserved86_IRQHandler
|
||||
def_irq_handler Reserved87_IRQHandler
|
||||
def_irq_handler Reserved88_IRQHandler
|
||||
def_irq_handler Reserved89_IRQHandler
|
||||
def_irq_handler Reserved90_IRQHandler
|
||||
def_irq_handler Reserved91_IRQHandler
|
||||
def_irq_handler Reserved92_IRQHandler
|
||||
def_irq_handler Reserved93_IRQHandler
|
||||
def_irq_handler CAN0_ORed_IRQHandler
|
||||
def_irq_handler CAN0_Error_IRQHandler
|
||||
def_irq_handler CAN0_Wake_Up_IRQHandler
|
||||
def_irq_handler CAN0_ORed_0_15_MB_IRQHandler
|
||||
def_irq_handler CAN0_ORed_16_31_MB_IRQHandler
|
||||
def_irq_handler Reserved99_IRQHandler
|
||||
def_irq_handler Reserved100_IRQHandler
|
||||
def_irq_handler CAN1_ORed_IRQHandler
|
||||
def_irq_handler CAN1_Error_IRQHandler
|
||||
def_irq_handler Reserved103_IRQHandler
|
||||
def_irq_handler CAN1_ORed_0_15_MB_IRQHandler
|
||||
def_irq_handler Reserved105_IRQHandler
|
||||
def_irq_handler Reserved106_IRQHandler
|
||||
def_irq_handler Reserved107_IRQHandler
|
||||
def_irq_handler CAN2_ORed_IRQHandler
|
||||
def_irq_handler CAN2_Error_IRQHandler
|
||||
def_irq_handler Reserved110_IRQHandler
|
||||
def_irq_handler CAN2_ORed_0_15_MB_IRQHandler
|
||||
def_irq_handler Reserved112_IRQHandler
|
||||
def_irq_handler Reserved113_IRQHandler
|
||||
def_irq_handler Reserved114_IRQHandler
|
||||
def_irq_handler FTM0_Ch0_Ch1_IRQHandler
|
||||
def_irq_handler FTM0_Ch2_Ch3_IRQHandler
|
||||
def_irq_handler FTM0_Ch4_Ch5_IRQHandler
|
||||
def_irq_handler FTM0_Ch6_Ch7_IRQHandler
|
||||
def_irq_handler FTM0_Fault_IRQHandler
|
||||
def_irq_handler FTM0_Ovf_Reload_IRQHandler
|
||||
def_irq_handler FTM1_Ch0_Ch1_IRQHandler
|
||||
def_irq_handler FTM1_Ch2_Ch3_IRQHandler
|
||||
def_irq_handler FTM1_Ch4_Ch5_IRQHandler
|
||||
def_irq_handler FTM1_Ch6_Ch7_IRQHandler
|
||||
def_irq_handler FTM1_Fault_IRQHandler
|
||||
def_irq_handler FTM1_Ovf_Reload_IRQHandler
|
||||
def_irq_handler FTM2_Ch0_Ch1_IRQHandler
|
||||
def_irq_handler FTM2_Ch2_Ch3_IRQHandler
|
||||
def_irq_handler FTM2_Ch4_Ch5_IRQHandler
|
||||
def_irq_handler FTM2_Ch6_Ch7_IRQHandler
|
||||
def_irq_handler FTM2_Fault_IRQHandler
|
||||
def_irq_handler FTM2_Ovf_Reload_IRQHandler
|
||||
def_irq_handler FTM3_Ch0_Ch1_IRQHandler
|
||||
def_irq_handler FTM3_Ch2_Ch3_IRQHandler
|
||||
def_irq_handler FTM3_Ch4_Ch5_IRQHandler
|
||||
def_irq_handler FTM3_Ch6_Ch7_IRQHandler
|
||||
def_irq_handler FTM3_Fault_IRQHandler
|
||||
def_irq_handler FTM3_Ovf_Reload_IRQHandler
|
||||
|
||||
.end
|
|
@ -0,0 +1,166 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<?fileVersion 4.0.0?><cproject storage_type_id="org.eclipse.cdt.core.XmlProjectDescriptionStorage">
|
||||
<storageModule moduleId="org.eclipse.cdt.core.settings">
|
||||
<cconfiguration id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.debug.2040336100">
|
||||
<storageModule buildSystemId="org.eclipse.cdt.managedbuilder.core.configurationDataProvider" id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.debug.2040336100" moduleId="org.eclipse.cdt.core.settings" name="Debug">
|
||||
<externalSettings/>
|
||||
<extensions>
|
||||
<extension id="org.eclipse.cdt.core.ELF" point="org.eclipse.cdt.core.BinaryParser"/>
|
||||
<extension id="org.eclipse.cdt.core.GASErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
|
||||
<extension id="org.eclipse.cdt.core.GmakeErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
|
||||
<extension id="com.freescale.s32ds.cdt.core.errorParsers.S32DSGNULinkerErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
|
||||
<extension id="org.eclipse.cdt.core.GCCErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
|
||||
</extensions>
|
||||
</storageModule>
|
||||
<storageModule moduleId="cdtBuildSystem" version="4.0.0">
|
||||
<configuration artifactExtension="elf" artifactName="demoprog_s32k144" buildArtefactType="com.nxp.s32ds.cle.arm.mbs.arm32.bare.buildArtefact.exe" buildProperties="org.eclipse.cdt.build.core.buildArtefactType=com.nxp.s32ds.cle.arm.mbs.arm32.bare.buildArtefact.exe,org.eclipse.cdt.build.core.buildType=org.eclipse.cdt.build.core.buildType.debug" description="" id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.debug.2040336100" name="Debug" parent="com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.debug">
|
||||
<folderInfo id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.debug.2040336100." name="/" resourcePath="">
|
||||
<toolChain id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.toolchain.debug.458764322" name="ARM Bare-Metal 32-bit Target Binary Toolchain" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.toolchain.debug">
|
||||
<option defaultValue="true" id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.option.addtools.printsize.902597682" name="Print size" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.option.addtools.printsize" valueType="boolean"/>
|
||||
<option id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.option.target.libraries.1287224447" name="Libraries support" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.option.target.libraries" value="com.nxp.s32ds.cle.arm.mbs.arm32.bare.option.target.libraries.newlib_nano_noio" valueType="enumerated"/>
|
||||
<option id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.option.target.fpu.abi.103879917" name="Float ABI" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.option.target.fpu.abi" value="com.nxp.s32ds.cle.arm.mbs.arm32.bare.option.target.fpu.abi.hard" valueType="enumerated"/>
|
||||
<option id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.option.target.fpu.unit.402464559" name="FPU Type" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.option.target.fpu.unit" value="com.nxp.s32ds.cle.arm.mbs.arm32.bare.option.target.fpu.unit.fpv4spd16" valueType="enumerated"/>
|
||||
<option id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.option.target.mcpu.1914968832" name="ARM family" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.option.target.mcpu" value="com.nxp.s32ds.cle.arm.mbs.arm32.bare.option.target.mcpu.cortex-m4" valueType="enumerated"/>
|
||||
<option id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.option.addtools.createflash.1975619066" name="Create flash image" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.option.addtools.createflash" value="true" valueType="boolean"/>
|
||||
<targetPlatform archList="all" binaryParser="org.eclipse.cdt.core.ELF" id="cdt.managedbuild.targetPlatform.gnu.cross.1171630519" isAbstract="false" osList="all" superClass="cdt.managedbuild.targetPlatform.gnu.cross"/>
|
||||
<builder buildPath="${workspace_loc:/Prog}/Debug_FLASH" id="com.freescale.s32ds.cross.gnu.builder.538644593" keepEnvironmentInBuildfile="false" managedBuildOn="true" name="FSL Make Builder" superClass="com.freescale.s32ds.cross.gnu.builder"/>
|
||||
<tool id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.compiler.937224809" name="Standard S32DS C Compiler" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.compiler">
|
||||
<option defaultValue="gnu.c.optimization.level.none" id="gnu.c.compiler.option.optimization.level.1640077662" name="Optimization Level" superClass="gnu.c.compiler.option.optimization.level" useByScannerDiscovery="false" value="gnu.c.optimization.level.optimize" valueType="enumerated"/>
|
||||
<option id="gnu.c.compiler.option.debugging.level.1470163089" name="Debug Level" superClass="gnu.c.compiler.option.debugging.level" useByScannerDiscovery="false" value="gnu.c.debugging.level.max" valueType="enumerated"/>
|
||||
<option id="com.freescale.s32ds.cross.gnu.tool.c.compiler.option.optimization.functionsections.1353890674" name="Function sections (-ffunction-sections)" superClass="com.freescale.s32ds.cross.gnu.tool.c.compiler.option.optimization.functionsections" useByScannerDiscovery="true" value="true" valueType="boolean"/>
|
||||
<option id="com.freescale.s32ds.cross.gnu.tool.c.compiler.option.optimization.datasections.660526265" name="Data sections (-fdata-sections)" superClass="com.freescale.s32ds.cross.gnu.tool.c.compiler.option.optimization.datasections" useByScannerDiscovery="true" value="true" valueType="boolean"/>
|
||||
<option id="com.freescale.s32ds.cross.gnu.tool.c.compiler.option.debugging.format.1062094627" name="Debug format" superClass="com.freescale.s32ds.cross.gnu.tool.c.compiler.option.debugging.format" useByScannerDiscovery="true"/>
|
||||
<option id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.compiler.option.target.libraries.685609114" name="Libraries support" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.compiler.option.target.libraries" useByScannerDiscovery="false" value="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.compiler.option.target.libraries.newlib_nano_noio" valueType="enumerated"/>
|
||||
<option id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.compiler.option.target.sysroot.1275900857" name="Sysroot" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.compiler.option.target.sysroot" useByScannerDiscovery="false" value="--sysroot="${S32DS_ARM32_NEWLIB_DIR}"" valueType="string"/>
|
||||
<option id="gnu.c.compiler.option.include.paths.1404288482" name="Include paths (-I)" superClass="gnu.c.compiler.option.include.paths" useByScannerDiscovery="false" valueType="includePath">
|
||||
<listOptionValue builtIn="false" value=""${ProjDirPath}""/>
|
||||
<listOptionValue builtIn="false" value=""${ProjDirPath}/lib""/>
|
||||
</option>
|
||||
<option id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.compiler.option.target.fpu.abi.890829790" name="Float ABI" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.compiler.option.target.fpu.abi" useByScannerDiscovery="true" value="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.compiler.option.target.fpu.abi.hard" valueType="enumerated"/>
|
||||
<option id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.compiler.option.target.fpu.unit.1378698519" name="FPU Type" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.compiler.option.target.fpu.unit" useByScannerDiscovery="true" value="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.compiler.option.target.fpu.unit.fpv4spd16" valueType="enumerated"/>
|
||||
<option id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.compiler.option.target.mcpu.1023001925" name="ARM family" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.compiler.option.target.mcpu" useByScannerDiscovery="true" value="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.compiler.option.target.mcpu.cortex-m4" valueType="enumerated"/>
|
||||
<option id="gnu.c.compiler.option.preprocessor.def.symbols.1532175444" name="Defined symbols (-D)" superClass="gnu.c.compiler.option.preprocessor.def.symbols" useByScannerDiscovery="false" valueType="definedSymbols">
|
||||
<listOptionValue builtIn="false" value="CPU_S32K144HFT0VLLT"/>
|
||||
</option>
|
||||
<option id="gnu.c.compiler.option.dialect.std.646071314" name="Language standard" superClass="gnu.c.compiler.option.dialect.std" useByScannerDiscovery="true" value="gnu.c.compiler.dialect.c99" valueType="enumerated"/>
|
||||
<inputType id="cdt.managedbuild.tool.gnu.c.compiler.input.759930541" superClass="cdt.managedbuild.tool.gnu.c.compiler.input"/>
|
||||
</tool>
|
||||
<tool id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.cpp.compiler.1959341704" name="Standard S32DS C++ Compiler" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.cpp.compiler">
|
||||
<option id="gnu.cpp.compiler.option.optimization.level.1846870945" name="Optimization Level" superClass="gnu.cpp.compiler.option.optimization.level" useByScannerDiscovery="false" value="gnu.cpp.compiler.optimization.level.none" valueType="enumerated"/>
|
||||
<option id="gnu.cpp.compiler.option.debugging.level.652287658" name="Debug Level" superClass="gnu.cpp.compiler.option.debugging.level" useByScannerDiscovery="false" value="gnu.cpp.compiler.debugging.level.max" valueType="enumerated"/>
|
||||
<option id="com.freescale.s32ds.cross.gnu.tool.cpp.compiler.option.optimization.functionsections.377024652" name="Function sections (-ffunction-sections)" superClass="com.freescale.s32ds.cross.gnu.tool.cpp.compiler.option.optimization.functionsections" useByScannerDiscovery="true" value="true" valueType="boolean"/>
|
||||
<option id="com.freescale.s32ds.cross.gnu.tool.cpp.compiler.option.optimization.datasections.118765465" name="Data sections (-fdata-sections)" superClass="com.freescale.s32ds.cross.gnu.tool.cpp.compiler.option.optimization.datasections" useByScannerDiscovery="true" value="true" valueType="boolean"/>
|
||||
<option id="com.freescale.s32ds.cross.gnu.tool.cpp.compiler.option.debugging.format.419523292" name="Debug format" superClass="com.freescale.s32ds.cross.gnu.tool.cpp.compiler.option.debugging.format" useByScannerDiscovery="true"/>
|
||||
<option id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.cpp.compiler.option.target.sysroot.1776177997" name="Sysroot" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.cpp.compiler.option.target.sysroot" useByScannerDiscovery="false" value="--sysroot="${S32DS_ARM32_NEWLIB_DIR}"" valueType="string"/>
|
||||
<option id="gnu.cpp.compiler.option.include.paths.1820900404" name="Include paths (-I)" superClass="gnu.cpp.compiler.option.include.paths" useByScannerDiscovery="false" valueType="includePath">
|
||||
<listOptionValue builtIn="false" value=""${ProjDirPath}/include""/>
|
||||
</option>
|
||||
<option id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.cpp.compiler.option.target.fpu.abi.1163056835" name="Float ABI" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.cpp.compiler.option.target.fpu.abi" useByScannerDiscovery="true" value="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.cpp.compiler.option.target.fpu.abi.hard" valueType="enumerated"/>
|
||||
<option id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.cpp.compiler.option.target.fpu.unit.411395682" name="FPU Type" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.cpp.compiler.option.target.fpu.unit" useByScannerDiscovery="true" value="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.cpp.compiler.option.target.fpu.unit.fpv4spd16" valueType="enumerated"/>
|
||||
<option id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.cpp.compiler.option.target.mcpu.512782100" name="ARM family" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.cpp.compiler.option.target.mcpu" useByScannerDiscovery="true" value="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.cpp.compiler.option.target.mcpu.cortex-m4" valueType="enumerated"/>
|
||||
<option id="gnu.cpp.compiler.option.preprocessor.def.1089995664" name="Defined symbols (-D)" superClass="gnu.cpp.compiler.option.preprocessor.def" useByScannerDiscovery="false" valueType="definedSymbols">
|
||||
<listOptionValue builtIn="false" value="CPU_S32K144HFT0VLLT"/>
|
||||
</option>
|
||||
</tool>
|
||||
<tool id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.linker.550705952" name="Standard S32DS C Linker" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.linker">
|
||||
<option id="com.freescale.s32ds.cross.gnu.tool.c.linker.option.gcsections.1535612077" name="Remove unused sections (-Xlinker --gc-sections)" superClass="com.freescale.s32ds.cross.gnu.tool.c.linker.option.gcsections" value="true" valueType="boolean"/>
|
||||
<option id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.linker.option.target.libraries.852085731" name="Libraries support" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.linker.option.target.libraries" value="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.linker.option.target.libraries.newlib_nano_noio" valueType="enumerated"/>
|
||||
<option id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.linker.option.target.sysroot.1257031892" name="Sysroot" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.linker.option.target.sysroot" value="--sysroot="${S32DS_ARM32_NEWLIB_DIR}"" valueType="string"/>
|
||||
<option id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.linker.option.target.fpu.abi.706362615" name="Float ABI" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.linker.option.target.fpu.abi" value="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.linker.option.target.fpu.abi.hard" valueType="enumerated"/>
|
||||
<option id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.linker.option.target.fpu.unit.88488328" name="FPU Type" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.linker.option.target.fpu.unit" value="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.linker.option.target.fpu.unit.fpv4spd16" valueType="enumerated"/>
|
||||
<option id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.linker.option.target.mcpu.236437881" name="ARM family" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.linker.option.target.mcpu" value="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.linker.option.target.mcpu.cortex-m4" valueType="enumerated"/>
|
||||
<option id="com.freescale.s32ds.cross.gnu.tool.c.linker.option.scriptfile.748319610" name="Script files (-T)" superClass="com.freescale.s32ds.cross.gnu.tool.c.linker.option.scriptfile" useByScannerDiscovery="false" valueType="stringList">
|
||||
<listOptionValue builtIn="false" value=""${ProjDirPath}/S32K144_64_flash.ld""/>
|
||||
</option>
|
||||
<inputType id="com.freescale.s32ds.cross.gnu.tool.c.linker.inputType.scriptfile.1351885105" superClass="com.freescale.s32ds.cross.gnu.tool.c.linker.inputType.scriptfile"/>
|
||||
</tool>
|
||||
<tool id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.cpp.linker.1207039283" name="Standard S32DS C++ Linker" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.cpp.linker">
|
||||
<option id="com.freescale.s32ds.cross.gnu.tool.cpp.linker.option.gcsections.813838149" name="Remove unused sections (-Xlinker --gc-sections)" superClass="com.freescale.s32ds.cross.gnu.tool.cpp.linker.option.gcsections" value="true" valueType="boolean"/>
|
||||
<option id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.cpp.linker.option.target.libraries.273828809" name="Libraries support" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.cpp.linker.option.target.libraries" value="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.cpp.linker.option.target.libraries.newlib_nano_noio" valueType="enumerated"/>
|
||||
<option id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.cpp.linker.option.target.sysroot.1775794909" name="Sysroot" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.cpp.linker.option.target.sysroot" value="--sysroot="${S32DS_ARM32_NEWLIB_DIR}"" valueType="string"/>
|
||||
<option id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.cpp.linker.option.target.fpu.abi.1438922040" name="Float ABI" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.cpp.linker.option.target.fpu.abi" value="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.cpp.linker.option.target.fpu.abi.hard" valueType="enumerated"/>
|
||||
<option id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.cpp.linker.option.target.fpu.unit.926499254" name="FPU Type" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.cpp.linker.option.target.fpu.unit" value="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.cpp.linker.option.target.fpu.unit.fpv4spd16" valueType="enumerated"/>
|
||||
<option id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.cpp.linker.option.target.mcpu.651871737" name="ARM family" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.cpp.linker.option.target.mcpu" value="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.cpp.linker.option.target.mcpu.cortex-m4" valueType="enumerated"/>
|
||||
<option id="com.freescale.s32ds.cross.gnu.tool.cpp.linker.option.scriptfile.958163827" name="Script files (-T)" superClass="com.freescale.s32ds.cross.gnu.tool.cpp.linker.option.scriptfile" valueType="stringList">
|
||||
<listOptionValue builtIn="false" value=""${ProjDirPath}/Project_Settings/Linker_Files/S32K144_64_flash.ld""/>
|
||||
</option>
|
||||
</tool>
|
||||
<tool id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.archiver.1106981748" name="Standard S32DS Archiver" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.archiver"/>
|
||||
<tool id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.assembler.1035169547" name="Standard S32DS Assembler" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.assembler">
|
||||
<option id="com.freescale.s32ds.cross.gnu.tool.assembler.usepreprocessor.1050996270" name="Use preprocessor" superClass="com.freescale.s32ds.cross.gnu.tool.assembler.usepreprocessor" value="true" valueType="boolean"/>
|
||||
<option id="com.freescale.s32ds.cross.gnu.tool.assembler.option.debugging.level.1251784802" name="Debug Level" superClass="com.freescale.s32ds.cross.gnu.tool.assembler.option.debugging.level" value="gnu.c.debugging.level.max" valueType="enumerated"/>
|
||||
<option id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.assembler.option.target.libraries.1895973769" name="Libraries support" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.assembler.option.target.libraries" value="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.assembler.option.target.libraries.newlib_nano_noio" valueType="enumerated"/>
|
||||
<option id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.assembler.option.target.sysroot.736006721" name="Sysroot" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.assembler.option.target.sysroot" value="--sysroot="${S32DS_ARM32_NEWLIB_DIR}"" valueType="string"/>
|
||||
<option id="gnu.both.asm.option.include.paths.479150447" name="Include paths (-I)" superClass="gnu.both.asm.option.include.paths" useByScannerDiscovery="false"/>
|
||||
<option id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.assembler.option.target.fpu.abi.335297637" name="Float ABI" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.assembler.option.target.fpu.abi" value="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.assembler.option.target.fpu.abi.hard" valueType="enumerated"/>
|
||||
<option id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.assembler.option.target.fpu.unit.1819630673" name="FPU Type" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.assembler.option.target.fpu.unit" value="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.assembler.option.target.fpu.unit.fpv4spd16" valueType="enumerated"/>
|
||||
<option id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.assembler.option.target.mcpu.70157124" name="ARM family" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.assembler.option.target.mcpu" value="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.assembler.option.target.mcpu.cortex-m4" valueType="enumerated"/>
|
||||
<option id="com.freescale.s32ds.cross.gnu.tool.assembler.option.defs.1983863951" name="Defined symbols (-D)" superClass="com.freescale.s32ds.cross.gnu.tool.assembler.option.defs" valueType="definedSymbols">
|
||||
<listOptionValue builtIn="false" value="START_FROM_FLASH"/>
|
||||
</option>
|
||||
<inputType id="cdt.managedbuild.tool.gnu.assembler.input.1987093463" superClass="cdt.managedbuild.tool.gnu.assembler.input"/>
|
||||
<inputType id="com.freescale.s32ds.cross.gnu.tool.assembler.inputType.asmfile.1646251302" superClass="com.freescale.s32ds.cross.gnu.tool.assembler.inputType.asmfile"/>
|
||||
</tool>
|
||||
<tool id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.createflash.685979785" name="Standard S32DS Create Flash Image" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.createflash"/>
|
||||
<tool id="com.freescale.s32ds.cross.gnu.tool.createlisting.1088101334" name="Standard S32DS Create Listing" superClass="com.freescale.s32ds.cross.gnu.tool.createlisting">
|
||||
<option id="com.freescale.s32ds.cross.gnu.option.createlisting.source.533624515" name="Display source (--source|-S)" superClass="com.freescale.s32ds.cross.gnu.option.createlisting.source" value="true" valueType="boolean"/>
|
||||
<option id="com.freescale.s32ds.cross.gnu.option.createlisting.allheaders.1870446717" name="Display all headers (--all-headers|-x)" superClass="com.freescale.s32ds.cross.gnu.option.createlisting.allheaders" value="true" valueType="boolean"/>
|
||||
<option id="com.freescale.s32ds.cross.gnu.option.createlisting.demangle.503075596" name="Demangle names (--demangle|-C)" superClass="com.freescale.s32ds.cross.gnu.option.createlisting.demangle" value="true" valueType="boolean"/>
|
||||
<option id="com.freescale.s32ds.cross.gnu.option.createlisting.linenumbers.1925863802" name="Display line numbers (--line-numbers|-l)" superClass="com.freescale.s32ds.cross.gnu.option.createlisting.linenumbers" value="true" valueType="boolean"/>
|
||||
<option id="com.freescale.s32ds.cross.gnu.option.createlisting.wide.1947510588" name="Wide lines (--wide|-w)" superClass="com.freescale.s32ds.cross.gnu.option.createlisting.wide" value="true" valueType="boolean"/>
|
||||
</tool>
|
||||
<tool id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.printsize.823755841" name="Standard S32DS Print Size" superClass="com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.printsize">
|
||||
<option id="com.freescale.s32ds.cross.gnu.option.printsize.format.1797462666" name="Size format" superClass="com.freescale.s32ds.cross.gnu.option.printsize.format"/>
|
||||
</tool>
|
||||
<tool id="com.freescale.s32ds.cross.gnu.c.preprocessor.243218720" name="Standard S32DS C Preprocessor" superClass="com.freescale.s32ds.cross.gnu.c.preprocessor"/>
|
||||
<tool id="com.freescale.s32ds.cross.gnu.cpp.preprocessor.1913775860" name="Standard S32DS C++ Preprocessor" superClass="com.freescale.s32ds.cross.gnu.cpp.preprocessor"/>
|
||||
<tool id="com.freescale.s32ds.cross.gnu.disassembler.1521244588" name="Standard S32DS Disassembler" superClass="com.freescale.s32ds.cross.gnu.disassembler"/>
|
||||
</toolChain>
|
||||
</folderInfo>
|
||||
<sourceEntries>
|
||||
<entry excluding="Project_Settings|include" flags="VALUE_WORKSPACE_PATH" kind="sourcePath" name=""/>
|
||||
</sourceEntries>
|
||||
</configuration>
|
||||
</storageModule>
|
||||
<storageModule moduleId="org.eclipse.cdt.core.externalSettings"/>
|
||||
</cconfiguration>
|
||||
</storageModule>
|
||||
<storageModule moduleId="cdtBuildSystem" version="4.0.0">
|
||||
<project id="Prog.com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.1809969" name="ARM32 Executable" projectType="com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe"/>
|
||||
</storageModule>
|
||||
<storageModule moduleId="scannerConfiguration">
|
||||
<autodiscovery enabled="true" problemReportingEnabled="true" selectedProfileId=""/>
|
||||
<scannerConfigBuildInfo instanceId="com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.debug.2040336100;com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.debug.2040336100.;com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.compiler.937224809;cdt.managedbuild.tool.gnu.c.compiler.input.759930541">
|
||||
<autodiscovery enabled="true" problemReportingEnabled="true" selectedProfileId=""/>
|
||||
</scannerConfigBuildInfo>
|
||||
<scannerConfigBuildInfo instanceId="com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.release.ram.537914742;com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.release.ram.537914742.;com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.compiler.1051205921;cdt.managedbuild.tool.gnu.c.compiler.input.512268002">
|
||||
<autodiscovery enabled="true" problemReportingEnabled="true" selectedProfileId=""/>
|
||||
</scannerConfigBuildInfo>
|
||||
<scannerConfigBuildInfo instanceId="com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.debug.ram.1476644705;com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.debug.ram.1476644705.;com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.compiler.1999490704;cdt.managedbuild.tool.gnu.c.compiler.input.491253786">
|
||||
<autodiscovery enabled="true" problemReportingEnabled="true" selectedProfileId=""/>
|
||||
</scannerConfigBuildInfo>
|
||||
<scannerConfigBuildInfo instanceId="com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.release.88811887;com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.release.88811887.;com.nxp.s32ds.cle.arm.mbs.arm32.bare.tool.c.compiler.1368520800;cdt.managedbuild.tool.gnu.c.compiler.input.1334961033">
|
||||
<autodiscovery enabled="true" problemReportingEnabled="true" selectedProfileId=""/>
|
||||
</scannerConfigBuildInfo>
|
||||
</storageModule>
|
||||
<storageModule moduleId="org.eclipse.cdt.core.LanguageSettingsProviders"/>
|
||||
<storageModule moduleId="org.eclipse.embsys" parent_project="true" register_architecture="" register_board="--- none ---" register_chip="" register_core="" register_vendor=""/>
|
||||
<storageModule moduleId="refreshScope" versionNumber="2">
|
||||
<configuration configurationName="Release_FLASH">
|
||||
<resource resourceType="PROJECT" workspacePath="/Prog"/>
|
||||
</configuration>
|
||||
<configuration configurationName="Release_RAM">
|
||||
<resource resourceType="PROJECT" workspacePath="/Prog"/>
|
||||
</configuration>
|
||||
<configuration configurationName="Debug_FLASH">
|
||||
<resource resourceType="PROJECT" workspacePath="/Prog"/>
|
||||
</configuration>
|
||||
<configuration configurationName="Debug_RAM">
|
||||
<resource resourceType="PROJECT" workspacePath="/Prog"/>
|
||||
</configuration>
|
||||
<configuration configurationName="Debug">
|
||||
<resource resourceType="PROJECT" workspacePath="/Prog"/>
|
||||
</configuration>
|
||||
</storageModule>
|
||||
<storageModule moduleId="org.eclipse.cdt.make.core.buildtargets"/>
|
||||
</cproject>
|
|
@ -0,0 +1,26 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<projectDescription>
|
||||
<name>Prog</name>
|
||||
<comment></comment>
|
||||
<projects>
|
||||
</projects>
|
||||
<buildSpec>
|
||||
<buildCommand>
|
||||
<name>org.eclipse.cdt.managedbuilder.core.genmakebuilder</name>
|
||||
<triggers>clean,full,incremental,</triggers>
|
||||
<arguments>
|
||||
</arguments>
|
||||
</buildCommand>
|
||||
<buildCommand>
|
||||
<name>org.eclipse.cdt.managedbuilder.core.ScannerConfigBuilder</name>
|
||||
<triggers>full,incremental,</triggers>
|
||||
<arguments>
|
||||
</arguments>
|
||||
</buildCommand>
|
||||
</buildSpec>
|
||||
<natures>
|
||||
<nature>org.eclipse.cdt.core.cnature</nature>
|
||||
<nature>org.eclipse.cdt.managedbuilder.core.managedBuildNature</nature>
|
||||
<nature>org.eclipse.cdt.managedbuilder.core.ScannerConfigNature</nature>
|
||||
</natures>
|
||||
</projectDescription>
|
|
@ -0,0 +1,8 @@
|
|||
com.nxp.s32ds.cle.runtime.component.registry.archetype.id=application
|
||||
com.nxp.s32ds.cle.runtime.component.registry.archetype.platform.id=
|
||||
com.nxp.s32ds.cle.runtime.hardware.registry.core.id=CortexM4F
|
||||
com.nxp.s32ds.cle.runtime.hardware.registry.device.id=S32K144
|
||||
com.nxp.s32ds.cle.runtime.hardware.registry.deviceCore.id=S32K144_M4F
|
||||
com.nxp.s32ds.cle.runtime.hardware.registry.family.id=S32K1
|
||||
com.nxp.s32ds.cle.runtime.lang.registry.lang.id=c
|
||||
eclipse.preferences.version=1
|
|
@ -0,0 +1,2 @@
|
|||
eclipse.preferences.version=1
|
||||
versionGenerated/versionGenerated=1.8.4.RT7_b1743-0713
|
|
@ -0,0 +1,14 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<project>
|
||||
<configuration id="com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.debug.2040336100" name="Debug">
|
||||
<extension point="org.eclipse.cdt.core.LanguageSettingsProvider">
|
||||
<provider copy-of="extension" id="org.eclipse.cdt.ui.UserLanguageSettingsProvider"/>
|
||||
<provider-reference id="org.eclipse.cdt.core.ReferencedProjectsLanguageSettingsProvider" ref="shared-provider"/>
|
||||
<provider-reference id="org.eclipse.cdt.managedbuilder.core.MBSLanguageSettingsProvider" ref="shared-provider"/>
|
||||
<provider class="com.freescale.s32ds.cross.gnu.CrossGCCBuiltinSpecsDetector" console="false" env-hash="1523537622117756807" id="com.freescale.s32ds.cross.gnu.CrossGCCBuiltinSpecsDetector" keep-relative-paths="false" name="CDT S32DS Built-in Compiler Settings" parameter="${COMMAND} ${FLAGS} -E -P -v -dD "${INPUTS}"" prefer-non-shared="true">
|
||||
<language-scope id="org.eclipse.cdt.core.gcc"/>
|
||||
<language-scope id="org.eclipse.cdt.core.g++"/>
|
||||
</provider>
|
||||
</extension>
|
||||
</configuration>
|
||||
</project>
|
|
@ -0,0 +1,3 @@
|
|||
eclipse.preferences.version=1
|
||||
inEditor=false
|
||||
onBuild=false
|
|
@ -0,0 +1,21 @@
|
|||
eclipse.preferences.version=1
|
||||
environment/project/com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.debug.2040336100/PATH/delimiter=;
|
||||
environment/project/com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.debug.2040336100/PATH/operation=prepend
|
||||
environment/project/com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.debug.2040336100/PATH/value=
|
||||
environment/project/com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.debug.2040336100/append=true
|
||||
environment/project/com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.debug.2040336100/appendContributed=true
|
||||
environment/project/com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.debug.ram.1476644705/PATH/delimiter=;
|
||||
environment/project/com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.debug.ram.1476644705/PATH/operation=prepend
|
||||
environment/project/com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.debug.ram.1476644705/PATH/value=
|
||||
environment/project/com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.debug.ram.1476644705/append=true
|
||||
environment/project/com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.debug.ram.1476644705/appendContributed=true
|
||||
environment/project/com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.release.88811887/PATH/delimiter=;
|
||||
environment/project/com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.release.88811887/PATH/operation=prepend
|
||||
environment/project/com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.release.88811887/PATH/value=
|
||||
environment/project/com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.release.88811887/append=true
|
||||
environment/project/com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.release.88811887/appendContributed=true
|
||||
environment/project/com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.release.ram.537914742/PATH/delimiter=;
|
||||
environment/project/com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.release.ram.537914742/PATH/operation=prepend
|
||||
environment/project/com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.release.ram.537914742/PATH/value=
|
||||
environment/project/com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.release.ram.537914742/append=true
|
||||
environment/project/com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.release.ram.537914742/appendContributed=true
|
Binary file not shown.
|
@ -0,0 +1,245 @@
|
|||
S018000064656D6F70726F675F7333326B3134342E7372656374
|
||||
S11320000070002029250000912500009125000082
|
||||
S1132010912500009125000091250000000000009A
|
||||
S113202000000000000000000000000091250000F6
|
||||
S1132030912500000000000091250000ED2B000018
|
||||
S113204091250000912500009125000091250000B4
|
||||
S113205091250000912500009125000091250000A4
|
||||
S11320609125000091250000912500009125000094
|
||||
S11320709125000091250000912500009125000084
|
||||
S11320809125000091250000912500009125000074
|
||||
S11320909125000091250000912500009125000064
|
||||
S11320A09125000091250000912500009125000054
|
||||
S11320B09125000091250000912500009125000044
|
||||
S11320C09125000091250000912500009125000034
|
||||
S11320D09125000091250000912500009125000024
|
||||
S11320E09125000091250000912500009125000014
|
||||
S11320F09125000091250000912500009125000004
|
||||
S113210091250000912500009125000091250000F3
|
||||
S113211091250000912500009125000091250000E3
|
||||
S113212091250000912500009125000091250000D3
|
||||
S113213091250000912500009125000091250000C3
|
||||
S113214091250000912500009125000091250000B3
|
||||
S113215091250000912500009125000091250000A3
|
||||
S11321609125000091250000912500009125000093
|
||||
S11321709125000091250000912500009125000083
|
||||
S11321809125000091250000912500009125000073
|
||||
S11321909125000091250000912500009125000063
|
||||
S11321A09125000091250000912500009125000053
|
||||
S11321B09125000091250000912500009125000043
|
||||
S11321C09125000091250000912500009125000033
|
||||
S11321D09125000091250000912500009125000023
|
||||
S11321E09125000091250000912500009125000013
|
||||
S11321F09125000091250000912500009125000003
|
||||
S113220091250000912500009125000091250000F2
|
||||
S113221091250000912500009125000091250000E2
|
||||
S113222091250000912500009125000091250000D2
|
||||
S113223091250000912500009125000091250000C2
|
||||
S113224091250000912500009125000091250000B2
|
||||
S113225091250000912500009125000091250000A2
|
||||
S11322609125000091250000912500009125000092
|
||||
S11322709125000091250000912500009125000082
|
||||
S11322809125000091250000912500009125000072
|
||||
S11322909125000091250000912500009125000062
|
||||
S11322A09125000091250000912500009125000052
|
||||
S11322B09125000091250000912500009125000042
|
||||
S11322C09125000091250000912500009125000032
|
||||
S11322D09125000091250000912500009125000022
|
||||
S11322E09125000091250000912500009125000012
|
||||
S11322F09125000091250000912500009125000002
|
||||
S113230091250000912500009125000091250000F1
|
||||
S113231091250000912500009125000091250000E1
|
||||
S113232091250000912500009125000091250000D1
|
||||
S113233091250000912500009125000091250000C1
|
||||
S113234091250000912500009125000091250000B1
|
||||
S113235091250000912500009125000091250000A1
|
||||
S11323609125000091250000912500009125000091
|
||||
S11323709125000091250000912500009125000081
|
||||
S11323809125000091250000912500009125000071
|
||||
S11323909125000091250000912500009125000061
|
||||
S11323A09125000091250000912500009125000051
|
||||
S11323B09125000091250000912500009125000041
|
||||
S11323C09125000091250000912500009125000031
|
||||
S11323D09125000091250000912500009125000021
|
||||
S11323E09125000091250000912500009125000011
|
||||
S11323F09125000091250000EE11AA55FFFFFFFF73
|
||||
S1132400FFFFFFFFFFFFFFFFFFFFFFFFFE7FFFFF59
|
||||
S1132410044B05481B1A062B02D9044B03B1184779
|
||||
S1132420704700BF6B84FF1F6884FF1F000000001B
|
||||
S113243005490648091A891001EBD171491002D0E7
|
||||
S1132440034B03B1184770476884FF1F6884FF1F5C
|
||||
S11324500000000010B5064C237843B9FFF7D8FFFD
|
||||
S1132460044B13B10448AFF300800123237010BD63
|
||||
S11324700000002000000000782E000008B5084B82
|
||||
S11324801BB108490848AFF300800848036813B932
|
||||
S1132490BDE80840CCE7064B002BF9D09847F7E796
|
||||
S11324A00000000004000020782E00006484FF1F58
|
||||
S11324B000000000154B002B08BF134B9D46A3F5ED
|
||||
S11324C0803A00218B460F461348144A121A00F032
|
||||
S11324D0A3FC0F4B002B00D098470E4B002B00D0D1
|
||||
S11324E098470020002104000D000D48002802D068
|
||||
S11324F00C48AFF3008000F06BFC2000290000F0D2
|
||||
S1132500CDFA00F051FC00BF00000800007000206C
|
||||
S11325100000000000000000000000207400002003
|
||||
S1132520000000000000000072B64FF000014FF000
|
||||
S113253000024FF000034FF000044FF000054FF08D
|
||||
S113254000064FF00007B846B946BA46BB46BC463B
|
||||
S11325500A490B4A521A013A05DD00200423086097
|
||||
S11325601944043AFBDA0748854607488047074878
|
||||
S1132570804762B6FFF79EFFFEE700000080FF1F62
|
||||
S11325800070002000700020FD2B0000D12C000002
|
||||
S1132590FFF7FEBF38B50C4B1B68002B00DB38BDC2
|
||||
S11325A0094A136823F00043136000F019FB00F19B
|
||||
S11325B0FA05054C236813F4801FF0D000F010FBDB
|
||||
S11325C08542F7D2EBE700BF0040024038B50B4B21
|
||||
S11325D01A6842F080421A601A6842F080521A6007
|
||||
S11325E000F0FEFA00F1FA05044C236813F0807F32
|
||||
S11325F003D100F0F5FA8542F7D238BD004002401D
|
||||
S113260070B582B000238DF8003001238DF80130BD
|
||||
S113261002238DF8023004238DF8033008238DF84B
|
||||
S1132620043010238DF8053020238DF80630402324
|
||||
S11326308DF80730AA4BD3F8AC2122F08042C3F8BE
|
||||
S1132640AC21D3F8AC2142F08442C3F8AC21A3F509
|
||||
S11326508053D3F80422C2F3022222B94FF48072C9
|
||||
S1132660C3F8042201229F4BD3F8081201F00101A0
|
||||
S11326709D489E4B002908BF034602A90A4412F84C
|
||||
S1132680082CB3FBF2F39A4AA2FB0323DB0B0733B8
|
||||
S1132690C3F3CC0343F0E063964A1361964B536152
|
||||
S11326A000239361136253624FF470339362936A0D
|
||||
S11326B043F0880393620123D3624FF44023936170
|
||||
S11326C0A2F5C042D2F8903043F08043C2F8903073
|
||||
S11326D0FFF760FFFFF77AFF884B1B68002B11DBC5
|
||||
S11326E0864A136843F00043136000F079FA00F15E
|
||||
S11326F0FA05824C236813F4801F03D100F070FAAA
|
||||
S11327008542F7D27D4A536823F400535360FFF7A0
|
||||
S113271041FFFFF75BFF00238DF8003001238DF8A4
|
||||
S1132720013002238DF8023004238DF8033008238E
|
||||
S11327308DF8043010238DF8053020238DF80630F1
|
||||
S113274040238DF80730674BD3F80431C3F30223D9
|
||||
S11327502BB94FF48072634BC3F80421012302AAFE
|
||||
S1132760134413F8083C4FF4FA50B0FBF3F0002282
|
||||
S11327701446634E4FF4FA7502E00132122A17D060
|
||||
S113278016F8223005FB03F3B0FBF3F103FB110150
|
||||
S11327900029F2D1B0FBF3F39CB2611E89B2FF2988
|
||||
S11327A0EBD8574B03EB820255789178D07802E04E
|
||||
S11327B0002001460546514A536823F087031B0451
|
||||
S11327C01B0C53605668631E46EA036353605468E7
|
||||
S11327D06B1E03F007032343536054684B1EDB0452
|
||||
S11327E003F46013234353605468431E1B0403F42F
|
||||
S11327F0E023234353605068042928BF04214B1E5F
|
||||
S11328009B0503F4400303435360536843F0800380
|
||||
S1132810536000231046194603F1200240F82210A9
|
||||
S11328200133802BF8D100233448194603F508728C
|
||||
S113283040F822100133202BF8D1304B1A6822F0D3
|
||||
S11328407F0242F01F021A601A6842F400321A60D2
|
||||
S11328501A6842F480321A601A6822F000521A6030
|
||||
S11328606FF02042C3F8A4284FF08062C3F810210F
|
||||
S1132870244AC3F8142100229A624FF0FF321A63EB
|
||||
S1132880214A1A621A6822F400021A605A6822F471
|
||||
S1132890805222F008025A601A6822F080421A60BC
|
||||
S11328A01A6822F080521A6000F09AF900F1FA05D1
|
||||
S11328B0124C236813F0807F03D000F091F9854215
|
||||
S11328C0F7D200F08DF900F1FA050C4C236813F0EF
|
||||
S11328D0006F03D000F084F98542F7D202B070BDD6
|
||||
S11328E0005006400040064080841E0000127A001A
|
||||
S11328F0C5B3A29100B0064000C01FC00040024012
|
||||
S11329002C2E000000009C1906003B0010B582B07C
|
||||
S11329103D4B1B78002B3FD13C4B5B6913F4001FEC
|
||||
S113292008D03A4BDB69DBB2394A1370013BDBB2A6
|
||||
S11329303F2B26D9374B1B6B13F4007F1FD0354B2D
|
||||
S1132940D3F81001C0F30340002855D00DF1FF3136
|
||||
S11329500023314C83F00302D2B2125D01F8012F3F
|
||||
S11329600133DAB29042F5D82A4B4FF400721A635D
|
||||
S11329709A682A4B1A609DF80030FF2B2CD002B0C5
|
||||
S113298010BD00F02DF9264B186001221E4B1A7061
|
||||
S11329900022244B1A70CDE71C4B5B6913F4001F13
|
||||
S11329A01FD020490B78194AD469194AD0184470A9
|
||||
S11329B00133DBB20B7012789A42BBD10022124B66
|
||||
S11329C01A70134B5B78FF2BB4D1114B9B78002BFF
|
||||
S11329D0B0D100F071F9ADE70228D0D100F06CF964
|
||||
S11329E0CDE700F0FDF80E4B1B6864339842A1D983
|
||||
S11329F00022054B1A709DE7064B4FF400721A63D0
|
||||
S1132A009A68064B1A60BAE76100002000B00640DD
|
||||
S1132A102000002000400240184102401C00002019
|
||||
S1132A206400002062000020074A136843F48073A6
|
||||
S1132A301360064B5A6942F001025A615A6842F027
|
||||
S1132A4001025A60704700BF00C00440C0F00F404C
|
||||
S1132A5008B500F0C5F80E4B1B68C31AB3F5FA7F2E
|
||||
S1132A600CD30C4B1B7853B901220A4B1A700A4A37
|
||||
S1132A70936843F001039360054B186008BD00227E
|
||||
S1132A80044B1A70044A536843F001035360F3E79C
|
||||
S1132A906C00002068000020C0F00F4008B5414BD6
|
||||
S1132AA040F20112C3F804212422C3F80821D3F808
|
||||
S1132AB0002112F4000FFAD101223A4BC3F800218D
|
||||
S1132AC0D3F8002112F0807FFAD0364BD3F80026D9
|
||||
S1132AD012F4000FFAD1334BD3F8002622F001028E
|
||||
S1132AE0C3F80026D3F8042642F4407242F00202EE
|
||||
S1132AF0C3F804264FF4C012C3F80826D3F80026FE
|
||||
S1132B0012F4000FFAD1274AD2F8003643F0010339
|
||||
S1132B10C2F800361346D3F8002612F0807FFAD0AC
|
||||
S1132B20204B40F20112C3F804221F4A5A611A468C
|
||||
S1132B301369C3F30363062BFAD100F07DF81B4B32
|
||||
S1132B40D3F82C2142F08042C3F82C21D3F8302151
|
||||
S1132B5042F08042C3F83021D3F8342142F080425D
|
||||
S1132B60C3F83421A3F5D0339A6942F400729A6110
|
||||
S1132B70DA6942F40072DA6103F500531A6942F427
|
||||
S1132B80A0621A615A6942F4A0625A6100F010F816
|
||||
S1132B90FFF74AFF62B6FFF733FDFFF759FFFFF770
|
||||
S1132BA0B5FEFAE700400640120001060050064058
|
||||
S1132BB0074B1B68074AA2FB03239B09013B064AF8
|
||||
S1132BC053600023936007211160044A1360704727
|
||||
S1132BD00084FF1FD34D621010E000E0700000205D
|
||||
S1132BE0014B1868704700BF70000020024A136848
|
||||
S1132BF001331360704700BF700000204FF0E023E2
|
||||
S1132C00D3F8882D42F47002C3F8882DD3F8342FFA
|
||||
S1132C1022F08042C3F8342F054B064A5A605A68A2
|
||||
S1132C2042F220121A604FF6FF729A60704700BF9A
|
||||
S1132C300020054020C528D91B4B1A691B69C3F322
|
||||
S1132C400363013B052B2ED8DFE803F025030D2D8C
|
||||
S1132C502D12154BD3F8083203F00103002B13494E
|
||||
S1132C6018BF0B4618E0104BD3F80833104B13E091
|
||||
S1132C700D4BD3F80816D3F80836C3F3044303F115
|
||||
S1132C8010000A4B03FB00F3C1F302210131490098
|
||||
S1132C90B3FBF1F300E0054BC2F303420132B3FB93
|
||||
S1132CA0F2F3044A136070470040064000127A00B1
|
||||
S1132CB0006CDC020084FF1F4FF0E021D1F80C2DE2
|
||||
S1132CC092B2024B1343C1F80C3D70470400FA055D
|
||||
S1132CD0264B274A9A4208D013462448254A13F81B
|
||||
S1132CE0011B02F8011B9842F9D1234B234A9A4253
|
||||
S1132CF008D013462048224A13F8011B02F8011B8E
|
||||
S1132D008342F9D11F4B204A9A4206D01346002130
|
||||
S1132D101C4A03F8011B9342FBD11C4B1C4A9A42E8
|
||||
S1132D2008D0134619481B4A13F8011B02F8011B6B
|
||||
S1132D308342F9D1184B194A9A4212D010B4184C54
|
||||
S1132D40A40808D01946002351F8040B42F8040BD8
|
||||
S1132D500133A342F8D1134B104A1A605DF8044BB7
|
||||
S1132D607047104B0C4A1A60704700BF082F0000D0
|
||||
S1132D70A02E00000084FF1F082F0000082F000071
|
||||
S1132D806884FF1F7400002000000020082F00004A
|
||||
S1132D90082F000000000020002000000080FF1F1A
|
||||
S1132DA00004000008ED00E008B5074B044613B129
|
||||
S1132DB00021AFF30080054B1868836A03B198477C
|
||||
S1132DC0204600F031F800BF00000000742E00001F
|
||||
S1132DD070B50D4E0D4CA41BA4100025A54209D1BD
|
||||
S1132DE00B4E0C4C00F048F8A41BA4100025A5427F
|
||||
S1132DF005D170BD56F8253098470135EEE756F8F1
|
||||
S1132E00253098470135F2E7982E0000982E0000EF
|
||||
S1132E10982E00009C2E000002440346934200D1E9
|
||||
S1132E20704703F8011BF9E7FEE7000008030202FC
|
||||
S1132E30090303020A0303030B0403030C0404033E
|
||||
S1132E400D0504030E0504040F060404100605040E
|
||||
S1132E5011070504120705051308050514080605DE
|
||||
S1132E6015080705160807061708080618080807AE
|
||||
S1132E70190808080484FF1FF8B500BFF8BC08BC93
|
||||
S1132E809E467047F8B500BFF8BC08BC9E46704724
|
||||
S10B2E9024F6FF7F010000009D
|
||||
S1072E987D24000091
|
||||
S1072E9C55240000B5
|
||||
S1132EA0006CDC02000000000000000000000000D4
|
||||
S1132EB0000000000000000000000000000000000E
|
||||
S1132EC000000000000000000000000000000000FE
|
||||
S1132ED000000000000000000000000000000000EE
|
||||
S1132EE000000000000000000000000000000000DE
|
||||
S1132EF000000000000000000000000000000000CE
|
||||
S10B2F000000000000000000C5
|
||||
S9032529AE
|
|
@ -0,0 +1,217 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<launchConfiguration type="com.pemicro.debug.gdbjtag.pne.launchConfigurationType">
|
||||
<stringAttribute key="com.nxp.s32ds.ext.cdt.debug.svd.svd_path" value=""/>
|
||||
<booleanAttribute key="com.nxp.s32ds.ext.cdt.debug.svd.use_default" value="true"/>
|
||||
<listAttribute key="com.pemicro.debug.gdbjtag.pne.ELVES"/>
|
||||
<listAttribute key="com.pemicro.debug.gdbjtag.pne.ELVES_OFFSET"/>
|
||||
<intAttribute key="com.pemicro.debug.gdbjtag.pne.NUMBER_ELVES" value="0"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.PE.BUSERR" value="true"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.PE.CHKERR" value="true"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.PE.CORERESET" value="true"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.PE.DEVICE_NAME" value="NXP_S32K1xx_S32K144F512M15"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.PE.GDB_OPTIONS" value=""/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.PE.HARDERR" value="true"/>
|
||||
<intAttribute key="com.pemicro.debug.gdbjtag.pne.PE.HARDWARE_INTERFACE" value="0"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.PE.INTERR" value="true"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.PE.LAST_ATTRIBUTE_HEADER" value="com.pemicro.debug.gdbjtag.pne.ml."/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.PE.MMERR" value="true"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.PE.NOCPERR" value="true"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.PE.STATERR" value="true"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.PE.STREAMING_ENABLE_PORT1" value="true"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.PE.STREAMING_SERVER_PORT1" value="10224"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.PE.USE_EXTERNAL_SERVER" value="true"/>
|
||||
<intAttribute key="com.pemicro.debug.gdbjtag.pne.algorithmIndex" value="0"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.alternativeAlgorithmPath" value=""/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.attachToRunning" value="false"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.customTrimFrequency" value="0"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_eth.ALWAYS_ERASE" value="false"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_eth.CYCLONE_IP" value=""/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_eth.DO_RESET_DELAY" value="false"/>
|
||||
<intAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_eth.INTERFACE_PORT" value="0"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_eth.INTERFACE_PORT_STRING" value=""/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_eth.NETWORK_CARD_IP" value=""/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_eth.POWER_DOWN_DELAY" value="250"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_eth.POWER_OFF" value="false"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_eth.POWER_UP_DELAY" value="250"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_eth.PROVIDE_POWER" value="true"/>
|
||||
<intAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_eth.REGULATOR_VOLTAGE" value="0"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_eth.RESET_DELAY" value="0"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_eth.SHIFT_FREQ" value="5000"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_eth.SPECIFY_IP" value="false"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_eth.SPECIFY_NETWORK_CARD" value="false"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_eth.STARTUP_USE_SWD" value="true"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_ser.ALWAYS_ERASE" value="false"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_ser.CYCLONE_IP" value=""/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_ser.DO_RESET_DELAY" value="false"/>
|
||||
<intAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_ser.INTERFACE_PORT" value="0"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_ser.INTERFACE_PORT_STRING" value=""/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_ser.NETWORK_CARD_IP" value=""/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_ser.POWER_DOWN_DELAY" value="250"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_ser.POWER_OFF" value="false"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_ser.POWER_UP_DELAY" value="250"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_ser.PROVIDE_POWER" value="true"/>
|
||||
<intAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_ser.REGULATOR_VOLTAGE" value="0"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_ser.RESET_DELAY" value="0"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_ser.SHIFT_FREQ" value="5000"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_ser.SPECIFY_IP" value="false"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_ser.SPECIFY_NETWORK_CARD" value="false"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_ser.STARTUP_USE_SWD" value="true"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_usb.ALWAYS_ERASE" value="false"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_usb.CYCLONE_IP" value=""/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_usb.DO_RESET_DELAY" value="false"/>
|
||||
<intAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_usb.INTERFACE_PORT" value="0"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_usb.INTERFACE_PORT_STRING" value=""/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_usb.NETWORK_CARD_IP" value=""/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_usb.POWER_DOWN_DELAY" value="250"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_usb.POWER_OFF" value="false"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_usb.POWER_UP_DELAY" value="250"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_usb.PROVIDE_POWER" value="true"/>
|
||||
<intAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_usb.REGULATOR_VOLTAGE" value="0"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_usb.RESET_DELAY" value="0"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_usb.SHIFT_FREQ" value="5000"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_usb.SPECIFY_IP" value="false"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_usb.SPECIFY_NETWORK_CARD" value="false"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.cyc_usb.STARTUP_USE_SWD" value="true"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.doContinue" value="true"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.doGdbServerAllocateSemihostingConsole" value="true"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.doPartitioning" value="false"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.enableSemihosting" value="true"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.enableSemihostingIoclientGdbClient" value="false"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.enableSemihostingIoclientTelnet" value="true"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.eraseCommandParam" value="EM"/>
|
||||
<intAttribute key="com.pemicro.debug.gdbjtag.pne.eraseOptionIndex" value="0"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.eraseOptionsenabled" value="false"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.executeUnlockCommand" value="false"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.gdbClientOtherCommands" value="set mem inaccessible-by-default off set tcp auto-retry on set tcp connect-timeout 240 set remotetimeout 60"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.gdbClientOtherOptions" value=""/>
|
||||
<intAttribute key="com.pemicro.debug.gdbjtag.pne.gdbServerTelnetPortNumber" value="51794"/>
|
||||
<intAttribute key="com.pemicro.debug.gdbjtag.pne.gdbmiPortNumber" value="6224"/>
|
||||
<intAttribute key="com.pemicro.debug.gdbjtag.pne.jtagPreIrBits" value="0"/>
|
||||
<intAttribute key="com.pemicro.debug.gdbjtag.pne.jtagTapNumber" value="0"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.macScript" value=""/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.macScriptEnable" value="false"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.ml.ALWAYS_ERASE" value="false"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.ml.CYCLONE_IP" value=""/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.ml.DO_RESET_DELAY" value="false"/>
|
||||
<intAttribute key="com.pemicro.debug.gdbjtag.pne.ml.INTERFACE_PORT" value="0"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.ml.INTERFACE_PORT_STRING" value=""/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.ml.NETWORK_CARD_IP" value=""/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.ml.POWER_DOWN_DELAY" value="250"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.ml.POWER_OFF" value="false"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.ml.POWER_UP_DELAY" value="1000"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.ml.PROVIDE_POWER" value="true"/>
|
||||
<intAttribute key="com.pemicro.debug.gdbjtag.pne.ml.REGULATOR_VOLTAGE" value="0"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.ml.RESET_DELAY" value="0"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.ml.SHIFT_FREQ" value="5000"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.ml.SPECIFY_IP" value="false"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.ml.SPECIFY_NETWORK_CARD" value="false"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.ml.STARTUP_USE_SWD" value="true"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.ml.SWO_BAUDRATE_SWITCH_MULTILINK_VALUE" value="-1.000000"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.ml.SWO_BAUDRATE_SWITCH_TARGET_VALUE" value="-1.000000"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.otherRunCommands" value=""/>
|
||||
<intAttribute key="com.pemicro.debug.gdbjtag.pne.partitionParam" value="0"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.preserveMemory0" value="false"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.preserveMemory1" value="false"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.preserveMemory2" value="false"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.preserveMemoryFrom0" value="0"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.preserveMemoryFrom1" value="0"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.preserveMemoryFrom2" value="0"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.preserveMemoryTo0" value="3"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.preserveMemoryTo1" value="3"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.preserveMemoryTo2" value="3"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.preservePartioning" value="false"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.programtrim" value="false"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.sda.ALWAYS_ERASE" value="false"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.sda.CYCLONE_IP" value=""/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.sda.DO_RESET_DELAY" value="false"/>
|
||||
<intAttribute key="com.pemicro.debug.gdbjtag.pne.sda.INTERFACE_PORT" value="0"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.sda.INTERFACE_PORT_STRING" value=""/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.sda.NETWORK_CARD_IP" value=""/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.sda.POWER_DOWN_DELAY" value=""/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.sda.POWER_OFF" value="false"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.sda.POWER_UP_DELAY" value=""/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.sda.PROVIDE_POWER" value="true"/>
|
||||
<intAttribute key="com.pemicro.debug.gdbjtag.pne.sda.REGULATOR_VOLTAGE" value="0"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.sda.RESET_DELAY" value="0"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.sda.SHIFT_FREQ" value="5000"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.sda.SPECIFY_IP" value="false"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.sda.SPECIFY_NETWORK_CARD" value="false"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.sda.STARTUP_USE_SWD" value="true"/>
|
||||
<intAttribute key="com.pemicro.debug.gdbjtag.pne.selectedCoreNumber" value="1"/>
|
||||
<intAttribute key="com.pemicro.debug.gdbjtag.pne.serverPortNumber" value="7224"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.trc_eth.ALWAYS_ERASE" value="false"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.trc_eth.CYCLONE_IP" value=""/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.trc_eth.DO_RESET_DELAY" value="false"/>
|
||||
<intAttribute key="com.pemicro.debug.gdbjtag.pne.trc_eth.INTERFACE_PORT" value="0"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.trc_eth.INTERFACE_PORT_STRING" value=""/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.trc_eth.NETWORK_CARD_IP" value=""/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.trc_eth.POWER_DOWN_DELAY" value="250"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.trc_eth.POWER_OFF" value="false"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.trc_eth.POWER_UP_DELAY" value="250"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.trc_eth.PROVIDE_POWER" value="true"/>
|
||||
<intAttribute key="com.pemicro.debug.gdbjtag.pne.trc_eth.REGULATOR_VOLTAGE" value="0"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.trc_eth.RESET_DELAY" value="0"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.trc_eth.SHIFT_FREQ" value="5000"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.trc_eth.SPECIFY_IP" value="false"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.trc_eth.SPECIFY_NETWORK_CARD" value="false"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.trc_eth.STARTUP_USE_SWD" value="true"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.trc_usb.ALWAYS_ERASE" value="false"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.trc_usb.CYCLONE_IP" value=""/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.trc_usb.DO_RESET_DELAY" value="false"/>
|
||||
<intAttribute key="com.pemicro.debug.gdbjtag.pne.trc_usb.INTERFACE_PORT" value="0"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.trc_usb.INTERFACE_PORT_STRING" value=""/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.trc_usb.NETWORK_CARD_IP" value=""/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.trc_usb.POWER_DOWN_DELAY" value="250"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.trc_usb.POWER_OFF" value="false"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.trc_usb.POWER_UP_DELAY" value="250"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.trc_usb.PROVIDE_POWER" value="true"/>
|
||||
<intAttribute key="com.pemicro.debug.gdbjtag.pne.trc_usb.REGULATOR_VOLTAGE" value="0"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.trc_usb.RESET_DELAY" value="0"/>
|
||||
<stringAttribute key="com.pemicro.debug.gdbjtag.pne.trc_usb.SHIFT_FREQ" value="5000"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.trc_usb.SPECIFY_IP" value="false"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.trc_usb.SPECIFY_NETWORK_CARD" value="false"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.trc_usb.STARTUP_USE_SWD" value="true"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.useAlternativeAlgorithm" value="false"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.useCustomTrim" value="false"/>
|
||||
<booleanAttribute key="com.pemicro.debug.gdbjtag.pne.useDaisyChain" value="false"/>
|
||||
<stringAttribute key="org.eclipse.cdt.debug.gdbjtag.core.imageFileName" value=""/>
|
||||
<stringAttribute key="org.eclipse.cdt.debug.gdbjtag.core.imageOffset" value=""/>
|
||||
<stringAttribute key="org.eclipse.cdt.debug.gdbjtag.core.ipAddress" value="localhost"/>
|
||||
<stringAttribute key="org.eclipse.cdt.debug.gdbjtag.core.jtagDevice" value="GNU ARM PEMicro Interface"/>
|
||||
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.loadImage" value="true"/>
|
||||
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.loadSymbols" value="true"/>
|
||||
<stringAttribute key="org.eclipse.cdt.debug.gdbjtag.core.pcRegister" value=""/>
|
||||
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.setPcRegister" value="false"/>
|
||||
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.setResume" value="false"/>
|
||||
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.setStopAt" value="true"/>
|
||||
<stringAttribute key="org.eclipse.cdt.debug.gdbjtag.core.stopAt" value="main"/>
|
||||
<stringAttribute key="org.eclipse.cdt.debug.gdbjtag.core.symbolsFileName" value=""/>
|
||||
<stringAttribute key="org.eclipse.cdt.debug.gdbjtag.core.symbolsOffset" value=""/>
|
||||
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.useFileForImage" value="false"/>
|
||||
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.useFileForSymbols" value="false"/>
|
||||
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.useProjBinaryForImage" value="true"/>
|
||||
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.useProjBinaryForSymbols" value="true"/>
|
||||
<booleanAttribute key="org.eclipse.cdt.debug.gdbjtag.core.useRemoteTarget" value="true"/>
|
||||
<stringAttribute key="org.eclipse.cdt.debug.mi.core.commandFactory" value="Standard (Windows)"/>
|
||||
<stringAttribute key="org.eclipse.cdt.debug.mi.core.protocol" value="mi"/>
|
||||
<booleanAttribute key="org.eclipse.cdt.debug.mi.core.verboseMode" value="false"/>
|
||||
<stringAttribute key="org.eclipse.cdt.dsf.gdb.DEBUG_NAME" value="${S32DS_ARM32_TOOLCHAIN_DIR}/bin/${arm32_cross_prefix}gdb${arm32_cross_suffix}"/>
|
||||
<booleanAttribute key="org.eclipse.cdt.dsf.gdb.UPDATE_THREADLIST_ON_SUSPEND" value="false"/>
|
||||
<intAttribute key="org.eclipse.cdt.launch.ATTR_BUILD_BEFORE_LAUNCH_ATTR" value="2"/>
|
||||
<stringAttribute key="org.eclipse.cdt.launch.COREFILE_PATH" value=""/>
|
||||
<stringAttribute key="org.eclipse.cdt.launch.DEBUGGER_REGISTER_GROUPS" value=""/>
|
||||
<stringAttribute key="org.eclipse.cdt.launch.PROGRAM_NAME" value="Debug/demoprog_s32k144.elf"/>
|
||||
<stringAttribute key="org.eclipse.cdt.launch.PROJECT_ATTR" value="Prog"/>
|
||||
<booleanAttribute key="org.eclipse.cdt.launch.PROJECT_BUILD_CONFIG_AUTO_ATTR" value="false"/>
|
||||
<stringAttribute key="org.eclipse.cdt.launch.PROJECT_BUILD_CONFIG_ID_ATTR" value="com.nxp.s32ds.cle.arm.mbs.arm32.bare.exe.debug.2040336100"/>
|
||||
<listAttribute key="org.eclipse.debug.core.MAPPED_RESOURCE_PATHS">
|
||||
<listEntry value="/Prog"/>
|
||||
</listAttribute>
|
||||
<listAttribute key="org.eclipse.debug.core.MAPPED_RESOURCE_TYPES">
|
||||
<listEntry value="4"/>
|
||||
</listAttribute>
|
||||
<stringAttribute key="org.eclipse.debug.core.source_locator_id" value="org.eclipse.cdt.debug.core.sourceLocator"/>
|
||||
<stringAttribute key="org.eclipse.debug.core.source_locator_memento" value="<?xml version="1.0" encoding="UTF-8" standalone="no"?> <sourceLookupDirector> <sourceContainers duplicates="false"> <container memento="&lt;?xml version=&quot;1.0&quot; encoding=&quot;UTF-8&quot; standalone=&quot;no&quot;?&gt;&#13;&#10;&lt;mapping backend_enabled=&quot;true&quot; name=&quot;EWL&quot;&gt;&#13;&#10;&lt;mapEntry memento=&quot;&amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;UTF-8&amp;quot; standalone=&amp;quot;no&amp;quot;?&amp;gt;&amp;#13;&amp;#10;&amp;lt;mapEntry backendPath=&amp;quot;arm32_ewl2&amp;quot; localPath=&amp;quot;C:\NXP\S32DS_ARM_v2.2\S32DS\build_tools\gcc_v6.3\arm32_ewl2&amp;quot;/&amp;gt;&amp;#13;&amp;#10;&quot;/&gt;&#13;&#10;&lt;/mapping&gt;&#13;&#10;" typeId="org.eclipse.cdt.debug.core.containerType.mapping"/> <container memento="&lt;?xml version=&quot;1.0&quot; encoding=&quot;UTF-8&quot; standalone=&quot;no&quot;?&gt;&#13;&#10;&lt;default/&gt;&#13;&#10;" typeId="org.eclipse.debug.core.containerType.default"/> </sourceContainers> </sourceLookupDirector> "/>
|
||||
<stringAttribute key="org.eclipse.dsf.launch.MEMORY_BLOCKS" value="<?xml version="1.0" encoding="UTF-8" standalone="no"?> <memoryBlockExpressionList context="reserved-for-future-use"/> "/>
|
||||
<stringAttribute key="process_factory_id" value="org.eclipse.cdt.dsf.gdb.GdbProcessFactory"/>
|
||||
</launchConfiguration>
|
|
@ -0,0 +1,280 @@
|
|||
/*
|
||||
** ###################################################################
|
||||
** Processor: S32K144 with 64 KB SRAM
|
||||
** Compiler: GNU C Compiler
|
||||
**
|
||||
** Abstract:
|
||||
** Linker file for the GNU C Compiler
|
||||
**
|
||||
** Copyright (c) 2015-2016 Freescale Semiconductor, Inc.
|
||||
** Copyright 2017 NXP
|
||||
** All rights reserved.
|
||||
**
|
||||
** THIS SOFTWARE IS PROVIDED BY NXP "AS IS" AND ANY EXPRESSED OR
|
||||
** IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
|
||||
** OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
|
||||
** IN NO EVENT SHALL NXP OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
|
||||
** INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
|
||||
** (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
|
||||
** SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
||||
** HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
|
||||
** STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING
|
||||
** IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
|
||||
** THE POSSIBILITY OF SUCH DAMAGE.
|
||||
**
|
||||
** http: www.freescale.com
|
||||
** mail: support@freescale.com
|
||||
**
|
||||
** ###################################################################
|
||||
*/
|
||||
|
||||
/* Entry Point */
|
||||
ENTRY(Reset_Handler)
|
||||
/*
|
||||
To use "new" operator with EWL in C++ project the following symbol shall be defined
|
||||
*/
|
||||
/*EXTERN(_ZN10__cxxabiv119__terminate_handlerE)*/
|
||||
|
||||
|
||||
HEAP_SIZE = DEFINED(__heap_size__) ? __heap_size__ : 0x00000400;
|
||||
STACK_SIZE = DEFINED(__stack_size__) ? __stack_size__ : 0x00000400;
|
||||
|
||||
/* If symbol __flash_vector_table__=1 is defined at link time
|
||||
* the interrupt vector will not be copied to RAM.
|
||||
* Warning: Using the interrupt vector from Flash will not allow
|
||||
* INT_SYS_InstallHandler because the section is Read Only.
|
||||
*/
|
||||
M_VECTOR_RAM_SIZE = DEFINED(__flash_vector_table__) ? 0x0 : 0x0400;
|
||||
|
||||
/* Specify the memory areas */
|
||||
MEMORY
|
||||
{
|
||||
/* Flash */
|
||||
m_interrupts (RX) : ORIGIN = 0x00002000, LENGTH = 0x00000400
|
||||
m_flash_config (RX) : ORIGIN = 0x00002400, LENGTH = 0x00000010
|
||||
m_text (RX) : ORIGIN = 0x00002410, LENGTH = 0x0007FBF0 - 0x2000
|
||||
|
||||
/* SRAM_L */
|
||||
m_data (RW) : ORIGIN = 0x1FFF8000, LENGTH = 0x00008000
|
||||
|
||||
/* SRAM_U */
|
||||
m_data_2 (RW) : ORIGIN = 0x20000000, LENGTH = 0x00007000
|
||||
}
|
||||
|
||||
/* Define output sections */
|
||||
SECTIONS
|
||||
{
|
||||
/* The startup code goes first into internal flash */
|
||||
.interrupts :
|
||||
{
|
||||
__VECTOR_TABLE = .;
|
||||
__interrupts_start__ = .;
|
||||
. = ALIGN(4);
|
||||
KEEP(*(.isr_vector)) /* Startup code */
|
||||
__interrupts_end__ = .;
|
||||
. = ALIGN(4);
|
||||
} > m_interrupts
|
||||
|
||||
.flash_config :
|
||||
{
|
||||
. = ALIGN(4);
|
||||
KEEP(*(.FlashConfig)) /* Flash Configuration Field (FCF) */
|
||||
. = ALIGN(4);
|
||||
} > m_flash_config
|
||||
|
||||
/* The program code and other data goes into internal flash */
|
||||
.text :
|
||||
{
|
||||
. = ALIGN(4);
|
||||
*(.text) /* .text sections (code) */
|
||||
*(.text*) /* .text* sections (code) */
|
||||
*(.rodata) /* .rodata sections (constants, strings, etc.) */
|
||||
*(.rodata*) /* .rodata* sections (constants, strings, etc.) */
|
||||
*(.glue_7) /* glue arm to thumb code */
|
||||
*(.glue_7t) /* glue thumb to arm code */
|
||||
*(.eh_frame)
|
||||
KEEP (*(.init))
|
||||
KEEP (*(.fini))
|
||||
. = ALIGN(4);
|
||||
} > m_text
|
||||
|
||||
.ARM.extab :
|
||||
{
|
||||
*(.ARM.extab* .gnu.linkonce.armextab.*)
|
||||
} > m_text
|
||||
|
||||
.ARM :
|
||||
{
|
||||
__exidx_start = .;
|
||||
*(.ARM.exidx*)
|
||||
__exidx_end = .;
|
||||
} > m_text
|
||||
|
||||
.ctors :
|
||||
{
|
||||
__CTOR_LIST__ = .;
|
||||
/* gcc uses crtbegin.o to find the start of
|
||||
the constructors, so we make sure it is
|
||||
first. Because this is a wildcard, it
|
||||
doesn't matter if the user does not
|
||||
actually link against crtbegin.o; the
|
||||
linker won't look for a file to match a
|
||||
wildcard. The wildcard also means that it
|
||||
doesn't matter which directory crtbegin.o
|
||||
is in. */
|
||||
KEEP (*crtbegin.o(.ctors))
|
||||
KEEP (*crtbegin?.o(.ctors))
|
||||
/* We don't want to include the .ctor section from
|
||||
from the crtend.o file until after the sorted ctors.
|
||||
The .ctor section from the crtend file contains the
|
||||
end of ctors marker and it must be last */
|
||||
KEEP (*(EXCLUDE_FILE(*crtend?.o *crtend.o) .ctors))
|
||||
KEEP (*(SORT(.ctors.*)))
|
||||
KEEP (*(.ctors))
|
||||
__CTOR_END__ = .;
|
||||
} > m_text
|
||||
|
||||
.dtors :
|
||||
{
|
||||
__DTOR_LIST__ = .;
|
||||
KEEP (*crtbegin.o(.dtors))
|
||||
KEEP (*crtbegin?.o(.dtors))
|
||||
KEEP (*(EXCLUDE_FILE(*crtend?.o *crtend.o) .dtors))
|
||||
KEEP (*(SORT(.dtors.*)))
|
||||
KEEP (*(.dtors))
|
||||
__DTOR_END__ = .;
|
||||
} > m_text
|
||||
|
||||
.preinit_array :
|
||||
{
|
||||
PROVIDE_HIDDEN (__preinit_array_start = .);
|
||||
KEEP (*(.preinit_array*))
|
||||
PROVIDE_HIDDEN (__preinit_array_end = .);
|
||||
} > m_text
|
||||
|
||||
.init_array :
|
||||
{
|
||||
PROVIDE_HIDDEN (__init_array_start = .);
|
||||
KEEP (*(SORT(.init_array.*)))
|
||||
KEEP (*(.init_array*))
|
||||
PROVIDE_HIDDEN (__init_array_end = .);
|
||||
} > m_text
|
||||
|
||||
.fini_array :
|
||||
{
|
||||
PROVIDE_HIDDEN (__fini_array_start = .);
|
||||
KEEP (*(SORT(.fini_array.*)))
|
||||
KEEP (*(.fini_array*))
|
||||
PROVIDE_HIDDEN (__fini_array_end = .);
|
||||
} > m_text
|
||||
|
||||
__etext = .; /* Define a global symbol at end of code. */
|
||||
__DATA_ROM = .; /* Symbol is used by startup for data initialization. */
|
||||
.interrupts_ram :
|
||||
{
|
||||
. = ALIGN(4);
|
||||
__VECTOR_RAM__ = .;
|
||||
__RAM_START = .;
|
||||
__interrupts_ram_start__ = .; /* Create a global symbol at data start. */
|
||||
*(.m_interrupts_ram) /* This is a user defined section. */
|
||||
. += M_VECTOR_RAM_SIZE;
|
||||
. = ALIGN(4);
|
||||
__interrupts_ram_end__ = .; /* Define a global symbol at data end. */
|
||||
} > m_data
|
||||
|
||||
__VECTOR_RAM = DEFINED(__flash_vector_table__) ? ORIGIN(m_interrupts) : __VECTOR_RAM__ ;
|
||||
__RAM_VECTOR_TABLE_SIZE = DEFINED(__flash_vector_table__) ? 0x0 : (__interrupts_ram_end__ - __interrupts_ram_start__) ;
|
||||
|
||||
.data : AT(__DATA_ROM)
|
||||
{
|
||||
. = ALIGN(4);
|
||||
__DATA_RAM = .;
|
||||
__data_start__ = .; /* Create a global symbol at data start. */
|
||||
*(.data) /* .data sections */
|
||||
*(.data*) /* .data* sections */
|
||||
KEEP(*(.jcr*))
|
||||
. = ALIGN(4);
|
||||
__data_end__ = .; /* Define a global symbol at data end. */
|
||||
} > m_data
|
||||
|
||||
__DATA_END = __DATA_ROM + (__data_end__ - __data_start__);
|
||||
__CODE_ROM = __DATA_END; /* Symbol is used by code initialization. */
|
||||
.code : AT(__CODE_ROM)
|
||||
{
|
||||
. = ALIGN(4);
|
||||
__CODE_RAM = .;
|
||||
__code_start__ = .; /* Create a global symbol at code start. */
|
||||
__code_ram_start__ = .;
|
||||
*(.code_ram) /* Custom section for storing code in RAM */
|
||||
. = ALIGN(4);
|
||||
__code_end__ = .; /* Define a global symbol at code end. */
|
||||
__code_ram_end__ = .;
|
||||
} > m_data
|
||||
|
||||
__CODE_END = __CODE_ROM + (__code_end__ - __code_start__);
|
||||
__CUSTOM_ROM = __CODE_END;
|
||||
|
||||
/* Custom Section Block that can be used to place data at absolute address. */
|
||||
/* Use __attribute__((section (".customSection"))) to place data here. */
|
||||
.customSectionBlock ORIGIN(m_data_2) : AT(__CUSTOM_ROM)
|
||||
{
|
||||
__customSection_start__ = .;
|
||||
KEEP(*(.customSection)) /* Keep section even if not referenced. */
|
||||
__customSection_end__ = .;
|
||||
} > m_data_2
|
||||
__CUSTOM_END = __CUSTOM_ROM + (__customSection_end__ - __customSection_start__);
|
||||
|
||||
/* Uninitialized data section. */
|
||||
.bss :
|
||||
{
|
||||
/* This is used by the startup in order to initialize the .bss section. */
|
||||
. = ALIGN(4);
|
||||
__BSS_START = .;
|
||||
__bss_start__ = .;
|
||||
*(.bss)
|
||||
*(.bss*)
|
||||
*(COMMON)
|
||||
. = ALIGN(4);
|
||||
__bss_end__ = .;
|
||||
__BSS_END = .;
|
||||
} > m_data_2
|
||||
|
||||
.heap :
|
||||
{
|
||||
. = ALIGN(8);
|
||||
__end__ = .;
|
||||
__heap_start__ = .;
|
||||
PROVIDE(end = .);
|
||||
PROVIDE(_end = .);
|
||||
PROVIDE(__end = .);
|
||||
__HeapBase = .;
|
||||
. += HEAP_SIZE;
|
||||
__HeapLimit = .;
|
||||
__heap_limit = .;
|
||||
__heap_end__ = .;
|
||||
} > m_data_2
|
||||
|
||||
/* Initializes stack on the end of block */
|
||||
__StackTop = ORIGIN(m_data_2) + LENGTH(m_data_2);
|
||||
__StackLimit = __StackTop - STACK_SIZE;
|
||||
PROVIDE(__stack = __StackTop);
|
||||
__RAM_END = __StackTop;
|
||||
|
||||
.stack __StackLimit :
|
||||
{
|
||||
. = ALIGN(8);
|
||||
__stack_start__ = .;
|
||||
. += STACK_SIZE;
|
||||
__stack_end__ = .;
|
||||
} > m_data_2
|
||||
|
||||
/* Labels required by EWL */
|
||||
__START_BSS = __BSS_START;
|
||||
__END_BSS = __BSS_END;
|
||||
__SP_INIT = __StackTop;
|
||||
|
||||
.ARM.attributes 0 : { *(.ARM.attributes) }
|
||||
|
||||
ASSERT(__StackLimit >= __HeapLimit, "region m_data_2 overflowed with stack and heap")
|
||||
}
|
||||
|
|
@ -0,0 +1,772 @@
|
|||
/************************************************************************************//**
|
||||
* \file Demo/ARMCM4_S32K14_S32K144EVB_GCC/Prog/boot.c
|
||||
* \brief Demo program bootloader interface source file.
|
||||
* \ingroup Prog_ARMCM4_S32K14_S32K144EVB_GCC
|
||||
* \internal
|
||||
*----------------------------------------------------------------------------------------
|
||||
* C O P Y R I G H T
|
||||
*----------------------------------------------------------------------------------------
|
||||
* Copyright (c) 2020 by Feaser http://www.feaser.com All rights reserved
|
||||
*
|
||||
*----------------------------------------------------------------------------------------
|
||||
* L I C E N S E
|
||||
*----------------------------------------------------------------------------------------
|
||||
* This file is part of OpenBLT. OpenBLT is free software: you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as published by the Free
|
||||
* Software Foundation, either version 3 of the License, or (at your option) any later
|
||||
* version.
|
||||
*
|
||||
* OpenBLT is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
|
||||
* without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
|
||||
* PURPOSE. See the GNU General Public License for more details.
|
||||
*
|
||||
* You have received a copy of the GNU General Public License along with OpenBLT. It
|
||||
* should be located in ".\Doc\license.html". If not, contact Feaser to obtain a copy.
|
||||
*
|
||||
* \endinternal
|
||||
****************************************************************************************/
|
||||
|
||||
/****************************************************************************************
|
||||
* Include files
|
||||
****************************************************************************************/
|
||||
#include "header.h" /* generic header */
|
||||
|
||||
|
||||
/****************************************************************************************
|
||||
* Function prototypes
|
||||
****************************************************************************************/
|
||||
#if (BOOT_COM_RS232_ENABLE > 0)
|
||||
static void BootComRs232Init(void);
|
||||
static void BootComRs232CheckActivationRequest(void);
|
||||
#endif
|
||||
#if (BOOT_COM_CAN_ENABLE > 0)
|
||||
static void BootComCanInit(void);
|
||||
static void BootComCanCheckActivationRequest(void);
|
||||
#endif
|
||||
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief Initializes the communication interface.
|
||||
** \return none.
|
||||
**
|
||||
****************************************************************************************/
|
||||
void BootComInit(void)
|
||||
{
|
||||
#if (BOOT_COM_RS232_ENABLE > 0)
|
||||
BootComRs232Init();
|
||||
#endif
|
||||
#if (BOOT_COM_CAN_ENABLE > 0)
|
||||
BootComCanInit();
|
||||
#endif
|
||||
} /*** end of BootComInit ***/
|
||||
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief Receives the CONNECT request from the host, which indicates that the
|
||||
** bootloader should be activated and, if so, activates it.
|
||||
** \return none.
|
||||
**
|
||||
****************************************************************************************/
|
||||
void BootComCheckActivationRequest(void)
|
||||
{
|
||||
#if (BOOT_COM_RS232_ENABLE > 0)
|
||||
BootComRs232CheckActivationRequest();
|
||||
#endif
|
||||
#if (BOOT_COM_CAN_ENABLE > 0)
|
||||
BootComCanCheckActivationRequest();
|
||||
#endif
|
||||
} /*** end of BootComCheckActivationRequest ***/
|
||||
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief Bootloader activation function.
|
||||
** \return none.
|
||||
**
|
||||
****************************************************************************************/
|
||||
void BootActivate(void)
|
||||
{
|
||||
/* Activate the bootloader by performing a software reset. */
|
||||
SystemSoftwareReset();
|
||||
} /*** end of BootActivate ***/
|
||||
|
||||
|
||||
#if (BOOT_COM_RS232_ENABLE > 0)
|
||||
/****************************************************************************************
|
||||
* U N I V E R S A L A S Y N C H R O N O U S R X T X I N T E R F A C E
|
||||
****************************************************************************************/
|
||||
|
||||
/****************************************************************************************
|
||||
* Macro definitions
|
||||
****************************************************************************************/
|
||||
/** \brief Timeout time for the reception of a CTO packet. The timer is started upon
|
||||
* reception of the first packet byte.
|
||||
*/
|
||||
#define RS232_CTO_RX_PACKET_TIMEOUT_MS (100u)
|
||||
/** \brief Set the peripheral LPUART base pointer. */
|
||||
#define LPUARTx (LPUART1)
|
||||
/** \brief Set the PCC index offset for LPUART. */
|
||||
#define PCC_LPUARTx_INDEX (PCC_LPUART1_INDEX)
|
||||
|
||||
|
||||
/****************************************************************************************
|
||||
* Function prototypes
|
||||
****************************************************************************************/
|
||||
static unsigned char Rs232ReceiveByte(unsigned char *data);
|
||||
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief Initializes the UART communication interface.
|
||||
** \return none.
|
||||
**
|
||||
****************************************************************************************/
|
||||
static void BootComRs232Init(void)
|
||||
{
|
||||
unsigned long sourceClockFreqHz;
|
||||
unsigned long div2RegValue;
|
||||
unsigned short baudrateSbr0_12;
|
||||
unsigned char const div2DividerLookup[] =
|
||||
{
|
||||
0U, /* 0b000. Output disabled. */
|
||||
1U, /* 0b001. Divide by 1. */
|
||||
2U, /* 0b010. Divide by 2. */
|
||||
4U, /* 0b011. Divide by 4. */
|
||||
8U, /* 0b100. Divide by 8. */
|
||||
16U, /* 0b101. Divide by 16. */
|
||||
32U, /* 0b110. Divide by 32. */
|
||||
64U, /* 0b111. Divide by 64. */
|
||||
};
|
||||
|
||||
/* Make sure the UART peripheral clock is disabled before configuring its source
|
||||
* clock.
|
||||
*/
|
||||
PCC->PCCn[PCC_LPUARTx_INDEX] &= ~PCC_PCCn_CGC_MASK;
|
||||
/* Select option 2 as the UART peripheral source clock and enable the clock. Option 2
|
||||
* is the SIRCDIV2_CLK, which is available on all peripherals and configurations.
|
||||
*/
|
||||
PCC->PCCn[PCC_LPUARTx_INDEX] |= PCC_PCCn_PCS(0b010) | PCC_PCCn_CGC_MASK;
|
||||
/* Obtain the DIV2 divider value of the SIRC_CLK. */
|
||||
div2RegValue = (SCG->SIRCDIV & SCG_SIRCDIV_SIRCDIV2_MASK) >> SCG_SIRCDIV_SIRCDIV2_SHIFT;
|
||||
/* Check if the DIV2 register value for SIRC is 0. In this case SIRCDIV2_CLK is
|
||||
* currently disabled.
|
||||
*/
|
||||
if (div2RegValue == 0U)
|
||||
{
|
||||
/* Configure the DIV2 for a default divide by 1 to make sure the SIRCDIV2_CLK is
|
||||
* actually enabled.
|
||||
*/
|
||||
div2RegValue = 1U;
|
||||
SCG->SIRCDIV = SCG_SIRCDIV_SIRCDIV2(div2RegValue);
|
||||
}
|
||||
/* Determine the SIRC clock frequency. If SIRC high range is enabled, it is 8 MHz. If
|
||||
* SIRC low range is enabled, it is 2 MHz.
|
||||
*/
|
||||
sourceClockFreqHz = 8000000U;
|
||||
if ((SCG->SIRCCFG & SCG_SIRCCFG_RANGE_MASK) == SCG_SIRCCFG_RANGE(0))
|
||||
{
|
||||
sourceClockFreqHz = 2000000U;
|
||||
}
|
||||
/* Now process the configured DIV2 divider factor to get the actual frequency of the
|
||||
* UART peripheral source clock.
|
||||
*/
|
||||
sourceClockFreqHz /= div2DividerLookup[div2RegValue];
|
||||
/* Configure the baudrate from BOOT_COM_RS232_BAUDRATE, taking into account that an
|
||||
* oversampling of 8 will be configured. Default 8,n,1 format is used. Integer
|
||||
* rounding is used to get the best value for baudrateSbr0_12. Actual baudrate equals
|
||||
* sourceClockFreqHz / 8 / baudrateSbr0_12.
|
||||
*/
|
||||
baudrateSbr0_12 = (((sourceClockFreqHz / BOOT_COM_RS232_BAUDRATE) + (8U - 1U)) / 8U) &
|
||||
LPUART_BAUD_SBR_MASK;
|
||||
/* OSR=7: Over sampling ratio = 7+1=8.
|
||||
* SBNS=0: One stop bit.
|
||||
* BOTHEDGE=0: receiver samples only on rising edge.
|
||||
* M10=0: Rx and Tx use 7 to 9 bit data characters.
|
||||
* RESYNCDIS=0: Resync during rec'd data word supported.
|
||||
* LBKDIE, RXEDGIE=0: interrupts disable.
|
||||
* TDMAE, RDMAE, TDMAE=0: DMA requests disabled.
|
||||
* MAEN1, MAEN2, MATCFG=0: Match disabled.
|
||||
*/
|
||||
LPUARTx->BAUD = LPUART_BAUD_SBR(baudrateSbr0_12) | LPUART_BAUD_OSR(7);
|
||||
/* Clear the error/interrupt flags */
|
||||
LPUARTx->STAT = FEATURE_LPUART_STAT_REG_FLAGS_MASK;
|
||||
/* Reset all features/interrupts by default */
|
||||
LPUARTx->CTRL = 0x00000000;
|
||||
/* Reset match addresses */
|
||||
LPUARTx->MATCH = 0x00000000;
|
||||
#if FEATURE_LPUART_HAS_MODEM_SUPPORT
|
||||
/* Reset IrDA modem features */
|
||||
LPUARTx->MODIR = 0x00000000;
|
||||
#endif
|
||||
#if FEATURE_LPUART_FIFO_SIZE > 0U
|
||||
/* Reset FIFO feature */
|
||||
LPUARTx->FIFO = FEATURE_LPUART_FIFO_RESET_MASK;
|
||||
/* Enable the transmit and receive FIFOs. */
|
||||
LPUARTx->FIFO |= LPUART_FIFO_TXFE(1) | LPUART_FIFO_RXFE(1);
|
||||
/* Set the reception water mark to 0 and the transmitter water mark to 1. */
|
||||
LPUARTx->WATER = LPUART_WATER_TXWATER(1) | LPUART_WATER_RXWATER(0);
|
||||
#endif
|
||||
/* Enable transmitter and receiver, no parity, 8 bit char:
|
||||
* RE=1: Receiver enabled.
|
||||
* TE=1: Transmitter enabled.
|
||||
* PE,PT=0: No hw parity generation or checking.
|
||||
* M7,M,R8T9,R9T8=0: 8-bit data characters.
|
||||
* DOZEEN=0: LPUART enabled in Doze mode.
|
||||
* ORIE,NEIE,FEIE,PEIE,TIE,TCIE,RIE,ILIE,MA1IE,MA2IE=0: no IRQ.
|
||||
* TxDIR=0: TxD pin is input if in single-wire mode.
|
||||
* TXINV=0: Transmit data not inverted.
|
||||
* RWU,WAKE=0: normal operation; rcvr not in standby.
|
||||
* IDLCFG=0: one idle character.
|
||||
* ILT=0: Idle char bit count starts after start bit.
|
||||
* SBK=0: Normal transmitter operation - no break char.
|
||||
* LOOPS,RSRC=0: no loop back.
|
||||
*/
|
||||
LPUARTx->CTRL = LPUART_CTRL_RE_MASK | LPUART_CTRL_TE_MASK;
|
||||
} /*** end of BootComRs232Init ***/
|
||||
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief Receives the CONNECT request from the host, which indicates that the
|
||||
** bootloader should be activated and, if so, activates it.
|
||||
** \return none.
|
||||
**
|
||||
****************************************************************************************/
|
||||
static void BootComRs232CheckActivationRequest(void)
|
||||
{
|
||||
static unsigned char xcpCtoReqPacket[BOOT_COM_RS232_RX_MAX_DATA+1];
|
||||
static unsigned char xcpCtoRxLength;
|
||||
static unsigned char xcpCtoRxInProgress = 0;
|
||||
static unsigned long xcpCtoRxStartTime = 0;
|
||||
|
||||
/* start of cto packet received? */
|
||||
if (xcpCtoRxInProgress == 0)
|
||||
{
|
||||
/* store the message length when received */
|
||||
if (Rs232ReceiveByte(&xcpCtoReqPacket[0]) == 1)
|
||||
{
|
||||
/* check that the length has a valid value. it should not be 0 */
|
||||
if ( (xcpCtoReqPacket[0] > 0) &&
|
||||
(xcpCtoReqPacket[0] <= BOOT_COM_RS232_RX_MAX_DATA) )
|
||||
{
|
||||
/* store the start time */
|
||||
xcpCtoRxStartTime = TimerGet();
|
||||
/* indicate that a cto packet is being received */
|
||||
xcpCtoRxInProgress = 1;
|
||||
/* reset packet data count */
|
||||
xcpCtoRxLength = 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
/* store the next packet byte */
|
||||
if (Rs232ReceiveByte(&xcpCtoReqPacket[xcpCtoRxLength+1]) == 1)
|
||||
{
|
||||
/* increment the packet data count */
|
||||
xcpCtoRxLength++;
|
||||
|
||||
/* check to see if the entire packet was received */
|
||||
if (xcpCtoRxLength == xcpCtoReqPacket[0])
|
||||
{
|
||||
/* done with cto packet reception */
|
||||
xcpCtoRxInProgress = 0;
|
||||
|
||||
/* check if this was an XCP CONNECT command */
|
||||
if ((xcpCtoReqPacket[1] == 0xff) && (xcpCtoReqPacket[2] == 0x00))
|
||||
{
|
||||
/* connection request received so start the bootloader */
|
||||
BootActivate();
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
/* check packet reception timeout */
|
||||
if (TimerGet() > (xcpCtoRxStartTime + RS232_CTO_RX_PACKET_TIMEOUT_MS))
|
||||
{
|
||||
/* cancel cto packet reception due to timeout. note that this automatically
|
||||
* discards the already received packet bytes, allowing the host to retry.
|
||||
*/
|
||||
xcpCtoRxInProgress = 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
} /*** end of BootComRs232CheckActivationRequest ***/
|
||||
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief Receives a communication interface byte if one is present.
|
||||
** \param data Pointer to byte where the data is to be stored.
|
||||
** \return 1 if a byte was received, 0 otherwise.
|
||||
**
|
||||
****************************************************************************************/
|
||||
static unsigned char Rs232ReceiveByte(unsigned char *data)
|
||||
{
|
||||
unsigned char result = 0;
|
||||
|
||||
/* Check if a new byte was received by means of the RDRF-bit. */
|
||||
if (((LPUARTx->STAT & LPUART_STAT_RDRF_MASK) >> LPUART_STAT_RDRF_SHIFT) != 0U)
|
||||
{
|
||||
/* Retrieve and store the newly received byte. */
|
||||
*data = LPUARTx->DATA;
|
||||
/* Update the result. */
|
||||
result = 1;
|
||||
}
|
||||
|
||||
/* Give the result back to the caller. */
|
||||
return result;
|
||||
} /*** end of Rs232ReceiveByte ***/
|
||||
#endif /* BOOT_COM_RS232_ENABLE > 0 */
|
||||
|
||||
|
||||
#if (BOOT_COM_CAN_ENABLE > 0)
|
||||
/****************************************************************************************
|
||||
* C O N T R O L L E R A R E A N E T W O R K I N T E R F A C E
|
||||
****************************************************************************************/
|
||||
|
||||
/****************************************************************************************
|
||||
* Macro definitions
|
||||
****************************************************************************************/
|
||||
/** \brief Timeout for entering/leaving CAN initialization mode in milliseconds. */
|
||||
#define CAN_INIT_TIMEOUT_MS (250U)
|
||||
|
||||
/** \brief Set the peripheral CAN0 base pointer. */
|
||||
#define CANx (CAN0)
|
||||
/** \brief Set the PCC index offset for CAN0. */
|
||||
#define PCC_FlexCANx_INDEX (PCC_FlexCAN0_INDEX)
|
||||
/** \brief Set the number of message boxes supported by CAN0. */
|
||||
#define CANx_MAX_MB_NUM (FEATURE_CAN0_MAX_MB_NUM)
|
||||
|
||||
/** \brief The mailbox used for receiving the XCP command message. */
|
||||
#define CAN_RX_MSGBOX_NUM (9U)
|
||||
|
||||
|
||||
/****************************************************************************************
|
||||
* Type definitions
|
||||
****************************************************************************************/
|
||||
/** \brief Structure type for grouping CAN bus timing related information. */
|
||||
typedef struct t_can_bus_timing
|
||||
{
|
||||
unsigned char timeQuanta; /**< Total number of time quanta */
|
||||
unsigned char propSeg; /**< CAN propagation segment */
|
||||
unsigned char phaseSeg1; /**< CAN phase segment 1 */
|
||||
unsigned char phaseSeg2; /**< CAN phase segment 2 */
|
||||
} tCanBusTiming;
|
||||
|
||||
|
||||
/****************************************************************************************
|
||||
* Local constant declarations
|
||||
****************************************************************************************/
|
||||
/** \brief CAN bit timing table for dynamically calculating the bittiming settings.
|
||||
* \details According to the CAN protocol 1 bit-time can be made up of between 8..25
|
||||
* time quanta (TQ). The total TQ in a bit is SYNC + TSEG1 + TSEG2 with SYNC
|
||||
* always being 1. The sample point is (SYNC + TSEG1) / (SYNC + TSEG1 + TSEG2)
|
||||
* * 100%. This array contains possible and valid time quanta configurations
|
||||
* with a sample point between 68..78%. A visual representation of the TQ in
|
||||
* a bit is:
|
||||
* | SYNCSEG | TIME1SEG | TIME2SEG |
|
||||
* Or with an alternative representation:
|
||||
* | SYNCSEG | PROPSEG | PHASE1SEG | PHASE2SEG |
|
||||
* With the alternative representation TIME1SEG = PROPSEG + PHASE1SEG.
|
||||
*
|
||||
*/
|
||||
static const tCanBusTiming canTiming[] =
|
||||
{
|
||||
/* Time-Quanta | PROPSEG | PSEG1 | PSEG2 | Sample-Point */
|
||||
/* ---------------------------------------------------- */
|
||||
{ 8U, 3U, 2U, 2U }, /*1+3+2+1=8 | 3 | 2 | 2 | 75% */
|
||||
{ 9U, 3U, 3U, 2U }, /* 9 | 3 | 3 | 2 | 78% */
|
||||
{ 10U, 3U, 3U, 3U }, /* 10 | 3 | 3 | 3 | 70% */
|
||||
{ 11U, 4U, 3U, 3U }, /* 11 | 4 | 3 | 3 | 73% */
|
||||
{ 12U, 4U, 4U, 3U }, /* 12 | 4 | 4 | 3 | 75% */
|
||||
{ 13U, 5U, 4U, 3U }, /* 13 | 5 | 4 | 3 | 77% */
|
||||
{ 14U, 5U, 4U, 4U }, /* 14 | 5 | 4 | 4 | 71% */
|
||||
{ 15U, 6U, 4U, 4U }, /* 15 | 6 | 4 | 4 | 73% */
|
||||
{ 16U, 6U, 5U, 4U }, /* 16 | 6 | 5 | 4 | 75% */
|
||||
{ 17U, 7U, 5U, 4U }, /* 17 | 7 | 5 | 4 | 76% */
|
||||
{ 18U, 7U, 5U, 5U }, /* 18 | 7 | 5 | 5 | 72% */
|
||||
{ 19U, 8U, 5U, 5U }, /* 19 | 8 | 5 | 5 | 74% */
|
||||
{ 20U, 8U, 6U, 5U }, /* 20 | 8 | 6 | 5 | 75% */
|
||||
{ 21U, 8U, 7U, 5U }, /* 21 | 8 | 7 | 5 | 76% */
|
||||
{ 22U, 8U, 7U, 6U }, /* 22 | 8 | 7 | 6 | 73% */
|
||||
{ 23U, 8U, 8U, 6U }, /* 23 | 8 | 8 | 6 | 74% */
|
||||
{ 24U, 8U, 8U, 7U }, /* 24 | 8 | 8 | 7 | 71% */
|
||||
{ 25U, 8U, 8U, 8U } /* 25 | 8 | 8 | 8 | 68% */
|
||||
};
|
||||
|
||||
|
||||
/****************************************************************************************
|
||||
* Local data declarations
|
||||
****************************************************************************************/
|
||||
/** \brief Dummy variable to store the CAN controller's free running timer value in.
|
||||
* This is needed at the end of a CAN message reception to unlock the mailbox
|
||||
* again. If this variable is declared locally within the function, it generates
|
||||
* an unwanted compiler warning about assigning a value and not using it.
|
||||
* For this reason this dummy variabled is declare here as a module global.
|
||||
*/
|
||||
static volatile unsigned long dummyTimerVal;
|
||||
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief Search algorithm to match the desired baudrate to a possible bus
|
||||
** timing configuration.
|
||||
** \param baud The desired baudrate in kbps. Valid values are 10..1000.
|
||||
** \param prescaler Pointer to where the value for the prescaler will be stored.
|
||||
** \param busTimingCfg Pointer to where the bus timing values will be stored.
|
||||
** \return 1 if the CAN bustiming register values were found, 0 otherwise.
|
||||
**
|
||||
****************************************************************************************/
|
||||
static unsigned char CanGetSpeedConfig(unsigned short baud, unsigned short * prescaler,
|
||||
tCanBusTiming * busTimingCfg)
|
||||
{
|
||||
unsigned char cnt;
|
||||
unsigned long canClockFreqkHz;
|
||||
unsigned long div2RegValue;
|
||||
unsigned char const div2DividerLookup[] =
|
||||
{
|
||||
0U, /* 0b000. Output disabled. */
|
||||
1U, /* 0b001. Divide by 1. */
|
||||
2U, /* 0b010. Divide by 2. */
|
||||
4U, /* 0b011. Divide by 4. */
|
||||
8U, /* 0b100. Divide by 8. */
|
||||
16U, /* 0b101. Divide by 16. */
|
||||
32U, /* 0b110. Divide by 32. */
|
||||
64U, /* 0b111. Divide by 64. */
|
||||
};
|
||||
|
||||
/* Obtain the DIV2 divider value of the SOSC_CLK. */
|
||||
div2RegValue = (SCG->SOSCDIV & SCG_SOSCDIV_SOSCDIV2_MASK) >> SCG_SOSCDIV_SOSCDIV2_SHIFT;
|
||||
/* Check if the DIV2 register value for SOSC is 0. In this case SOSCDIV2_CLK is
|
||||
* currently disabled.
|
||||
*/
|
||||
if (div2RegValue == 0U)
|
||||
{
|
||||
/* Configure the DIV2 for a default divide by 1 to make sure the SOSCDIV2_CLK is
|
||||
* actually enabled.
|
||||
*/
|
||||
div2RegValue = 1U;
|
||||
SCG->SOSCDIV = SCG_SOSCDIV_SOSCDIV2(div2RegValue);
|
||||
}
|
||||
/* Determine the SOSC clock frequency. */
|
||||
canClockFreqkHz = BOOT_CPU_XTAL_SPEED_KHZ;
|
||||
/* Now process the configured DIV2 divider factor to get the actual frequency of the
|
||||
* CAN peripheral source clock.
|
||||
*/
|
||||
canClockFreqkHz /= div2DividerLookup[div2RegValue];
|
||||
|
||||
/* Loop through all possible time quanta configurations to find a match. */
|
||||
for (cnt=0; cnt < sizeof(canTiming)/sizeof(canTiming[0]); cnt++)
|
||||
{
|
||||
if ((canClockFreqkHz % (baud * canTiming[cnt].timeQuanta)) == 0U)
|
||||
{
|
||||
/* Compute the prescaler that goes with this TQ configuration. */
|
||||
*prescaler = canClockFreqkHz/(baud * canTiming[cnt].timeQuanta);
|
||||
|
||||
/* Make sure the prescaler is valid. */
|
||||
if ((*prescaler > 0U) && (*prescaler <= 256U))
|
||||
{
|
||||
/* Store the bustiming configuration. */
|
||||
*busTimingCfg = canTiming[cnt];
|
||||
/* Found a good bus timing configuration. */
|
||||
return 1U;
|
||||
}
|
||||
}
|
||||
}
|
||||
/* Could not find a good bus timing configuration. */
|
||||
return 0U;
|
||||
} /*** end of CanGetSpeedConfig ***/
|
||||
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief Places the CAN controller in freeze mode. Note that the CAN controller
|
||||
** can only be placed in freeze mode, if it is actually enabled.
|
||||
** \return none.
|
||||
**
|
||||
****************************************************************************************/
|
||||
static void CanFreezeModeEnter(void)
|
||||
{
|
||||
unsigned long timeout;
|
||||
|
||||
/* Request to enter freeze mode. */
|
||||
CANx->MCR = (CANx->MCR & ~CAN_MCR_FRZ_MASK) | CAN_MCR_FRZ(1U);
|
||||
CANx->MCR = (CANx->MCR & ~CAN_MCR_HALT_MASK) | CAN_MCR_HALT(1U);
|
||||
/* Set timeout time for entering freeze mode. */
|
||||
timeout = TimerGet() + CAN_INIT_TIMEOUT_MS;
|
||||
/* Wait for freeze mode acknowledgement. */
|
||||
while (((CANx->MCR & CAN_MCR_FRZACK_MASK)) == 0U)
|
||||
{
|
||||
/* Break loop upon timeout. This would indicate a hardware failure. */
|
||||
if (TimerGet() > timeout)
|
||||
{
|
||||
break;
|
||||
}
|
||||
}
|
||||
} /*** end of CanFreezeModeEnter ***/
|
||||
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief Leaves the CAN controller's freeze mode. Note that this operation can
|
||||
** only be done, if it is actually enabled.
|
||||
** \return none.
|
||||
**
|
||||
****************************************************************************************/
|
||||
static void CanFreezeModeExit(void)
|
||||
{
|
||||
unsigned long timeout;
|
||||
|
||||
/* Request to leave freeze mode. */
|
||||
CANx->MCR = (CANx->MCR & ~CAN_MCR_FRZ_MASK) | CAN_MCR_FRZ(0U);
|
||||
CANx->MCR = (CANx->MCR & ~CAN_MCR_HALT_MASK) | CAN_MCR_HALT(0U);
|
||||
/* Set timeout time for leaving freeze mode. */
|
||||
timeout = TimerGet() + CAN_INIT_TIMEOUT_MS;
|
||||
/* Wait for non freeze mode acknowledgement. */
|
||||
while (((CANx->MCR & CAN_MCR_FRZACK_MASK)) != 0U)
|
||||
{
|
||||
/* Break loop upon timeout. This would indicate a hardware failure. */
|
||||
if (TimerGet() > timeout)
|
||||
{
|
||||
break;
|
||||
}
|
||||
}
|
||||
} /*** end of CanFreezeModeExit ***/
|
||||
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief Places the CAN controller in disabled mode.
|
||||
** \return none.
|
||||
**
|
||||
****************************************************************************************/
|
||||
static void CanDisabledModeEnter(void)
|
||||
{
|
||||
unsigned long timeout;
|
||||
|
||||
/* Only continue if the CAN controller is currently enabled. */
|
||||
if ((CANx->MCR & CAN_MCR_MDIS_MASK) == 0U)
|
||||
{
|
||||
/* Request disabled mode. */
|
||||
CANx->MCR = (CANx->MCR & ~CAN_MCR_MDIS_MASK) | CAN_MCR_MDIS(1U);
|
||||
/* Set timeout time for entering disabled mode. */
|
||||
timeout = TimerGet() + CAN_INIT_TIMEOUT_MS;
|
||||
/* Wait for disabled mode acknowledgement. */
|
||||
while (((CANx->MCR & CAN_MCR_LPMACK_MASK)) == 0U)
|
||||
{
|
||||
/* Break loop upon timeout. This would indicate a hardware failure. */
|
||||
if (TimerGet() > timeout)
|
||||
{
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
} /*** end of CanDisabledModeEnter ***/
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief Places the CAN controller in enabled mode.
|
||||
** \return none.
|
||||
**
|
||||
****************************************************************************************/
|
||||
static void CanDisabledModeExit(void)
|
||||
{
|
||||
unsigned long timeout;
|
||||
|
||||
/* Only continue if the CAN controller is currently disabled. */
|
||||
if ((CANx->MCR & CAN_MCR_MDIS_MASK) != 0U)
|
||||
{
|
||||
/* Request enabled mode. */
|
||||
CANx->MCR = (CANx->MCR & ~CAN_MCR_MDIS_MASK) | CAN_MCR_MDIS(0U);
|
||||
/* Set timeout time for leaving disabled mode. */
|
||||
timeout = TimerGet() + CAN_INIT_TIMEOUT_MS;
|
||||
/* Wait for disabled mode acknowledgement. */
|
||||
while (((CANx->MCR & CAN_MCR_LPMACK_MASK)) != 0U)
|
||||
{
|
||||
/* Break loop upon timeout. This would indicate a hardware failure. */
|
||||
if (TimerGet() > timeout)
|
||||
{
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
} /*** end of CanDisabledModeExit ***/
|
||||
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief Initializes the CAN communication interface.
|
||||
** \return none.
|
||||
**
|
||||
****************************************************************************************/
|
||||
static void BootComCanInit(void)
|
||||
{
|
||||
unsigned short prescaler = 0;
|
||||
tCanBusTiming timingCfg = { 0 };
|
||||
unsigned char rjw;
|
||||
unsigned short idx;
|
||||
unsigned long timeout;
|
||||
unsigned long rxMsgId = BOOT_COM_CAN_RX_MSG_ID;
|
||||
|
||||
/* Enable the CAN peripheral clock. */
|
||||
PCC->PCCn[PCC_FlexCANx_INDEX] |= PCC_PCCn_CGC_MASK;
|
||||
|
||||
/* The source clock needs to be configured first. For this the CAN controller must be
|
||||
* in disabled mode, but that can only be entered after first entering freeze mode,
|
||||
* which in turn can only be in enabled mode. So first enable the module, then goto
|
||||
* freeze mode and finally enter disabled mode.
|
||||
*/
|
||||
CanDisabledModeExit();
|
||||
CanFreezeModeEnter();
|
||||
CanDisabledModeEnter();
|
||||
/* Configure SOSCDIV2 as the source clock. This assumes that an external oscillator
|
||||
* is available, which is typically the case to meet the clock tolerance requirements
|
||||
* of the CAN 2.0B secification.
|
||||
*/
|
||||
CANx->CTRL1 &= ~CAN_CTRL1_CLKSRC_MASK;
|
||||
/* Leave disabled mode. */
|
||||
CanDisabledModeExit();
|
||||
/* Make sure freeze mode is active to be able to initialize the CAN controller. */
|
||||
CanFreezeModeEnter();
|
||||
|
||||
/* Obtain bittiming configuration information. */
|
||||
(void)CanGetSpeedConfig(BOOT_COM_CAN_BAUDRATE/1000, &prescaler, &timingCfg);
|
||||
|
||||
/* Reset the current bittiming configuration. */
|
||||
CANx->CTRL1 &= ~(CAN_CTRL1_PRESDIV_MASK | CAN_CTRL1_PROPSEG_MASK |
|
||||
CAN_CTRL1_PSEG1_MASK | CAN_CTRL1_PSEG2_MASK | CAN_CTRL1_RJW_MASK |
|
||||
CAN_CTRL1_SMP_MASK);
|
||||
/* Configure the baudrate prescaler. */
|
||||
CANx->CTRL1 |= CAN_CTRL1_PRESDIV(prescaler - 1U);
|
||||
/* Configure the propagation segment. */
|
||||
CANx->CTRL1 |= CAN_CTRL1_PROPSEG(timingCfg.propSeg - 1U);
|
||||
/* Configure the phase segments. */
|
||||
CANx->CTRL1 |= CAN_CTRL1_PSEG1(timingCfg.phaseSeg1 - 1U);
|
||||
CANx->CTRL1 |= CAN_CTRL1_PSEG2(timingCfg.phaseSeg2 - 1U);
|
||||
/* The resynchronization jump width (RJW) can be 1 - 4 TQ, yet should never be larger
|
||||
* than pseg1. Configure the longest possible value for RJW.
|
||||
*/
|
||||
rjw = (timingCfg.phaseSeg1 < 4) ? timingCfg.phaseSeg1 : 4;
|
||||
CANx->CTRL1 |= CAN_CTRL1_RJW(rjw - 1U);
|
||||
/* All the entries in canTiming[] have a PSEG1 >= 2, so three samples can be used to
|
||||
* determine the value of the received bit, instead of the default one.
|
||||
*/
|
||||
CANx->CTRL1 |= CAN_CTRL1_SMP(1U);
|
||||
|
||||
/* Clear the message box RAM. Each message box covers 4 words (1 word = 32-bits. */
|
||||
for (idx = 0; idx < (CANx_MAX_MB_NUM * 4U); idx++)
|
||||
{
|
||||
CANx->RAMn[idx] = 0U;
|
||||
}
|
||||
/* Clear the reception mask register for each message box. */
|
||||
for (idx = 0; idx < CANx_MAX_MB_NUM; idx++)
|
||||
{
|
||||
CANx->RXIMR[idx] = 0U;
|
||||
}
|
||||
/* Configure the maximum number of message boxes. */
|
||||
CANx->MCR = (CANx->MCR & ~CAN_MCR_MAXMB_MASK) | CAN_MCR_MAXMB(CANx_MAX_MB_NUM - 1U);
|
||||
/* Disable the self reception feature. */
|
||||
CANx->MCR = (CANx->MCR & ~CAN_MCR_SRXDIS_MASK) | CAN_MCR_SRXDIS(1U);
|
||||
|
||||
/* Enable individual reception masking. This disables the legacy support for the
|
||||
* global reception mask and the mailbox 14/15 individual reception mask.
|
||||
*/
|
||||
CANx->MCR = (CANx->MCR & ~CAN_MCR_IRMQ_MASK) | CAN_MCR_IRMQ(1U);
|
||||
/* Disable the reception FIFO. This driver only needs to receive one CAN message
|
||||
* identifier. It is sufficient to use just one dedicated mailbox for this.
|
||||
*/
|
||||
CANx->MCR &= ~CAN_MCR_RFEN_MASK;
|
||||
/* Configure the mask of the invididual message reception mailbox to check all ID bits
|
||||
* and also the IDE bit.
|
||||
*/
|
||||
CANx->RXIMR[CAN_RX_MSGBOX_NUM] = 0x40000000U | 0x1FFFFFFFU;
|
||||
/* Configure the reception mailbox to receive just the CAN message configured with
|
||||
* BOOT_COM_CAN_RX_MSG_ID.
|
||||
* EDL, BRS, ESI=0: CANFD not used.
|
||||
* CODE=0b0100: mailbox set to active and empty.
|
||||
* IDE=0: 11-bit CAN identifier.
|
||||
* SRR, RTR, TIME STAMP=0: not applicable.
|
||||
*/
|
||||
CANx->RAMn[(CAN_RX_MSGBOX_NUM * 4U) + 0U] = 0x04000000;
|
||||
/* Store the message identifier to receive in the mailbox RAM. */
|
||||
if ((rxMsgId & 0x80000000U) != 0U)
|
||||
{
|
||||
/* It is a 29-bit extended CAN identifier. */
|
||||
rxMsgId &= ~0x80000000U;
|
||||
/* Set the IDE bit to configure the message for a 29-bit identifier. */
|
||||
CANx->RAMn[(CAN_RX_MSGBOX_NUM * 4U) + 0U] |= CAN_WMBn_CS_IDE_MASK;
|
||||
/* Store the 29-bit CAN identifier. */
|
||||
CANx->RAMn[(CAN_RX_MSGBOX_NUM * 4U) + 1U] = CAN_WMBn_ID_ID(rxMsgId);
|
||||
}
|
||||
else
|
||||
{
|
||||
/* Store the 11-bit CAN identifier. */
|
||||
CANx->RAMn[(CAN_RX_MSGBOX_NUM * 4U) + 1U] = CAN_WMBn_ID_ID(rxMsgId << 18U);
|
||||
}
|
||||
|
||||
/* Disable all message box interrupts. */
|
||||
CANx->IMASK1 = 0U;
|
||||
/* Clear all mesasge box interrupt flags. */
|
||||
CANx->IFLAG1 = CAN_IMASK1_BUF31TO0M_MASK;
|
||||
/* Clear all error interrupt flags */
|
||||
CANx->ESR1 = CAN_ESR1_ERRINT_MASK | CAN_ESR1_BOFFINT_MASK | CAN_ESR1_RWRNINT_MASK |
|
||||
CAN_ESR1_TWRNINT_MASK | CAN_ESR1_BOFFDONEINT_MASK |
|
||||
CAN_ESR1_ERRINT_FAST_MASK | CAN_ESR1_ERROVR_MASK;
|
||||
|
||||
/* Switch to normal user mode. */
|
||||
CANx->MCR &= ~CAN_MCR_SUPV_MASK;
|
||||
CANx->CTRL1 &= ~(CAN_CTRL1_LOM_MASK | CAN_CTRL1_LPB_MASK);
|
||||
/* Exit freeze mode. */
|
||||
CanFreezeModeExit();
|
||||
/* Set timeout time for entering normal user mode. */
|
||||
timeout = TimerGet() + CAN_INIT_TIMEOUT_MS;
|
||||
/* Wait for normal user mode acknowledgement. */
|
||||
while (((CANx->MCR & CAN_MCR_NOTRDY_MASK)) != 0U)
|
||||
{
|
||||
/* Break loop upon timeout. This would indicate a hardware failure. */
|
||||
if (TimerGet() > timeout)
|
||||
{
|
||||
break;
|
||||
}
|
||||
}
|
||||
} /*** end of BootComCanInit ***/
|
||||
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief Receives the CONNECT request from the host, which indicates that the
|
||||
** bootloader should be activated and, if so, activates it.
|
||||
** \return none.
|
||||
**
|
||||
****************************************************************************************/
|
||||
static void BootComCanCheckActivationRequest(void)
|
||||
{
|
||||
unsigned char * pMsgBoxData;
|
||||
unsigned char byteIdx;
|
||||
unsigned char rxMsgData[8];
|
||||
unsigned char rxMsgLen;
|
||||
|
||||
/* Check if a message was received in the individual mailbox configured to receive
|
||||
* the BOOT_COM_CAN_RX_MSG_ID message.
|
||||
*/
|
||||
if ((CANx->IFLAG1 & (1U << CAN_RX_MSGBOX_NUM)) != 0U)
|
||||
{
|
||||
/* Note that there is no need to verify the identifier of the CAN message because the
|
||||
* mailbox is configured to only receive the BOOT_COM_CAN_TX_MSG_ID message. Start
|
||||
* by reading out the DLC of the newly received CAN message.
|
||||
*/
|
||||
rxMsgLen = (CANx->RAMn[(CAN_RX_MSGBOX_NUM * 4U) + 0U] & CAN_WMBn_CS_DLC_MASK) >> CAN_WMBn_CS_DLC_SHIFT;
|
||||
/* Read the data bytes of the CAN message from the mailbox RAM. */
|
||||
pMsgBoxData = (unsigned char *)(&CANx->RAMn[(CAN_RX_MSGBOX_NUM * 4U) + 2U]);
|
||||
for (byteIdx = 0; byteIdx < rxMsgLen; byteIdx++)
|
||||
{
|
||||
rxMsgData[byteIdx] = pMsgBoxData[((byteIdx) & ~3U) + (3U - ((byteIdx) & 3U))];
|
||||
}
|
||||
/* Clear the mailbox interrupt flag by writing a 1 to the corresponding box. */
|
||||
CANx->IFLAG1 = (1U << CAN_RX_MSGBOX_NUM);
|
||||
/* Read the free running timer to unlock the mailbox. */
|
||||
dummyTimerVal = CANx->TIMER;
|
||||
|
||||
/* check if this was an XCP CONNECT command */
|
||||
if ((rxMsgData[0] == 0xff) && (rxMsgLen == 2))
|
||||
{
|
||||
/* connection request received so start the bootloader */
|
||||
BootActivate();
|
||||
}
|
||||
}
|
||||
} /*** end of BootComCanCheckActivationRequest ***/
|
||||
#endif /* BOOT_COM_CAN_ENABLE > 0 */
|
||||
|
||||
|
||||
/*********************************** end of boot.c *************************************/
|
|
@ -0,0 +1,40 @@
|
|||
/************************************************************************************//**
|
||||
* \file Demo/ARMCM4_S32K14_S32K144EVB_GCC/Prog/boot.h
|
||||
* \brief Demo program bootloader interface header file.
|
||||
* \ingroup Prog_ARMCM4_S32K14_S32K144EVB_GCC
|
||||
* \internal
|
||||
*----------------------------------------------------------------------------------------
|
||||
* C O P Y R I G H T
|
||||
*----------------------------------------------------------------------------------------
|
||||
* Copyright (c) 2020 by Feaser http://www.feaser.com All rights reserved
|
||||
*
|
||||
*----------------------------------------------------------------------------------------
|
||||
* L I C E N S E
|
||||
*----------------------------------------------------------------------------------------
|
||||
* This file is part of OpenBLT. OpenBLT is free software: you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as published by the Free
|
||||
* Software Foundation, either version 3 of the License, or (at your option) any later
|
||||
* version.
|
||||
*
|
||||
* OpenBLT is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
|
||||
* without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
|
||||
* PURPOSE. See the GNU General Public License for more details.
|
||||
*
|
||||
* You have received a copy of the GNU General Public License along with OpenBLT. It
|
||||
* should be located in ".\Doc\license.html". If not, contact Feaser to obtain a copy.
|
||||
*
|
||||
* \endinternal
|
||||
****************************************************************************************/
|
||||
#ifndef BOOT_H
|
||||
#define BOOT_H
|
||||
|
||||
/****************************************************************************************
|
||||
* Function prototypes
|
||||
****************************************************************************************/
|
||||
void BootComInit(void);
|
||||
void BootComCheckActivationRequest(void);
|
||||
void BootActivate(void);
|
||||
|
||||
|
||||
#endif /* BOOT_H */
|
||||
/*********************************** end of boot.h *************************************/
|
|
@ -0,0 +1,42 @@
|
|||
/************************************************************************************//**
|
||||
* \file Demo/ARMCM4_S32K14_S32K144EVB_GCC/Prog/header.h
|
||||
* \brief Generic header file.
|
||||
* \ingroup Prog_ARMCM4_S32K14_S32K144EVB_GCC
|
||||
* \internal
|
||||
*----------------------------------------------------------------------------------------
|
||||
* C O P Y R I G H T
|
||||
*----------------------------------------------------------------------------------------
|
||||
* Copyright (c) 2020 by Feaser http://www.feaser.com All rights reserved
|
||||
*
|
||||
*----------------------------------------------------------------------------------------
|
||||
* L I C E N S E
|
||||
*----------------------------------------------------------------------------------------
|
||||
* This file is part of OpenBLT. OpenBLT is free software: you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as published by the Free
|
||||
* Software Foundation, either version 3 of the License, or (at your option) any later
|
||||
* version.
|
||||
*
|
||||
* OpenBLT is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
|
||||
* without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
|
||||
* PURPOSE. See the GNU General Public License for more details.
|
||||
*
|
||||
* You have received a copy of the GNU General Public License along with OpenBLT. It
|
||||
* should be located in ".\Doc\license.html". If not, contact Feaser to obtain a copy.
|
||||
*
|
||||
* \endinternal
|
||||
****************************************************************************************/
|
||||
#ifndef HEADER_H
|
||||
#define HEADER_H
|
||||
|
||||
/****************************************************************************************
|
||||
* Include files
|
||||
****************************************************************************************/
|
||||
#include "../Boot/blt_conf.h" /* bootloader configuration */
|
||||
#include "boot.h" /* bootloader interface driver */
|
||||
#include "led.h" /* LED driver */
|
||||
#include "timer.h" /* Timer driver */
|
||||
#include "device_registers.h" /* Device registers */
|
||||
#include "system_S32K144.h" /* Device sconfiguration */
|
||||
|
||||
#endif /* HEADER_H */
|
||||
/*********************************** end of header.h ***********************************/
|
|
@ -0,0 +1,96 @@
|
|||
/************************************************************************************//**
|
||||
* \file Demo/ARMCM4_S32K14_S32K144EVB_GCC/Prog/led.c
|
||||
* \brief LED driver source file.
|
||||
* \ingroup Prog_ARMCM4_S32K14_S32K144EVB_GCC
|
||||
* \internal
|
||||
*----------------------------------------------------------------------------------------
|
||||
* C O P Y R I G H T
|
||||
*----------------------------------------------------------------------------------------
|
||||
* Copyright (c) 2020 by Feaser http://www.feaser.com All rights reserved
|
||||
*
|
||||
*----------------------------------------------------------------------------------------
|
||||
* L I C E N S E
|
||||
*----------------------------------------------------------------------------------------
|
||||
* This file is part of OpenBLT. OpenBLT is free software: you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as published by the Free
|
||||
* Software Foundation, either version 3 of the License, or (at your option) any later
|
||||
* version.
|
||||
*
|
||||
* OpenBLT is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
|
||||
* without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
|
||||
* PURPOSE. See the GNU General Public License for more details.
|
||||
*
|
||||
* You have received a copy of the GNU General Public License along with OpenBLT. It
|
||||
* should be located in ".\Doc\license.html". If not, contact Feaser to obtain a copy.
|
||||
*
|
||||
* \endinternal
|
||||
****************************************************************************************/
|
||||
|
||||
/****************************************************************************************
|
||||
* Include files
|
||||
****************************************************************************************/
|
||||
#include "header.h" /* generic header */
|
||||
|
||||
|
||||
/****************************************************************************************
|
||||
* Macro definitions
|
||||
****************************************************************************************/
|
||||
/** \brief Toggle interval time in milliseconds. */
|
||||
#define LED_TOGGLE_MS (500U)
|
||||
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief Initializes the LED.
|
||||
** \return none.
|
||||
**
|
||||
****************************************************************************************/
|
||||
void LedInit(void)
|
||||
{
|
||||
/* LED GPIO pin configuration. PD0 = GPIO, MUX = ALT1. */
|
||||
PORTD->PCR[0] |= PORT_PCR_MUX(1);
|
||||
/* configure Port D pin 0 GPIO as digital output */
|
||||
PTD->PDDR |= GPIO_PDDR_PDD(0x00000001);
|
||||
/* turn the LED off on Port D pin 0 */
|
||||
PTD->PSOR |= GPIO_PSOR_PTSO(0x00000001);
|
||||
} /*** end of LedInit ***/
|
||||
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief Toggles the LED at a fixed time interval.
|
||||
** \return none.
|
||||
**
|
||||
****************************************************************************************/
|
||||
void LedToggle(void)
|
||||
{
|
||||
static unsigned char led_toggle_state = 0;
|
||||
static unsigned long timer_counter_last = 0;
|
||||
unsigned long timer_counter_now;
|
||||
|
||||
/* Check if toggle interval time passed. */
|
||||
timer_counter_now = TimerGet();
|
||||
if ( (timer_counter_now - timer_counter_last) < LED_TOGGLE_MS)
|
||||
{
|
||||
/* Not yet time to toggle. */
|
||||
return;
|
||||
}
|
||||
|
||||
/* Determine toggle action. */
|
||||
if (led_toggle_state == 0)
|
||||
{
|
||||
led_toggle_state = 1;
|
||||
/* Turn the LED on. */
|
||||
PTD->PCOR |= GPIO_PCOR_PTCO(0x00000001);
|
||||
}
|
||||
else
|
||||
{
|
||||
led_toggle_state = 0;
|
||||
/* Turn the LED off. */
|
||||
PTD->PSOR |= GPIO_PSOR_PTSO(0x00000001);
|
||||
}
|
||||
|
||||
/* Store toggle time to determine next toggle interval. */
|
||||
timer_counter_last = timer_counter_now;
|
||||
} /*** end of LedToggle ***/
|
||||
|
||||
|
||||
/*********************************** end of led.c **************************************/
|
|
@ -0,0 +1,39 @@
|
|||
/************************************************************************************//**
|
||||
* \file Demo/ARMCM4_S32K14_S32K144EVB_GCC/Prog/led.h
|
||||
* \brief LED driver header file.
|
||||
* \ingroup Prog_ARMCM4_S32K14_S32K144EVB_GCC
|
||||
* \internal
|
||||
*----------------------------------------------------------------------------------------
|
||||
* C O P Y R I G H T
|
||||
*----------------------------------------------------------------------------------------
|
||||
* Copyright (c) 2020 by Feaser http://www.feaser.com All rights reserved
|
||||
*
|
||||
*----------------------------------------------------------------------------------------
|
||||
* L I C E N S E
|
||||
*----------------------------------------------------------------------------------------
|
||||
* This file is part of OpenBLT. OpenBLT is free software: you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as published by the Free
|
||||
* Software Foundation, either version 3 of the License, or (at your option) any later
|
||||
* version.
|
||||
*
|
||||
* OpenBLT is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
|
||||
* without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
|
||||
* PURPOSE. See the GNU General Public License for more details.
|
||||
*
|
||||
* You have received a copy of the GNU General Public License along with OpenBLT. It
|
||||
* should be located in ".\Doc\license.html". If not, contact Feaser to obtain a copy.
|
||||
*
|
||||
* \endinternal
|
||||
****************************************************************************************/
|
||||
#ifndef LED_H
|
||||
#define LED_H
|
||||
|
||||
/****************************************************************************************
|
||||
* Function prototypes
|
||||
****************************************************************************************/
|
||||
void LedInit(void);
|
||||
void LedToggle(void);
|
||||
|
||||
|
||||
#endif /* LED_H */
|
||||
/*********************************** end of led.h **************************************/
|
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
|
@ -0,0 +1,84 @@
|
|||
/*
|
||||
* Copyright (c) 2015, Freescale Semiconductor, Inc.
|
||||
* Copyright 2016-2017 NXP
|
||||
* All rights reserved.
|
||||
*
|
||||
* THIS SOFTWARE IS PROVIDED BY NXP "AS IS" AND ANY EXPRESSED OR
|
||||
* IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
|
||||
* OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
|
||||
* IN NO EVENT SHALL NXP OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
|
||||
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
|
||||
* (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
|
||||
* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
||||
* HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
|
||||
* STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING
|
||||
* IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
|
||||
* THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
#ifndef DEVASSERT_H
|
||||
#define DEVASSERT_H
|
||||
|
||||
#include <stdbool.h>
|
||||
|
||||
/**
|
||||
* @page misra_violations MISRA-C:2012 violations
|
||||
*
|
||||
* @section [global]
|
||||
* Violates MISRA 2012 Advisory Rule 2.5, global macro not referenced.
|
||||
* The macro is defined to be used by drivers to validate input parameters and can be disabled.
|
||||
*
|
||||
* @section [global]
|
||||
* Violates MISRA 2012 Advisory Directive 4.9, Function-like macro defined.
|
||||
* The macros are used to validate input parameters to driver functions.
|
||||
*
|
||||
*/
|
||||
|
||||
/**
|
||||
\page Error_detection_and_reporting Error detection and reporting
|
||||
|
||||
S32 SDK drivers can use a mechanism to validate data coming from upper software layers (application code) by performing
|
||||
a number of checks on input parameters' range or other invariants that can be statically checked (not dependent on
|
||||
runtime conditions). A failed validation is indicative of a software bug in application code, therefore it is important
|
||||
to use this mechanism during development.
|
||||
|
||||
The validation is performed by using DEV_ASSERT macro.
|
||||
A default implementation of this macro is provided in this file. However, application developers can provide their own
|
||||
implementation in a custom file. This requires defining the CUSTOM_DEVASSERT symbol with the specific file name in the
|
||||
project configuration (for example: -DCUSTOM_DEVASSERT="custom_devassert.h")
|
||||
|
||||
The default implementation accommodates two behaviors, based on DEV_ERROR_DETECT symbol:
|
||||
- When DEV_ERROR_DETECT symbol is defined in the project configuration (for example: -DDEV_ERROR_DETECT), the validation
|
||||
performed by the DEV_ASSERT macro is enabled, and a failed validation triggers a software breakpoint and further execution is
|
||||
prevented (application spins in an infinite loop)
|
||||
This configuration is recommended for development environments, as it prevents further execution and allows investigating
|
||||
potential problems from the point of error detection.
|
||||
- When DEV_ERROR_DETECT symbol is not defined, the DEV_ASSERT macro is implemented as no-op, therefore disabling all validations.
|
||||
This configuration can be used to eliminate the overhead of development-time checks.
|
||||
|
||||
It is the application developer's responsibility to decide the error detection strategy for production code: one can opt to
|
||||
disable development-time checking altogether (by not defining DEV_ERROR_DETECT symbol), or one can opt to keep the checks
|
||||
in place and implement a recovery mechanism in case of a failed validation, by defining CUSTOM_DEVASSERT to point
|
||||
to the file containing the custom implementation.
|
||||
*/
|
||||
|
||||
#if defined (CUSTOM_DEVASSERT)
|
||||
/* If the CUSTOM_DEVASSERT symbol is defined, then add the custom implementation */
|
||||
#include CUSTOM_DEVASSERT
|
||||
#elif defined (DEV_ERROR_DETECT)
|
||||
/* Implement default assert macro */
|
||||
static inline void DevAssert(volatile bool x)
|
||||
{
|
||||
if(x) { } else { BKPT_ASM; for(;;) {} }
|
||||
}
|
||||
#define DEV_ASSERT(x) DevAssert(x)
|
||||
#else
|
||||
/* Assert macro does nothing */
|
||||
#define DEV_ASSERT(x) ((void)0)
|
||||
#endif
|
||||
|
||||
#endif /* DEVASSERT_H */
|
||||
|
||||
/*******************************************************************************
|
||||
* EOF
|
||||
******************************************************************************/
|
|
@ -0,0 +1,70 @@
|
|||
/*
|
||||
** ###################################################################
|
||||
** Abstract:
|
||||
** Common include file for CMSIS register access layer headers.
|
||||
**
|
||||
** Copyright (c) 2015 Freescale Semiconductor, Inc.
|
||||
** Copyright 2016-2017 NXP
|
||||
** All rights reserved.
|
||||
**
|
||||
** THIS SOFTWARE IS PROVIDED BY NXP "AS IS" AND ANY EXPRESSED OR
|
||||
** IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
|
||||
** OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
|
||||
** IN NO EVENT SHALL NXP OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
|
||||
** INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
|
||||
** (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
|
||||
** SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
||||
** HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
|
||||
** STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING
|
||||
** IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
|
||||
** THE POSSIBILITY OF SUCH DAMAGE.
|
||||
**
|
||||
** http: www.nxp.com
|
||||
** mail: support@nxp.com
|
||||
** ###################################################################
|
||||
*/
|
||||
|
||||
#ifndef DEVICE_REGISTERS_H
|
||||
#define DEVICE_REGISTERS_H
|
||||
|
||||
/**
|
||||
* @page misra_violations MISRA-C:2012 violations
|
||||
*
|
||||
* @section [global]
|
||||
* Violates MISRA 2012 Advisory Rule 2.5, global macro not referenced.
|
||||
* The macro defines the device currently in use and may be used by components for specific checks.
|
||||
*
|
||||
*/
|
||||
|
||||
|
||||
/*
|
||||
* Include the cpu specific register header files.
|
||||
*
|
||||
* The CPU macro should be declared in the project or makefile.
|
||||
*/
|
||||
|
||||
#if (defined(CPU_S32K144HFT0VLLT) || defined(CPU_S32K144LFT0MLLT))
|
||||
|
||||
#define S32K14x_SERIES
|
||||
|
||||
/* Specific core definitions */
|
||||
#include "s32_core_cm4.h"
|
||||
|
||||
#define S32K144_SERIES
|
||||
|
||||
/* Register definitions */
|
||||
#include "S32K144.h"
|
||||
/* CPU specific feature definitions */
|
||||
#include "S32K144_features.h"
|
||||
|
||||
#else
|
||||
#error "No valid CPU defined!"
|
||||
#endif
|
||||
|
||||
#include "devassert.h"
|
||||
|
||||
#endif /* DEVICE_REGISTERS_H */
|
||||
|
||||
/*******************************************************************************
|
||||
* EOF
|
||||
******************************************************************************/
|
|
@ -0,0 +1,209 @@
|
|||
/*
|
||||
* Copyright (c) 2015-2016 Freescale Semiconductor, Inc.
|
||||
* Copyright 2016-2017 NXP
|
||||
* All rights reserved.
|
||||
*
|
||||
* THIS SOFTWARE IS PROVIDED BY NXP "AS IS" AND ANY EXPRESSED OR
|
||||
* IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
|
||||
* OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
|
||||
* IN NO EVENT SHALL NXP OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
|
||||
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
|
||||
* (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
|
||||
* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
||||
* HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
|
||||
* STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING
|
||||
* IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
|
||||
* THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*
|
||||
*/
|
||||
/*!
|
||||
* @file s32_core_cm4.h
|
||||
*
|
||||
* @page misra_violations MISRA-C:2012 violations
|
||||
*
|
||||
* @section [global]
|
||||
* Violates MISRA 2012 Advisory Directive 4.9, Function-like macro
|
||||
* Function-like macros are used instead of inline functions in order to ensure
|
||||
* that the performance will not be decreased if the functions will not be
|
||||
* inlined by the compiler.
|
||||
*
|
||||
* @section [global]
|
||||
* Violates MISRA 2012 Advisory Rule 2.5, Global macro not referenced.
|
||||
* The macros defined are used only on some of the drivers, so this might be reported
|
||||
* when the analysis is made only on one driver.
|
||||
*/
|
||||
|
||||
/*
|
||||
* Tool Chains:
|
||||
* GNUC flag is defined also by ARM compiler - it shows the current major version of the compatible GCC version
|
||||
* __GNUC__ : GNU Compiler Collection
|
||||
* __ghs__ : Green Hills ARM Compiler
|
||||
* __ICCARM__ : IAR ARM Compiler
|
||||
* __DCC__ : Wind River Diab Compiler
|
||||
* __ARMCC_VERSION: ARM Compiler
|
||||
*/
|
||||
|
||||
#if !defined (CORE_CM4_H)
|
||||
#define CORE_CM4_H
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
/** \brief BKPT_ASM
|
||||
*
|
||||
* Macro to be used to trigger an debug interrupt
|
||||
*/
|
||||
#define BKPT_ASM __asm("BKPT #0\n\t")
|
||||
|
||||
|
||||
/** \brief Enable FPU
|
||||
*
|
||||
* ENABLE_FPU indicates whether SystemInit will enable the Floating point unit (FPU)
|
||||
*/
|
||||
#if defined (__GNUC__) || defined (__ARMCC_VERSION)
|
||||
#if defined (__VFP_FP__) && !defined (__SOFTFP__)
|
||||
#define ENABLE_FPU
|
||||
#endif
|
||||
|
||||
#elif defined (__ICCARM__)
|
||||
#if defined __ARMVFP__
|
||||
#define ENABLE_FPU
|
||||
#endif
|
||||
|
||||
#elif defined (__ghs__) || defined (__DCC__)
|
||||
#if defined (__VFP__)
|
||||
#define ENABLE_FPU
|
||||
#endif
|
||||
#endif /* if defined (__GNUC__) */
|
||||
|
||||
/** \brief Enable interrupts
|
||||
*/
|
||||
#if defined (__GNUC__)
|
||||
#define ENABLE_INTERRUPTS() __asm volatile ("cpsie i" : : : "memory");
|
||||
#else
|
||||
#define ENABLE_INTERRUPTS() __asm("cpsie i")
|
||||
#endif
|
||||
|
||||
|
||||
/** \brief Disable interrupts
|
||||
*/
|
||||
#if defined (__GNUC__)
|
||||
#define DISABLE_INTERRUPTS() __asm volatile ("cpsid i" : : : "memory");
|
||||
#else
|
||||
#define DISABLE_INTERRUPTS() __asm("cpsid i")
|
||||
#endif
|
||||
|
||||
|
||||
/** \brief Enter low-power standby state
|
||||
* WFI (Wait For Interrupt) makes the processor suspend execution (Clock is stopped) until an IRQ interrupts.
|
||||
*/
|
||||
#if defined (__GNUC__)
|
||||
#define STANDBY() __asm volatile ("wfi")
|
||||
#else
|
||||
#define STANDBY() __asm("wfi")
|
||||
#endif
|
||||
|
||||
/** \brief No-op
|
||||
*/
|
||||
#define NOP() __asm volatile ("nop")
|
||||
|
||||
/** \brief Reverse byte order in a word.
|
||||
*/
|
||||
#if defined (__GNUC__) || defined (__ICCARM__) || defined (__ghs__) || defined (__ARMCC_VERSION)
|
||||
#define REV_BYTES_32(a, b) __asm volatile ("rev %0, %1" : "=r" (b) : "r" (a))
|
||||
#else
|
||||
#define REV_BYTES_32(a, b) (b = ((a & 0xFF000000U) >> 24U) | ((a & 0xFF0000U) >> 8U) \
|
||||
| ((a & 0xFF00U) << 8U) | ((a & 0xFFU) << 24U))
|
||||
#endif
|
||||
|
||||
/** \brief Reverse byte order in each halfword independently.
|
||||
*/
|
||||
#if defined (__GNUC__) || defined (__ICCARM__) || defined (__ghs__) || defined (__ARMCC_VERSION)
|
||||
#define REV_BYTES_16(a, b) __asm volatile ("rev16 %0, %1" : "=r" (b) : "r" (a))
|
||||
#else
|
||||
#define REV_BYTES_16(a, b) (b = ((a & 0xFF000000U) >> 8U) | ((a & 0xFF0000U) << 8U) \
|
||||
| ((a & 0xFF00U) >> 8U) | ((a & 0xFFU) << 8U))
|
||||
#endif
|
||||
|
||||
/** \brief Places a function in RAM.
|
||||
*/
|
||||
#if defined ( __GNUC__ ) || defined (__ARMCC_VERSION)
|
||||
#define START_FUNCTION_DECLARATION_RAMSECTION
|
||||
#define END_FUNCTION_DECLARATION_RAMSECTION __attribute__((section (".code_ram")));
|
||||
#elif defined ( __ghs__ )
|
||||
#define START_FUNCTION_DECLARATION_RAMSECTION _Pragma("ghs callmode=far")
|
||||
#define END_FUNCTION_DECLARATION_RAMSECTION __attribute__((section (".code_ram")));\
|
||||
_Pragma("ghs callmode=default")
|
||||
#elif defined ( __ICCARM__ )
|
||||
#define START_FUNCTION_DECLARATION_RAMSECTION __ramfunc
|
||||
#define END_FUNCTION_DECLARATION_RAMSECTION ;
|
||||
#elif defined ( __DCC__ )
|
||||
#define START_FUNCTION_DECLARATION_RAMSECTION _Pragma("section CODE \".code_ram\"") \
|
||||
_Pragma("use_section CODE")
|
||||
#define END_FUNCTION_DECLARATION_RAMSECTION ; \
|
||||
_Pragma("section CODE \".text\"")
|
||||
#else
|
||||
/* Keep compatibility with software analysis tools */
|
||||
#define START_FUNCTION_DECLARATION_RAMSECTION
|
||||
#define END_FUNCTION_DECLARATION_RAMSECTION ;
|
||||
#endif
|
||||
|
||||
/* For GCC, IAR, GHS, Diab and ARMC there is no need to specify the section when
|
||||
defining a function, it is enough to specify it at the declaration. This
|
||||
also enables compatibility with software analysis tools. */
|
||||
#define START_FUNCTION_DEFINITION_RAMSECTION
|
||||
#define END_FUNCTION_DEFINITION_RAMSECTION
|
||||
|
||||
#if defined (__ICCARM__)
|
||||
#define DISABLE_CHECK_RAMSECTION_FUNCTION_CALL _Pragma("diag_suppress=Ta022")
|
||||
#define ENABLE_CHECK_RAMSECTION_FUNCTION_CALL _Pragma("diag_default=Ta022")
|
||||
#else
|
||||
#define DISABLE_CHECK_RAMSECTION_FUNCTION_CALL
|
||||
#define ENABLE_CHECK_RAMSECTION_FUNCTION_CALL
|
||||
#endif
|
||||
|
||||
/** \brief Get Core ID
|
||||
*
|
||||
* GET_CORE_ID returns the processor identification number for cm4
|
||||
*/
|
||||
#define GET_CORE_ID() 0U
|
||||
|
||||
/** \brief Data alignment.
|
||||
*/
|
||||
#if defined ( __GNUC__ ) || defined ( __ghs__ ) || defined ( __DCC__ ) || defined (__ARMCC_VERSION)
|
||||
#define ALIGNED(x) __attribute__((aligned(x)))
|
||||
#elif defined ( __ICCARM__ )
|
||||
#define stringify(s) tostring(s)
|
||||
#define tostring(s) #s
|
||||
#define ALIGNED(x) _Pragma(stringify(data_alignment=x))
|
||||
#else
|
||||
/* Keep compatibility with software analysis tools */
|
||||
#define ALIGNED(x)
|
||||
#endif
|
||||
|
||||
/** \brief Section placement.
|
||||
*/
|
||||
#if defined ( __GNUC__ ) || defined ( __ghs__ ) || defined ( __DCC__ ) || defined (__ARMCC_VERSION)
|
||||
#define PLACE_IN_SECTION(x) __attribute__((section(x)))
|
||||
#elif defined ( __ICCARM__ )
|
||||
#define PLACE_IN_SECTION(x) _Pragma(stringify(section=x))
|
||||
#else
|
||||
/* Keep compatibility with software analysis tools */
|
||||
#define PLACE_IN_SECTION(x)
|
||||
#endif
|
||||
|
||||
/** \brief Endianness.
|
||||
*/
|
||||
#define CORE_LITTLE_ENDIAN
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* CORE_CM4_H */
|
||||
|
||||
/*******************************************************************************
|
||||
* EOF
|
||||
******************************************************************************/
|
|
@ -0,0 +1,197 @@
|
|||
/*
|
||||
* Copyright (c) 2015 Freescale Semiconductor, Inc.
|
||||
* Copyright 2016-2017 NXP
|
||||
* All rights reserved.
|
||||
*
|
||||
* THIS SOFTWARE IS PROVIDED BY NXP "AS IS" AND ANY EXPRESSED OR
|
||||
* IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
|
||||
* OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
|
||||
* IN NO EVENT SHALL NXP OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
|
||||
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
|
||||
* (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
|
||||
* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
||||
* HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
|
||||
* STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING
|
||||
* IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
|
||||
* THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
/**
|
||||
* @page misra_violations MISRA-C:2012 violations
|
||||
*
|
||||
* @section [global]
|
||||
* Violates MISRA 2012 Advisory Rule 8.9, An object should be defined at block
|
||||
* scope if its identifier only appears in a single function.
|
||||
* An object with static storage duration declared at block scope cannot be
|
||||
* accessed directly from outside the block.
|
||||
*
|
||||
* @section [global]
|
||||
* Violates MISRA 2012 Advisory Rule 11.4, A conversion should not be performed
|
||||
* between a pointer to object and an integer type.
|
||||
* The cast is required to initialize a pointer with an unsigned int define,
|
||||
* representing an address.
|
||||
*
|
||||
* @section [global]
|
||||
* Violates MISRA 2012 Required Rule 11.6, A cast shall not be performed
|
||||
* between pointer to void and an arithmetic type.
|
||||
* The cast is required to initialize a pointer with an unsigned int define,
|
||||
* representing an address.
|
||||
*
|
||||
* @section [global]
|
||||
* Violates MISRA 2012 Advisory Rule 8.7, External could be made static.
|
||||
* Function is defined for usage by application code.
|
||||
*
|
||||
*/
|
||||
|
||||
#include "device_registers.h"
|
||||
#include "system_S32K144.h"
|
||||
#include "stdbool.h"
|
||||
|
||||
/* ----------------------------------------------------------------------------
|
||||
-- Core clock
|
||||
---------------------------------------------------------------------------- */
|
||||
|
||||
uint32_t SystemCoreClock = DEFAULT_SYSTEM_CLOCK;
|
||||
|
||||
/*FUNCTION**********************************************************************
|
||||
*
|
||||
* Function Name : SystemInit
|
||||
* Description : This function disables the watchdog, enables FPU
|
||||
* and the power mode protection if the corresponding feature macro
|
||||
* is enabled. SystemInit is called from startup_device file.
|
||||
*
|
||||
* Implements : SystemInit_Activity
|
||||
*END**************************************************************************/
|
||||
void SystemInit(void)
|
||||
{
|
||||
/**************************************************************************/
|
||||
/* FPU ENABLE*/
|
||||
/**************************************************************************/
|
||||
#ifdef ENABLE_FPU
|
||||
/* Enable CP10 and CP11 coprocessors */
|
||||
S32_SCB->CPACR |= (S32_SCB_CPACR_CP10_MASK | S32_SCB_CPACR_CP11_MASK);
|
||||
#ifdef ERRATA_E6940
|
||||
/* Disable lazy context save of floating point state by clearing LSPEN bit
|
||||
* Workaround for errata e6940 */
|
||||
S32_SCB->FPCCR &= ~(S32_SCB_FPCCR_LSPEN_MASK);
|
||||
#endif
|
||||
#endif /* ENABLE_FPU */
|
||||
|
||||
/**************************************************************************/
|
||||
/* WDOG DISABLE*/
|
||||
/**************************************************************************/
|
||||
|
||||
#if (DISABLE_WDOG)
|
||||
/* Write of the WDOG unlock key to CNT register, must be done in order to allow any modifications*/
|
||||
WDOG->CNT = (uint32_t ) FEATURE_WDOG_UNLOCK_VALUE;
|
||||
/* The dummy read is used in order to make sure that the WDOG registers will be configured only
|
||||
* after the write of the unlock value was completed. */
|
||||
(void)WDOG->CNT;
|
||||
|
||||
/* Initial write of WDOG configuration register:
|
||||
* enables support for 32-bit refresh/unlock command write words,
|
||||
* clock select from LPO, update enable, watchdog disabled */
|
||||
WDOG->CS = (uint32_t ) ( (1UL << WDOG_CS_CMD32EN_SHIFT) |
|
||||
(FEATURE_WDOG_CLK_FROM_LPO << WDOG_CS_CLK_SHIFT) |
|
||||
(0U << WDOG_CS_EN_SHIFT) |
|
||||
(1U << WDOG_CS_UPDATE_SHIFT) );
|
||||
|
||||
/* Configure timeout */
|
||||
WDOG->TOVAL = (uint32_t )0xFFFF;
|
||||
#endif /* (DISABLE_WDOG) */
|
||||
|
||||
/**************************************************************************/
|
||||
/* ENABLE CACHE */
|
||||
/**************************************************************************/
|
||||
#if defined(I_CACHE) && (ICACHE_ENABLE == 1)
|
||||
/* Invalidate and enable code cache */
|
||||
LMEM->PCCCR = LMEM_PCCCR_INVW0(1) | LMEM_PCCCR_INVW1(1) | LMEM_PCCCR_GO(1) | LMEM_PCCCR_ENCACHE(1);
|
||||
#endif /* defined(I_CACHE) && (ICACHE_ENABLE == 1) */
|
||||
}
|
||||
|
||||
/*FUNCTION**********************************************************************
|
||||
*
|
||||
* Function Name : SystemCoreClockUpdate
|
||||
* Description : This function must be called whenever the core clock is changed
|
||||
* during program execution. It evaluates the clock register settings and calculates
|
||||
* the current core clock.
|
||||
*
|
||||
* Implements : SystemCoreClockUpdate_Activity
|
||||
*END**************************************************************************/
|
||||
void SystemCoreClockUpdate(void)
|
||||
{
|
||||
uint32_t SCGOUTClock = 0U; /* Variable to store output clock frequency of the SCG module */
|
||||
uint32_t regValue; /* Temporary variable */
|
||||
uint32_t divider, prediv, multi;
|
||||
bool validSystemClockSource = true;
|
||||
static const uint32_t fircFreq[] = {
|
||||
FEATURE_SCG_FIRC_FREQ0,
|
||||
};
|
||||
|
||||
divider = ((SCG->CSR & SCG_CSR_DIVCORE_MASK) >> SCG_CSR_DIVCORE_SHIFT) + 1U;
|
||||
|
||||
switch ((SCG->CSR & SCG_CSR_SCS_MASK) >> SCG_CSR_SCS_SHIFT) {
|
||||
case 0x1:
|
||||
/* System OSC */
|
||||
SCGOUTClock = CPU_XTAL_CLK_HZ;
|
||||
break;
|
||||
case 0x2:
|
||||
/* Slow IRC */
|
||||
regValue = (SCG->SIRCCFG & SCG_SIRCCFG_RANGE_MASK) >> SCG_SIRCCFG_RANGE_SHIFT;
|
||||
|
||||
if (regValue != 0U)
|
||||
{
|
||||
SCGOUTClock = FEATURE_SCG_SIRC_HIGH_RANGE_FREQ;
|
||||
}
|
||||
|
||||
break;
|
||||
case 0x3:
|
||||
/* Fast IRC */
|
||||
regValue = (SCG->FIRCCFG & SCG_FIRCCFG_RANGE_MASK) >> SCG_FIRCCFG_RANGE_SHIFT;
|
||||
SCGOUTClock= fircFreq[regValue];
|
||||
break;
|
||||
case 0x6:
|
||||
/* System PLL */
|
||||
SCGOUTClock = CPU_XTAL_CLK_HZ;
|
||||
prediv = ((SCG->SPLLCFG & SCG_SPLLCFG_PREDIV_MASK) >> SCG_SPLLCFG_PREDIV_SHIFT) + 1U;
|
||||
multi = ((SCG->SPLLCFG & SCG_SPLLCFG_MULT_MASK) >> SCG_SPLLCFG_MULT_SHIFT) + 16U;
|
||||
SCGOUTClock = SCGOUTClock * multi / (prediv * 2U);
|
||||
break;
|
||||
default:
|
||||
validSystemClockSource = false;
|
||||
break;
|
||||
}
|
||||
|
||||
if (validSystemClockSource == true) {
|
||||
SystemCoreClock = (SCGOUTClock / divider);
|
||||
}
|
||||
}
|
||||
|
||||
/*FUNCTION**********************************************************************
|
||||
*
|
||||
* Function Name : SystemSoftwareReset
|
||||
* Description : This function is used to initiate a system reset
|
||||
*
|
||||
* Implements : SystemSoftwareReset_Activity
|
||||
*END**************************************************************************/
|
||||
void SystemSoftwareReset(void)
|
||||
{
|
||||
uint32_t regValue;
|
||||
|
||||
/* Read Application Interrupt and Reset Control Register */
|
||||
regValue = S32_SCB->AIRCR;
|
||||
|
||||
/* Clear register key */
|
||||
regValue &= ~( S32_SCB_AIRCR_VECTKEY_MASK);
|
||||
|
||||
/* Configure System reset request bit and Register Key */
|
||||
regValue |= S32_SCB_AIRCR_VECTKEY(FEATURE_SCB_VECTKEY);
|
||||
regValue |= S32_SCB_AIRCR_SYSRESETREQ(0x1u);
|
||||
|
||||
/* Write computed register value */
|
||||
S32_SCB->AIRCR = regValue;
|
||||
}
|
||||
|
||||
/*******************************************************************************
|
||||
* EOF
|
||||
******************************************************************************/
|
|
@ -0,0 +1,111 @@
|
|||
/*
|
||||
* Copyright (c) 2015 Freescale Semiconductor, Inc.
|
||||
* Copyright 2016-2017 NXP
|
||||
* All rights reserved.
|
||||
*
|
||||
* THIS SOFTWARE IS PROVIDED BY NXP "AS IS" AND ANY EXPRESSED OR
|
||||
* IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
|
||||
* OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
|
||||
* IN NO EVENT SHALL NXP OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
|
||||
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
|
||||
* (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
|
||||
* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
||||
* HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
|
||||
* STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING
|
||||
* IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
|
||||
* THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
|
||||
/*! @addtogroup soc_support_S32K144*/
|
||||
/*! @{*/
|
||||
|
||||
/*!
|
||||
* @file system_S32K144.h
|
||||
* @brief Device specific configuration file for S32K144
|
||||
*/
|
||||
|
||||
#ifndef SYSTEM_S32K144_H_
|
||||
#define SYSTEM_S32K144_H_ /**< Symbol preventing repeated inclusion */
|
||||
|
||||
#include <stdint.h>
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
/******************************************************************************
|
||||
* CPU Settings.
|
||||
*****************************************************************************/
|
||||
|
||||
/* Watchdog disable */
|
||||
#ifndef DISABLE_WDOG
|
||||
#define DISABLE_WDOG 1
|
||||
#endif
|
||||
|
||||
/* Cache enablement */
|
||||
#ifndef ICACHE_ENABLE
|
||||
#define ICACHE_ENABLE 0
|
||||
#endif
|
||||
|
||||
/* Value of the external crystal or oscillator clock frequency in Hz */
|
||||
#ifndef CPU_XTAL_CLK_HZ
|
||||
#define CPU_XTAL_CLK_HZ 8000000u
|
||||
#endif
|
||||
|
||||
/* Value of the fast internal oscillator clock frequency in Hz */
|
||||
#ifndef CPU_INT_FAST_CLK_HZ
|
||||
#define CPU_INT_FAST_CLK_HZ 48000000u
|
||||
#endif
|
||||
|
||||
/* Default System clock value */
|
||||
#ifndef DEFAULT_SYSTEM_CLOCK
|
||||
#define DEFAULT_SYSTEM_CLOCK 48000000u
|
||||
#endif
|
||||
|
||||
/**
|
||||
* @brief System clock frequency (core clock)
|
||||
*
|
||||
* The system clock frequency supplied to the SysTick timer and the processor
|
||||
* core clock. This variable can be used by the user application to setup the
|
||||
* SysTick timer or configure other parameters. It may also be used by debugger to
|
||||
* query the frequency of the debug timer or configure the trace clock speed
|
||||
* SystemCoreClock is initialized with a correct predefined value.
|
||||
*/
|
||||
extern uint32_t SystemCoreClock;
|
||||
|
||||
/**
|
||||
* @brief Setup the SoC.
|
||||
*
|
||||
* This function disables the watchdog, enables FPU.
|
||||
* if the corresponding feature macro is enabled.
|
||||
* SystemInit is called from startup_device file.
|
||||
*/
|
||||
void SystemInit(void);
|
||||
|
||||
/**
|
||||
* @brief Updates the SystemCoreClock variable.
|
||||
*
|
||||
* It must be called whenever the core clock is changed during program
|
||||
* execution. SystemCoreClockUpdate() evaluates the clock register settings and calculates
|
||||
* the current core clock.
|
||||
* This function must be called when user does not want to use clock manager component.
|
||||
* If clock manager is used, the CLOCK_SYS_GetFreq function must be used with CORE_CLOCK
|
||||
* parameter.
|
||||
*
|
||||
*/
|
||||
void SystemCoreClockUpdate(void);
|
||||
|
||||
/**
|
||||
* @brief Initiates a system reset.
|
||||
*
|
||||
* This function is used to initiate a system reset
|
||||
*/
|
||||
void SystemSoftwareReset(void);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
/*! @}*/
|
||||
#endif /* #if !defined(SYSTEM_S32K144_H_) */
|
|
@ -0,0 +1,207 @@
|
|||
/************************************************************************************//**
|
||||
* \file Demo/ARMCM4_S32K14_S32K144EVB_GCC/Prog/main.c
|
||||
* \brief Demo program application source file.
|
||||
* \ingroup Prog_ARMCM4_S32K14_S32K144EVB_GCC
|
||||
* \internal
|
||||
*----------------------------------------------------------------------------------------
|
||||
* C O P Y R I G H T
|
||||
*----------------------------------------------------------------------------------------
|
||||
* Copyright (c) 2020 by Feaser http://www.feaser.com All rights reserved
|
||||
*
|
||||
*----------------------------------------------------------------------------------------
|
||||
* L I C E N S E
|
||||
*----------------------------------------------------------------------------------------
|
||||
* This file is part of OpenBLT. OpenBLT is free software: you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as published by the Free
|
||||
* Software Foundation, either version 3 of the License, or (at your option) any later
|
||||
* version.
|
||||
*
|
||||
* OpenBLT is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
|
||||
* without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
|
||||
* PURPOSE. See the GNU General Public License for more details.
|
||||
*
|
||||
* You have received a copy of the GNU General Public License along with OpenBLT. It
|
||||
* should be located in ".\Doc\license.html". If not, contact Feaser to obtain a copy.
|
||||
*
|
||||
* \endinternal
|
||||
****************************************************************************************/
|
||||
|
||||
/****************************************************************************************
|
||||
* Include files
|
||||
****************************************************************************************/
|
||||
#include "header.h" /* generic header */
|
||||
|
||||
|
||||
/****************************************************************************************
|
||||
* Function prototypes
|
||||
****************************************************************************************/
|
||||
static void Init(void);
|
||||
static void SystemClockConfig(void);
|
||||
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief This is the entry point for the bootloader application and is called
|
||||
** by the reset interrupt vector after the C-startup routines executed.
|
||||
** \return Program return code.
|
||||
**
|
||||
****************************************************************************************/
|
||||
int main(void)
|
||||
{
|
||||
/* Initialize the microcontroller. */
|
||||
Init();
|
||||
/* Initialize the bootloader interface */
|
||||
BootComInit();
|
||||
|
||||
/* Start the infinite program loop. */
|
||||
while (1)
|
||||
{
|
||||
/* Toggle LED with a fixed frequency. */
|
||||
LedToggle();
|
||||
/* Check for bootloader activation request */
|
||||
BootComCheckActivationRequest();
|
||||
}
|
||||
|
||||
/* Program should never get here. */
|
||||
return 0;
|
||||
} /*** end of main ***/
|
||||
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief Initializes the microcontroller.
|
||||
** \return none.
|
||||
**
|
||||
****************************************************************************************/
|
||||
static void Init(void)
|
||||
{
|
||||
/* Configure the system clock. */
|
||||
SystemClockConfig();
|
||||
/* Enable the peripheral clock for the ports that are used. */
|
||||
PCC->PCCn[PCC_PORTC_INDEX] |= PCC_PCCn_CGC_MASK;
|
||||
PCC->PCCn[PCC_PORTD_INDEX] |= PCC_PCCn_CGC_MASK;
|
||||
PCC->PCCn[PCC_PORTE_INDEX] |= PCC_PCCn_CGC_MASK;
|
||||
#if (BOOT_COM_RS232_ENABLE > 0)
|
||||
/* UART RX GPIO pin configuration. PC6 = UART1 RX, MUX = ALT2. */
|
||||
PORTC->PCR[6] |= PORT_PCR_MUX(2);
|
||||
/* UART TX GPIO pin configuration. PC7 = UART1 TX, MUX = ALT2. */
|
||||
PORTC->PCR[7] |= PORT_PCR_MUX(2);
|
||||
#endif
|
||||
#if (BOOT_COM_CAN_ENABLE > 0)
|
||||
/* CAN RX GPIO pin configuration. PE4 = CAN0 RX, MUX = ALT5. */
|
||||
PORTE->PCR[4] |= PORT_PCR_MUX(5);
|
||||
/* CAN TX GPIO pin configuration. PE5 = CAN0 TX, MUX = ALT5. */
|
||||
PORTE->PCR[5] |= PORT_PCR_MUX(5);
|
||||
#endif
|
||||
|
||||
/* Initialize the timer driver. */
|
||||
TimerInit();
|
||||
/* Initialize the led driver. */
|
||||
LedInit();
|
||||
/* Enable the global interrupts. */
|
||||
ENABLE_INTERRUPTS();
|
||||
} /*** end of Init ***/
|
||||
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief System Clock Configuration. This code was derived from a S32 Design Studio
|
||||
** example program. It uses the 8 MHz external crystal as a source for the
|
||||
** PLL and configures the normal RUN mode for the following clock settings:
|
||||
** - SPLL_CLK = 160 MHz
|
||||
** - CORE_CLK = 80 MHz
|
||||
** - SYS_CLK = 80 MHz
|
||||
** - BUS_CLK = 40 MHz
|
||||
** - FLASH_CLK = 26.67 MHz
|
||||
** - SIRCDIV1_CLK = 8 MHz
|
||||
** - SIRCDIV2_CLK = 8 MHz
|
||||
** \return none.
|
||||
**
|
||||
****************************************************************************************/
|
||||
static void SystemClockConfig(void)
|
||||
{
|
||||
/* --------- SOSC Initialization (8 MHz) ------------------------------------------- */
|
||||
/* SOSCDIV1 & SOSCDIV2 =1: divide by 1. */
|
||||
SCG->SOSCDIV = SCG_SOSCDIV_SOSCDIV1(1) | SCG_SOSCDIV_SOSCDIV2(1);
|
||||
/* Range=2: Medium freq (SOSC betw 1MHz-8MHz).
|
||||
* HGO=0: Config xtal osc for low power.
|
||||
* EREFS=1: Input is external XTAL.
|
||||
*/
|
||||
SCG->SOSCCFG = SCG_SOSCCFG_RANGE(2) | SCG_SOSCCFG_EREFS_MASK;
|
||||
/* Ensure SOSCCSR unlocked. */
|
||||
while (SCG->SOSCCSR & SCG_SOSCCSR_LK_MASK)
|
||||
{
|
||||
;
|
||||
}
|
||||
/* LK=0: SOSCCSR can be written.
|
||||
* SOSCCMRE=0: OSC CLK monitor IRQ if enabled.
|
||||
* SOSCCM=0: OSC CLK monitor disabled.
|
||||
* SOSCERCLKEN=0: Sys OSC 3V ERCLK output clk disabled.
|
||||
* SOSCLPEN=0: Sys OSC disabled in VLP modes.
|
||||
* SOSCSTEN=0: Sys OSC disabled in Stop modes.
|
||||
* SOSCEN=1: Enable oscillator.
|
||||
*/
|
||||
SCG->SOSCCSR = SCG_SOSCCSR_SOSCEN_MASK;
|
||||
/* Wait for system OSC clock to become valid. */
|
||||
while (!(SCG->SOSCCSR & SCG_SOSCCSR_SOSCVLD_MASK))
|
||||
{
|
||||
;
|
||||
}
|
||||
|
||||
/* --------- SPLL Initialization (160 MHz) ----------------------------------------- */
|
||||
/* Ensure SPLLCSR is unlocked. */
|
||||
while (SCG->SPLLCSR & SCG_SPLLCSR_LK_MASK)
|
||||
{
|
||||
;
|
||||
}
|
||||
/* SPLLEN=0: SPLL is disabled (default). */
|
||||
SCG->SPLLCSR &= ~SCG_SPLLCSR_SPLLEN_MASK;
|
||||
/* SPLLDIV1 divide by 2 and SPLLDIV2 divide by 4. */
|
||||
SCG->SPLLDIV |= SCG_SPLLDIV_SPLLDIV1(2) | SCG_SPLLDIV_SPLLDIV2(3);
|
||||
/* PREDIV=0: Divide SOSC_CLK by 0+1=1.
|
||||
* MULT=24: Multiply sys pll by 4+24=40.
|
||||
* SPLL_CLK = 8MHz / 1 * 40 / 2 = 160 MHz.
|
||||
*/
|
||||
SCG->SPLLCFG = SCG_SPLLCFG_MULT(24);
|
||||
/* Ensure SPLLCSR is unlocked. */
|
||||
while (SCG->SPLLCSR & SCG_SPLLCSR_LK_MASK)
|
||||
{
|
||||
;
|
||||
}
|
||||
/* LK=0: SPLLCSR can be written.
|
||||
* SPLLCMRE=0: SPLL CLK monitor IRQ if enabled.
|
||||
* SPLLCM=0: SPLL CLK monitor disabled.
|
||||
* SPLLSTEN=0: SPLL disabled in Stop modes.
|
||||
* SPLLEN=1: Enable SPLL.
|
||||
*/
|
||||
SCG->SPLLCSR |= SCG_SPLLCSR_SPLLEN_MASK;
|
||||
/* Wait for SPLL to become valid. */
|
||||
while (!(SCG->SPLLCSR & SCG_SPLLCSR_SPLLVLD_MASK))
|
||||
{
|
||||
;
|
||||
}
|
||||
|
||||
/* --------- SIRC Initialization --------------------------------------------------- */
|
||||
/* Slow IRC is enabled with high range (8 MHz) in reset. Enable SIRCDIV2_CLK and
|
||||
* SIRCDIV1_CLK, divide by 1 = 8MHz asynchronous clock source.
|
||||
*/
|
||||
SCG->SIRCDIV = SCG_SIRCDIV_SIRCDIV1(1) | SCG_SIRCDIV_SIRCDIV2(1);
|
||||
|
||||
/* --------- Change to normal RUN mode with 8MHz SOSC, 80 MHz PLL ------------------ */
|
||||
/* Select PLL as clock source.
|
||||
* DIVCORE=1, div. by 2: Core clock = 160/2 MHz = 80 MHz.
|
||||
* DIVBUS=1, div. by 2: bus clock = 40 MHz.
|
||||
* DIVSLOW=2, div. by 2: SCG slow, flash clock= 26 2/3 MHz.
|
||||
*/
|
||||
SCG->RCCR= SCG_RCCR_SCS(6) | SCG_RCCR_DIVCORE(0b01) | SCG_RCCR_DIVBUS(0b01) |
|
||||
SCG_RCCR_DIVSLOW(0b10);
|
||||
/* Wait until system clock source is SPLL. */
|
||||
while (((SCG->CSR & SCG_CSR_SCS_MASK) >> SCG_CSR_SCS_SHIFT ) != 6U)
|
||||
{
|
||||
;
|
||||
}
|
||||
/* Evaluate the clock register settings and calculates the current core clock. This
|
||||
* function must be called when the clock manager component is not used.
|
||||
*/
|
||||
SystemCoreClockUpdate();
|
||||
} /*** end of SystemClockConfig ***/
|
||||
|
||||
|
||||
/*********************************** end of main.c *************************************/
|
|
@ -0,0 +1,13 @@
|
|||
/**
|
||||
\defgroup Prog_ARMCM4_S32K14_S32K144EVB_GCC User Program
|
||||
\ingroup ARMCM4_S32K14_S32K144EVB_GCC
|
||||
\brief User Program.
|
||||
\details The intention of the demo user program is two-fold. (1) To test the
|
||||
bootloader, you need some sort of firmware to see if you can perform a
|
||||
firmware update with the bootloader. This program can be used for this
|
||||
purpose. (2) To make firmware programmable by the bootloader, a few
|
||||
adjustments to the firmware are required. The demo user program serves as an
|
||||
example for how these adjustments can be implemented. This demo user program
|
||||
is a template that can be used as a starting point for creating your own
|
||||
demo user program.
|
||||
*/
|
|
@ -0,0 +1,248 @@
|
|||
/*
|
||||
* Copyright (c) 2013 - 2014, Freescale Semiconductor, Inc.
|
||||
* Copyright 2016-2018 NXP
|
||||
* All rights reserved.
|
||||
*
|
||||
* THIS SOFTWARE IS PROVIDED BY NXP "AS IS" AND ANY EXPRESSED OR
|
||||
* IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
|
||||
* OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
|
||||
* IN NO EVENT SHALL NXP OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
|
||||
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
|
||||
* (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
|
||||
* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
||||
* HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
|
||||
* STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING
|
||||
* IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
|
||||
* THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
/**
|
||||
* @page misra_violations MISRA-C:2012 violations
|
||||
*
|
||||
* @section [global]
|
||||
* Violates MISRA 2012 Advisory Rule 8.9, An object should be defined at block
|
||||
* scope if its identifier only appears in a single function.
|
||||
* All variables with this problem are defined in the linker files.
|
||||
*
|
||||
* @section [global]
|
||||
* Violates MISRA 2012 Advisory Rule 8.11, When an array with external linkage
|
||||
* is declared, its size should be explicitly specified.
|
||||
* The size of the arrays can not be explicitly determined.
|
||||
*
|
||||
* @section [global]
|
||||
* Violates MISRA 2012 Advisory Rule 11.4, A conversion should not be performed
|
||||
* between a pointer to object and an integer type.
|
||||
* The cast is required to initialize a pointer with an unsigned int define,
|
||||
* representing an address.
|
||||
*
|
||||
* @section [global]
|
||||
* Violates MISRA 2012 Required Rule 11.6, A cast shall not be performed
|
||||
* between pointer to void and an arithmetic type.
|
||||
* The cast is required to initialize a pointer with an unsigned int define,
|
||||
* representing an address.
|
||||
*
|
||||
* @section [global]
|
||||
* Violates MISRA 2012 Required Rule 2.1, A project shall not contain unreachable
|
||||
* code.
|
||||
* The condition compares two address defined in linker files that can be different.
|
||||
*
|
||||
* @section [global]
|
||||
* Violates MISRA 2012 Advisory Rule 8.7, External could be made static.
|
||||
* Function is defined for usage by application code.
|
||||
*
|
||||
* @section [global]
|
||||
* Violates MISRA 2012 Mandatory Rule 17.3, Symbol 'MFSPR' undeclared, assumed
|
||||
* to return int.
|
||||
* This is an e200 Power Architecture Assembly instruction used to retrieve
|
||||
* the core number.
|
||||
*
|
||||
*/
|
||||
|
||||
#include "startup.h"
|
||||
#include <stdint.h>
|
||||
|
||||
|
||||
/*******************************************************************************
|
||||
* Static Variables
|
||||
******************************************************************************/
|
||||
static volatile uint32_t * const s_vectors[NUMBER_OF_CORES] = FEATURE_INTERRUPT_INT_VECTORS;
|
||||
|
||||
/*******************************************************************************
|
||||
* Code
|
||||
******************************************************************************/
|
||||
|
||||
/*FUNCTION**********************************************************************
|
||||
*
|
||||
* Function Name : init_data_bss
|
||||
* Description : Make necessary initializations for RAM.
|
||||
* - Copy the vector table from ROM to RAM.
|
||||
* - Copy initialized data from ROM to RAM.
|
||||
* - Copy code that should reside in RAM from ROM
|
||||
* - Clear the zero-initialized data section.
|
||||
*
|
||||
* Tool Chains:
|
||||
* __GNUC__ : GNU Compiler Collection
|
||||
* __ghs__ : Green Hills ARM Compiler
|
||||
* __ICCARM__ : IAR ARM Compiler
|
||||
* __DCC__ : Wind River Diab Compiler
|
||||
* __ARMCC_VERSION : ARMC Compiler
|
||||
*
|
||||
* Implements : init_data_bss_Activity
|
||||
*END**************************************************************************/
|
||||
void init_data_bss(void)
|
||||
{
|
||||
uint32_t n;
|
||||
uint8_t coreId;
|
||||
/* For ARMC we are using the library method of initializing DATA, Custom Section and
|
||||
* Code RAM sections so the below variables are not needed */
|
||||
#if !defined(__ARMCC_VERSION)
|
||||
/* Declare pointers for various data sections. These pointers
|
||||
* are initialized using values pulled in from the linker file */
|
||||
uint8_t * data_ram;
|
||||
uint8_t * code_ram;
|
||||
uint8_t * bss_start;
|
||||
uint8_t * custom_ram;
|
||||
const uint8_t * data_rom, * data_rom_end;
|
||||
const uint8_t * code_rom, * code_rom_end;
|
||||
const uint8_t * bss_end;
|
||||
const uint8_t * custom_rom, * custom_rom_end;
|
||||
#endif
|
||||
/* Addresses for VECTOR_TABLE and VECTOR_RAM come from the linker file */
|
||||
|
||||
#if defined(__ARMCC_VERSION)
|
||||
extern uint32_t __RAM_VECTOR_TABLE_SIZE;
|
||||
extern uint32_t __VECTOR_ROM;
|
||||
extern uint32_t __VECTOR_RAM;
|
||||
#else
|
||||
extern uint32_t __RAM_VECTOR_TABLE_SIZE[];
|
||||
extern uint32_t __VECTOR_TABLE[];
|
||||
extern uint32_t __VECTOR_RAM[];
|
||||
#endif
|
||||
/* Get section information from linker files */
|
||||
#if defined(__ICCARM__)
|
||||
/* Data */
|
||||
data_ram = __section_begin(".data");
|
||||
data_rom = __section_begin(".data_init");
|
||||
data_rom_end = __section_end(".data_init");
|
||||
|
||||
/* CODE RAM */
|
||||
#pragma section = "__CODE_ROM"
|
||||
#pragma section = "__CODE_RAM"
|
||||
code_ram = __section_begin("__CODE_RAM");
|
||||
code_rom = __section_begin("__CODE_ROM");
|
||||
code_rom_end = __section_end("__CODE_ROM");
|
||||
|
||||
/* BSS */
|
||||
bss_start = __section_begin(".bss");
|
||||
bss_end = __section_end(".bss");
|
||||
|
||||
custom_ram = __section_begin(".customSection");
|
||||
custom_rom = __section_begin(".customSection_init");
|
||||
custom_rom_end = __section_end(".customSection_init");
|
||||
|
||||
#elif defined (__ARMCC_VERSION)
|
||||
/* VECTOR TABLE*/
|
||||
uint8_t * vector_table_size = (uint8_t *)__RAM_VECTOR_TABLE_SIZE;
|
||||
uint32_t * vector_rom = (uint32_t *)__VECTOR_ROM;
|
||||
uint32_t * vector_ram = (uint32_t *)__VECTOR_RAM;
|
||||
#else
|
||||
extern uint32_t __DATA_ROM[];
|
||||
extern uint32_t __DATA_RAM[];
|
||||
extern uint32_t __DATA_END[];
|
||||
|
||||
extern uint32_t __CODE_RAM[];
|
||||
extern uint32_t __CODE_ROM[];
|
||||
extern uint32_t __CODE_END[];
|
||||
|
||||
extern uint32_t __BSS_START[];
|
||||
extern uint32_t __BSS_END[];
|
||||
|
||||
extern uint32_t __CUSTOM_ROM[];
|
||||
extern uint32_t __CUSTOM_END[];
|
||||
|
||||
/* Data */
|
||||
data_ram = (uint8_t *)__DATA_RAM;
|
||||
data_rom = (uint8_t *)__DATA_ROM;
|
||||
data_rom_end = (uint8_t *)__DATA_END;
|
||||
/* CODE RAM */
|
||||
code_ram = (uint8_t *)__CODE_RAM;
|
||||
code_rom = (uint8_t *)__CODE_ROM;
|
||||
code_rom_end = (uint8_t *)__CODE_END;
|
||||
/* BSS */
|
||||
bss_start = (uint8_t *)__BSS_START;
|
||||
bss_end = (uint8_t *)__BSS_END;
|
||||
|
||||
/* Custom section */
|
||||
custom_ram = CUSTOMSECTION_SECTION_START;
|
||||
custom_rom = (uint8_t *)__CUSTOM_ROM;
|
||||
custom_rom_end = (uint8_t *)__CUSTOM_END;
|
||||
|
||||
#endif
|
||||
|
||||
#if !defined(__ARMCC_VERSION)
|
||||
/* Copy initialized data from ROM to RAM */
|
||||
while (data_rom_end != data_rom)
|
||||
{
|
||||
*data_ram = *data_rom;
|
||||
data_ram++;
|
||||
data_rom++;
|
||||
}
|
||||
|
||||
/* Copy functions from ROM to RAM */
|
||||
while (code_rom_end != code_rom)
|
||||
{
|
||||
*code_ram = *code_rom;
|
||||
code_ram++;
|
||||
code_rom++;
|
||||
}
|
||||
|
||||
/* Clear the zero-initialized data section */
|
||||
while(bss_end != bss_start)
|
||||
{
|
||||
*bss_start = 0;
|
||||
bss_start++;
|
||||
}
|
||||
|
||||
/* Copy customsection rom to ram */
|
||||
while(custom_rom_end != custom_rom)
|
||||
{
|
||||
*custom_ram = *custom_rom;
|
||||
custom_rom++;
|
||||
custom_ram++;
|
||||
}
|
||||
#endif
|
||||
coreId = (uint8_t)GET_CORE_ID();
|
||||
#if defined (__ARMCC_VERSION)
|
||||
/* Copy the vector table from ROM to RAM */
|
||||
/* Workaround */
|
||||
for (n = 0; n < (((uint32_t)(vector_table_size))/sizeof(uint32_t)); n++)
|
||||
{
|
||||
vector_ram[n] = vector_rom[n];
|
||||
}
|
||||
/* Point the VTOR to the position of vector table */
|
||||
*s_vectors[coreId] = (uint32_t) __VECTOR_RAM;
|
||||
#else
|
||||
/* Check if VECTOR_TABLE copy is needed */
|
||||
if (__VECTOR_RAM != __VECTOR_TABLE)
|
||||
{
|
||||
/* Copy the vector table from ROM to RAM */
|
||||
for (n = 0; n < (((uint32_t)__RAM_VECTOR_TABLE_SIZE)/sizeof(uint32_t)); n++)
|
||||
{
|
||||
__VECTOR_RAM[n] = __VECTOR_TABLE[n];
|
||||
}
|
||||
/* Point the VTOR to the position of vector table */
|
||||
*s_vectors[coreId] = (uint32_t)__VECTOR_RAM;
|
||||
}
|
||||
else
|
||||
{
|
||||
/* Point the VTOR to the position of vector table */
|
||||
*s_vectors[coreId] = (uint32_t)__VECTOR_TABLE;
|
||||
}
|
||||
#endif
|
||||
|
||||
}
|
||||
|
||||
/*******************************************************************************
|
||||
* EOF
|
||||
******************************************************************************/
|
||||
|
|
@ -0,0 +1,133 @@
|
|||
/*
|
||||
* Copyright (c) 2013 - 2014, Freescale Semiconductor, Inc.
|
||||
* Copyright 2016-2019 NXP
|
||||
* All rights reserved.
|
||||
*
|
||||
* THIS SOFTWARE IS PROVIDED BY NXP "AS IS" AND ANY EXPRESSED OR
|
||||
* IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
|
||||
* OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
|
||||
* IN NO EVENT SHALL NXP OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
|
||||
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
|
||||
* (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
|
||||
* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
||||
* HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
|
||||
* STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING
|
||||
* IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
|
||||
* THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
#ifndef STARTUP_H
|
||||
#define STARTUP_H
|
||||
|
||||
#include <stdint.h>
|
||||
#include "device_registers.h"
|
||||
/**
|
||||
* @page misra_violations MISRA-C:2012 violations
|
||||
*
|
||||
* @section [global]
|
||||
* Violates MISRA 2012 Advisory Rule 2.5, Local macro not referenced.
|
||||
* The defined macro is used as include guard.
|
||||
*
|
||||
* @section [global]
|
||||
* Violates MISRA 2012 Advisory Rule 8.9, An object should be defined at block
|
||||
* scope if its identifier only appears in a single function.
|
||||
* All variables with this problem are defined in the linker files.
|
||||
*
|
||||
*/
|
||||
|
||||
/*******************************************************************************
|
||||
* API
|
||||
******************************************************************************/
|
||||
|
||||
/*!
|
||||
* @brief define symbols that specific start and end addres of some basic sections.
|
||||
*/
|
||||
#if (defined(S32K14x_SERIES) || defined(S32K11x_SERIES) || defined(S32V234_SERIES) || defined(MPC574x_SERIES) || defined(S32R_SERIES) || defined(S32MTV_SERIES) || defined(SJA1110_SERIES)) || defined (S32K144W_M4_SERIES)
|
||||
#if (defined(__ICCARM__))
|
||||
#define INTERRUPTS_SECTION_START __section_begin(".intvec")
|
||||
#define INTERRUPTS_SECTION_END __section_end(".intvec")
|
||||
#define BSS_SECTION_START __section_begin(".bss")
|
||||
#define BSS_SECTION_END __section_end(".bss")
|
||||
#define DATA_SECTION_START __section_begin(".data")
|
||||
#define DATA_SECTION_END __section_end(".data")
|
||||
#define CUSTOMSECTION_SECTION_START __section_begin(".customSection")
|
||||
#define CUSTOMSECTION_SECTION_END __section_end(".customSection")
|
||||
#define CODE_RAM_SECTION_START __section_begin("__CODE_RAM")
|
||||
#define CODE_RAM_SECTION_END __section_end("__CODE_RAM")
|
||||
#define DATA_INIT_SECTION_START __section_begin(".data_init")
|
||||
#define DATA_INIT_SECTION_END __section_end(".data_init")
|
||||
#define CODE_ROM_SECTION_START __section_begin("__CODE_ROM")
|
||||
#define CODE_ROM_SECTION_END __section_end("__CODE_ROM")
|
||||
|
||||
#elif (defined(__ARMCC_VERSION))
|
||||
#define INTERRUPTS_SECTION_START (uint8_t *)__VECTOR_ROM_START
|
||||
#define INTERRUPTS_SECTION_END (uint8_t *)__VECTOR_ROM_END
|
||||
#define BSS_SECTION_START (uint8_t *)__BSS_START
|
||||
#define BSS_SECTION_END (uint8_t *)__BSS_END
|
||||
#define DATA_SECTION_START (uint8_t *)__DATA_RAM_START
|
||||
#define DATA_SECTION_END (uint8_t *)__DATA_RAM_END
|
||||
#define CUSTOMSECTION_SECTION_START (uint8_t *)__CUSTOM_SECTION_START
|
||||
#define CUSTOMSECTION_SECTION_END (uint8_t *)__CUSTOM_SECTION_END
|
||||
#define CODE_RAM_SECTION_START (uint8_t *)__CODE_RAM_START
|
||||
#define CODE_RAM_SECTION_END (uint8_t *)__CODE_RAM_END
|
||||
|
||||
extern uint32_t __VECTOR_ROM_START;
|
||||
extern uint32_t __VECTOR_ROM_END;
|
||||
extern uint32_t __BSS_START;
|
||||
extern uint32_t __BSS_END;
|
||||
extern uint32_t __DATA_RAM_START;
|
||||
extern uint32_t __DATA_RAM_END;
|
||||
extern uint32_t __CUSTOM_SECTION_START;
|
||||
extern uint32_t __CUSTOM_SECTION_END;
|
||||
extern uint32_t __CODE_RAM_START;
|
||||
extern uint32_t __CODE_RAM_END;
|
||||
#else
|
||||
#define INTERRUPTS_SECTION_START (uint8_t *)&__interrupts_start__
|
||||
#define INTERRUPTS_SECTION_END (uint8_t *)&__interrupts_end__
|
||||
#define BSS_SECTION_START (uint8_t *)&__bss_start__
|
||||
#define BSS_SECTION_END (uint8_t *)&__bss_end__
|
||||
#define DATA_SECTION_START (uint8_t *)&__data_start__
|
||||
#define DATA_SECTION_END (uint8_t *)&__data_end__
|
||||
#define CUSTOMSECTION_SECTION_START (uint8_t *)&__customSection_start__
|
||||
#define CUSTOMSECTION_SECTION_END (uint8_t *)&__customSection_end__
|
||||
#define CODE_RAM_SECTION_START (uint8_t *)&__code_ram_start__
|
||||
#define CODE_RAM_SECTION_END (uint8_t *)&__code_ram_end__
|
||||
|
||||
extern uint32_t __interrupts_start__;
|
||||
extern uint32_t __interrupts_end__;
|
||||
extern uint32_t __bss_start__;
|
||||
extern uint32_t __bss_end__;
|
||||
extern uint32_t __data_start__;
|
||||
extern uint32_t __data_end__;
|
||||
extern uint32_t __customSection_start__;
|
||||
extern uint32_t __customSection_end__;
|
||||
extern uint32_t __code_ram_start__;
|
||||
extern uint32_t __code_ram_end__;
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#if (defined(__ICCARM__))
|
||||
#pragma section = ".data"
|
||||
#pragma section = ".data_init"
|
||||
#pragma section = ".bss"
|
||||
#pragma section = ".intvec"
|
||||
#pragma section = ".customSection"
|
||||
#pragma section = ".customSection_init"
|
||||
#pragma section = "__CODE_RAM"
|
||||
#pragma section = "__CODE_ROM"
|
||||
#endif
|
||||
|
||||
/*!
|
||||
* @brief Make necessary initializations for RAM.
|
||||
*
|
||||
* - Copy initialized data from ROM to RAM.
|
||||
* - Clear the zero-initialized data section.
|
||||
* - Copy the vector table from ROM to RAM. This could be an option.
|
||||
*/
|
||||
void init_data_bss(void);
|
||||
|
||||
#endif /* STARTUP_H*/
|
||||
/*******************************************************************************
|
||||
* EOF
|
||||
******************************************************************************/
|
||||
|
|
@ -0,0 +1,531 @@
|
|||
/* ---------------------------------------------------------------------------------------*/
|
||||
/* @file: startup_S32K144.s */
|
||||
/* @purpose: GNU Compiler Collection Startup File */
|
||||
/* S32K144 */
|
||||
/* @version: 2.0 */
|
||||
/* @date: 2017-1-10 */
|
||||
/* @build: b170107 */
|
||||
/* ---------------------------------------------------------------------------------------*/
|
||||
/* */
|
||||
/* Copyright (c) 1997 - 2016 , Freescale Semiconductor, Inc. */
|
||||
/* Copyright 2016-2017 NXP */
|
||||
/* All rights reserved. */
|
||||
/* */
|
||||
/* THIS SOFTWARE IS PROVIDED BY NXP "AS IS" AND ANY EXPRESSED OR */
|
||||
/* IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES */
|
||||
/* OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. */
|
||||
/* IN NO EVENT SHALL NXP OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, */
|
||||
/* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES */
|
||||
/* (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR */
|
||||
/* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) */
|
||||
/* HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, */
|
||||
/* STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING */
|
||||
/* IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF */
|
||||
/* THE POSSIBILITY OF SUCH DAMAGE. */
|
||||
/*****************************************************************************/
|
||||
/* Version: GNU Compiler Collection */
|
||||
/*****************************************************************************/
|
||||
.syntax unified
|
||||
.arch armv7-m
|
||||
|
||||
.section .isr_vector, "a"
|
||||
.align 2
|
||||
.globl __isr_vector
|
||||
__isr_vector:
|
||||
.long __StackTop /* Top of Stack */
|
||||
.long Reset_Handler /* Reset Handler */
|
||||
.long NMI_Handler /* NMI Handler*/
|
||||
.long HardFault_Handler /* Hard Fault Handler*/
|
||||
.long MemManage_Handler /* MPU Fault Handler*/
|
||||
.long BusFault_Handler /* Bus Fault Handler*/
|
||||
.long UsageFault_Handler /* Usage Fault Handler*/
|
||||
.long 0 /* Reserved*/
|
||||
.long 0 /* Reserved*/
|
||||
.long 0 /* Reserved*/
|
||||
.long 0 /* Reserved*/
|
||||
.long SVC_Handler /* SVCall Handler*/
|
||||
.long DebugMon_Handler /* Debug Monitor Handler*/
|
||||
.long 0 /* Reserved*/
|
||||
.long PendSV_Handler /* PendSV Handler*/
|
||||
.long SysTick_Handler /* SysTick Handler*/
|
||||
|
||||
/* External Interrupts*/
|
||||
.long DMA0_IRQHandler /* DMA channel 0 transfer complete*/
|
||||
.long DMA1_IRQHandler /* DMA channel 1 transfer complete*/
|
||||
.long DMA2_IRQHandler /* DMA channel 2 transfer complete*/
|
||||
.long DMA3_IRQHandler /* DMA channel 3 transfer complete*/
|
||||
.long DMA4_IRQHandler /* DMA channel 4 transfer complete*/
|
||||
.long DMA5_IRQHandler /* DMA channel 5 transfer complete*/
|
||||
.long DMA6_IRQHandler /* DMA channel 6 transfer complete*/
|
||||
.long DMA7_IRQHandler /* DMA channel 7 transfer complete*/
|
||||
.long DMA8_IRQHandler /* DMA channel 8 transfer complete*/
|
||||
.long DMA9_IRQHandler /* DMA channel 9 transfer complete*/
|
||||
.long DMA10_IRQHandler /* DMA channel 10 transfer complete*/
|
||||
.long DMA11_IRQHandler /* DMA channel 11 transfer complete*/
|
||||
.long DMA12_IRQHandler /* DMA channel 12 transfer complete*/
|
||||
.long DMA13_IRQHandler /* DMA channel 13 transfer complete*/
|
||||
.long DMA14_IRQHandler /* DMA channel 14 transfer complete*/
|
||||
.long DMA15_IRQHandler /* DMA channel 15 transfer complete*/
|
||||
.long DMA_Error_IRQHandler /* DMA error interrupt channels 0-15*/
|
||||
.long MCM_IRQHandler /* FPU sources*/
|
||||
.long FTFC_IRQHandler /* FTFC Command complete*/
|
||||
.long Read_Collision_IRQHandler /* FTFC Read collision*/
|
||||
.long LVD_LVW_IRQHandler /* PMC Low voltage detect interrupt*/
|
||||
.long FTFC_Fault_IRQHandler /* FTFC Double bit fault detect*/
|
||||
.long WDOG_EWM_IRQHandler /* Single interrupt vector for WDOG and EWM*/
|
||||
.long RCM_IRQHandler /* RCM Asynchronous Interrupt*/
|
||||
.long LPI2C0_Master_IRQHandler /* LPI2C0 Master Interrupt*/
|
||||
.long LPI2C0_Slave_IRQHandler /* LPI2C0 Slave Interrupt*/
|
||||
.long LPSPI0_IRQHandler /* LPSPI0 Interrupt*/
|
||||
.long LPSPI1_IRQHandler /* LPSPI1 Interrupt*/
|
||||
.long LPSPI2_IRQHandler /* LPSPI2 Interrupt*/
|
||||
.long Reserved45_IRQHandler /* Reserved Interrupt 45*/
|
||||
.long Reserved46_IRQHandler /* Reserved Interrupt 46*/
|
||||
.long LPUART0_RxTx_IRQHandler /* LPUART0 Transmit / Receive Interrupt*/
|
||||
.long Reserved48_IRQHandler /* Reserved Interrupt 48*/
|
||||
.long LPUART1_RxTx_IRQHandler /* LPUART1 Transmit / Receive Interrupt*/
|
||||
.long Reserved50_IRQHandler /* Reserved Interrupt 50*/
|
||||
.long LPUART2_RxTx_IRQHandler /* LPUART2 Transmit / Receive Interrupt*/
|
||||
.long Reserved52_IRQHandler /* Reserved Interrupt 52*/
|
||||
.long Reserved53_IRQHandler /* Reserved Interrupt 53*/
|
||||
.long Reserved54_IRQHandler /* Reserved Interrupt 54*/
|
||||
.long ADC0_IRQHandler /* ADC0 interrupt request.*/
|
||||
.long ADC1_IRQHandler /* ADC1 interrupt request.*/
|
||||
.long CMP0_IRQHandler /* CMP0 interrupt request*/
|
||||
.long Reserved58_IRQHandler /* Reserved Interrupt 58*/
|
||||
.long Reserved59_IRQHandler /* Reserved Interrupt 59*/
|
||||
.long ERM_single_fault_IRQHandler /* ERM single bit error correction*/
|
||||
.long ERM_double_fault_IRQHandler /* ERM double bit error non-correctable*/
|
||||
.long RTC_IRQHandler /* RTC alarm interrupt*/
|
||||
.long RTC_Seconds_IRQHandler /* RTC seconds interrupt*/
|
||||
.long LPIT0_Ch0_IRQHandler /* LPIT0 channel 0 overflow interrupt*/
|
||||
.long LPIT0_Ch1_IRQHandler /* LPIT0 channel 1 overflow interrupt*/
|
||||
.long LPIT0_Ch2_IRQHandler /* LPIT0 channel 2 overflow interrupt*/
|
||||
.long LPIT0_Ch3_IRQHandler /* LPIT0 channel 3 overflow interrupt*/
|
||||
.long PDB0_IRQHandler /* PDB0 interrupt*/
|
||||
.long Reserved69_IRQHandler /* Reserved Interrupt 69*/
|
||||
.long Reserved70_IRQHandler /* Reserved Interrupt 70*/
|
||||
.long Reserved71_IRQHandler /* Reserved Interrupt 71*/
|
||||
.long Reserved72_IRQHandler /* Reserved Interrupt 72*/
|
||||
.long SCG_IRQHandler /* SCG bus interrupt request*/
|
||||
.long LPTMR0_IRQHandler /* LPTIMER interrupt request*/
|
||||
.long PORTA_IRQHandler /* Port A pin detect interrupt*/
|
||||
.long PORTB_IRQHandler /* Port B pin detect interrupt*/
|
||||
.long PORTC_IRQHandler /* Port C pin detect interrupt*/
|
||||
.long PORTD_IRQHandler /* Port D pin detect interrupt*/
|
||||
.long PORTE_IRQHandler /* Port E pin detect interrupt*/
|
||||
.long SWI_IRQHandler /* Software interrupt*/
|
||||
.long Reserved81_IRQHandler /* Reserved Interrupt 81*/
|
||||
.long Reserved82_IRQHandler /* Reserved Interrupt 82*/
|
||||
.long Reserved83_IRQHandler /* Reserved Interrupt 83*/
|
||||
.long PDB1_IRQHandler /* PDB1 interrupt*/
|
||||
.long FLEXIO_IRQHandler /* FlexIO Interrupt*/
|
||||
.long Reserved86_IRQHandler /* Reserved Interrupt 86*/
|
||||
.long Reserved87_IRQHandler /* Reserved Interrupt 87*/
|
||||
.long Reserved88_IRQHandler /* Reserved Interrupt 88*/
|
||||
.long Reserved89_IRQHandler /* Reserved Interrupt 89*/
|
||||
.long Reserved90_IRQHandler /* Reserved Interrupt 90*/
|
||||
.long Reserved91_IRQHandler /* Reserved Interrupt 91*/
|
||||
.long Reserved92_IRQHandler /* Reserved Interrupt 92*/
|
||||
.long Reserved93_IRQHandler /* Reserved Interrupt 93*/
|
||||
.long CAN0_ORed_IRQHandler /* CAN0 OR'ed [Bus Off OR Transmit Warning OR Receive Warning]*/
|
||||
.long CAN0_Error_IRQHandler /* CAN0 Interrupt indicating that errors were detected on the CAN bus*/
|
||||
.long CAN0_Wake_Up_IRQHandler /* CAN0 Interrupt asserted when Pretended Networking operation is enabled, and a valid message matches the selected filter criteria during Low Power mode*/
|
||||
.long CAN0_ORed_0_15_MB_IRQHandler /* CAN0 OR'ed Message buffer (0-15)*/
|
||||
.long CAN0_ORed_16_31_MB_IRQHandler /* CAN0 OR'ed Message buffer (16-31)*/
|
||||
.long Reserved99_IRQHandler /* Reserved Interrupt 99*/
|
||||
.long Reserved100_IRQHandler /* Reserved Interrupt 100*/
|
||||
.long CAN1_ORed_IRQHandler /* CAN1 OR'ed [Bus Off OR Transmit Warning OR Receive Warning]*/
|
||||
.long CAN1_Error_IRQHandler /* CAN1 Interrupt indicating that errors were detected on the CAN bus*/
|
||||
.long Reserved103_IRQHandler /* Reserved Interrupt 103*/
|
||||
.long CAN1_ORed_0_15_MB_IRQHandler /* CAN1 OR'ed Interrupt for Message buffer (0-15)*/
|
||||
.long Reserved105_IRQHandler /* Reserved Interrupt 105*/
|
||||
.long Reserved106_IRQHandler /* Reserved Interrupt 106*/
|
||||
.long Reserved107_IRQHandler /* Reserved Interrupt 107*/
|
||||
.long CAN2_ORed_IRQHandler /* CAN2 OR'ed [Bus Off OR Transmit Warning OR Receive Warning]*/
|
||||
.long CAN2_Error_IRQHandler /* CAN2 Interrupt indicating that errors were detected on the CAN bus*/
|
||||
.long Reserved110_IRQHandler /* Reserved Interrupt 110*/
|
||||
.long CAN2_ORed_0_15_MB_IRQHandler /* CAN2 OR'ed Message buffer (0-15)*/
|
||||
.long Reserved112_IRQHandler /* Reserved Interrupt 112*/
|
||||
.long Reserved113_IRQHandler /* Reserved Interrupt 113*/
|
||||
.long Reserved114_IRQHandler /* Reserved Interrupt 114*/
|
||||
.long FTM0_Ch0_Ch1_IRQHandler /* FTM0 Channel 0 and 1 interrupt*/
|
||||
.long FTM0_Ch2_Ch3_IRQHandler /* FTM0 Channel 2 and 3 interrupt*/
|
||||
.long FTM0_Ch4_Ch5_IRQHandler /* FTM0 Channel 4 and 5 interrupt*/
|
||||
.long FTM0_Ch6_Ch7_IRQHandler /* FTM0 Channel 6 and 7 interrupt*/
|
||||
.long FTM0_Fault_IRQHandler /* FTM0 Fault interrupt*/
|
||||
.long FTM0_Ovf_Reload_IRQHandler /* FTM0 Counter overflow and Reload interrupt*/
|
||||
.long FTM1_Ch0_Ch1_IRQHandler /* FTM1 Channel 0 and 1 interrupt*/
|
||||
.long FTM1_Ch2_Ch3_IRQHandler /* FTM1 Channel 2 and 3 interrupt*/
|
||||
.long FTM1_Ch4_Ch5_IRQHandler /* FTM1 Channel 4 and 5 interrupt*/
|
||||
.long FTM1_Ch6_Ch7_IRQHandler /* FTM1 Channel 6 and 7 interrupt*/
|
||||
.long FTM1_Fault_IRQHandler /* FTM1 Fault interrupt*/
|
||||
.long FTM1_Ovf_Reload_IRQHandler /* FTM1 Counter overflow and Reload interrupt*/
|
||||
.long FTM2_Ch0_Ch1_IRQHandler /* FTM2 Channel 0 and 1 interrupt*/
|
||||
.long FTM2_Ch2_Ch3_IRQHandler /* FTM2 Channel 2 and 3 interrupt*/
|
||||
.long FTM2_Ch4_Ch5_IRQHandler /* FTM2 Channel 4 and 5 interrupt*/
|
||||
.long FTM2_Ch6_Ch7_IRQHandler /* FTM2 Channel 6 and 7 interrupt*/
|
||||
.long FTM2_Fault_IRQHandler /* FTM2 Fault interrupt*/
|
||||
.long FTM2_Ovf_Reload_IRQHandler /* FTM2 Counter overflow and Reload interrupt*/
|
||||
.long FTM3_Ch0_Ch1_IRQHandler /* FTM3 Channel 0 and 1 interrupt*/
|
||||
.long FTM3_Ch2_Ch3_IRQHandler /* FTM3 Channel 2 and 3 interrupt*/
|
||||
.long FTM3_Ch4_Ch5_IRQHandler /* FTM3 Channel 4 and 5 interrupt*/
|
||||
.long FTM3_Ch6_Ch7_IRQHandler /* FTM3 Channel 6 and 7 interrupt*/
|
||||
.long FTM3_Fault_IRQHandler /* FTM3 Fault interrupt*/
|
||||
.long FTM3_Ovf_Reload_IRQHandler /* FTM3 Counter overflow and Reload interrupt*/
|
||||
.long DefaultISR /* 139*/
|
||||
.long DefaultISR /* 140*/
|
||||
.long DefaultISR /* 141*/
|
||||
.long DefaultISR /* 142*/
|
||||
.long DefaultISR /* 143*/
|
||||
.long DefaultISR /* 144*/
|
||||
.long DefaultISR /* 145*/
|
||||
.long DefaultISR /* 146*/
|
||||
.long DefaultISR /* 147*/
|
||||
.long DefaultISR /* 148*/
|
||||
.long DefaultISR /* 149*/
|
||||
.long DefaultISR /* 150*/
|
||||
.long DefaultISR /* 151*/
|
||||
.long DefaultISR /* 152*/
|
||||
.long DefaultISR /* 153*/
|
||||
.long DefaultISR /* 154*/
|
||||
.long DefaultISR /* 155*/
|
||||
.long DefaultISR /* 156*/
|
||||
.long DefaultISR /* 157*/
|
||||
.long DefaultISR /* 158*/
|
||||
.long DefaultISR /* 159*/
|
||||
.long DefaultISR /* 160*/
|
||||
.long DefaultISR /* 161*/
|
||||
.long DefaultISR /* 162*/
|
||||
.long DefaultISR /* 163*/
|
||||
.long DefaultISR /* 164*/
|
||||
.long DefaultISR /* 165*/
|
||||
.long DefaultISR /* 166*/
|
||||
.long DefaultISR /* 167*/
|
||||
.long DefaultISR /* 168*/
|
||||
.long DefaultISR /* 169*/
|
||||
.long DefaultISR /* 170*/
|
||||
.long DefaultISR /* 171*/
|
||||
.long DefaultISR /* 172*/
|
||||
.long DefaultISR /* 173*/
|
||||
.long DefaultISR /* 174*/
|
||||
.long DefaultISR /* 175*/
|
||||
.long DefaultISR /* 176*/
|
||||
.long DefaultISR /* 177*/
|
||||
.long DefaultISR /* 178*/
|
||||
.long DefaultISR /* 179*/
|
||||
.long DefaultISR /* 180*/
|
||||
.long DefaultISR /* 181*/
|
||||
.long DefaultISR /* 182*/
|
||||
.long DefaultISR /* 183*/
|
||||
.long DefaultISR /* 184*/
|
||||
.long DefaultISR /* 185*/
|
||||
.long DefaultISR /* 186*/
|
||||
.long DefaultISR /* 187*/
|
||||
.long DefaultISR /* 188*/
|
||||
.long DefaultISR /* 189*/
|
||||
.long DefaultISR /* 190*/
|
||||
.long DefaultISR /* 191*/
|
||||
.long DefaultISR /* 192*/
|
||||
.long DefaultISR /* 193*/
|
||||
.long DefaultISR /* 194*/
|
||||
.long DefaultISR /* 195*/
|
||||
.long DefaultISR /* 196*/
|
||||
.long DefaultISR /* 197*/
|
||||
.long DefaultISR /* 198*/
|
||||
.long DefaultISR /* 199*/
|
||||
.long DefaultISR /* 200*/
|
||||
.long DefaultISR /* 201*/
|
||||
.long DefaultISR /* 202*/
|
||||
.long DefaultISR /* 203*/
|
||||
.long DefaultISR /* 204*/
|
||||
.long DefaultISR /* 205*/
|
||||
.long DefaultISR /* 206*/
|
||||
.long DefaultISR /* 207*/
|
||||
.long DefaultISR /* 208*/
|
||||
.long DefaultISR /* 209*/
|
||||
.long DefaultISR /* 210*/
|
||||
.long DefaultISR /* 211*/
|
||||
.long DefaultISR /* 212*/
|
||||
.long DefaultISR /* 213*/
|
||||
.long DefaultISR /* 214*/
|
||||
.long DefaultISR /* 215*/
|
||||
.long DefaultISR /* 216*/
|
||||
.long DefaultISR /* 217*/
|
||||
.long DefaultISR /* 218*/
|
||||
.long DefaultISR /* 219*/
|
||||
.long DefaultISR /* 220*/
|
||||
.long DefaultISR /* 221*/
|
||||
.long DefaultISR /* 222*/
|
||||
.long DefaultISR /* 223*/
|
||||
.long DefaultISR /* 224*/
|
||||
.long DefaultISR /* 225*/
|
||||
.long DefaultISR /* 226*/
|
||||
.long DefaultISR /* 227*/
|
||||
.long DefaultISR /* 228*/
|
||||
.long DefaultISR /* 229*/
|
||||
.long DefaultISR /* 230*/
|
||||
.long DefaultISR /* 231*/
|
||||
.long DefaultISR /* 232*/
|
||||
.long DefaultISR /* 233*/
|
||||
.long DefaultISR /* 234*/
|
||||
.long DefaultISR /* 235*/
|
||||
.long DefaultISR /* 236*/
|
||||
.long DefaultISR /* 237*/
|
||||
.long DefaultISR /* 238*/
|
||||
.long DefaultISR /* 239*/
|
||||
.long DefaultISR /* 240*/
|
||||
.long DefaultISR /* 241*/
|
||||
.long DefaultISR /* 242*/
|
||||
.long DefaultISR /* 243*/
|
||||
.long DefaultISR /* 244*/
|
||||
.long DefaultISR /* 245*/
|
||||
.long DefaultISR /* 246*/
|
||||
.long DefaultISR /* 247*/
|
||||
.long DefaultISR /* 248*/
|
||||
.long DefaultISR /* 249*/
|
||||
.long DefaultISR /* 250*/
|
||||
.long DefaultISR /* 251*/
|
||||
.long DefaultISR /* 252*/
|
||||
.long DefaultISR /* 253*/
|
||||
.long 0x55AA11EE /* 254 - Reserved for OpenBLT checksum*/
|
||||
.long 0xFFFFFFFF /* Reserved for user TRIM value*/
|
||||
|
||||
.size __isr_vector, . - __isr_vector
|
||||
|
||||
/* Flash Configuration */
|
||||
.section .FlashConfig, "a"
|
||||
.long 0xFFFFFFFF /* 8 bytes backdoor comparison key */
|
||||
.long 0xFFFFFFFF /* */
|
||||
.long 0xFFFFFFFF /* 4 bytes program flash protection bytes */
|
||||
.long 0xFFFF7FFE /* FDPROT:FEPROT:FOPT:FSEC(0xFE = unsecured) */
|
||||
|
||||
.text
|
||||
.thumb
|
||||
|
||||
/* Reset Handler */
|
||||
|
||||
.thumb_func
|
||||
.align 2
|
||||
.globl Reset_Handler
|
||||
.weak Reset_Handler
|
||||
.type Reset_Handler, %function
|
||||
Reset_Handler:
|
||||
cpsid i /* Mask interrupts */
|
||||
|
||||
/* Init the rest of the registers */
|
||||
ldr r1,=0
|
||||
ldr r2,=0
|
||||
ldr r3,=0
|
||||
ldr r4,=0
|
||||
ldr r5,=0
|
||||
ldr r6,=0
|
||||
ldr r7,=0
|
||||
mov r8,r7
|
||||
mov r9,r7
|
||||
mov r10,r7
|
||||
mov r11,r7
|
||||
mov r12,r7
|
||||
|
||||
#ifdef START_FROM_FLASH
|
||||
|
||||
/* Init ECC RAM */
|
||||
|
||||
ldr r1, =__RAM_START
|
||||
ldr r2, =__RAM_END
|
||||
|
||||
subs r2, r1
|
||||
subs r2, #1
|
||||
ble .LC5
|
||||
|
||||
movs r0, 0
|
||||
movs r3, #4
|
||||
.LC4:
|
||||
str r0, [r1]
|
||||
add r1, r1, r3
|
||||
subs r2, 4
|
||||
bge .LC4
|
||||
.LC5:
|
||||
#endif
|
||||
|
||||
/* Initialize the stack pointer */
|
||||
ldr r0,=__StackTop
|
||||
mov r13,r0
|
||||
|
||||
#ifndef __NO_SYSTEM_INIT
|
||||
/* Call the system init routine */
|
||||
ldr r0,=SystemInit
|
||||
blx r0
|
||||
#endif
|
||||
|
||||
/* Init .data and .bss sections */
|
||||
ldr r0,=init_data_bss
|
||||
blx r0
|
||||
cpsie i /* Unmask interrupts */
|
||||
|
||||
#ifndef __START
|
||||
#ifdef __EWL__
|
||||
#define __START __thumb_startup
|
||||
#else
|
||||
#define __START _start
|
||||
#endif
|
||||
#endif
|
||||
bl __START
|
||||
|
||||
JumpToSelf:
|
||||
b JumpToSelf
|
||||
|
||||
.pool
|
||||
.size Reset_Handler, . - Reset_Handler
|
||||
|
||||
.align 1
|
||||
.thumb_func
|
||||
.weak DefaultISR
|
||||
.type DefaultISR, %function
|
||||
DefaultISR:
|
||||
b DefaultISR
|
||||
.size DefaultISR, . - DefaultISR
|
||||
|
||||
/* Macro to define default handlers. Default handler
|
||||
* will be weak symbol and just dead loops. They can be
|
||||
* overwritten by other handlers */
|
||||
.macro def_irq_handler handler_name
|
||||
.weak \handler_name
|
||||
.set \handler_name, DefaultISR
|
||||
.endm
|
||||
|
||||
/* Exception Handlers */
|
||||
def_irq_handler NMI_Handler
|
||||
def_irq_handler HardFault_Handler
|
||||
def_irq_handler MemManage_Handler
|
||||
def_irq_handler BusFault_Handler
|
||||
def_irq_handler UsageFault_Handler
|
||||
def_irq_handler SVC_Handler
|
||||
def_irq_handler DebugMon_Handler
|
||||
def_irq_handler PendSV_Handler
|
||||
def_irq_handler SysTick_Handler
|
||||
def_irq_handler DMA0_IRQHandler
|
||||
def_irq_handler DMA1_IRQHandler
|
||||
def_irq_handler DMA2_IRQHandler
|
||||
def_irq_handler DMA3_IRQHandler
|
||||
def_irq_handler DMA4_IRQHandler
|
||||
def_irq_handler DMA5_IRQHandler
|
||||
def_irq_handler DMA6_IRQHandler
|
||||
def_irq_handler DMA7_IRQHandler
|
||||
def_irq_handler DMA8_IRQHandler
|
||||
def_irq_handler DMA9_IRQHandler
|
||||
def_irq_handler DMA10_IRQHandler
|
||||
def_irq_handler DMA11_IRQHandler
|
||||
def_irq_handler DMA12_IRQHandler
|
||||
def_irq_handler DMA13_IRQHandler
|
||||
def_irq_handler DMA14_IRQHandler
|
||||
def_irq_handler DMA15_IRQHandler
|
||||
def_irq_handler DMA_Error_IRQHandler
|
||||
def_irq_handler MCM_IRQHandler
|
||||
def_irq_handler FTFC_IRQHandler
|
||||
def_irq_handler Read_Collision_IRQHandler
|
||||
def_irq_handler LVD_LVW_IRQHandler
|
||||
def_irq_handler FTFC_Fault_IRQHandler
|
||||
def_irq_handler WDOG_EWM_IRQHandler
|
||||
def_irq_handler RCM_IRQHandler
|
||||
def_irq_handler LPI2C0_Master_IRQHandler
|
||||
def_irq_handler LPI2C0_Slave_IRQHandler
|
||||
def_irq_handler LPSPI0_IRQHandler
|
||||
def_irq_handler LPSPI1_IRQHandler
|
||||
def_irq_handler LPSPI2_IRQHandler
|
||||
def_irq_handler Reserved45_IRQHandler
|
||||
def_irq_handler Reserved46_IRQHandler
|
||||
def_irq_handler LPUART0_RxTx_IRQHandler
|
||||
def_irq_handler Reserved48_IRQHandler
|
||||
def_irq_handler LPUART1_RxTx_IRQHandler
|
||||
def_irq_handler Reserved50_IRQHandler
|
||||
def_irq_handler LPUART2_RxTx_IRQHandler
|
||||
def_irq_handler Reserved52_IRQHandler
|
||||
def_irq_handler Reserved53_IRQHandler
|
||||
def_irq_handler Reserved54_IRQHandler
|
||||
def_irq_handler ADC0_IRQHandler
|
||||
def_irq_handler ADC1_IRQHandler
|
||||
def_irq_handler CMP0_IRQHandler
|
||||
def_irq_handler Reserved58_IRQHandler
|
||||
def_irq_handler Reserved59_IRQHandler
|
||||
def_irq_handler ERM_single_fault_IRQHandler
|
||||
def_irq_handler ERM_double_fault_IRQHandler
|
||||
def_irq_handler RTC_IRQHandler
|
||||
def_irq_handler RTC_Seconds_IRQHandler
|
||||
def_irq_handler LPIT0_Ch0_IRQHandler
|
||||
def_irq_handler LPIT0_Ch1_IRQHandler
|
||||
def_irq_handler LPIT0_Ch2_IRQHandler
|
||||
def_irq_handler LPIT0_Ch3_IRQHandler
|
||||
def_irq_handler PDB0_IRQHandler
|
||||
def_irq_handler Reserved69_IRQHandler
|
||||
def_irq_handler Reserved70_IRQHandler
|
||||
def_irq_handler Reserved71_IRQHandler
|
||||
def_irq_handler Reserved72_IRQHandler
|
||||
def_irq_handler SCG_IRQHandler
|
||||
def_irq_handler LPTMR0_IRQHandler
|
||||
def_irq_handler PORTA_IRQHandler
|
||||
def_irq_handler PORTB_IRQHandler
|
||||
def_irq_handler PORTC_IRQHandler
|
||||
def_irq_handler PORTD_IRQHandler
|
||||
def_irq_handler PORTE_IRQHandler
|
||||
def_irq_handler SWI_IRQHandler
|
||||
def_irq_handler Reserved81_IRQHandler
|
||||
def_irq_handler Reserved82_IRQHandler
|
||||
def_irq_handler Reserved83_IRQHandler
|
||||
def_irq_handler PDB1_IRQHandler
|
||||
def_irq_handler FLEXIO_IRQHandler
|
||||
def_irq_handler Reserved86_IRQHandler
|
||||
def_irq_handler Reserved87_IRQHandler
|
||||
def_irq_handler Reserved88_IRQHandler
|
||||
def_irq_handler Reserved89_IRQHandler
|
||||
def_irq_handler Reserved90_IRQHandler
|
||||
def_irq_handler Reserved91_IRQHandler
|
||||
def_irq_handler Reserved92_IRQHandler
|
||||
def_irq_handler Reserved93_IRQHandler
|
||||
def_irq_handler CAN0_ORed_IRQHandler
|
||||
def_irq_handler CAN0_Error_IRQHandler
|
||||
def_irq_handler CAN0_Wake_Up_IRQHandler
|
||||
def_irq_handler CAN0_ORed_0_15_MB_IRQHandler
|
||||
def_irq_handler CAN0_ORed_16_31_MB_IRQHandler
|
||||
def_irq_handler Reserved99_IRQHandler
|
||||
def_irq_handler Reserved100_IRQHandler
|
||||
def_irq_handler CAN1_ORed_IRQHandler
|
||||
def_irq_handler CAN1_Error_IRQHandler
|
||||
def_irq_handler Reserved103_IRQHandler
|
||||
def_irq_handler CAN1_ORed_0_15_MB_IRQHandler
|
||||
def_irq_handler Reserved105_IRQHandler
|
||||
def_irq_handler Reserved106_IRQHandler
|
||||
def_irq_handler Reserved107_IRQHandler
|
||||
def_irq_handler CAN2_ORed_IRQHandler
|
||||
def_irq_handler CAN2_Error_IRQHandler
|
||||
def_irq_handler Reserved110_IRQHandler
|
||||
def_irq_handler CAN2_ORed_0_15_MB_IRQHandler
|
||||
def_irq_handler Reserved112_IRQHandler
|
||||
def_irq_handler Reserved113_IRQHandler
|
||||
def_irq_handler Reserved114_IRQHandler
|
||||
def_irq_handler FTM0_Ch0_Ch1_IRQHandler
|
||||
def_irq_handler FTM0_Ch2_Ch3_IRQHandler
|
||||
def_irq_handler FTM0_Ch4_Ch5_IRQHandler
|
||||
def_irq_handler FTM0_Ch6_Ch7_IRQHandler
|
||||
def_irq_handler FTM0_Fault_IRQHandler
|
||||
def_irq_handler FTM0_Ovf_Reload_IRQHandler
|
||||
def_irq_handler FTM1_Ch0_Ch1_IRQHandler
|
||||
def_irq_handler FTM1_Ch2_Ch3_IRQHandler
|
||||
def_irq_handler FTM1_Ch4_Ch5_IRQHandler
|
||||
def_irq_handler FTM1_Ch6_Ch7_IRQHandler
|
||||
def_irq_handler FTM1_Fault_IRQHandler
|
||||
def_irq_handler FTM1_Ovf_Reload_IRQHandler
|
||||
def_irq_handler FTM2_Ch0_Ch1_IRQHandler
|
||||
def_irq_handler FTM2_Ch2_Ch3_IRQHandler
|
||||
def_irq_handler FTM2_Ch4_Ch5_IRQHandler
|
||||
def_irq_handler FTM2_Ch6_Ch7_IRQHandler
|
||||
def_irq_handler FTM2_Fault_IRQHandler
|
||||
def_irq_handler FTM2_Ovf_Reload_IRQHandler
|
||||
def_irq_handler FTM3_Ch0_Ch1_IRQHandler
|
||||
def_irq_handler FTM3_Ch2_Ch3_IRQHandler
|
||||
def_irq_handler FTM3_Ch4_Ch5_IRQHandler
|
||||
def_irq_handler FTM3_Ch6_Ch7_IRQHandler
|
||||
def_irq_handler FTM3_Fault_IRQHandler
|
||||
def_irq_handler FTM3_Ovf_Reload_IRQHandler
|
||||
|
||||
.end
|
|
@ -0,0 +1,88 @@
|
|||
/************************************************************************************//**
|
||||
* \file Demo/ARMCM4_S32K14_S32K144EVB_GCC/Prog/timer.c
|
||||
* \brief Timer driver source file.
|
||||
* \ingroup Prog_ARMCM4_S32K14_S32K144EVB_GCC
|
||||
* \internal
|
||||
*----------------------------------------------------------------------------------------
|
||||
* C O P Y R I G H T
|
||||
*----------------------------------------------------------------------------------------
|
||||
* Copyright (c) 2020 by Feaser http://www.feaser.com All rights reserved
|
||||
*
|
||||
*----------------------------------------------------------------------------------------
|
||||
* L I C E N S E
|
||||
*----------------------------------------------------------------------------------------
|
||||
* This file is part of OpenBLT. OpenBLT is free software: you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as published by the Free
|
||||
* Software Foundation, either version 3 of the License, or (at your option) any later
|
||||
* version.
|
||||
*
|
||||
* OpenBLT is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
|
||||
* without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
|
||||
* PURPOSE. See the GNU General Public License for more details.
|
||||
*
|
||||
* You have received a copy of the GNU General Public License along with OpenBLT. It
|
||||
* should be located in ".\Doc\license.html". If not, contact Feaser to obtain a copy.
|
||||
*
|
||||
* \endinternal
|
||||
****************************************************************************************/
|
||||
|
||||
/****************************************************************************************
|
||||
* Include files
|
||||
****************************************************************************************/
|
||||
#include "header.h" /* generic header */
|
||||
|
||||
|
||||
/****************************************************************************************
|
||||
* Local data declarations
|
||||
****************************************************************************************/
|
||||
/** \brief Local variable for storing the number of milliseconds that have elapsed since
|
||||
* startup.
|
||||
*/
|
||||
static unsigned long millisecond_counter;
|
||||
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief Initializes the timer.
|
||||
** \return none.
|
||||
**
|
||||
****************************************************************************************/
|
||||
void TimerInit(void)
|
||||
{
|
||||
/* Configure the systick frequency as a 1 ms event generator. */
|
||||
S32_SysTick->RVR = (SystemCoreClock / 1000U) - 1U;
|
||||
/* Reset the current counter value. */
|
||||
S32_SysTick->CVR = 0U;
|
||||
/* Select core clock as source and enable the timer. */
|
||||
S32_SysTick->CSR = S32_SysTick_CSR_ENABLE_MASK |
|
||||
S32_SysTick_CSR_TICKINT_MASK |
|
||||
S32_SysTick_CSR_CLKSOURCE_MASK;
|
||||
/* Reset the millisecond counter value. */
|
||||
millisecond_counter = 0U;
|
||||
} /*** end of TimerInit ***/
|
||||
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief Obtains the counter value of the millisecond timer.
|
||||
** \return Current value of the millisecond timer.
|
||||
**
|
||||
****************************************************************************************/
|
||||
unsigned long TimerGet(void)
|
||||
{
|
||||
/* Read and return the tick counter value. */
|
||||
return millisecond_counter;
|
||||
} /*** end of TimerGet ***/
|
||||
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief Interrupt service routine of the timer.
|
||||
** \return none.
|
||||
**
|
||||
****************************************************************************************/
|
||||
void SysTick_Handler(void)
|
||||
{
|
||||
/* Increment the millisecond counter. */
|
||||
millisecond_counter++;
|
||||
} /*** end of SysTick_Handler ***/
|
||||
|
||||
|
||||
/*********************************** end of timer.c ************************************/
|
|
@ -0,0 +1,38 @@
|
|||
/************************************************************************************//**
|
||||
* \file Demo/ARMCM4_S32K14_S32K144EVB_GCC/Prog/timer.h
|
||||
* \brief Timer driver header file.
|
||||
* \ingroup Prog_ARMCM4_S32K14_S32K144EVB_GCC
|
||||
* \internal
|
||||
*----------------------------------------------------------------------------------------
|
||||
* C O P Y R I G H T
|
||||
*----------------------------------------------------------------------------------------
|
||||
* Copyright (c) 2020 by Feaser http://www.feaser.com All rights reserved
|
||||
*
|
||||
*----------------------------------------------------------------------------------------
|
||||
* L I C E N S E
|
||||
*----------------------------------------------------------------------------------------
|
||||
* This file is part of OpenBLT. OpenBLT is free software: you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as published by the Free
|
||||
* Software Foundation, either version 3 of the License, or (at your option) any later
|
||||
* version.
|
||||
*
|
||||
* OpenBLT is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
|
||||
* without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
|
||||
* PURPOSE. See the GNU General Public License for more details.
|
||||
*
|
||||
* You have received a copy of the GNU General Public License along with OpenBLT. It
|
||||
* should be located in ".\Doc\license.html". If not, contact Feaser to obtain a copy.
|
||||
*
|
||||
* \endinternal
|
||||
****************************************************************************************/
|
||||
#ifndef TIMER_H
|
||||
#define TIMER_H
|
||||
|
||||
/****************************************************************************************
|
||||
* Function prototypes
|
||||
****************************************************************************************/
|
||||
void TimerInit(void);
|
||||
unsigned long TimerGet(void);
|
||||
|
||||
#endif /* TIMER_H */
|
||||
/*********************************** end of timer.h ************************************/
|
|
@ -0,0 +1,8 @@
|
|||
/**
|
||||
\defgroup ARMCM4_S32K14_S32K144EVB_GCC Demo for S32K144EVB/GCC
|
||||
\ingroup Demos
|
||||
\brief Preconfigured programs for the NXP S32K144EVB board and the S32 Design Studio
|
||||
development environment, which is based on the ARM GCC toolchain.
|
||||
*/
|
||||
|
||||
|
|
@ -198,7 +198,7 @@ static unsigned char Rs232ReceiveByte(unsigned char *data)
|
|||
{
|
||||
unsigned char result = 0;
|
||||
|
||||
/* TODO ##Port Check if a new byte was received on the configured channel. This is
|
||||
/* TODO ##Prog Check if a new byte was received on the configured channel. This is
|
||||
* typically done by checking the reception register not empty flag. If a new byte
|
||||
* was received, read it out and store it in '*data'. Next, clear the reception flag
|
||||
* such that a new byte can be received again. Finally, set 'result' to 1 to indicate
|
||||
|
|
|
@ -0,0 +1,59 @@
|
|||
/************************************************************************************//**
|
||||
* \file Source/ARMCM4_S32K14/GCC/cpu_comp.c
|
||||
* \brief Bootloader cpu module source file.
|
||||
* \ingroup Target_ARMCM4_S32K14
|
||||
* \internal
|
||||
*----------------------------------------------------------------------------------------
|
||||
* C O P Y R I G H T
|
||||
*----------------------------------------------------------------------------------------
|
||||
* Copyright (c) 2020 by Feaser http://www.feaser.com All rights reserved
|
||||
*
|
||||
*----------------------------------------------------------------------------------------
|
||||
* L I C E N S E
|
||||
*----------------------------------------------------------------------------------------
|
||||
* This file is part of OpenBLT. OpenBLT is free software: you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as published by the Free
|
||||
* Software Foundation, either version 3 of the License, or (at your option) any later
|
||||
* version.
|
||||
*
|
||||
* OpenBLT is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
|
||||
* without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
|
||||
* PURPOSE. See the GNU General Public License for more details.
|
||||
*
|
||||
* You have received a copy of the GNU General Public License along with OpenBLT. It
|
||||
* should be located in ".\Doc\license.html". If not, contact Feaser to obtain a copy.
|
||||
*
|
||||
* \endinternal
|
||||
****************************************************************************************/
|
||||
|
||||
/****************************************************************************************
|
||||
* Include files
|
||||
****************************************************************************************/
|
||||
#include "boot.h" /* bootloader generic header */
|
||||
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief Disable global interrupts.
|
||||
** \return none.
|
||||
**
|
||||
****************************************************************************************/
|
||||
void CpuIrqDisable(void)
|
||||
{
|
||||
/* Disable the global interrupts. */
|
||||
__asm volatile ("cpsid i" : : : "memory");
|
||||
} /*** end of CpuIrqDisable ***/
|
||||
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief Enable global interrupts.
|
||||
** \return none.
|
||||
**
|
||||
****************************************************************************************/
|
||||
void CpuIrqEnable(void)
|
||||
{
|
||||
/* Enable the global interrupts. */
|
||||
__asm volatile ("cpsie i" : : : "memory");
|
||||
} /*** end of CpuIrqEnable ***/
|
||||
|
||||
|
||||
/*********************************** end of cpu_comp.c *********************************/
|
|
@ -0,0 +1,616 @@
|
|||
/************************************************************************************//**
|
||||
* \file Source/ARMCM4_S32K14/can.c
|
||||
* \brief Bootloader CAN communication interface source file.
|
||||
* \ingroup Target_ARMCM4_S32K14
|
||||
* \internal
|
||||
*----------------------------------------------------------------------------------------
|
||||
* C O P Y R I G H T
|
||||
*----------------------------------------------------------------------------------------
|
||||
* Copyright (c) 2020 by Feaser http://www.feaser.com All rights reserved
|
||||
*
|
||||
*----------------------------------------------------------------------------------------
|
||||
* L I C E N S E
|
||||
*----------------------------------------------------------------------------------------
|
||||
* This file is part of OpenBLT. OpenBLT is free software: you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as published by the Free
|
||||
* Software Foundation, either version 3 of the License, or (at your option) any later
|
||||
* version.
|
||||
*
|
||||
* OpenBLT is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
|
||||
* without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
|
||||
* PURPOSE. See the GNU General Public License for more details.
|
||||
*
|
||||
* You have received a copy of the GNU General Public License along with OpenBLT. It
|
||||
* should be located in ".\Doc\license.html". If not, contact Feaser to obtain a copy.
|
||||
*
|
||||
* \endinternal
|
||||
****************************************************************************************/
|
||||
|
||||
/****************************************************************************************
|
||||
* Include files
|
||||
****************************************************************************************/
|
||||
#include "boot.h" /* bootloader generic header */
|
||||
#if (BOOT_COM_CAN_ENABLE > 0)
|
||||
#include "device_registers.h" /* device registers */
|
||||
|
||||
|
||||
/****************************************************************************************
|
||||
* Macro definitions
|
||||
****************************************************************************************/
|
||||
/** \brief Timeout for entering/leaving CAN initialization mode in milliseconds. */
|
||||
#define CAN_INIT_TIMEOUT_MS (250U)
|
||||
/** \brief Timeout for transmitting a CAN message in milliseconds. */
|
||||
#define CAN_MSG_TX_TIMEOUT_MS (50U)
|
||||
|
||||
#if (BOOT_COM_CAN_CHANNEL_INDEX == 0)
|
||||
/** \brief Set the peripheral CAN0 base pointer. */
|
||||
#define CANx (CAN0)
|
||||
/** \brief Set the PCC index offset for CAN0. */
|
||||
#define PCC_FlexCANx_INDEX (PCC_FlexCAN0_INDEX)
|
||||
/** \brief Set the number of message boxes supported by CAN0. */
|
||||
#define CANx_MAX_MB_NUM (FEATURE_CAN0_MAX_MB_NUM)
|
||||
#elif (BOOT_COM_CAN_CHANNEL_INDEX == 1)
|
||||
/** \brief Set the peripheral CAN1 base pointer. */
|
||||
#define CANx (CAN1)
|
||||
/** \brief Set the PCC index offset for CAN1. */
|
||||
#define PCC_FlexCANx_INDEX (PCC_FlexCAN1_INDEX)
|
||||
/** \brief Set the number of message boxes supported by CAN1. */
|
||||
#define CANx_MAX_MB_NUM (FEATURE_CAN1_MAX_MB_NUM)
|
||||
#elif (BOOT_COM_CAN_CHANNEL_INDEX == 2)
|
||||
/** \brief Set the peripheral CAN2 base pointer. */
|
||||
#define CANx (CAN2)
|
||||
/** \brief Set the PCC index offset for CAN2. */
|
||||
#define PCC_FlexCANx_INDEX (PCC_FlexCAN2_INDEX)
|
||||
/** \brief Set the number of message boxes supported by CAN2. */
|
||||
#define CANx_MAX_MB_NUM (FEATURE_CAN2_MAX_MB_NUM)
|
||||
#endif
|
||||
|
||||
/** \brief The mailbox used for transmitting the XCP respond message. */
|
||||
#define CAN_TX_MSGBOX_NUM (8U)
|
||||
/** \brief The mailbox used for receiving the XCP command message. */
|
||||
#define CAN_RX_MSGBOX_NUM (9U)
|
||||
|
||||
|
||||
/****************************************************************************************
|
||||
* Type definitions
|
||||
****************************************************************************************/
|
||||
/** \brief Structure type for grouping CAN bus timing related information. */
|
||||
typedef struct t_can_bus_timing
|
||||
{
|
||||
blt_int8u timeQuanta; /**< Total number of time quanta */
|
||||
blt_int8u propSeg; /**< CAN propagation segment */
|
||||
blt_int8u phaseSeg1; /**< CAN phase segment 1 */
|
||||
blt_int8u phaseSeg2; /**< CAN phase segment 2 */
|
||||
} tCanBusTiming;
|
||||
|
||||
|
||||
/****************************************************************************************
|
||||
* Local constant declarations
|
||||
****************************************************************************************/
|
||||
/** \brief CAN bit timing table for dynamically calculating the bittiming settings.
|
||||
* \details According to the CAN protocol 1 bit-time can be made up of between 8..25
|
||||
* time quanta (TQ). The total TQ in a bit is SYNC + TSEG1 + TSEG2 with SYNC
|
||||
* always being 1. The sample point is (SYNC + TSEG1) / (SYNC + TSEG1 + TSEG2)
|
||||
* * 100%. This array contains possible and valid time quanta configurations
|
||||
* with a sample point between 68..78%. A visual representation of the TQ in
|
||||
* a bit is:
|
||||
* | SYNCSEG | TIME1SEG | TIME2SEG |
|
||||
* Or with an alternative representation:
|
||||
* | SYNCSEG | PROPSEG | PHASE1SEG | PHASE2SEG |
|
||||
* With the alternative representation TIME1SEG = PROPSEG + PHASE1SEG.
|
||||
*
|
||||
*/
|
||||
static const tCanBusTiming canTiming[] =
|
||||
{
|
||||
/* Time-Quanta | PROPSEG | PSEG1 | PSEG2 | Sample-Point */
|
||||
/* ---------------------------------------------------- */
|
||||
{ 8U, 3U, 2U, 2U }, /*1+3+2+1=8 | 3 | 2 | 2 | 75% */
|
||||
{ 9U, 3U, 3U, 2U }, /* 9 | 3 | 3 | 2 | 78% */
|
||||
{ 10U, 3U, 3U, 3U }, /* 10 | 3 | 3 | 3 | 70% */
|
||||
{ 11U, 4U, 3U, 3U }, /* 11 | 4 | 3 | 3 | 73% */
|
||||
{ 12U, 4U, 4U, 3U }, /* 12 | 4 | 4 | 3 | 75% */
|
||||
{ 13U, 5U, 4U, 3U }, /* 13 | 5 | 4 | 3 | 77% */
|
||||
{ 14U, 5U, 4U, 4U }, /* 14 | 5 | 4 | 4 | 71% */
|
||||
{ 15U, 6U, 4U, 4U }, /* 15 | 6 | 4 | 4 | 73% */
|
||||
{ 16U, 6U, 5U, 4U }, /* 16 | 6 | 5 | 4 | 75% */
|
||||
{ 17U, 7U, 5U, 4U }, /* 17 | 7 | 5 | 4 | 76% */
|
||||
{ 18U, 7U, 5U, 5U }, /* 18 | 7 | 5 | 5 | 72% */
|
||||
{ 19U, 8U, 5U, 5U }, /* 19 | 8 | 5 | 5 | 74% */
|
||||
{ 20U, 8U, 6U, 5U }, /* 20 | 8 | 6 | 5 | 75% */
|
||||
{ 21U, 8U, 7U, 5U }, /* 21 | 8 | 7 | 5 | 76% */
|
||||
{ 22U, 8U, 7U, 6U }, /* 22 | 8 | 7 | 6 | 73% */
|
||||
{ 23U, 8U, 8U, 6U }, /* 23 | 8 | 8 | 6 | 74% */
|
||||
{ 24U, 8U, 8U, 7U }, /* 24 | 8 | 8 | 7 | 71% */
|
||||
{ 25U, 8U, 8U, 8U } /* 25 | 8 | 8 | 8 | 68% */
|
||||
};
|
||||
|
||||
|
||||
/****************************************************************************************
|
||||
* Local data declarations
|
||||
****************************************************************************************/
|
||||
/** \brief Dummy variable to store the CAN controller's free running timer value in.
|
||||
* This is needed at the end of a CAN message reception to unlock the mailbox
|
||||
* again. If this variable is declared locally within the function, it generates
|
||||
* an unwanted compiler warning about assigning a value and not using it.
|
||||
* For this reason this dummy variabled is declare here as a module global.
|
||||
*/
|
||||
static volatile blt_int32u dummyTimerVal;
|
||||
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief Search algorithm to match the desired baudrate to a possible bus
|
||||
** timing configuration.
|
||||
** \param baud The desired baudrate in kbps. Valid values are 10..1000.
|
||||
** \param prescaler Pointer to where the value for the prescaler will be stored.
|
||||
** \param busTimingCfg Pointer to where the bus timing values will be stored.
|
||||
** \return BLT_TRUE if the CAN bustiming register values were found, BLT_FALSE
|
||||
** otherwise.
|
||||
**
|
||||
****************************************************************************************/
|
||||
static blt_bool CanGetSpeedConfig(blt_int16u baud, blt_int16u * prescaler,
|
||||
tCanBusTiming * busTimingCfg)
|
||||
{
|
||||
blt_int8u cnt;
|
||||
blt_int32u canClockFreqkHz;
|
||||
blt_int32u div2RegValue;
|
||||
blt_int8u const div2DividerLookup[] =
|
||||
{
|
||||
0U, /* 0b000. Output disabled. */
|
||||
1U, /* 0b001. Divide by 1. */
|
||||
2U, /* 0b010. Divide by 2. */
|
||||
4U, /* 0b011. Divide by 4. */
|
||||
8U, /* 0b100. Divide by 8. */
|
||||
16U, /* 0b101. Divide by 16. */
|
||||
32U, /* 0b110. Divide by 32. */
|
||||
64U, /* 0b111. Divide by 64. */
|
||||
};
|
||||
|
||||
/* Obtain the DIV2 divider value of the SOSC_CLK. */
|
||||
div2RegValue = (SCG->SOSCDIV & SCG_SOSCDIV_SOSCDIV2_MASK) >> SCG_SOSCDIV_SOSCDIV2_SHIFT;
|
||||
/* Check if the DIV2 register value for SOSC is 0. In this case SOSCDIV2_CLK is
|
||||
* currently disabled.
|
||||
*/
|
||||
if (div2RegValue == 0U)
|
||||
{
|
||||
/* Configure the DIV2 for a default divide by 1 to make sure the SOSCDIV2_CLK is
|
||||
* actually enabled.
|
||||
*/
|
||||
div2RegValue = 1U;
|
||||
SCG->SOSCDIV = SCG_SOSCDIV_SOSCDIV2(div2RegValue);
|
||||
}
|
||||
/* Determine the SOSC clock frequency. */
|
||||
canClockFreqkHz = BOOT_CPU_XTAL_SPEED_KHZ;
|
||||
/* Now process the configured DIV2 divider factor to get the actual frequency of the
|
||||
* CAN peripheral source clock.
|
||||
*/
|
||||
canClockFreqkHz /= div2DividerLookup[div2RegValue];
|
||||
|
||||
/* Loop through all possible time quanta configurations to find a match. */
|
||||
for (cnt=0; cnt < sizeof(canTiming)/sizeof(canTiming[0]); cnt++)
|
||||
{
|
||||
if ((canClockFreqkHz % (baud * canTiming[cnt].timeQuanta)) == 0U)
|
||||
{
|
||||
/* Compute the prescaler that goes with this TQ configuration. */
|
||||
*prescaler = canClockFreqkHz/(baud * canTiming[cnt].timeQuanta);
|
||||
|
||||
/* Make sure the prescaler is valid. */
|
||||
if ((*prescaler > 0U) && (*prescaler <= 256U))
|
||||
{
|
||||
/* Store the bustiming configuration. */
|
||||
*busTimingCfg = canTiming[cnt];
|
||||
/* Found a good bus timing configuration. */
|
||||
return BLT_TRUE;
|
||||
}
|
||||
}
|
||||
}
|
||||
/* Could not find a good bus timing configuration. */
|
||||
return BLT_FALSE;
|
||||
} /*** end of CanGetSpeedConfig ***/
|
||||
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief Places the CAN controller in freeze mode. Note that the CAN controller
|
||||
** can only be placed in freeze mode, if it is actually enabled.
|
||||
** \return none.
|
||||
**
|
||||
****************************************************************************************/
|
||||
static void CanFreezeModeEnter(void)
|
||||
{
|
||||
blt_int32u timeout;
|
||||
|
||||
/* This function should only be called with the module enabled. */
|
||||
ASSERT_RT((CANx->MCR & CAN_MCR_MDIS_MASK) == 0U);
|
||||
|
||||
/* Request to enter freeze mode. */
|
||||
CANx->MCR = (CANx->MCR & ~CAN_MCR_FRZ_MASK) | CAN_MCR_FRZ(1U);
|
||||
CANx->MCR = (CANx->MCR & ~CAN_MCR_HALT_MASK) | CAN_MCR_HALT(1U);
|
||||
/* Set timeout time for entering freeze mode. */
|
||||
timeout = TimerGet() + CAN_INIT_TIMEOUT_MS;
|
||||
/* Wait for freeze mode acknowledgement. */
|
||||
while (((CANx->MCR & CAN_MCR_FRZACK_MASK)) == 0U)
|
||||
{
|
||||
/* Keep the watchdog happy. */
|
||||
CopService();
|
||||
/* Break loop upon timeout. This would indicate a hardware failure. */
|
||||
if (TimerGet() > timeout)
|
||||
{
|
||||
break;
|
||||
}
|
||||
}
|
||||
} /*** end of CanFreezeModeEnter ***/
|
||||
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief Leaves the CAN controller's freeze mode. Note that this operation can
|
||||
** only be done, if it is actually enabled.
|
||||
** \return none.
|
||||
**
|
||||
****************************************************************************************/
|
||||
static void CanFreezeModeExit(void)
|
||||
{
|
||||
blt_int32u timeout;
|
||||
|
||||
/* This function should only be called with the module enabled. */
|
||||
ASSERT_RT((CANx->MCR & CAN_MCR_MDIS_MASK) == 0U);
|
||||
|
||||
/* Request to leave freeze mode. */
|
||||
CANx->MCR = (CANx->MCR & ~CAN_MCR_FRZ_MASK) | CAN_MCR_FRZ(0U);
|
||||
CANx->MCR = (CANx->MCR & ~CAN_MCR_HALT_MASK) | CAN_MCR_HALT(0U);
|
||||
/* Set timeout time for leaving freeze mode. */
|
||||
timeout = TimerGet() + CAN_INIT_TIMEOUT_MS;
|
||||
/* Wait for non freeze mode acknowledgement. */
|
||||
while (((CANx->MCR & CAN_MCR_FRZACK_MASK)) != 0U)
|
||||
{
|
||||
/* Keep the watchdog happy. */
|
||||
CopService();
|
||||
/* Break loop upon timeout. This would indicate a hardware failure. */
|
||||
if (TimerGet() > timeout)
|
||||
{
|
||||
break;
|
||||
}
|
||||
}
|
||||
} /*** end of CanFreezeModeExit ***/
|
||||
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief Places the CAN controller in disabled mode.
|
||||
** \return none.
|
||||
**
|
||||
****************************************************************************************/
|
||||
static void CanDisabledModeEnter(void)
|
||||
{
|
||||
blt_int32u timeout;
|
||||
|
||||
/* Only continue if the CAN controller is currently enabled. */
|
||||
if ((CANx->MCR & CAN_MCR_MDIS_MASK) == 0U)
|
||||
{
|
||||
/* Request disabled mode. */
|
||||
CANx->MCR = (CANx->MCR & ~CAN_MCR_MDIS_MASK) | CAN_MCR_MDIS(1U);
|
||||
/* Set timeout time for entering disabled mode. */
|
||||
timeout = TimerGet() + CAN_INIT_TIMEOUT_MS;
|
||||
/* Wait for disabled mode acknowledgement. */
|
||||
while (((CANx->MCR & CAN_MCR_LPMACK_MASK)) == 0U)
|
||||
{
|
||||
/* Keep the watchdog happy. */
|
||||
CopService();
|
||||
/* Break loop upon timeout. This would indicate a hardware failure. */
|
||||
if (TimerGet() > timeout)
|
||||
{
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
} /*** end of CanDisabledModeEnter ***/
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief Places the CAN controller in enabled mode.
|
||||
** \return none.
|
||||
**
|
||||
****************************************************************************************/
|
||||
static void CanDisabledModeExit(void)
|
||||
{
|
||||
blt_int32u timeout;
|
||||
|
||||
/* Only continue if the CAN controller is currently disabled. */
|
||||
if ((CANx->MCR & CAN_MCR_MDIS_MASK) != 0U)
|
||||
{
|
||||
/* Request enabled mode. */
|
||||
CANx->MCR = (CANx->MCR & ~CAN_MCR_MDIS_MASK) | CAN_MCR_MDIS(0U);
|
||||
/* Set timeout time for leaving disabled mode. */
|
||||
timeout = TimerGet() + CAN_INIT_TIMEOUT_MS;
|
||||
/* Wait for disabled mode acknowledgement. */
|
||||
while (((CANx->MCR & CAN_MCR_LPMACK_MASK)) != 0U)
|
||||
{
|
||||
/* Keep the watchdog happy. */
|
||||
CopService();
|
||||
/* Break loop upon timeout. This would indicate a hardware failure. */
|
||||
if (TimerGet() > timeout)
|
||||
{
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
} /*** end of CanDisabledModeExit ***/
|
||||
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief Initializes the CAN controller and synchronizes it to the CAN bus.
|
||||
** \return none.
|
||||
**
|
||||
****************************************************************************************/
|
||||
void CanInit(void)
|
||||
{
|
||||
blt_int16u prescaler = 0;
|
||||
tCanBusTiming timingCfg = { 0 };
|
||||
blt_int8u rjw;
|
||||
blt_int16u idx;
|
||||
blt_int32u timeout;
|
||||
blt_int32u rxMsgId = BOOT_COM_CAN_RX_MSG_ID;
|
||||
|
||||
/* Perform compile time assertion to check that the configured CAN channel is actually
|
||||
* supported by this driver.
|
||||
*/
|
||||
ASSERT_CT((BOOT_COM_CAN_CHANNEL_INDEX == 0) ||
|
||||
(BOOT_COM_CAN_CHANNEL_INDEX == 1) ||
|
||||
(BOOT_COM_CAN_CHANNEL_INDEX == 2));
|
||||
|
||||
/* Verify the correct configuration of the transmit and receive mailboxes. */
|
||||
ASSERT_CT(CAN_TX_MSGBOX_NUM < CANx_MAX_MB_NUM);
|
||||
ASSERT_CT(CAN_RX_MSGBOX_NUM < CANx_MAX_MB_NUM);
|
||||
|
||||
/* Enable the CAN peripheral clock. */
|
||||
PCC->PCCn[PCC_FlexCANx_INDEX] |= PCC_PCCn_CGC_MASK;
|
||||
|
||||
/* The source clock needs to be configured first. For this the CAN controller must be
|
||||
* in disabled mode, but that can only be entered after first entering freeze mode,
|
||||
* which in turn can only be in enabled mode. So first enable the module, then goto
|
||||
* freeze mode and finally enter disabled mode.
|
||||
*/
|
||||
CanDisabledModeExit();
|
||||
CanFreezeModeEnter();
|
||||
CanDisabledModeEnter();
|
||||
/* Configure SOSCDIV2 as the source clock. This assumes that an external oscillator
|
||||
* is available, which is typically the case to meet the clock tolerance requirements
|
||||
* of the CAN 2.0B secification.
|
||||
*/
|
||||
CANx->CTRL1 &= ~CAN_CTRL1_CLKSRC_MASK;
|
||||
/* Leave disabled mode. */
|
||||
CanDisabledModeExit();
|
||||
/* Make sure freeze mode is active to be able to initialize the CAN controller. */
|
||||
CanFreezeModeEnter();
|
||||
|
||||
/* Obtain bittiming configuration information. */
|
||||
if (CanGetSpeedConfig(BOOT_COM_CAN_BAUDRATE/1000, &prescaler, &timingCfg) == BLT_FALSE)
|
||||
{
|
||||
/* Incorrect configuration. The specified baudrate is not supported for the given
|
||||
* clock configuration. Verify the following settings in blt_conf.h:
|
||||
* - BOOT_COM_CAN_BAUDRATE
|
||||
* - BOOT_CPU_XTAL_SPEED_KHZ
|
||||
* - BOOT_CPU_SYSTEM_SPEED_KHZ
|
||||
*/
|
||||
ASSERT_RT(BLT_FALSE);
|
||||
}
|
||||
|
||||
/* Reset the current bittiming configuration. */
|
||||
CANx->CTRL1 &= ~(CAN_CTRL1_PRESDIV_MASK | CAN_CTRL1_PROPSEG_MASK |
|
||||
CAN_CTRL1_PSEG1_MASK | CAN_CTRL1_PSEG2_MASK | CAN_CTRL1_RJW_MASK |
|
||||
CAN_CTRL1_SMP_MASK);
|
||||
/* Configure the baudrate prescaler. */
|
||||
CANx->CTRL1 |= CAN_CTRL1_PRESDIV(prescaler - 1U);
|
||||
/* Configure the propagation segment. */
|
||||
CANx->CTRL1 |= CAN_CTRL1_PROPSEG(timingCfg.propSeg - 1U);
|
||||
/* Configure the phase segments. */
|
||||
CANx->CTRL1 |= CAN_CTRL1_PSEG1(timingCfg.phaseSeg1 - 1U);
|
||||
CANx->CTRL1 |= CAN_CTRL1_PSEG2(timingCfg.phaseSeg2 - 1U);
|
||||
/* The resynchronization jump width (RJW) can be 1 - 4 TQ, yet should never be larger
|
||||
* than pseg1. Configure the longest possible value for RJW.
|
||||
*/
|
||||
rjw = (timingCfg.phaseSeg1 < 4) ? timingCfg.phaseSeg1 : 4;
|
||||
CANx->CTRL1 |= CAN_CTRL1_RJW(rjw - 1U);
|
||||
/* All the entries in canTiming[] have a PSEG1 >= 2, so three samples can be used to
|
||||
* determine the value of the received bit, instead of the default one.
|
||||
*/
|
||||
CANx->CTRL1 |= CAN_CTRL1_SMP(1U);
|
||||
|
||||
/* Clear the message box RAM. Each message box covers 4 words (1 word = 32-bits. */
|
||||
for (idx = 0; idx < (CANx_MAX_MB_NUM * 4U); idx++)
|
||||
{
|
||||
CANx->RAMn[idx] = 0U;
|
||||
}
|
||||
/* Clear the reception mask register for each message box. */
|
||||
for (idx = 0; idx < CANx_MAX_MB_NUM; idx++)
|
||||
{
|
||||
CANx->RXIMR[idx] = 0U;
|
||||
}
|
||||
/* Configure the maximum number of message boxes. */
|
||||
CANx->MCR = (CANx->MCR & ~CAN_MCR_MAXMB_MASK) | CAN_MCR_MAXMB(CANx_MAX_MB_NUM - 1U);
|
||||
/* Disable the self reception feature. */
|
||||
CANx->MCR = (CANx->MCR & ~CAN_MCR_SRXDIS_MASK) | CAN_MCR_SRXDIS(1U);
|
||||
|
||||
/* Enable individual reception masking. This disables the legacy support for the
|
||||
* global reception mask and the mailbox 14/15 individual reception mask.
|
||||
*/
|
||||
CANx->MCR = (CANx->MCR & ~CAN_MCR_IRMQ_MASK) | CAN_MCR_IRMQ(1U);
|
||||
/* Disable the reception FIFO. This driver only needs to receive one CAN message
|
||||
* identifier. It is sufficient to use just one dedicated mailbox for this.
|
||||
*/
|
||||
CANx->MCR &= ~CAN_MCR_RFEN_MASK;
|
||||
/* Configure the mask of the invididual message reception mailbox to check all ID bits
|
||||
* and also the IDE bit.
|
||||
*/
|
||||
CANx->RXIMR[CAN_RX_MSGBOX_NUM] = 0x40000000U | 0x1FFFFFFFU;
|
||||
/* Configure the reception mailbox to receive just the CAN message configured with
|
||||
* BOOT_COM_CAN_RX_MSG_ID.
|
||||
* EDL, BRS, ESI=0: CANFD not used.
|
||||
* CODE=0b0100: mailbox set to active and empty.
|
||||
* IDE=0: 11-bit CAN identifier.
|
||||
* SRR, RTR, TIME STAMP=0: not applicable.
|
||||
*/
|
||||
CANx->RAMn[(CAN_RX_MSGBOX_NUM * 4U) + 0U] = 0x04000000;
|
||||
/* Store the message identifier to receive in the mailbox RAM. */
|
||||
if ((rxMsgId & 0x80000000U) != 0U)
|
||||
{
|
||||
/* It is a 29-bit extended CAN identifier. */
|
||||
rxMsgId &= ~0x80000000U;
|
||||
/* Set the IDE bit to configure the message for a 29-bit identifier. */
|
||||
CANx->RAMn[(CAN_RX_MSGBOX_NUM * 4U) + 0U] |= CAN_WMBn_CS_IDE_MASK;
|
||||
/* Store the 29-bit CAN identifier. */
|
||||
CANx->RAMn[(CAN_RX_MSGBOX_NUM * 4U) + 1U] = CAN_WMBn_ID_ID(rxMsgId);
|
||||
}
|
||||
else
|
||||
{
|
||||
/* Store the 11-bit CAN identifier. */
|
||||
CANx->RAMn[(CAN_RX_MSGBOX_NUM * 4U) + 1U] = CAN_WMBn_ID_ID(rxMsgId << 18U);
|
||||
}
|
||||
|
||||
/* Disable all message box interrupts. */
|
||||
CANx->IMASK1 = 0U;
|
||||
/* Clear all mesasge box interrupt flags. */
|
||||
CANx->IFLAG1 = CAN_IMASK1_BUF31TO0M_MASK;
|
||||
/* Clear all error interrupt flags */
|
||||
CANx->ESR1 = CAN_ESR1_ERRINT_MASK | CAN_ESR1_BOFFINT_MASK | CAN_ESR1_RWRNINT_MASK |
|
||||
CAN_ESR1_TWRNINT_MASK | CAN_ESR1_BOFFDONEINT_MASK |
|
||||
CAN_ESR1_ERRINT_FAST_MASK | CAN_ESR1_ERROVR_MASK;
|
||||
|
||||
/* Switch to normal user mode. */
|
||||
CANx->MCR &= ~CAN_MCR_SUPV_MASK;
|
||||
CANx->CTRL1 &= ~(CAN_CTRL1_LOM_MASK | CAN_CTRL1_LPB_MASK);
|
||||
/* Exit freeze mode. */
|
||||
CanFreezeModeExit();
|
||||
/* Set timeout time for entering normal user mode. */
|
||||
timeout = TimerGet() + CAN_INIT_TIMEOUT_MS;
|
||||
/* Wait for normal user mode acknowledgement. */
|
||||
while (((CANx->MCR & CAN_MCR_NOTRDY_MASK)) != 0U)
|
||||
{
|
||||
/* Keep the watchdog happy. */
|
||||
CopService();
|
||||
/* Break loop upon timeout. This would indicate a hardware failure. */
|
||||
if (TimerGet() > timeout)
|
||||
{
|
||||
break;
|
||||
}
|
||||
}
|
||||
} /*** end of CanInit ***/
|
||||
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief Transmits a packet formatted for the communication interface.
|
||||
** \param data Pointer to byte array with data that it to be transmitted.
|
||||
** \param len Number of bytes that are to be transmitted.
|
||||
** \return none.
|
||||
**
|
||||
****************************************************************************************/
|
||||
void CanTransmitPacket(blt_int8u *data, blt_int8u len)
|
||||
{
|
||||
blt_int32u timeout;
|
||||
blt_bool isExtId = BLT_FALSE;
|
||||
blt_int32u txMsgId = BOOT_COM_CAN_TX_MSG_ID;
|
||||
blt_int8u * pMsgBoxData;
|
||||
blt_int8u byteIdx;
|
||||
|
||||
/* Prepare information about the message identifier. */
|
||||
if ((txMsgId & 0x80000000U) != 0U)
|
||||
{
|
||||
/* It is a 29-bit extended CAN identifier. */
|
||||
txMsgId &= ~0x80000000U;
|
||||
isExtId = BLT_TRUE;
|
||||
}
|
||||
|
||||
/* Clear the mailbox interrupt flag by writing a 1 to the corresponding box. */
|
||||
CANx->IFLAG1 = (1U << CAN_TX_MSGBOX_NUM);
|
||||
|
||||
/* Prepare the mailbox RAM for a basic CAN message.
|
||||
* EDL,BRS,ESI=0: CANFD not used.
|
||||
*/
|
||||
CANx->RAMn[(CAN_TX_MSGBOX_NUM * 4U) + 0U] &= ~0xE0000000U;
|
||||
/* Configure SRR, IDE, RTR bits for a standard 11-bit transmit frame. */
|
||||
CANx->RAMn[(CAN_TX_MSGBOX_NUM * 4U) + 0U] &= ~(CAN_WMBn_CS_IDE_MASK |
|
||||
CAN_WMBn_CS_RTR_MASK);
|
||||
CANx->RAMn[(CAN_TX_MSGBOX_NUM * 4U) + 0U] |= CAN_WMBn_CS_SRR_MASK;
|
||||
/* Configure the DLC. */
|
||||
CANx->RAMn[(CAN_TX_MSGBOX_NUM * 4U) + 0U] &= ~CAN_WMBn_CS_DLC_MASK;
|
||||
CANx->RAMn[(CAN_TX_MSGBOX_NUM * 4U) + 0U] |= CAN_WMBn_CS_DLC(len);
|
||||
/* Write the data bytes of the CAN message to the mailbox RAM. */
|
||||
pMsgBoxData = (blt_int8u * )(&CANx->RAMn[(CAN_TX_MSGBOX_NUM * 4U) + 2U]);
|
||||
for (byteIdx = 0; byteIdx < len; byteIdx++)
|
||||
{
|
||||
pMsgBoxData[((byteIdx) & ~3U) + (3U - ((byteIdx) & 3U))] = data[byteIdx];
|
||||
}
|
||||
/* Store the CAN message identifier in the mailbox RAM. */
|
||||
if (isExtId == BLT_FALSE)
|
||||
{
|
||||
/* Store the 11-bit CAN identifier. */
|
||||
CANx->RAMn[(CAN_TX_MSGBOX_NUM * 4U) + 1U] = CAN_WMBn_ID_ID(txMsgId << 18U);
|
||||
}
|
||||
else
|
||||
{
|
||||
/* Set the IDE bit to configure the message for a 29-bit identifier. */
|
||||
CANx->RAMn[(CAN_TX_MSGBOX_NUM * 4U) + 0U] |= CAN_WMBn_CS_IDE_MASK;
|
||||
/* Store the 29-bit CAN identifier. */
|
||||
CANx->RAMn[(CAN_TX_MSGBOX_NUM * 4U) + 1U] = CAN_WMBn_ID_ID(txMsgId);
|
||||
}
|
||||
/* Activate the mailbox to start the transmission by writing 0x0C to the CODE field. */
|
||||
CANx->RAMn[(CAN_TX_MSGBOX_NUM * 4U) + 0U] |= (0x0CU << 24U) & 0x0F000000U;
|
||||
|
||||
/* Determine timeout time for the transmit completion. */
|
||||
timeout = TimerGet() + CAN_MSG_TX_TIMEOUT_MS;
|
||||
/* Poll for completion of the transmit operation. */
|
||||
while ((CANx->IFLAG1 & (1U << CAN_TX_MSGBOX_NUM)) == 0U)
|
||||
{
|
||||
/* Service the watchdog. */
|
||||
CopService();
|
||||
/* Break loop upon timeout. this would indicate a hardware failure or no other
|
||||
* nodes connected to the bus.
|
||||
*/
|
||||
if (TimerGet() > timeout)
|
||||
{
|
||||
break;
|
||||
}
|
||||
}
|
||||
} /*** end of CanTransmitPacket ***/
|
||||
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief Receives a communication interface packet if one is present.
|
||||
** \param data Pointer to byte array where the data is to be stored.
|
||||
** \param len Pointer where the length of the packet is to be stored.
|
||||
** \return BLT_TRUE is a packet was received, BLT_FALSE otherwise.
|
||||
**
|
||||
****************************************************************************************/
|
||||
blt_bool CanReceivePacket(blt_int8u *data, blt_int8u *len)
|
||||
{
|
||||
blt_bool result = BLT_FALSE;
|
||||
blt_int8u * pMsgBoxData;
|
||||
blt_int8u byteIdx;
|
||||
|
||||
/* Check if a message was received in the individual mailbox configured to receive
|
||||
* the BOOT_COM_CAN_RX_MSG_ID message.
|
||||
*/
|
||||
if ((CANx->IFLAG1 & (1U << CAN_RX_MSGBOX_NUM)) != 0U)
|
||||
{
|
||||
/* Note that there is no need to verify the identifier of the CAN message because the
|
||||
* mailbox is configured to only receive the BOOT_COM_CAN_TX_MSG_ID message. Start
|
||||
* by reading out the DLC of the newly received CAN message.
|
||||
*/
|
||||
*len = (CANx->RAMn[(CAN_RX_MSGBOX_NUM * 4U) + 0U] & CAN_WMBn_CS_DLC_MASK) >> CAN_WMBn_CS_DLC_SHIFT;
|
||||
/* Read the data bytes of the CAN message from the mailbox RAM. */
|
||||
pMsgBoxData = (blt_int8u *)(&CANx->RAMn[(CAN_RX_MSGBOX_NUM * 4U) + 2U]);
|
||||
for (byteIdx = 0; byteIdx < *len; byteIdx++)
|
||||
{
|
||||
data[byteIdx] = pMsgBoxData[((byteIdx) & ~3U) + (3U - ((byteIdx) & 3U))];
|
||||
}
|
||||
/* Clear the mailbox interrupt flag by writing a 1 to the corresponding box. */
|
||||
CANx->IFLAG1 = (1U << CAN_RX_MSGBOX_NUM);
|
||||
/* Read the free running timer to unlock the mailbox. */
|
||||
dummyTimerVal = CANx->TIMER;
|
||||
/* Update the result. */
|
||||
result = BLT_TRUE;
|
||||
}
|
||||
|
||||
/* Give the result back to the caller. */
|
||||
return result;
|
||||
} /*** end of CanReceivePacket ***/
|
||||
#endif /* BOOT_COM_CAN_ENABLE > 0 */
|
||||
|
||||
|
||||
/*********************************** end of can.c **************************************/
|
|
@ -0,0 +1,192 @@
|
|||
/************************************************************************************//**
|
||||
* \file Source/ARMCM4_S32K14/cpu.c
|
||||
* \brief Bootloader cpu module source file.
|
||||
* \ingroup Target_ARMCM4_S32K14
|
||||
* \internal
|
||||
*----------------------------------------------------------------------------------------
|
||||
* C O P Y R I G H T
|
||||
*----------------------------------------------------------------------------------------
|
||||
* Copyright (c) 2020 by Feaser http://www.feaser.com All rights reserved
|
||||
*
|
||||
*----------------------------------------------------------------------------------------
|
||||
* L I C E N S E
|
||||
*----------------------------------------------------------------------------------------
|
||||
* This file is part of OpenBLT. OpenBLT is free software: you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as published by the Free
|
||||
* Software Foundation, either version 3 of the License, or (at your option) any later
|
||||
* version.
|
||||
*
|
||||
* OpenBLT is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
|
||||
* without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
|
||||
* PURPOSE. See the GNU General Public License for more details.
|
||||
*
|
||||
* You have received a copy of the GNU General Public License along with OpenBLT. It
|
||||
* should be located in ".\Doc\license.html". If not, contact Feaser to obtain a copy.
|
||||
*
|
||||
* \endinternal
|
||||
****************************************************************************************/
|
||||
|
||||
/****************************************************************************************
|
||||
* Include files
|
||||
****************************************************************************************/
|
||||
#include "boot.h" /* bootloader generic header */
|
||||
#include "device_registers.h" /* device registers */
|
||||
|
||||
|
||||
/****************************************************************************************
|
||||
* Macro definitions
|
||||
****************************************************************************************/
|
||||
/** \brief Pointer to the user program's reset vector. */
|
||||
#define CPU_USER_PROGRAM_STARTADDR_PTR ((blt_addr)(NvmGetUserProgBaseAddress() + 0x00000004))
|
||||
/** \brief Pointer to the user program's vector table. */
|
||||
#define CPU_USER_PROGRAM_VECTABLE_OFFSET ((blt_addr)NvmGetUserProgBaseAddress())
|
||||
|
||||
|
||||
/****************************************************************************************
|
||||
* Hook functions
|
||||
****************************************************************************************/
|
||||
#if (BOOT_CPU_USER_PROGRAM_START_HOOK > 0)
|
||||
extern blt_bool CpuUserProgramStartHook(void);
|
||||
#endif
|
||||
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief Initializes the CPU module.
|
||||
** \return none.
|
||||
**
|
||||
****************************************************************************************/
|
||||
void CpuInit(void)
|
||||
{
|
||||
/* bootloader runs in polling mode so disable the global interrupts. this is done for
|
||||
* safety reasons. if the bootloader was started from a running user program, it could
|
||||
* be that the user program did not properly disable the interrupt generation of
|
||||
* peripherals. */
|
||||
CpuIrqDisable();
|
||||
} /*** end of CpuInit ***/
|
||||
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief Starts the user program, if one is present. In this case this function
|
||||
** does not return.
|
||||
** \return none.
|
||||
**
|
||||
****************************************************************************************/
|
||||
void CpuStartUserProgram(void)
|
||||
{
|
||||
void (*pProgResetHandler)(void);
|
||||
|
||||
/* check if a user program is present by verifying the checksum */
|
||||
if (NvmVerifyChecksum() == BLT_FALSE)
|
||||
{
|
||||
#if (BOOT_COM_DEFERRED_INIT_ENABLE > 0) && (BOOT_COM_ENABLE > 0)
|
||||
/* bootloader will stay active so perform deferred initialization to make sure
|
||||
* the communication interface that were not yet initialized are now initialized.
|
||||
* this is needed to make sure firmware updates via these communication interfaces
|
||||
* will be possible.
|
||||
*/
|
||||
ComDeferredInit();
|
||||
#endif
|
||||
/* not a valid user program so it cannot be started */
|
||||
return;
|
||||
}
|
||||
#if (BOOT_CPU_USER_PROGRAM_START_HOOK > 0)
|
||||
/* invoke callback */
|
||||
if (CpuUserProgramStartHook() == BLT_FALSE)
|
||||
{
|
||||
#if (BOOT_COM_DEFERRED_INIT_ENABLE > 0) && (BOOT_COM_ENABLE > 0)
|
||||
/* bootloader will stay active so perform deferred initialization to make sure
|
||||
* the communication interface that were not yet initialized are now initialized.
|
||||
* this is needed to make sure firmware updates via these communication interfaces
|
||||
* will be possible.
|
||||
*/
|
||||
ComDeferredInit();
|
||||
#endif
|
||||
/* callback requests the user program to not be started */
|
||||
return;
|
||||
}
|
||||
#endif
|
||||
#if (BOOT_COM_ENABLE > 0)
|
||||
/* release the communication interface */
|
||||
ComFree();
|
||||
#endif
|
||||
/* reset the timer */
|
||||
TimerReset();
|
||||
/* remap user program's vector table */
|
||||
S32_SCB->VTOR = CPU_USER_PROGRAM_VECTABLE_OFFSET & (blt_int32u)0x1FFFFF80;
|
||||
/* The Cortex-M4 core has interrupts enabled out of reset. the bootloader
|
||||
* explicitly disables these for security reasons. Enable them here again, so it does
|
||||
* not have to be done by the user program.
|
||||
*/
|
||||
CpuIrqEnable();
|
||||
/* set the address where the bootloader needs to jump to. this is the address of
|
||||
* the 2nd entry in the user program's vector table. this address points to the
|
||||
* user program's reset handler.
|
||||
*/
|
||||
pProgResetHandler = (void(*)(void))(*((blt_addr *)CPU_USER_PROGRAM_STARTADDR_PTR));
|
||||
/* start the user program by calling its reset interrupt service routine */
|
||||
pProgResetHandler();
|
||||
#if (BOOT_COM_DEFERRED_INIT_ENABLE > 0) && (BOOT_COM_ENABLE > 0)
|
||||
/* theoretically, the code never gets here because the user program should now be
|
||||
* running and the previous function call should not return. In case it did return
|
||||
* for whatever reason, make sure all communication interfaces are initialized so that
|
||||
* firmware updates can be started.
|
||||
*/
|
||||
ComDeferredInit();
|
||||
#endif
|
||||
} /*** end of CpuStartUserProgram ***/
|
||||
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief Copies data from the source to the destination address.
|
||||
** \param dest Destination address for the data.
|
||||
** \param src Source address of the data.
|
||||
** \param len length of the data in bytes.
|
||||
** \return none.
|
||||
**
|
||||
****************************************************************************************/
|
||||
void CpuMemCopy(blt_addr dest, blt_addr src, blt_int16u len)
|
||||
{
|
||||
blt_int8u *from, *to;
|
||||
|
||||
/* set casted pointers */
|
||||
from = (blt_int8u *)src;
|
||||
to = (blt_int8u *)dest;
|
||||
|
||||
/* copy all bytes from source address to destination address */
|
||||
while (len-- > 0)
|
||||
{
|
||||
/* store byte value from source to destination */
|
||||
*to++ = *from++;
|
||||
/* keep the watchdog happy */
|
||||
CopService();
|
||||
}
|
||||
} /*** end of CpuMemCopy ***/
|
||||
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief Sets the bytes at the destination address to the specified value.
|
||||
** \param dest Destination address for the data.
|
||||
** \param value Value to write.
|
||||
** \param len Number of bytes to write.
|
||||
** \return none.
|
||||
**
|
||||
****************************************************************************************/
|
||||
void CpuMemSet(blt_addr dest, blt_int8u value, blt_int16u len)
|
||||
{
|
||||
blt_int8u *to;
|
||||
|
||||
/* set casted pointer */
|
||||
to = (blt_int8u *)dest;
|
||||
|
||||
/* set all bytes at the destination address to the specified value */
|
||||
while (len-- > 0)
|
||||
{
|
||||
/* set byte value */
|
||||
*to++ = value;
|
||||
/* keep the watchdog happy */
|
||||
CopService();
|
||||
}
|
||||
} /*** end of CpuMemSet ***/
|
||||
|
||||
|
||||
/*********************************** end of cpu.c **************************************/
|
File diff suppressed because it is too large
Load Diff
|
@ -0,0 +1,45 @@
|
|||
/************************************************************************************//**
|
||||
* \file Source/ARMCM4_S32K14/flash.h
|
||||
* \brief Bootloader flash driver header file.
|
||||
* \ingroup Target_ARMCM4_S32K14
|
||||
* \internal
|
||||
*----------------------------------------------------------------------------------------
|
||||
* C O P Y R I G H T
|
||||
*----------------------------------------------------------------------------------------
|
||||
* Copyright (c) 2020 by Feaser http://www.feaser.com All rights reserved
|
||||
*
|
||||
*----------------------------------------------------------------------------------------
|
||||
* L I C E N S E
|
||||
*----------------------------------------------------------------------------------------
|
||||
* This file is part of OpenBLT. OpenBLT is free software: you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as published by the Free
|
||||
* Software Foundation, either version 3 of the License, or (at your option) any later
|
||||
* version.
|
||||
*
|
||||
* OpenBLT is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
|
||||
* without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
|
||||
* PURPOSE. See the GNU General Public License for more details.
|
||||
*
|
||||
* You have received a copy of the GNU General Public License along with OpenBLT. It
|
||||
* should be located in ".\Doc\license.html". If not, contact Feaser to obtain a copy.
|
||||
*
|
||||
* \endinternal
|
||||
****************************************************************************************/
|
||||
#ifndef FLASH_H
|
||||
#define FLASH_H
|
||||
|
||||
/****************************************************************************************
|
||||
* Function prototypes
|
||||
****************************************************************************************/
|
||||
void FlashInit(void);
|
||||
void FlashReinit(void);
|
||||
blt_bool FlashWrite(blt_addr addr, blt_int32u len, blt_int8u *data);
|
||||
blt_bool FlashErase(blt_addr addr, blt_int32u len);
|
||||
blt_bool FlashWriteChecksum(void);
|
||||
blt_bool FlashVerifyChecksum(void);
|
||||
blt_bool FlashDone(void);
|
||||
blt_addr FlashGetUserProgBaseAddress(void);
|
||||
|
||||
|
||||
#endif /* FLASH_H */
|
||||
/*********************************** end of flash.h ************************************/
|
|
@ -0,0 +1,245 @@
|
|||
/************************************************************************************//**
|
||||
* \file Source/ARMCM4_S32K14/nvm.c
|
||||
* \brief Bootloader non-volatile memory driver source file.
|
||||
* \ingroup Target_ARMCM4_S32K14
|
||||
* \internal
|
||||
*----------------------------------------------------------------------------------------
|
||||
* C O P Y R I G H T
|
||||
*----------------------------------------------------------------------------------------
|
||||
* Copyright (c) 2020 by Feaser http://www.feaser.com All rights reserved
|
||||
*
|
||||
*----------------------------------------------------------------------------------------
|
||||
* L I C E N S E
|
||||
*----------------------------------------------------------------------------------------
|
||||
* This file is part of OpenBLT. OpenBLT is free software: you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as published by the Free
|
||||
* Software Foundation, either version 3 of the License, or (at your option) any later
|
||||
* version.
|
||||
*
|
||||
* OpenBLT is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
|
||||
* without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
|
||||
* PURPOSE. See the GNU General Public License for more details.
|
||||
*
|
||||
* You have received a copy of the GNU General Public License along with OpenBLT. It
|
||||
* should be located in ".\Doc\license.html". If not, contact Feaser to obtain a copy.
|
||||
*
|
||||
* \endinternal
|
||||
****************************************************************************************/
|
||||
|
||||
/****************************************************************************************
|
||||
* Include files
|
||||
****************************************************************************************/
|
||||
#include "boot.h" /* bootloader generic header */
|
||||
#include "flash.h"
|
||||
|
||||
|
||||
/****************************************************************************************
|
||||
* Hook functions
|
||||
****************************************************************************************/
|
||||
#if (BOOT_NVM_HOOKS_ENABLE > 0)
|
||||
extern void NvmInitHook(void);
|
||||
extern void NvmReinitHook(void);
|
||||
extern blt_int8u NvmWriteHook(blt_addr addr, blt_int32u len, blt_int8u *data);
|
||||
extern blt_int8u NvmEraseHook(blt_addr addr, blt_int32u len);
|
||||
extern blt_bool NvmDoneHook(void);
|
||||
#endif
|
||||
|
||||
#if (BOOT_NVM_CHECKSUM_HOOKS_ENABLE > 0)
|
||||
extern blt_bool NvmWriteChecksumHook(void);
|
||||
extern blt_bool NvmVerifyChecksumHook(void);
|
||||
#endif
|
||||
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief Initializes the NVM driver.
|
||||
** \return none.
|
||||
**
|
||||
****************************************************************************************/
|
||||
void NvmInit(void)
|
||||
{
|
||||
#if (BOOT_NVM_HOOKS_ENABLE > 0)
|
||||
/* give the application a chance to initialize a driver for operating on NVM
|
||||
* that is not by default supported by this driver.
|
||||
*/
|
||||
NvmInitHook();
|
||||
#endif
|
||||
|
||||
/* init the internal driver */
|
||||
FlashInit();
|
||||
} /*** end of NvmInit ***/
|
||||
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief Reinitializes the NVM driver. This function is called at the start of each
|
||||
** firmware update as opposed to NvmInit, which is only called once during
|
||||
** power on.
|
||||
** \return none.
|
||||
**
|
||||
****************************************************************************************/
|
||||
void NvmReinit(void)
|
||||
{
|
||||
#if (BOOT_NVM_HOOKS_ENABLE > 0)
|
||||
/* give the application a chance to re-initialize a driver for operating on NVM
|
||||
* that is not by default supported by this driver.
|
||||
*/
|
||||
NvmReinitHook();
|
||||
#endif
|
||||
|
||||
/* reinitialize the internal driver */
|
||||
FlashReinit();
|
||||
} /*** end of NvmReinit ***/
|
||||
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief Programs the non-volatile memory.
|
||||
** \param addr Start address.
|
||||
** \param len Length in bytes.
|
||||
** \param data Pointer to the data buffer.
|
||||
** \return BLT_TRUE if successful, BLT_FALSE otherwise.
|
||||
**
|
||||
****************************************************************************************/
|
||||
blt_bool NvmWrite(blt_addr addr, blt_int32u len, blt_int8u *data)
|
||||
{
|
||||
#if (BOOT_NVM_HOOKS_ENABLE > 0)
|
||||
blt_int8u result = BLT_NVM_NOT_IN_RANGE;
|
||||
#endif
|
||||
|
||||
#if (BOOT_NVM_HOOKS_ENABLE > 0)
|
||||
/* give the application a chance to operate on memory that is not by default supported
|
||||
* by this driver.
|
||||
*/
|
||||
result = NvmWriteHook(addr, len, data);
|
||||
|
||||
/* process the return code */
|
||||
if (result == BLT_NVM_OKAY)
|
||||
{
|
||||
/* data was within range of the additionally supported memory and succesfully
|
||||
* programmed, so we are all done.
|
||||
*/
|
||||
return BLT_TRUE;
|
||||
}
|
||||
else if (result == BLT_NVM_ERROR)
|
||||
{
|
||||
/* data was within range of the additionally supported memory and attempted to be
|
||||
* programmed, but an error occurred, so we can't continue.
|
||||
*/
|
||||
return BLT_FALSE;
|
||||
}
|
||||
#endif
|
||||
|
||||
/* still here so the internal driver should try and perform the program operation */
|
||||
return FlashWrite(addr, len, data);
|
||||
} /*** end of NvmWrite ***/
|
||||
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief Erases the non-volatile memory.
|
||||
** \param addr Start address.
|
||||
** \param len Length in bytes.
|
||||
** \return BLT_TRUE if successful, BLT_FALSE otherwise.
|
||||
**
|
||||
****************************************************************************************/
|
||||
blt_bool NvmErase(blt_addr addr, blt_int32u len)
|
||||
{
|
||||
#if (BOOT_NVM_HOOKS_ENABLE > 0)
|
||||
blt_int8u result = BLT_NVM_NOT_IN_RANGE;
|
||||
#endif
|
||||
|
||||
#if (BOOT_NVM_HOOKS_ENABLE > 0)
|
||||
/* give the application a chance to operate on memory that is not by default supported
|
||||
* by this driver.
|
||||
*/
|
||||
result = NvmEraseHook(addr, len);
|
||||
|
||||
/* process the return code */
|
||||
if (result == BLT_NVM_OKAY)
|
||||
{
|
||||
/* address was within range of the additionally supported memory and succesfully
|
||||
* erased, so we are all done.
|
||||
*/
|
||||
return BLT_TRUE;
|
||||
}
|
||||
else if (result == BLT_NVM_ERROR)
|
||||
{
|
||||
/* address was within range of the additionally supported memory and attempted to be
|
||||
* erased, but an error occurred, so we can't continue.
|
||||
*/
|
||||
return BLT_FALSE;
|
||||
}
|
||||
#endif
|
||||
|
||||
/* still here so the internal driver should try and perform the erase operation */
|
||||
return FlashErase(addr, len);
|
||||
} /*** end of NvmErase ***/
|
||||
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief Verifies the checksum, which indicates that a valid user program is
|
||||
** present and can be started.
|
||||
** \return BLT_TRUE if successful, BLT_FALSE otherwise.
|
||||
**
|
||||
****************************************************************************************/
|
||||
blt_bool NvmVerifyChecksum(void)
|
||||
{
|
||||
#if (BOOT_NVM_CHECKSUM_HOOKS_ENABLE > 0)
|
||||
/* check checksum using the application specific method. */
|
||||
return NvmVerifyChecksumHook();
|
||||
#else
|
||||
/* check checksum using the interally supported method. */
|
||||
return FlashVerifyChecksum();
|
||||
#endif
|
||||
} /*** end of NvmVerifyChecksum ***/
|
||||
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief Obtains the base address of the non-volatile memory available to the user
|
||||
** program. This is typically that start of the vector table.
|
||||
** \return Base address.
|
||||
**
|
||||
****************************************************************************************/
|
||||
blt_addr NvmGetUserProgBaseAddress(void)
|
||||
{
|
||||
return FlashGetUserProgBaseAddress();
|
||||
} /*** end of NvmGetUserProgBaseAddress ***/
|
||||
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief Once all erase and programming operations are completed, this
|
||||
** function is called, so at the end of the programming session and
|
||||
** right before a software reset is performed. It is used to calculate
|
||||
** a checksum and program this into flash. This checksum is later used
|
||||
** to determine if a valid user program is present in flash.
|
||||
** \return BLT_TRUE if successful, BLT_FALSE otherwise.
|
||||
**
|
||||
****************************************************************************************/
|
||||
blt_bool NvmDone(void)
|
||||
{
|
||||
#if (BOOT_NVM_HOOKS_ENABLE > 0)
|
||||
/* give the application's NVM driver a chance to finish up */
|
||||
if (NvmDoneHook() == BLT_FALSE)
|
||||
{
|
||||
/* error so no need to continue */
|
||||
return BLT_FALSE;
|
||||
}
|
||||
#endif
|
||||
|
||||
#if (BOOT_NVM_CHECKSUM_HOOKS_ENABLE > 0)
|
||||
/* compute and write checksum, using the application specific method. */
|
||||
if (NvmWriteChecksumHook() == BLT_FALSE)
|
||||
{
|
||||
return BLT_FALSE;
|
||||
}
|
||||
#else
|
||||
/* compute and write checksum, which is programmed by the internal driver. */
|
||||
if (FlashWriteChecksum() == BLT_FALSE)
|
||||
{
|
||||
return BLT_FALSE;
|
||||
}
|
||||
#endif
|
||||
|
||||
/* finish up internal driver operations */
|
||||
return FlashDone();
|
||||
} /*** end of NvmDone ***/
|
||||
|
||||
|
||||
/*********************************** end of nvm.c **************************************/
|
|
@ -0,0 +1,341 @@
|
|||
/************************************************************************************//**
|
||||
* \file Source/ARMCM4_S32K14/uart.c
|
||||
* \brief Bootloader RS232 communication interface source file.
|
||||
* \ingroup Target_ARMCM4_S32K14
|
||||
* \internal
|
||||
*----------------------------------------------------------------------------------------
|
||||
* C O P Y R I G H T
|
||||
*----------------------------------------------------------------------------------------
|
||||
* Copyright (c) 2020 by Feaser http://www.feaser.com All rights reserved
|
||||
*
|
||||
*----------------------------------------------------------------------------------------
|
||||
* L I C E N S E
|
||||
*----------------------------------------------------------------------------------------
|
||||
* This file is part of OpenBLT. OpenBLT is free software: you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as published by the Free
|
||||
* Software Foundation, either version 3 of the License, or (at your option) any later
|
||||
* version.
|
||||
*
|
||||
* OpenBLT is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
|
||||
* without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
|
||||
* PURPOSE. See the GNU General Public License for more details.
|
||||
*
|
||||
* You have received a copy of the GNU General Public License along with OpenBLT. It
|
||||
* should be located in ".\Doc\license.html". If not, contact Feaser to obtain a copy.
|
||||
*
|
||||
* \endinternal
|
||||
****************************************************************************************/
|
||||
|
||||
/****************************************************************************************
|
||||
* Include files
|
||||
****************************************************************************************/
|
||||
#include "boot.h" /* bootloader generic header */
|
||||
#if (BOOT_COM_RS232_ENABLE > 0)
|
||||
#include "device_registers.h" /* device registers */
|
||||
|
||||
|
||||
/****************************************************************************************
|
||||
* Macro definitions
|
||||
****************************************************************************************/
|
||||
/** \brief Timeout time for the reception of a CTO packet. The timer is started upon
|
||||
* reception of the first packet byte.
|
||||
*/
|
||||
#define RS232_CTO_RX_PACKET_TIMEOUT_MS (100U)
|
||||
/** \brief Timeout for transmitting a byte in milliseconds. */
|
||||
#define RS232_BYTE_TX_TIMEOUT_MS (10U)
|
||||
|
||||
#if (BOOT_COM_RS232_CHANNEL_INDEX == 0)
|
||||
/** \brief Set the peripheral LPUART0 base pointer. */
|
||||
#define LPUARTx (LPUART0)
|
||||
/** \brief Set the PCC index offset for LPUART0. */
|
||||
#define PCC_LPUARTx_INDEX (PCC_LPUART0_INDEX)
|
||||
#elif (BOOT_COM_RS232_CHANNEL_INDEX == 1)
|
||||
/** \brief Set the peripheral LPUART1 base pointer. */
|
||||
#define LPUARTx (LPUART1)
|
||||
/** \brief Set the PCC index offset for LPUART1. */
|
||||
#define PCC_LPUARTx_INDEX (PCC_LPUART1_INDEX)
|
||||
#elif (BOOT_COM_RS232_CHANNEL_INDEX == 2)
|
||||
/** \brief Set the peripheral LPUART2 base pointer. */
|
||||
#define LPUARTx (LPUART2)
|
||||
/** \brief Set the PCC index offset for LPUART2. */
|
||||
#define PCC_LPUARTx_INDEX (PCC_LPUART2_INDEX)
|
||||
#endif
|
||||
|
||||
|
||||
/****************************************************************************************
|
||||
* Function prototypes
|
||||
****************************************************************************************/
|
||||
static blt_bool Rs232ReceiveByte(blt_int8u *data);
|
||||
static void Rs232TransmitByte(blt_int8u data);
|
||||
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief Initializes the RS232 communication interface.
|
||||
** \return none.
|
||||
**
|
||||
****************************************************************************************/
|
||||
void Rs232Init(void)
|
||||
{
|
||||
blt_int32u sourceClockFreqHz;
|
||||
blt_int32u div2RegValue;
|
||||
blt_int16u baudrateSbr0_12;
|
||||
blt_int8u const div2DividerLookup[] =
|
||||
{
|
||||
0U, /* 0b000. Output disabled. */
|
||||
1U, /* 0b001. Divide by 1. */
|
||||
2U, /* 0b010. Divide by 2. */
|
||||
4U, /* 0b011. Divide by 4. */
|
||||
8U, /* 0b100. Divide by 8. */
|
||||
16U, /* 0b101. Divide by 16. */
|
||||
32U, /* 0b110. Divide by 32. */
|
||||
64U, /* 0b111. Divide by 64. */
|
||||
};
|
||||
|
||||
/* Perform compile time assertion to check that the configured UART channel is actually
|
||||
* supported by this driver.
|
||||
*/
|
||||
ASSERT_CT((BOOT_COM_RS232_CHANNEL_INDEX == 0) ||
|
||||
(BOOT_COM_RS232_CHANNEL_INDEX == 1) ||
|
||||
(BOOT_COM_RS232_CHANNEL_INDEX == 2));
|
||||
|
||||
/* Make sure the UART peripheral clock is disabled before configuring its source
|
||||
* clock.
|
||||
*/
|
||||
PCC->PCCn[PCC_LPUARTx_INDEX] &= ~PCC_PCCn_CGC_MASK;
|
||||
/* Select option 2 as the UART peripheral source clock and enable the clock. Option 2
|
||||
* is the SIRCDIV2_CLK, which is available on all peripherals and configurations.
|
||||
*/
|
||||
PCC->PCCn[PCC_LPUARTx_INDEX] |= PCC_PCCn_PCS(0b010) | PCC_PCCn_CGC_MASK;
|
||||
/* Obtain the DIV2 divider value of the SIRC_CLK. */
|
||||
div2RegValue = (SCG->SIRCDIV & SCG_SIRCDIV_SIRCDIV2_MASK) >> SCG_SIRCDIV_SIRCDIV2_SHIFT;
|
||||
/* Check if the DIV2 register value for SIRC is 0. In this case SIRCDIV2_CLK is
|
||||
* currently disabled.
|
||||
*/
|
||||
if (div2RegValue == 0U)
|
||||
{
|
||||
/* Configure the DIV2 for a default divide by 1 to make sure the SIRCDIV2_CLK is
|
||||
* actually enabled.
|
||||
*/
|
||||
div2RegValue = 1U;
|
||||
SCG->SIRCDIV |= SCG_SIRCDIV_SIRCDIV2(div2RegValue);
|
||||
}
|
||||
/* Determine the SIRC clock frequency. If SIRC high range is enabled, it is 8 MHz. If
|
||||
* SIRC low range is enabled, it is 2 MHz.
|
||||
*/
|
||||
sourceClockFreqHz = 8000000U;
|
||||
if ((SCG->SIRCCFG & SCG_SIRCCFG_RANGE_MASK) == SCG_SIRCCFG_RANGE(0))
|
||||
{
|
||||
sourceClockFreqHz = 2000000U;
|
||||
}
|
||||
/* Now process the configured DIV2 divider factor to get the actual frequency of the
|
||||
* UART peripheral source clock.
|
||||
*/
|
||||
sourceClockFreqHz /= div2DividerLookup[div2RegValue];
|
||||
/* Configure the baudrate from BOOT_COM_RS232_BAUDRATE, taking into account that an
|
||||
* oversampling of 8 will be configured. Default 8,n,1 format is used. Integer
|
||||
* rounding is used to get the best value for baudrateSbr0_12. Actual baudrate equals
|
||||
* sourceClockFreqHz / 8 / baudrateSbr0_12.
|
||||
*/
|
||||
baudrateSbr0_12 = (((sourceClockFreqHz / BOOT_COM_RS232_BAUDRATE) + (8U - 1U)) / 8U) &
|
||||
LPUART_BAUD_SBR_MASK;
|
||||
/* OSR=7: Over sampling ratio = 7+1=8.
|
||||
* SBNS=0: One stop bit.
|
||||
* BOTHEDGE=0: receiver samples only on rising edge.
|
||||
* M10=0: Rx and Tx use 7 to 9 bit data characters.
|
||||
* RESYNCDIS=0: Resync during rec'd data word supported.
|
||||
* LBKDIE, RXEDGIE=0: interrupts disable.
|
||||
* TDMAE, RDMAE, TDMAE=0: DMA requests disabled.
|
||||
* MAEN1, MAEN2, MATCFG=0: Match disabled.
|
||||
*/
|
||||
LPUARTx->BAUD = LPUART_BAUD_SBR(baudrateSbr0_12) | LPUART_BAUD_OSR(7);
|
||||
/* Clear the error/interrupt flags */
|
||||
LPUARTx->STAT = FEATURE_LPUART_STAT_REG_FLAGS_MASK;
|
||||
/* Reset all features/interrupts by default */
|
||||
LPUARTx->CTRL = 0x00000000;
|
||||
/* Reset match addresses */
|
||||
LPUARTx->MATCH = 0x00000000;
|
||||
#if FEATURE_LPUART_HAS_MODEM_SUPPORT
|
||||
/* Reset IrDA modem features */
|
||||
LPUARTx->MODIR = 0x00000000;
|
||||
#endif
|
||||
#if FEATURE_LPUART_FIFO_SIZE > 0U
|
||||
/* Reset FIFO feature */
|
||||
LPUARTx->FIFO = FEATURE_LPUART_FIFO_RESET_MASK;
|
||||
/* Enable the transmit and receive FIFOs. */
|
||||
LPUARTx->FIFO |= LPUART_FIFO_TXFE(1) | LPUART_FIFO_RXFE(1);
|
||||
/* Set the reception water mark to 0 and the transmitter water mark to 1. */
|
||||
LPUARTx->WATER = LPUART_WATER_TXWATER(1) | LPUART_WATER_RXWATER(0);
|
||||
#endif
|
||||
/* Enable transmitter and receiver, no parity, 8 bit char:
|
||||
* RE=1: Receiver enabled.
|
||||
* TE=1: Transmitter enabled.
|
||||
* PE,PT=0: No hw parity generation or checking.
|
||||
* M7,M,R8T9,R9T8=0: 8-bit data characters.
|
||||
* DOZEEN=0: LPUART enabled in Doze mode.
|
||||
* ORIE,NEIE,FEIE,PEIE,TIE,TCIE,RIE,ILIE,MA1IE,MA2IE=0: no IRQ.
|
||||
* TxDIR=0: TxD pin is input if in single-wire mode.
|
||||
* TXINV=0: Transmit data not inverted.
|
||||
* RWU,WAKE=0: normal operation; rcvr not in standby.
|
||||
* IDLCFG=0: one idle character.
|
||||
* ILT=0: Idle char bit count starts after start bit.
|
||||
* SBK=0: Normal transmitter operation - no break char.
|
||||
* LOOPS,RSRC=0: no loop back.
|
||||
*/
|
||||
LPUARTx->CTRL = LPUART_CTRL_RE_MASK | LPUART_CTRL_TE_MASK;
|
||||
} /*** end of Rs232Init ***/
|
||||
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief Transmits a packet formatted for the communication interface.
|
||||
** \param data Pointer to byte array with data that it to be transmitted.
|
||||
** \param len Number of bytes that are to be transmitted.
|
||||
** \return none.
|
||||
**
|
||||
****************************************************************************************/
|
||||
void Rs232TransmitPacket(blt_int8u *data, blt_int8u len)
|
||||
{
|
||||
blt_int16u data_index;
|
||||
|
||||
/* Verify validity of the len-paramenter. */
|
||||
ASSERT_RT(len <= BOOT_COM_RS232_TX_MAX_DATA);
|
||||
|
||||
/* First transmit the length of the packet. */
|
||||
Rs232TransmitByte(len);
|
||||
|
||||
/* Transmit all the packet bytes one-by-one. */
|
||||
for (data_index = 0U; data_index < len; data_index++)
|
||||
{
|
||||
/* Keep the watchdog happy. */
|
||||
CopService();
|
||||
/* Write byte. */
|
||||
Rs232TransmitByte(data[data_index]);
|
||||
}
|
||||
} /*** end of Rs232TransmitPacket ***/
|
||||
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief Receives a communication interface packet if one is present.
|
||||
** \param data Pointer to byte array where the data is to be stored.
|
||||
** \param len Pointer where the length of the packet is to be stored.
|
||||
** \return BLT_TRUE if a packet was received, BLT_FALSE otherwise.
|
||||
**
|
||||
****************************************************************************************/
|
||||
blt_bool Rs232ReceivePacket(blt_int8u *data, blt_int8u *len)
|
||||
{
|
||||
static blt_int8u xcpCtoReqPacket[BOOT_COM_RS232_RX_MAX_DATA+1U]; /* One extra for length. */
|
||||
static blt_int8u xcpCtoRxLength;
|
||||
static blt_bool xcpCtoRxInProgress = BLT_FALSE;
|
||||
static blt_int32u xcpCtoRxStartTime = 0U;
|
||||
|
||||
/* Start of cto packet received? */
|
||||
if (xcpCtoRxInProgress == BLT_FALSE)
|
||||
{
|
||||
/* Store the message length when received. */
|
||||
if (Rs232ReceiveByte(&xcpCtoReqPacket[0]) == BLT_TRUE)
|
||||
{
|
||||
if ( (xcpCtoReqPacket[0] > 0U) &&
|
||||
(xcpCtoReqPacket[0] <= BOOT_COM_RS232_RX_MAX_DATA) )
|
||||
{
|
||||
/* Store the start time. */
|
||||
xcpCtoRxStartTime = TimerGet();
|
||||
/* Reset packet data count. */
|
||||
xcpCtoRxLength = 0U;
|
||||
/* Indicate that a cto packet is being received. */
|
||||
xcpCtoRxInProgress = BLT_TRUE;
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
/* Store the next packet byte. */
|
||||
if (Rs232ReceiveByte(&xcpCtoReqPacket[xcpCtoRxLength+1U]) == BLT_TRUE)
|
||||
{
|
||||
/* Increment the packet data count. */
|
||||
xcpCtoRxLength++;
|
||||
|
||||
/* Check to see if the entire packet was received. */
|
||||
if (xcpCtoRxLength == xcpCtoReqPacket[0])
|
||||
{
|
||||
/* Copy the packet data. */
|
||||
CpuMemCopy((blt_int32u)data, (blt_int32u)&xcpCtoReqPacket[1], xcpCtoRxLength);
|
||||
/* Done with cto packet reception. */
|
||||
xcpCtoRxInProgress = BLT_FALSE;
|
||||
/* Set the packet length. */
|
||||
*len = xcpCtoRxLength;
|
||||
/* Packet reception complete. */
|
||||
return BLT_TRUE;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
/* Check packet reception timeout. */
|
||||
if (TimerGet() > (xcpCtoRxStartTime + RS232_CTO_RX_PACKET_TIMEOUT_MS))
|
||||
{
|
||||
/* Cancel cto packet reception due to timeout. Note that that automaticaly
|
||||
* discards the already received packet bytes, allowing the host to retry.
|
||||
*/
|
||||
xcpCtoRxInProgress = BLT_FALSE;
|
||||
}
|
||||
}
|
||||
}
|
||||
/* Packet reception not yet complete. */
|
||||
return BLT_FALSE;
|
||||
} /*** end of Rs232ReceivePacket ***/
|
||||
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief Receives a communication interface byte if one is present.
|
||||
** \param data Pointer to byte where the data is to be stored.
|
||||
** \return BLT_TRUE if a byte was received, BLT_FALSE otherwise.
|
||||
**
|
||||
****************************************************************************************/
|
||||
static blt_bool Rs232ReceiveByte(blt_int8u *data)
|
||||
{
|
||||
blt_bool result = BLT_FALSE;
|
||||
|
||||
/* Check if a new byte was received by means of the RDRF-bit. */
|
||||
if (((LPUARTx->STAT & LPUART_STAT_RDRF_MASK) >> LPUART_STAT_RDRF_SHIFT) != 0U)
|
||||
{
|
||||
/* Retrieve and store the newly received byte. */
|
||||
*data = LPUARTx->DATA;
|
||||
/* Update the result. */
|
||||
result = BLT_TRUE;
|
||||
}
|
||||
|
||||
/* Give the result back to the caller. */
|
||||
return result;
|
||||
} /*** end of Rs232ReceiveByte ***/
|
||||
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief Transmits a communication interface byte.
|
||||
** \param data Value of byte that is to be transmitted.
|
||||
** \return none.
|
||||
**
|
||||
****************************************************************************************/
|
||||
static void Rs232TransmitByte(blt_int8u data)
|
||||
{
|
||||
blt_int32u timeout;
|
||||
|
||||
/* Write the byte value in 'data' to the transmit register of the UART peripheral such
|
||||
* that the transmission of the byte value is started.
|
||||
*/
|
||||
LPUARTx->DATA = data;
|
||||
/* Set timeout time to wait for transmit completion. */
|
||||
timeout = TimerGet() + RS232_BYTE_TX_TIMEOUT_MS;
|
||||
/* Wait for tx holding register to be empty. */
|
||||
while (((LPUARTx->STAT & LPUART_STAT_TDRE_MASK) >> LPUART_STAT_TDRE_SHIFT) == 0U)
|
||||
{
|
||||
/* Keep the watchdog happy. */
|
||||
CopService();
|
||||
/* Break loop upon timeout. this would indicate a hardware failure. */
|
||||
if (TimerGet() > timeout)
|
||||
{
|
||||
break;
|
||||
}
|
||||
}
|
||||
} /*** end of Rs232TransmitByte ***/
|
||||
#endif /* BOOT_COM_RS232_ENABLE > 0 */
|
||||
|
||||
|
||||
/*********************************** end of rs232.c ************************************/
|
|
@ -0,0 +1,9 @@
|
|||
/**
|
||||
\defgroup Target_ARMCM4_S32K14 Target ARMCM4 S32K14
|
||||
\ingroup Ports
|
||||
\brief Target dependent code for the NXP ARMCM4 S32K14x microcontroller family.
|
||||
\details This module implements the bootloader's target dependent part for the
|
||||
NXP ARMCM4 S32K14x microcontroller family.
|
||||
*/
|
||||
|
||||
|
|
@ -0,0 +1,110 @@
|
|||
/************************************************************************************//**
|
||||
* \file Source/ARMCM4_S32K14/timer.c
|
||||
* \brief Bootloader timer driver source file.
|
||||
* \ingroup Target_ARMCM4_S32K14
|
||||
* \internal
|
||||
*----------------------------------------------------------------------------------------
|
||||
* C O P Y R I G H T
|
||||
*----------------------------------------------------------------------------------------
|
||||
* Copyright (c) 2020 by Feaser http://www.feaser.com All rights reserved
|
||||
*
|
||||
*----------------------------------------------------------------------------------------
|
||||
* L I C E N S E
|
||||
*----------------------------------------------------------------------------------------
|
||||
* This file is part of OpenBLT. OpenBLT is free software: you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as published by the Free
|
||||
* Software Foundation, either version 3 of the License, or (at your option) any later
|
||||
* version.
|
||||
*
|
||||
* OpenBLT is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
|
||||
* without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
|
||||
* PURPOSE. See the GNU General Public License for more details.
|
||||
*
|
||||
* You have received a copy of the GNU General Public License along with OpenBLT. It
|
||||
* should be located in ".\Doc\license.html". If not, contact Feaser to obtain a copy.
|
||||
*
|
||||
* \endinternal
|
||||
****************************************************************************************/
|
||||
|
||||
/****************************************************************************************
|
||||
* Include files
|
||||
****************************************************************************************/
|
||||
#include "boot.h" /* bootloader generic header */
|
||||
#include "device_registers.h" /* device registers */
|
||||
|
||||
|
||||
/****************************************************************************************
|
||||
* Local data declarations
|
||||
****************************************************************************************/
|
||||
/** \brief Local variable for storing the number of milliseconds that have elapsed since
|
||||
* startup.
|
||||
*/
|
||||
static blt_int32u millisecond_counter;
|
||||
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief Initializes the polling based millisecond timer driver.
|
||||
** \return none.
|
||||
**
|
||||
****************************************************************************************/
|
||||
void TimerInit(void)
|
||||
{
|
||||
/* Reset the timer configuration. */
|
||||
TimerReset();
|
||||
/* Configure the systick frequency as a 1 ms event generator. */
|
||||
S32_SysTick->RVR = BOOT_CPU_SYSTEM_SPEED_KHZ - 1;
|
||||
/* Reset the current counter value. */
|
||||
S32_SysTick->CVR = 0u;
|
||||
/* Select core clock as source and enable the timer. */
|
||||
S32_SysTick->CSR = S32_SysTick_CSR_ENABLE_MASK | S32_SysTick_CSR_CLKSOURCE_MASK;
|
||||
/* Reset the millisecond counter value. */
|
||||
millisecond_counter = 0;
|
||||
} /*** end of TimerInit ***/
|
||||
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief Reset the timer by placing the timer back into it's default reset
|
||||
** configuration.
|
||||
** \return none.
|
||||
**
|
||||
****************************************************************************************/
|
||||
void TimerReset(void)
|
||||
{
|
||||
/* Set the systick's status and control register back into the default reset value. */
|
||||
S32_SysTick->CSR = 0;
|
||||
} /* end of TimerReset */
|
||||
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief Updates the millisecond timer.
|
||||
** \return none.
|
||||
**
|
||||
****************************************************************************************/
|
||||
void TimerUpdate(void)
|
||||
{
|
||||
/* Check if the millisecond event occurred. */
|
||||
if ((S32_SysTick->CSR & S32_SysTick_CSR_COUNTFLAG_MASK) != 0)
|
||||
{
|
||||
/* Increment the millisecond counter. */
|
||||
millisecond_counter++;
|
||||
}
|
||||
} /*** end of TimerUpdate ***/
|
||||
|
||||
|
||||
/************************************************************************************//**
|
||||
** \brief Obtains the counter value of the millisecond timer.
|
||||
** \return Current value of the millisecond timer.
|
||||
**
|
||||
****************************************************************************************/
|
||||
blt_int32u TimerGet(void)
|
||||
{
|
||||
/* Updating timer here allows this function to be called in a loop with timeout
|
||||
* detection.
|
||||
*/
|
||||
TimerUpdate();
|
||||
/* Read and return the amount of milliseconds that passed since initialization. */
|
||||
return millisecond_counter;
|
||||
} /*** end of TimerGet ***/
|
||||
|
||||
|
||||
/*********************************** end of timer.c ************************************/
|
|
@ -0,0 +1,57 @@
|
|||
/************************************************************************************//**
|
||||
* \file Source/ARMCM4_S32K14/types.h
|
||||
* \brief Bootloader types header file.
|
||||
* \ingroup Target_ARMCM4_S32K14
|
||||
* \internal
|
||||
*----------------------------------------------------------------------------------------
|
||||
* C O P Y R I G H T
|
||||
*----------------------------------------------------------------------------------------
|
||||
* Copyright (c) 2020 by Feaser http://www.feaser.com All rights reserved
|
||||
*
|
||||
*----------------------------------------------------------------------------------------
|
||||
* L I C E N S E
|
||||
*----------------------------------------------------------------------------------------
|
||||
* This file is part of OpenBLT. OpenBLT is free software: you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as published by the Free
|
||||
* Software Foundation, either version 3 of the License, or (at your option) any later
|
||||
* version.
|
||||
*
|
||||
* OpenBLT is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
|
||||
* without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
|
||||
* PURPOSE. See the GNU General Public License for more details.
|
||||
*
|
||||
* You have received a copy of the GNU General Public License along with OpenBLT. It
|
||||
* should be located in ".\Doc\license.html". If not, contact Feaser to obtain a copy.
|
||||
*
|
||||
* \endinternal
|
||||
****************************************************************************************/
|
||||
#ifndef TYPES_H
|
||||
#define TYPES_H
|
||||
|
||||
/****************************************************************************************
|
||||
* Macro definitions
|
||||
****************************************************************************************/
|
||||
/** \brief Boolean true value. */
|
||||
#define BLT_TRUE (1)
|
||||
/** \brief Boolean false value. */
|
||||
#define BLT_FALSE (0)
|
||||
/** \brief NULL pointer value. */
|
||||
#define BLT_NULL ((void *)0)
|
||||
|
||||
|
||||
/****************************************************************************************
|
||||
* Type definitions
|
||||
****************************************************************************************/
|
||||
typedef unsigned char blt_bool; /**< boolean type */
|
||||
typedef char blt_char; /**< character type */
|
||||
typedef unsigned long blt_addr; /**< memory address type */
|
||||
typedef unsigned char blt_int8u; /**< 8-bit unsigned integer */
|
||||
typedef signed char blt_int8s; /**< 8-bit signed integer */
|
||||
typedef unsigned short blt_int16u; /**< 16-bit unsigned integer */
|
||||
typedef signed short blt_int16s; /**< 16-bit signed integer */
|
||||
typedef unsigned int blt_int32u; /**< 32-bit unsigned integer */
|
||||
typedef signed int blt_int32s; /**< 32-bit signed integer */
|
||||
|
||||
|
||||
#endif /* TYPES_H */
|
||||
/*********************************** end of types.h ************************************/
|
|
@ -181,7 +181,7 @@ void CanInit(void)
|
|||
ASSERT_RT(BLT_FALSE);
|
||||
}
|
||||
|
||||
/* TODO ##Vg Perform the configuration and initialization of the CAN controller. Note
|
||||
/* TODO ##Port Perform the configuration and initialization of the CAN controller. Note
|
||||
* that the bittiming related values are already stored in 'prescaler, 'tseg1', and
|
||||
* 'tseg2'. There values are ready to be used. Typically, the following tasks need
|
||||
* to be performed:
|
||||
|
|
Loading…
Reference in New Issue