Version 1.4 du soft robot. Rajout de la commande PowerOff

This commit is contained in:
Sébastien DI MERCURIO 2018-10-10 10:22:57 +02:00
parent 365843d786
commit 5beb9ad12d
8 changed files with 157 additions and 84 deletions

View file

@ -12,7 +12,7 @@
</extensions>
</storageModule>
<storageModule moduleId="cdtBuildSystem" version="4.0.0">
<configuration artifactExtension="elf" artifactName="${ProjName}" buildArtefactType="org.eclipse.cdt.build.core.buildArtefactType.exe" buildProperties="org.eclipse.cdt.build.core.buildArtefactType=org.eclipse.cdt.build.core.buildArtefactType.exe" cleanCommand="rm -rf" description="" id="com.atollic.truestudio.exe.debug.584431509" name="Debug" parent="com.atollic.truestudio.exe.debug">
<configuration artifactExtension="elf" artifactName="${ProjName}" buildArtefactType="org.eclipse.cdt.build.core.buildArtefactType.exe" buildProperties="org.eclipse.cdt.build.core.buildArtefactType=org.eclipse.cdt.build.core.buildArtefactType.exe" cleanCommand="rm -rf" description="Programme de debug avec symbol et compteur d'inactivité desactivé" id="com.atollic.truestudio.exe.debug.584431509" name="Debug" parent="com.atollic.truestudio.exe.debug">
<folderInfo id="com.atollic.truestudio.exe.debug.584431509." name="/" resourcePath="">
<toolChain id="com.atollic.truestudio.exe.debug.toolchain.1572207901" name="Atollic ARM Tools" superClass="com.atollic.truestudio.exe.debug.toolchain">
<option id="com.atollic.truestudio.general.runtimelib.2022035895" name="Runtime Library" superClass="com.atollic.truestudio.general.runtimelib" useByScannerDiscovery="false" value="com.atollic.truestudio.ld.general.cclib.CCSmallCSmall" valueType="enumerated"/>
@ -139,8 +139,8 @@
</storageModule>
<storageModule moduleId="org.eclipse.cdt.core.externalSettings"/>
</cconfiguration>
<cconfiguration id="com.atollic.truestudio.configuration.release.1711240076">
<storageModule buildSystemId="org.eclipse.cdt.managedbuilder.core.configurationDataProvider" id="com.atollic.truestudio.configuration.release.1711240076" moduleId="org.eclipse.cdt.core.settings" name="Release">
<cconfiguration id="com.atollic.truestudio.exe.debug.584431509.2045581985">
<storageModule buildSystemId="org.eclipse.cdt.managedbuilder.core.configurationDataProvider" id="com.atollic.truestudio.exe.debug.584431509.2045581985" moduleId="org.eclipse.cdt.core.settings" name="Release">
<externalSettings/>
<extensions>
<extension id="org.eclipse.cdt.core.ELF" point="org.eclipse.cdt.core.BinaryParser"/>
@ -150,103 +150,131 @@
</extensions>
</storageModule>
<storageModule moduleId="cdtBuildSystem" version="4.0.0">
<configuration artifactExtension="elf" artifactName="${ProjName}" buildArtefactType="org.eclipse.cdt.build.core.buildArtefactType.exe" buildProperties="org.eclipse.cdt.build.core.buildArtefactType=org.eclipse.cdt.build.core.buildArtefactType.exe" cleanCommand="rm -rf" description="" id="com.atollic.truestudio.configuration.release.1711240076" name="Release" parent="com.atollic.truestudio.configuration.release">
<folderInfo id="com.atollic.truestudio.configuration.release.1711240076." name="/" resourcePath="">
<toolChain id="com.atollic.truestudio.exe.release.toolchain.1405567933" name="Atollic ARM Tools" superClass="com.atollic.truestudio.exe.release.toolchain">
<option id="com.atollic.truestudio.general.runtimelib.745872935" name="Runtime Library" superClass="com.atollic.truestudio.general.runtimelib" value="com.atollic.truestudio.ld.general.clib.small" valueType="enumerated"/>
<option id="com.atollic.truestudio.toolchain_options.mcu.1702656728" name="Microcontroller" superClass="com.atollic.truestudio.toolchain_options.mcu" value="STM32F103C6" valueType="string"/>
<option id="com.atollic.truestudio.toolchain_options.vendor.557653686" name="Vendor name" superClass="com.atollic.truestudio.toolchain_options.vendor" value="STMicroelectronics" valueType="string"/>
<targetPlatform archList="all" binaryParser="org.eclipse.cdt.core.ELF" id="com.atollic.truestudio.exe.release.toolchain.platform.209638276" isAbstract="false" name="release platform" superClass="com.atollic.truestudio.exe.release.toolchain.platform"/>
<builder buildPath="${workspace_loc:/Dumber-Robot-Firmware}/Release" id="com.atollic.truestudio.mbs.builder1.1059870046" keepEnvironmentInBuildfile="false" managedBuildOn="true" name="CDT Internal Builder" superClass="com.atollic.truestudio.mbs.builder1"/>
<tool id="com.atollic.truestudio.exe.release.toolchain.as.1594028390" name="Assembler" superClass="com.atollic.truestudio.exe.release.toolchain.as">
<option id="com.atollic.truestudio.common_options.target.endianess.1550970254" name="Endianess" superClass="com.atollic.truestudio.common_options.target.endianess"/>
<option id="com.atollic.truestudio.common_options.target.mcpu.539967276" name="Microcontroller" superClass="com.atollic.truestudio.common_options.target.mcpu" value="STM32F103C6" valueType="enumerated"/>
<option id="com.atollic.truestudio.common_options.target.instr_set.379638892" name="Instruction set" superClass="com.atollic.truestudio.common_options.target.instr_set" value="com.atollic.truestudio.common_options.target.instr_set.thumb2" valueType="enumerated"/>
<option id="com.atollic.truestudio.common_options.target.fpucore.1963414035" name="FPU" superClass="com.atollic.truestudio.common_options.target.fpucore" value="com.atollic.truestudio.common_options.target.fpucore.None" valueType="enumerated"/>
<option id="com.atollic.truestudio.common_options.target.fpu.507994149" name="Floating point" superClass="com.atollic.truestudio.common_options.target.fpu"/>
<option id="com.atollic.truestudio.as.symbols.defined.16226109" name="Defined symbols" superClass="com.atollic.truestudio.as.symbols.defined" valueType="definedSymbols">
<configuration artifactExtension="elf" artifactName="${ProjName}" buildArtefactType="org.eclipse.cdt.build.core.buildArtefactType.exe" buildProperties="org.eclipse.cdt.build.core.buildArtefactType=org.eclipse.cdt.build.core.buildArtefactType.exe" cleanCommand="rm -rf" description="Programme optimisé, sans symboles de debug et avec le compteur d'inactivité" id="com.atollic.truestudio.exe.debug.584431509.2045581985" name="Release" parent="com.atollic.truestudio.exe.debug">
<folderInfo id="com.atollic.truestudio.exe.debug.584431509.2045581985." name="/" resourcePath="">
<toolChain id="com.atollic.truestudio.exe.debug.toolchain.1365910328" name="Atollic ARM Tools" superClass="com.atollic.truestudio.exe.debug.toolchain">
<option id="com.atollic.truestudio.general.runtimelib.1609891271" name="Runtime Library" superClass="com.atollic.truestudio.general.runtimelib" useByScannerDiscovery="false" value="com.atollic.truestudio.ld.general.cclib.CCSmallCSmall" valueType="enumerated"/>
<option id="com.atollic.truestudio.toolchain_options.mcu.234071029" name="Microcontroller" superClass="com.atollic.truestudio.toolchain_options.mcu" useByScannerDiscovery="false" value="STM32F103C6" valueType="string"/>
<option id="com.atollic.truestudio.toolchain_options.vendor.1677670172" name="Vendor name" superClass="com.atollic.truestudio.toolchain_options.vendor" useByScannerDiscovery="false" value="STMicroelectronics" valueType="string"/>
<targetPlatform archList="all" binaryParser="org.eclipse.cdt.core.ELF" id="com.atollic.truestudio.exe.debug.toolchain.platform.228741120" isAbstract="false" name="Debug platform" osList="all" superClass="com.atollic.truestudio.exe.debug.toolchain.platform"/>
<builder buildPath="${workspace_loc:/Dumber-Robot-Firmware}/Debug" customBuilderProperties="toolChainpathType=1|toolChainpathString=/opt/Atollic_TrueSTUDIO_for_STM32_x86_64_9.0.0/ARMTools/bin|" id="com.atollic.truestudio.mbs.builder1.946431501" keepEnvironmentInBuildfile="false" managedBuildOn="true" name="CDT Internal Builder" superClass="com.atollic.truestudio.mbs.builder1"/>
<tool id="com.atollic.truestudio.exe.debug.toolchain.as.1282106265" name="Assembler" superClass="com.atollic.truestudio.exe.debug.toolchain.as">
<option id="com.atollic.truestudio.common_options.target.endianess.337390915" name="Endianess" superClass="com.atollic.truestudio.common_options.target.endianess" useByScannerDiscovery="false"/>
<option id="com.atollic.truestudio.common_options.target.mcpu.1626495693" name="Microcontroller" superClass="com.atollic.truestudio.common_options.target.mcpu" useByScannerDiscovery="false" value="STM32F103C6" valueType="enumerated"/>
<option id="com.atollic.truestudio.common_options.target.instr_set.155423512" name="Instruction set" superClass="com.atollic.truestudio.common_options.target.instr_set" useByScannerDiscovery="false" value="com.atollic.truestudio.common_options.target.instr_set.thumb2" valueType="enumerated"/>
<option id="com.atollic.truestudio.common_options.target.fpucore.1963239944" name="FPU" superClass="com.atollic.truestudio.common_options.target.fpucore" useByScannerDiscovery="false" value="com.atollic.truestudio.common_options.target.fpucore.None" valueType="enumerated"/>
<option id="com.atollic.truestudio.common_options.target.fpu.457240445" name="Floating point" superClass="com.atollic.truestudio.common_options.target.fpu" useByScannerDiscovery="false"/>
<option id="com.atollic.truestudio.as.symbols.defined.1918321435" name="Defined symbols" superClass="com.atollic.truestudio.as.symbols.defined" useByScannerDiscovery="false" valueType="definedSymbols">
<listOptionValue builtIn="false" value="STM32F10X_LD"/>
<listOptionValue builtIn="false" value="USE_STDPERIPH_DRIVER"/>
</option>
<option id="com.atollic.truestudio.as.general.incpath.2055969997" name="Include path" superClass="com.atollic.truestudio.as.general.incpath" valueType="includePath">
<option id="com.atollic.truestudio.as.general.incpath.2122465989" name="Include path" superClass="com.atollic.truestudio.as.general.incpath" useByScannerDiscovery="false" valueType="includePath">
<listOptionValue builtIn="false" value="../src"/>
<listOptionValue builtIn="false" value="../Libraries/STM32F10x_StdPeriph_Driver/inc"/>
<listOptionValue builtIn="false" value="../Libraries/CMSIS/Device/ST/STM32F10x/Include"/>
<listOptionValue builtIn="false" value="../Libraries/CMSIS/Include"/>
</option>
<inputType id="com.atollic.truestudio.as.input.128409797" name="Input" superClass="com.atollic.truestudio.as.input"/>
<inputType id="com.atollic.truestudio.as.input.1815967562" name="Input" superClass="com.atollic.truestudio.as.input"/>
</tool>
<tool id="com.atollic.truestudio.exe.release.toolchain.gcc.34521579" name="C Compiler" superClass="com.atollic.truestudio.exe.release.toolchain.gcc">
<option id="com.atollic.truestudio.gcc.symbols.defined.896134054" name="Defined symbols" superClass="com.atollic.truestudio.gcc.symbols.defined" valueType="definedSymbols">
<tool id="com.atollic.truestudio.exe.debug.toolchain.gcc.176685112" name="C Compiler" superClass="com.atollic.truestudio.exe.debug.toolchain.gcc">
<option id="com.atollic.truestudio.gcc.symbols.defined.1170000142" name="Defined symbols" superClass="com.atollic.truestudio.gcc.symbols.defined" useByScannerDiscovery="false" valueType="definedSymbols">
<listOptionValue builtIn="false" value="STM32F10X_LD"/>
<listOptionValue builtIn="false" value="USE_STDPERIPH_DRIVER"/>
</option>
<option id="com.atollic.truestudio.gcc.directories.select.220679468" name="Include path" superClass="com.atollic.truestudio.gcc.directories.select" valueType="includePath">
<option id="com.atollic.truestudio.gcc.directories.select.1517262429" name="Include path" superClass="com.atollic.truestudio.gcc.directories.select" useByScannerDiscovery="false" valueType="includePath">
<listOptionValue builtIn="false" value="../src"/>
<listOptionValue builtIn="false" value="../Libraries/STM32F10x_StdPeriph_Driver/inc"/>
<listOptionValue builtIn="false" value="../Libraries/CMSIS/Device/ST/STM32F10x/Include"/>
<listOptionValue builtIn="false" value="../Libraries/CMSIS/Include"/>
</option>
<option id="com.atollic.truestudio.common_options.target.endianess.706271228" name="Endianess" superClass="com.atollic.truestudio.common_options.target.endianess"/>
<option id="com.atollic.truestudio.common_options.target.mcpu.1964199330" name="Microcontroller" superClass="com.atollic.truestudio.common_options.target.mcpu" value="STM32F103C6" valueType="enumerated"/>
<option id="com.atollic.truestudio.common_options.target.instr_set.1616704135" name="Instruction set" superClass="com.atollic.truestudio.common_options.target.instr_set" value="com.atollic.truestudio.common_options.target.instr_set.thumb2" valueType="enumerated"/>
<option id="com.atollic.truestudio.common_options.target.fpucore.801415246" name="FPU" superClass="com.atollic.truestudio.common_options.target.fpucore" value="com.atollic.truestudio.common_options.target.fpucore.None" valueType="enumerated"/>
<option id="com.atollic.truestudio.common_options.target.fpu.258702060" name="Floating point" superClass="com.atollic.truestudio.common_options.target.fpu"/>
<option id="com.atollic.truestudio.gcc.optimization.prep_garbage.1280377076" name="Prepare dead code removal " superClass="com.atollic.truestudio.gcc.optimization.prep_garbage" value="true" valueType="boolean"/>
<option id="com.atollic.truestudio.gcc.optimization.prep_data.624201007" name="Prepare dead data removal" superClass="com.atollic.truestudio.gcc.optimization.prep_data" value="true" valueType="boolean"/>
<inputType id="com.atollic.truestudio.gcc.input.723277448" superClass="com.atollic.truestudio.gcc.input"/>
<option id="com.atollic.truestudio.common_options.target.endianess.1137125295" name="Endianess" superClass="com.atollic.truestudio.common_options.target.endianess" useByScannerDiscovery="false"/>
<option id="com.atollic.truestudio.common_options.target.mcpu.1544713666" name="Microcontroller" superClass="com.atollic.truestudio.common_options.target.mcpu" useByScannerDiscovery="false" value="STM32F103C6" valueType="enumerated"/>
<option id="com.atollic.truestudio.common_options.target.instr_set.1258702383" name="Instruction set" superClass="com.atollic.truestudio.common_options.target.instr_set" useByScannerDiscovery="false" value="com.atollic.truestudio.common_options.target.instr_set.thumb2" valueType="enumerated"/>
<option id="com.atollic.truestudio.common_options.target.fpucore.1316464568" name="FPU" superClass="com.atollic.truestudio.common_options.target.fpucore" useByScannerDiscovery="false" value="com.atollic.truestudio.common_options.target.fpucore.None" valueType="enumerated"/>
<option id="com.atollic.truestudio.common_options.target.fpu.1866738467" name="Floating point" superClass="com.atollic.truestudio.common_options.target.fpu" useByScannerDiscovery="false"/>
<option id="com.atollic.truestudio.gcc.optimization.prep_garbage.2044849590" name="Prepare dead code removal " superClass="com.atollic.truestudio.gcc.optimization.prep_garbage" useByScannerDiscovery="false" value="true" valueType="boolean"/>
<option id="com.atollic.truestudio.gcc.optimization.prep_data.1653398661" name="Prepare dead data removal" superClass="com.atollic.truestudio.gcc.optimization.prep_data" useByScannerDiscovery="false" value="true" valueType="boolean"/>
<option id="com.atollic.truestudio.exe.debug.toolchain.gcc.optimization.level.1568105244" name="Optimization Level" superClass="com.atollic.truestudio.exe.debug.toolchain.gcc.optimization.level" useByScannerDiscovery="false" value="com.atollic.truestudio.gcc.optimization.level.0s" valueType="enumerated"/>
<option id="com.atollic.truestudio.exe.debug.toolchain.gcc.debug.info.150606538" superClass="com.atollic.truestudio.exe.debug.toolchain.gcc.debug.info" useByScannerDiscovery="false" value="com.atollic.truestudio.gcc.debug.info.0" valueType="enumerated"/>
<option id="com.atollic.truestudio.gcc.misc.stackusage.111740427" superClass="com.atollic.truestudio.gcc.misc.stackusage" useByScannerDiscovery="false" value="false" valueType="boolean"/>
<inputType id="com.atollic.truestudio.gcc.input.315452709" superClass="com.atollic.truestudio.gcc.input"/>
</tool>
<tool id="com.atollic.truestudio.exe.release.toolchain.ld.506505654" name="C Linker" superClass="com.atollic.truestudio.exe.release.toolchain.ld">
<option id="com.atollic.truestudio.common_options.target.endianess.1015608354" name="Endianess" superClass="com.atollic.truestudio.common_options.target.endianess"/>
<option id="com.atollic.truestudio.common_options.target.mcpu.1474414038" name="Microcontroller" superClass="com.atollic.truestudio.common_options.target.mcpu" value="STM32F103C6" valueType="enumerated"/>
<option id="com.atollic.truestudio.common_options.target.instr_set.176493136" name="Instruction set" superClass="com.atollic.truestudio.common_options.target.instr_set" value="com.atollic.truestudio.common_options.target.instr_set.thumb2" valueType="enumerated"/>
<option id="com.atollic.truestudio.common_options.target.fpucore.1323768380" name="FPU" superClass="com.atollic.truestudio.common_options.target.fpucore" value="com.atollic.truestudio.common_options.target.fpucore.None" valueType="enumerated"/>
<option id="com.atollic.truestudio.common_options.target.fpu.1342724396" name="Floating point" superClass="com.atollic.truestudio.common_options.target.fpu"/>
<option id="com.atollic.truestudio.ld.general.scriptfile.1449950940" name="Linker script" superClass="com.atollic.truestudio.ld.general.scriptfile" value="../stm32_flash.ld" valueType="string"/>
<option id="com.atollic.truestudio.ld.optimization.do_garbage.1461671650" name="Dead code removal " superClass="com.atollic.truestudio.ld.optimization.do_garbage" value="true" valueType="boolean"/>
<tool id="com.atollic.truestudio.exe.debug.toolchain.ld.539950594" name="C Linker" superClass="com.atollic.truestudio.exe.debug.toolchain.ld">
<option id="com.atollic.truestudio.common_options.target.endianess.1683175786" name="Endianess" superClass="com.atollic.truestudio.common_options.target.endianess"/>
<option id="com.atollic.truestudio.common_options.target.mcpu.810336117" name="Microcontroller" superClass="com.atollic.truestudio.common_options.target.mcpu" value="STM32F103C6" valueType="enumerated"/>
<option id="com.atollic.truestudio.common_options.target.instr_set.227078225" name="Instruction set" superClass="com.atollic.truestudio.common_options.target.instr_set" value="com.atollic.truestudio.common_options.target.instr_set.thumb2" valueType="enumerated"/>
<option id="com.atollic.truestudio.common_options.target.fpucore.437910239" name="FPU" superClass="com.atollic.truestudio.common_options.target.fpucore" value="com.atollic.truestudio.common_options.target.fpucore.None" valueType="enumerated"/>
<option id="com.atollic.truestudio.common_options.target.fpu.1122015995" name="Floating point" superClass="com.atollic.truestudio.common_options.target.fpu"/>
<option id="com.atollic.truestudio.ld.general.scriptfile.1007340251" name="Linker script" superClass="com.atollic.truestudio.ld.general.scriptfile" value="../stm32_flash.ld" valueType="string"/>
<option id="com.atollic.truestudio.ld.optimization.do_garbage.1103877399" name="Dead code removal " superClass="com.atollic.truestudio.ld.optimization.do_garbage" value="true" valueType="boolean"/>
</tool>
<tool id="com.atollic.truestudio.exe.release.toolchain.gpp.2117884124" name="C++ Compiler" superClass="com.atollic.truestudio.exe.release.toolchain.gpp">
<option id="com.atollic.truestudio.gpp.symbols.defined.1227169168" name="Defined symbols" superClass="com.atollic.truestudio.gpp.symbols.defined" valueType="definedSymbols">
<tool id="com.atollic.truestudio.exe.debug.toolchain.gpp.1799243953" name="C++ Compiler" superClass="com.atollic.truestudio.exe.debug.toolchain.gpp">
<option id="com.atollic.truestudio.gpp.symbols.defined.765136390" name="Defined symbols" superClass="com.atollic.truestudio.gpp.symbols.defined" useByScannerDiscovery="false" valueType="definedSymbols">
<listOptionValue builtIn="false" value="STM32F10X_LD"/>
<listOptionValue builtIn="false" value="USE_STDPERIPH_DRIVER"/>
</option>
<option id="com.atollic.truestudio.gpp.directories.select.835605758" name="Include path" superClass="com.atollic.truestudio.gpp.directories.select" valueType="includePath">
<option id="com.atollic.truestudio.gpp.directories.select.1422676259" name="Include path" superClass="com.atollic.truestudio.gpp.directories.select" useByScannerDiscovery="false" valueType="includePath">
<listOptionValue builtIn="false" value="../src"/>
<listOptionValue builtIn="false" value="../Libraries/STM32F10x_StdPeriph_Driver/inc"/>
<listOptionValue builtIn="false" value="../Libraries/CMSIS/Device/ST/STM32F10x/Include"/>
<listOptionValue builtIn="false" value="../Libraries/CMSIS/Include"/>
</option>
<option id="com.atollic.truestudio.common_options.target.endianess.1967238277" name="Endianess" superClass="com.atollic.truestudio.common_options.target.endianess"/>
<option id="com.atollic.truestudio.common_options.target.mcpu.1875365386" name="Microcontroller" superClass="com.atollic.truestudio.common_options.target.mcpu" value="STM32F103C6" valueType="enumerated"/>
<option id="com.atollic.truestudio.common_options.target.instr_set.585318403" name="Instruction set" superClass="com.atollic.truestudio.common_options.target.instr_set" value="com.atollic.truestudio.common_options.target.instr_set.thumb2" valueType="enumerated"/>
<option id="com.atollic.truestudio.common_options.target.fpucore.302951526" name="FPU" superClass="com.atollic.truestudio.common_options.target.fpucore" value="com.atollic.truestudio.common_options.target.fpucore.None" valueType="enumerated"/>
<option id="com.atollic.truestudio.common_options.target.fpu.225902667" name="Floating point" superClass="com.atollic.truestudio.common_options.target.fpu"/>
<option id="com.atollic.truestudio.gpp.optimization.prep_garbage.1354058843" name="Prepare dead code removal" superClass="com.atollic.truestudio.gpp.optimization.prep_garbage" value="true" valueType="boolean"/>
<option id="com.atollic.truestudio.gpp.optimization.prep_data.588745643" name="Prepare dead data removal" superClass="com.atollic.truestudio.gpp.optimization.prep_data" value="true" valueType="boolean"/>
<option id="com.atollic.truestudio.gpp.optimization.fno_rtti.252107689" name="Disable RTTI" superClass="com.atollic.truestudio.gpp.optimization.fno_rtti"/>
<option id="com.atollic.truestudio.gpp.optimization.fno_exceptions.2129524145" name="Disable exception handling" superClass="com.atollic.truestudio.gpp.optimization.fno_exceptions"/>
<inputType id="com.atollic.truestudio.gpp.input.1229320757" superClass="com.atollic.truestudio.gpp.input"/>
<option id="com.atollic.truestudio.common_options.target.endianess.779852714" name="Endianess" superClass="com.atollic.truestudio.common_options.target.endianess" useByScannerDiscovery="false"/>
<option id="com.atollic.truestudio.common_options.target.mcpu.2009546706" name="Microcontroller" superClass="com.atollic.truestudio.common_options.target.mcpu" useByScannerDiscovery="false" value="STM32F103C6" valueType="enumerated"/>
<option id="com.atollic.truestudio.common_options.target.instr_set.971161078" name="Instruction set" superClass="com.atollic.truestudio.common_options.target.instr_set" useByScannerDiscovery="false" value="com.atollic.truestudio.common_options.target.instr_set.thumb2" valueType="enumerated"/>
<option id="com.atollic.truestudio.common_options.target.fpucore.76521404" name="FPU" superClass="com.atollic.truestudio.common_options.target.fpucore" useByScannerDiscovery="false" value="com.atollic.truestudio.common_options.target.fpucore.None" valueType="enumerated"/>
<option id="com.atollic.truestudio.common_options.target.fpu.292768194" name="Floating point" superClass="com.atollic.truestudio.common_options.target.fpu" useByScannerDiscovery="false"/>
<option id="com.atollic.truestudio.gpp.optimization.prep_garbage.1295550110" name="Prepare dead code removal" superClass="com.atollic.truestudio.gpp.optimization.prep_garbage" useByScannerDiscovery="false" value="true" valueType="boolean"/>
<option id="com.atollic.truestudio.gpp.optimization.prep_data.1848113239" name="Prepare dead data removal" superClass="com.atollic.truestudio.gpp.optimization.prep_data" useByScannerDiscovery="false" value="true" valueType="boolean"/>
<option id="com.atollic.truestudio.gpp.optimization.fno_rtti.1984887368" name="Disable RTTI" superClass="com.atollic.truestudio.gpp.optimization.fno_rtti" useByScannerDiscovery="false"/>
<option id="com.atollic.truestudio.gpp.optimization.fno_exceptions.2131091817" name="Disable exception handling" superClass="com.atollic.truestudio.gpp.optimization.fno_exceptions" useByScannerDiscovery="false"/>
<option id="com.atollic.truestudio.exe.debug.toolchain.gpp.optimization.level.880563678" name="Optimization Level" superClass="com.atollic.truestudio.exe.debug.toolchain.gpp.optimization.level" useByScannerDiscovery="false" value="com.atollic.truestudio.gpp.optimization.level.00" valueType="enumerated"/>
<option id="com.atollic.truestudio.exe.debug.toolchain.gpp.debug.info.1676148341" superClass="com.atollic.truestudio.exe.debug.toolchain.gpp.debug.info" useByScannerDiscovery="false" value="com.atollic.truestudio.gpp.debug.info.0" valueType="enumerated"/>
<option id="com.atollic.truestudio.gpp.misc.stackusage.1577073534" superClass="com.atollic.truestudio.gpp.misc.stackusage" useByScannerDiscovery="false" value="false" valueType="boolean"/>
<inputType id="com.atollic.truestudio.gpp.input.1483596384" superClass="com.atollic.truestudio.gpp.input"/>
</tool>
<tool id="com.atollic.truestudio.exe.release.toolchain.ldcc.814843865" name="C++ Linker" superClass="com.atollic.truestudio.exe.release.toolchain.ldcc">
<option id="com.atollic.truestudio.common_options.target.endianess.463874311" name="Endianess" superClass="com.atollic.truestudio.common_options.target.endianess"/>
<option id="com.atollic.truestudio.common_options.target.mcpu.310965165" name="Microcontroller" superClass="com.atollic.truestudio.common_options.target.mcpu" value="STM32F103C6" valueType="enumerated"/>
<option id="com.atollic.truestudio.common_options.target.instr_set.1819338136" name="Instruction set" superClass="com.atollic.truestudio.common_options.target.instr_set" value="com.atollic.truestudio.common_options.target.instr_set.thumb2" valueType="enumerated"/>
<option id="com.atollic.truestudio.common_options.target.fpucore.1383712909" name="FPU" superClass="com.atollic.truestudio.common_options.target.fpucore" value="com.atollic.truestudio.common_options.target.fpucore.None" valueType="enumerated"/>
<option id="com.atollic.truestudio.common_options.target.fpu.740897850" name="Floating point" superClass="com.atollic.truestudio.common_options.target.fpu"/>
<option id="com.atollic.truestudio.ldcc.optimization.do_garbage.1252563406" name="Dead code removal" superClass="com.atollic.truestudio.ldcc.optimization.do_garbage" value="true" valueType="boolean"/>
<option id="com.atollic.truestudio.ldcc.general.scriptfile.1933119698" name="Linker script" superClass="com.atollic.truestudio.ldcc.general.scriptfile" value="../stm32_flash.ld" valueType="string"/>
<inputType id="com.atollic.truestudio.ldcc.input.889935215" name="Input" superClass="com.atollic.truestudio.ldcc.input">
<tool id="com.atollic.truestudio.exe.debug.toolchain.ldcc.78429074" name="C++ Linker" superClass="com.atollic.truestudio.exe.debug.toolchain.ldcc">
<option id="com.atollic.truestudio.common_options.target.endianess.1508155988" name="Endianess" superClass="com.atollic.truestudio.common_options.target.endianess" useByScannerDiscovery="false"/>
<option id="com.atollic.truestudio.common_options.target.mcpu.1309806098" name="Microcontroller" superClass="com.atollic.truestudio.common_options.target.mcpu" useByScannerDiscovery="false" value="STM32F103C6" valueType="enumerated"/>
<option id="com.atollic.truestudio.common_options.target.instr_set.1326581983" name="Instruction set" superClass="com.atollic.truestudio.common_options.target.instr_set" useByScannerDiscovery="false" value="com.atollic.truestudio.common_options.target.instr_set.thumb2" valueType="enumerated"/>
<option id="com.atollic.truestudio.common_options.target.fpucore.1327953134" name="FPU" superClass="com.atollic.truestudio.common_options.target.fpucore" useByScannerDiscovery="false" value="com.atollic.truestudio.common_options.target.fpucore.None" valueType="enumerated"/>
<option id="com.atollic.truestudio.common_options.target.fpu.316456134" name="Floating point" superClass="com.atollic.truestudio.common_options.target.fpu" useByScannerDiscovery="false"/>
<option id="com.atollic.truestudio.ldcc.optimization.do_garbage.1063872512" name="Dead code removal" superClass="com.atollic.truestudio.ldcc.optimization.do_garbage" useByScannerDiscovery="false" value="true" valueType="boolean"/>
<option id="com.atollic.truestudio.ldcc.general.scriptfile.1677631160" name="Linker script" superClass="com.atollic.truestudio.ldcc.general.scriptfile" useByScannerDiscovery="false" value="../stm32_flash.ld" valueType="string"/>
<inputType id="com.atollic.truestudio.ldcc.input.1448912373" name="Input" superClass="com.atollic.truestudio.ldcc.input">
<additionalInput kind="additionalinputdependency" paths="$(USER_OBJS)"/>
<additionalInput kind="additionalinput" paths="$(LIBS)"/>
</inputType>
</tool>
<tool id="com.atollic.truestudio.ar.base.1273293321" name="Archiver" superClass="com.atollic.truestudio.ar.base"/>
<tool id="com.atollic.truestudio.exe.release.toolchain.secoutput.1769879070" name="Other" superClass="com.atollic.truestudio.exe.release.toolchain.secoutput"/>
<tool id="com.atollic.truestudio.ar.base.488911491" name="Archiver" superClass="com.atollic.truestudio.ar.base"/>
<tool id="com.atollic.truestudio.exe.debug.toolchain.secoutput.1237334475" name="Other" superClass="com.atollic.truestudio.exe.debug.toolchain.secoutput"/>
</toolChain>
</folderInfo>
<folderInfo id="com.atollic.truestudio.exe.debug.584431509.2045581985.system" name="/" resourcePath="system">
<toolChain id="com.atollic.truestudio.exe.debug.toolchain.1622713741" name="Atollic ARM Tools" superClass="com.atollic.truestudio.exe.debug.toolchain" unusedChildren="">
<option id="com.atollic.truestudio.general.runtimelib.2022035895.1664729184.1404950193" name="Runtime Library" superClass="com.atollic.truestudio.general.runtimelib.2022035895"/>
<option id="com.atollic.truestudio.toolchain_options.mcu.536866847.908777965.359661470" name="Microcontroller" superClass="com.atollic.truestudio.toolchain_options.mcu.536866847"/>
<option id="com.atollic.truestudio.toolchain_options.vendor.636197389.788614232.1573191851" name="Vendor name" superClass="com.atollic.truestudio.toolchain_options.vendor.636197389"/>
<targetPlatform archList="all" binaryParser="org.eclipse.cdt.core.ELF" id="com.atollic.truestudio.exe.debug.toolchain.platform.1940668383" isAbstract="false" name="Debug platform" osList="all" superClass="com.atollic.truestudio.exe.debug.toolchain.platform"/>
<tool id="com.atollic.truestudio.exe.debug.toolchain.as.609504728" name="Assembler" superClass="com.atollic.truestudio.exe.debug.toolchain.as.1282106265">
<inputType id="com.atollic.truestudio.as.input.1107133505" name="Input" superClass="com.atollic.truestudio.as.input"/>
</tool>
<tool id="com.atollic.truestudio.exe.debug.toolchain.gcc.1122108280" name="C Compiler" superClass="com.atollic.truestudio.exe.debug.toolchain.gcc.176685112">
<inputType id="com.atollic.truestudio.gcc.input.931352173" superClass="com.atollic.truestudio.gcc.input"/>
</tool>
<tool id="com.atollic.truestudio.exe.debug.toolchain.ld.1614483643" name="C Linker" superClass="com.atollic.truestudio.exe.debug.toolchain.ld.539950594"/>
<tool id="com.atollic.truestudio.exe.debug.toolchain.gpp.1062710865" name="C++ Compiler" superClass="com.atollic.truestudio.exe.debug.toolchain.gpp.1799243953">
<inputType id="com.atollic.truestudio.gpp.input.65736761" superClass="com.atollic.truestudio.gpp.input"/>
</tool>
<tool id="com.atollic.truestudio.exe.debug.toolchain.ldcc.1006350212" name="C++ Linker" superClass="com.atollic.truestudio.exe.debug.toolchain.ldcc.78429074"/>
<tool id="com.atollic.truestudio.ar.base.1384193587" name="Archiver" superClass="com.atollic.truestudio.ar.base.488911491"/>
<tool id="com.atollic.truestudio.exe.debug.toolchain.secoutput.1245030582" name="Other" superClass="com.atollic.truestudio.exe.debug.toolchain.secoutput.1237334475"/>
</toolChain>
</folderInfo>
<sourceEntries>
<entry flags="VALUE_WORKSPACE_PATH|RESOLVED" kind="sourcePath" name="Libraries"/>
<entry flags="VALUE_WORKSPACE_PATH|RESOLVED" kind="sourcePath" name="src"/>
<entry excluding="MAE.h|SPI.h|cmde_spi.h|MAE.c|SPI.c|cmde_spi.c|main.cpp|it_dubmy.c" flags="VALUE_WORKSPACE_PATH|RESOLVED" kind="sourcePath" name="src"/>
<entry flags="VALUE_WORKSPACE_PATH|RESOLVED" kind="sourcePath" name="system"/>
</sourceEntries>
</configuration>
</storageModule>

View file

@ -1,3 +1,4 @@
/Debug/
/html/
/Release/

View file

@ -10,7 +10,7 @@
</provider>
</extension>
</configuration>
<configuration id="com.atollic.truestudio.configuration.release.1711240076" name="Release">
<configuration id="com.atollic.truestudio.exe.debug.584431509.2045581985" name="Release">
<extension point="org.eclipse.cdt.core.LanguageSettingsProvider">
<provider copy-of="extension" id="org.eclipse.cdt.ui.UserLanguageSettingsProvider"/>
<provider-reference id="org.eclipse.cdt.managedbuilder.core.MBSLanguageSettingsProvider" ref="shared-provider"/>

View file

@ -1,10 +1,20 @@
eclipse.preferences.version=1
environment/buildEnvironmentInclude/com.atollic.truestudio.exe.debug.584431509.2045581985/CPATH/delimiter=\:
environment/buildEnvironmentInclude/com.atollic.truestudio.exe.debug.584431509.2045581985/CPATH/operation=remove
environment/buildEnvironmentInclude/com.atollic.truestudio.exe.debug.584431509.2045581985/C_INCLUDE_PATH/delimiter=\:
environment/buildEnvironmentInclude/com.atollic.truestudio.exe.debug.584431509.2045581985/C_INCLUDE_PATH/operation=remove
environment/buildEnvironmentInclude/com.atollic.truestudio.exe.debug.584431509.2045581985/append=true
environment/buildEnvironmentInclude/com.atollic.truestudio.exe.debug.584431509.2045581985/appendContributed=true
environment/buildEnvironmentInclude/com.atollic.truestudio.exe.debug.584431509/CPATH/delimiter=\:
environment/buildEnvironmentInclude/com.atollic.truestudio.exe.debug.584431509/CPATH/operation=remove
environment/buildEnvironmentInclude/com.atollic.truestudio.exe.debug.584431509/C_INCLUDE_PATH/delimiter=\:
environment/buildEnvironmentInclude/com.atollic.truestudio.exe.debug.584431509/C_INCLUDE_PATH/operation=remove
environment/buildEnvironmentInclude/com.atollic.truestudio.exe.debug.584431509/append=true
environment/buildEnvironmentInclude/com.atollic.truestudio.exe.debug.584431509/appendContributed=true
environment/buildEnvironmentLibrary/com.atollic.truestudio.exe.debug.584431509.2045581985/LIBRARY_PATH/delimiter=\:
environment/buildEnvironmentLibrary/com.atollic.truestudio.exe.debug.584431509.2045581985/LIBRARY_PATH/operation=remove
environment/buildEnvironmentLibrary/com.atollic.truestudio.exe.debug.584431509.2045581985/append=true
environment/buildEnvironmentLibrary/com.atollic.truestudio.exe.debug.584431509.2045581985/appendContributed=true
environment/buildEnvironmentLibrary/com.atollic.truestudio.exe.debug.584431509/LIBRARY_PATH/delimiter=\:
environment/buildEnvironmentLibrary/com.atollic.truestudio.exe.debug.584431509/LIBRARY_PATH/operation=remove
environment/buildEnvironmentLibrary/com.atollic.truestudio.exe.debug.584431509/append=true

View file

@ -38,5 +38,8 @@
<packet name="GetBattery">
<payload>76760D</payload>
</packet>
<packet name="PowerOff">
<payload>7A7A0D</payload>
</packet>
</packets_list>
</data>

View file

@ -49,6 +49,7 @@
#define BusyStateCMD 'b'
#define TestCMD 't'
#define DebugCMD 'a'
#define PowerOffCMD 'z'
#define OK_ANS "O\r"
#define ERR_ANS "E\r"
@ -57,6 +58,23 @@
#define BAT_LOW "1\r"
#define BAT_EMPTY "0\r"
/* Prototype des fonctions */
char cmdVerifyChecksum(void);
void cmdAddChecksum(void);
void cmdResetAction(void);
void cmdBusyStateAction(void);
void cmdPingAction(void);
void cmdVersionAction(void);
void cmdStartWithoutWatchdogAction(void);
void cmdMoveAction(void);
void cmdTurnAction(void);
void cmdBatteryVoltageAction(void);
void cmdStartWithWatchdogAction(void);
void cmdResetWatchdogAction(void);
void cmdDebugAction(void);
void cmdPowerOffAction(void);
/** @addtogroup Checksum
* @{
*/
@ -138,8 +156,11 @@ void cmdManage(void) {
if (cmdVerifyChecksum() != 0) {
strcpy(sendString, UNKNOW_ANS);
} else { // Checksum valide
if (Dumber.StateSystem==STATE_DISABLE) { // SI la batterie est trop faible, impossible d'accepter une commande: on reste dans ce mode
strcpy(sendString, ERR_ANS);
if (Dumber.StateSystem==STATE_DISABLE) { // SI la batterie est trop faible, impossible d'accepter une commande sauf poweroff: on reste dans ce mode
if (receiptString[0]==PowerOffCMD)
cmdPowerOffAction();
else
strcpy(sendString, ERR_ANS);
} else {
switch (receiptString[0]) {
case PingCMD:
@ -182,10 +203,13 @@ void cmdManage(void) {
cmdBusyStateAction();
break;
case 'a':
case DebugCMD:
cmdDebugAction();
break;
case PowerOffCMD:
cmdPowerOffAction();
break;
default:
strcpy(sendString, UNKNOW_ANS);
}
@ -418,6 +442,25 @@ void cmdDebugAction(void) {
usartSendData();
}
/**
* @brief Eteint le robot
*
* @param None
* @retval None
*/
void cmdPowerOffAction(void) {
volatile int i;
systemChangeState(STATE_DISABLE);
strcpy(sendString, OK_ANS);
cmdAddChecksum();
usartSendData();
/* Attente d'un certain temps (100 ms), pour que la reponse parte */
for (i=0; i<100000; i++);
systemShutDown(); // Ne ressort jamais de cette fonction
}
/**
* @}
*/

View file

@ -22,19 +22,7 @@
#include <stm32f10x.h>
void cmdManage(void);
char cmdVerifyChecksum(void);
void cmdAddChecksum(void);
void cmdResetAction(void);
void cmdBusyStateAction(void);
void cmdPingAction(void);
void cmdVersionAction(void);
void cmdStartWithoutWatchdogAction(void);
void cmdMoveAction(void);
void cmdTurnAction(void);
void cmdBatteryVoltageAction(void);
void cmdStartWithWatchdogAction(void);
void cmdResetWatchdogAction(void);
void cmdDebugAction(void);
#endif /* _CMD_MANAGER_H_ */

View file

@ -33,7 +33,7 @@
#include "stm32f10x.h"
/* Déclaration des Constantes */
#define VERSION "version 1.3\r"
#define VERSION "version 1.4\r"
#define SPI 10
#define USART 20
@ -47,9 +47,9 @@
#define UNDEFINED 101
#define TIMER_1s 1000 // 1 sec
#define TIMER_Watchdog 3050 //
#define TTMER_Inactivity 120000 // 2 min
#define TIMER_1s 1000 // 1 sec
//#define TIMER_Watchdog 3050
//#define TTMER_Inactivity 120000 // 2 min
#define WATCHDOG_MIN 970
#define WATCHDOG_MAX 1030