Merge Prepare a class for button-hold enchancement #25 from vas-dav/button-hold
Prepare a class for button-hold enchancement
This commit is contained in:
commit
9358ede4df
268
SwitchController/.cproject
Normal file
268
SwitchController/.cproject
Normal file
@ -0,0 +1,268 @@
|
|||||||
|
<?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.crt.advproject.config.lib.debug.635589349">
|
||||||
|
<storageModule buildSystemId="org.eclipse.cdt.managedbuilder.core.configurationDataProvider" id="com.crt.advproject.config.lib.debug.635589349" moduleId="org.eclipse.cdt.core.settings" name="Debug">
|
||||||
|
<externalSettings>
|
||||||
|
<externalSetting>
|
||||||
|
<entry flags="VALUE_WORKSPACE_PATH" kind="includePath" name="/SwitchController"/>
|
||||||
|
<entry flags="VALUE_WORKSPACE_PATH" kind="libraryPath" name="/SwitchController/Debug"/>
|
||||||
|
<entry flags="RESOLVED" kind="libraryFile" name="SwitchController" srcPrefixMapping="" srcRootPath=""/>
|
||||||
|
</externalSetting>
|
||||||
|
</externalSettings>
|
||||||
|
<extensions>
|
||||||
|
<extension id="org.eclipse.cdt.core.ELF" point="org.eclipse.cdt.core.BinaryParser"/>
|
||||||
|
<extension id="org.eclipse.cdt.core.GNU_ELF" point="org.eclipse.cdt.core.BinaryParser"/>
|
||||||
|
<extension id="org.eclipse.cdt.core.GmakeErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
|
||||||
|
<extension id="org.eclipse.cdt.core.GASErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
|
||||||
|
<extension id="org.eclipse.cdt.core.GLDErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
|
||||||
|
<extension id="org.eclipse.cdt.core.CWDLocator" 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="a" artifactName="${ProjName}" buildArtefactType="org.eclipse.cdt.build.core.buildArtefactType.staticLib" buildProperties="org.eclipse.cdt.build.core.buildArtefactType=org.eclipse.cdt.build.core.buildArtefactType.staticLib" cleanCommand="rm -rf" description="Debug build" errorParsers="org.eclipse.cdt.core.CWDLocator;org.eclipse.cdt.core.GmakeErrorParser;org.eclipse.cdt.core.GCCErrorParser;org.eclipse.cdt.core.GLDErrorParser;org.eclipse.cdt.core.GASErrorParser" id="com.crt.advproject.config.lib.debug.635589349" name="Debug" parent="com.crt.advproject.config.lib.debug" postannouncebuildStep="Performing post-build steps" postbuildStep="arm-none-eabi-size "lib${BuildArtifactFileName}" ; # arm-none-eabi-objdump -h -S "lib${BuildArtifactFileName}" >"${BuildArtifactFileBaseName}.lss"">
|
||||||
|
<folderInfo id="com.crt.advproject.config.lib.debug.635589349." name="/" resourcePath="">
|
||||||
|
<toolChain id="com.crt.advproject.toolchain.lib.debug.2140760951" name="NXP MCU Tools" superClass="com.crt.advproject.toolchain.lib.debug">
|
||||||
|
<targetPlatform binaryParser="org.eclipse.cdt.core.ELF;org.eclipse.cdt.core.GNU_ELF" id="com.crt.advproject.platform.lib.debug.196257978" name="ARM-based MCU (Debug)" superClass="com.crt.advproject.platform.lib.debug"/>
|
||||||
|
<builder buildPath="${workspace_loc:/SwitchController}/Debug" id="com.crt.advproject.builder.lib.debug.1193962071" keepEnvironmentInBuildfile="false" managedBuildOn="true" name="Gnu Make Builder" superClass="com.crt.advproject.builder.lib.debug"/>
|
||||||
|
<tool id="com.crt.advproject.cpp.lib.debug.1578552365" name="MCU C++ Compiler" superClass="com.crt.advproject.cpp.lib.debug">
|
||||||
|
<option id="com.crt.advproject.cpp.thumb.42808972" name="Thumb mode" superClass="com.crt.advproject.cpp.thumb" useByScannerDiscovery="false" value="true" valueType="boolean"/>
|
||||||
|
<option id="com.crt.advproject.cpp.specs.1719869092" name="Specs" superClass="com.crt.advproject.cpp.specs" useByScannerDiscovery="false" value="com.crt.advproject.cpp.specs.newlib" valueType="enumerated"/>
|
||||||
|
<option id="com.crt.advproject.cpp.arch.1842204631" name="Architecture" superClass="com.crt.advproject.cpp.arch" useByScannerDiscovery="true" value="com.crt.advproject.cpp.target.cm3" valueType="enumerated"/>
|
||||||
|
<option IS_BUILTIN_EMPTY="false" IS_VALUE_EMPTY="false" id="gnu.cpp.compiler.option.preprocessor.def.35080570" name="Defined symbols (-D)" superClass="gnu.cpp.compiler.option.preprocessor.def" useByScannerDiscovery="false" valueType="definedSymbols">
|
||||||
|
<listOptionValue builtIn="false" value="DEBUG"/>
|
||||||
|
<listOptionValue builtIn="false" value="__CODE_RED"/>
|
||||||
|
<listOptionValue builtIn="false" value="__NEWLIB__"/>
|
||||||
|
<listOptionValue builtIn="false" value="CORE_M3"/>
|
||||||
|
<listOptionValue builtIn="false" value="__USE_LPCOPEN"/>
|
||||||
|
<listOptionValue builtIn="false" value="__LPC15XX__"/>
|
||||||
|
</option>
|
||||||
|
<option id="gnu.cpp.compiler.option.other.other.1245317167" name="Other flags" superClass="gnu.cpp.compiler.option.other.other" useByScannerDiscovery="false" value="-c -fmessage-length=0 -fno-builtin -ffunction-sections -fdata-sections -fno-rtti -fno-exceptions" valueType="string"/>
|
||||||
|
<option id="gnu.cpp.compiler.option.optimization.flags.2081311291" name="Other optimization flags" superClass="gnu.cpp.compiler.option.optimization.flags" useByScannerDiscovery="false" value="-fno-common" valueType="string"/>
|
||||||
|
<option id="com.crt.advproject.cpp.hdrlib.1685627813" name="Library headers" superClass="com.crt.advproject.cpp.hdrlib" useByScannerDiscovery="false" value="Newlib" valueType="enumerated"/>
|
||||||
|
<option id="com.crt.advproject.cpp.fpu.147933061" name="Floating point" superClass="com.crt.advproject.cpp.fpu" useByScannerDiscovery="true"/>
|
||||||
|
<option IS_BUILTIN_EMPTY="false" IS_VALUE_EMPTY="false" id="gnu.cpp.compiler.option.include.paths.2143294611" name="Include paths (-I)" superClass="gnu.cpp.compiler.option.include.paths" useByScannerDiscovery="false" valueType="includePath">
|
||||||
|
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/inc}""/>
|
||||||
|
<listOptionValue builtIn="false" value=""${workspace_loc:/lpc_board_nxp_lpcxpresso_1549/inc}""/>
|
||||||
|
<listOptionValue builtIn="false" value=""${workspace_loc:/lpc_chip_15xx/inc}""/>
|
||||||
|
<listOptionValue builtIn="false" value=""${workspace_loc://inc}""/>
|
||||||
|
<listOptionValue builtIn="false" value=""${workspace_loc:/DigitalIoPin/inc}""/>
|
||||||
|
<listOptionValue builtIn="false" value=""${workspace_loc:/Timer/inc}""/>
|
||||||
|
<listOptionValue builtIn="false" value=""${workspace_loc:/StateHandler/inc}""/>
|
||||||
|
<listOptionValue builtIn="false" value=""${workspace_loc:/LiquidCrystal/inc}""/>
|
||||||
|
</option>
|
||||||
|
<option id="com.crt.advproject.cpp.misc.dialect.1439270310" name="Language standard" superClass="com.crt.advproject.cpp.misc.dialect" useByScannerDiscovery="true" value="com.crt.advproject.misc.dialect.c++11" valueType="enumerated"/>
|
||||||
|
<inputType id="com.crt.advproject.compiler.cpp.input.1836081321" superClass="com.crt.advproject.compiler.cpp.input"/>
|
||||||
|
</tool>
|
||||||
|
<tool id="com.crt.advproject.gcc.lib.debug.259312642" name="MCU C Compiler" superClass="com.crt.advproject.gcc.lib.debug">
|
||||||
|
<option id="com.crt.advproject.gcc.thumb.514647179" name="Thumb mode" superClass="com.crt.advproject.gcc.thumb" useByScannerDiscovery="false" value="true" valueType="boolean"/>
|
||||||
|
<option id="com.crt.advproject.gcc.arch.1879582437" name="Architecture" superClass="com.crt.advproject.gcc.arch" useByScannerDiscovery="true" value="com.crt.advproject.gcc.target.cm3" valueType="enumerated"/>
|
||||||
|
<option IS_BUILTIN_EMPTY="false" IS_VALUE_EMPTY="false" id="gnu.c.compiler.option.preprocessor.def.symbols.552213767" name="Defined symbols (-D)" superClass="gnu.c.compiler.option.preprocessor.def.symbols" useByScannerDiscovery="false" valueType="definedSymbols">
|
||||||
|
<listOptionValue builtIn="false" value="DEBUG"/>
|
||||||
|
<listOptionValue builtIn="false" value="__CODE_RED"/>
|
||||||
|
<listOptionValue builtIn="false" value="CORE_M3"/>
|
||||||
|
<listOptionValue builtIn="false" value="__USE_LPCOPEN"/>
|
||||||
|
<listOptionValue builtIn="false" value="__LPC15XX__"/>
|
||||||
|
<listOptionValue builtIn="false" value="__NEWLIB__"/>
|
||||||
|
</option>
|
||||||
|
<option id="gnu.c.compiler.option.misc.other.755130431" name="Other flags" superClass="gnu.c.compiler.option.misc.other" useByScannerDiscovery="false" value="-c -fmessage-length=0 -fno-builtin -ffunction-sections -fdata-sections" valueType="string"/>
|
||||||
|
<option id="gnu.c.compiler.option.optimization.flags.1689384638" name="Other optimization flags" superClass="gnu.c.compiler.option.optimization.flags" useByScannerDiscovery="false" value="-fno-common" valueType="string"/>
|
||||||
|
<option IS_BUILTIN_EMPTY="false" IS_VALUE_EMPTY="false" id="gnu.c.compiler.option.include.paths.120577390" name="Include paths (-I)" superClass="gnu.c.compiler.option.include.paths" useByScannerDiscovery="false" valueType="includePath">
|
||||||
|
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/inc}""/>
|
||||||
|
<listOptionValue builtIn="false" value=""${workspace_loc:/lpc_board_nxp_lpcxpresso_1549/inc}""/>
|
||||||
|
<listOptionValue builtIn="false" value=""${workspace_loc:/lpc_chip_15xx/inc}""/>
|
||||||
|
<listOptionValue builtIn="false" value=""${workspace_loc://inc}""/>
|
||||||
|
<listOptionValue builtIn="false" value=""${workspace_loc:/DigitalIoPin/inc}""/>
|
||||||
|
<listOptionValue builtIn="false" value=""${workspace_loc:/Timer/inc}""/>
|
||||||
|
<listOptionValue builtIn="false" value=""${workspace_loc:/StateHandler/inc}""/>
|
||||||
|
<listOptionValue builtIn="false" value=""${workspace_loc:/LiquidCrystal/inc}""/>
|
||||||
|
</option>
|
||||||
|
<option id="com.crt.advproject.c.misc.dialect.1562701315" name="Language standard" superClass="com.crt.advproject.c.misc.dialect" useByScannerDiscovery="true" value="com.crt.advproject.misc.dialect.c11" valueType="enumerated"/>
|
||||||
|
<option id="com.crt.advproject.gcc.hdrlib.1858206733" name="Library headers" superClass="com.crt.advproject.gcc.hdrlib" useByScannerDiscovery="false" value="Newlib" valueType="enumerated"/>
|
||||||
|
<option id="com.crt.advproject.gcc.specs.509811958" name="Specs" superClass="com.crt.advproject.gcc.specs" useByScannerDiscovery="false" value="com.crt.advproject.gcc.specs.newlib" valueType="enumerated"/>
|
||||||
|
<inputType id="com.crt.advproject.compiler.input.2112036038" superClass="com.crt.advproject.compiler.input"/>
|
||||||
|
</tool>
|
||||||
|
<tool id="com.crt.advproject.gas.lib.debug.931630343" name="MCU Assembler" superClass="com.crt.advproject.gas.lib.debug">
|
||||||
|
<option id="com.crt.advproject.gas.thumb.2115778133" name="Thumb mode" superClass="com.crt.advproject.gas.thumb" value="true" valueType="boolean"/>
|
||||||
|
<option id="com.crt.advproject.gas.arch.1339408441" name="Architecture" superClass="com.crt.advproject.gas.arch" value="com.crt.advproject.gas.target.cm3" valueType="enumerated"/>
|
||||||
|
<option id="gnu.both.asm.option.flags.crt.952745785" name="Assembler flags" superClass="gnu.both.asm.option.flags.crt" value="-c -x assembler-with-cpp -DDEBUG -D__CODE_RED -DCORE_M3 -D__USE_LPCOPEN -D__LPC15XX__ -D__NEWLIB__" valueType="string"/>
|
||||||
|
<option IS_BUILTIN_EMPTY="false" IS_VALUE_EMPTY="false" id="gnu.both.asm.option.include.paths.31861287" name="Include paths (-I)" superClass="gnu.both.asm.option.include.paths" valueType="includePath">
|
||||||
|
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/inc}""/>
|
||||||
|
<listOptionValue builtIn="false" value=""${workspace_loc:/lpc_board_nxp_lpcxpresso_1549/inc}""/>
|
||||||
|
<listOptionValue builtIn="false" value=""${workspace_loc:/lpc_chip_15xx/inc}""/>
|
||||||
|
<listOptionValue builtIn="false" value=""${workspace_loc://inc}""/>
|
||||||
|
<listOptionValue builtIn="false" value=""${workspace_loc:/DigitalIoPin/inc}""/>
|
||||||
|
<listOptionValue builtIn="false" value=""${workspace_loc:/Timer/inc}""/>
|
||||||
|
<listOptionValue builtIn="false" value=""${workspace_loc:/StateHandler/inc}""/>
|
||||||
|
<listOptionValue builtIn="false" value=""${workspace_loc:/LiquidCrystal/inc}""/>
|
||||||
|
</option>
|
||||||
|
<option id="com.crt.advproject.gas.hdrlib.679003420" name="Library headers" superClass="com.crt.advproject.gas.hdrlib" value="Newlib" valueType="enumerated"/>
|
||||||
|
<option id="com.crt.advproject.gas.specs.658181602" name="Specs" superClass="com.crt.advproject.gas.specs" value="com.crt.advproject.gas.specs.newlib" valueType="enumerated"/>
|
||||||
|
<inputType id="cdt.managedbuild.tool.gnu.assembler.input.2139380937" superClass="cdt.managedbuild.tool.gnu.assembler.input"/>
|
||||||
|
<inputType id="com.crt.advproject.assembler.input.1892693440" name="Additional Assembly Source Files" superClass="com.crt.advproject.assembler.input"/>
|
||||||
|
</tool>
|
||||||
|
<tool id="com.crt.advproject.ar.lib.debug.1620867410" name="MCU Archiver" superClass="com.crt.advproject.ar.lib.debug"/>
|
||||||
|
</toolChain>
|
||||||
|
</folderInfo>
|
||||||
|
<sourceEntries>
|
||||||
|
<entry flags="VALUE_WORKSPACE_PATH|RESOLVED" kind="sourcePath" name="inc"/>
|
||||||
|
<entry flags="VALUE_WORKSPACE_PATH|RESOLVED" kind="sourcePath" name="src"/>
|
||||||
|
</sourceEntries>
|
||||||
|
</configuration>
|
||||||
|
</storageModule>
|
||||||
|
<storageModule moduleId="org.eclipse.cdt.core.externalSettings"/>
|
||||||
|
</cconfiguration>
|
||||||
|
<cconfiguration id="com.crt.advproject.config.lib.release.1997903078">
|
||||||
|
<storageModule buildSystemId="org.eclipse.cdt.managedbuilder.core.configurationDataProvider" id="com.crt.advproject.config.lib.release.1997903078" moduleId="org.eclipse.cdt.core.settings" name="Release">
|
||||||
|
<externalSettings>
|
||||||
|
<externalSetting>
|
||||||
|
<entry flags="VALUE_WORKSPACE_PATH" kind="includePath" name="/SwitchController"/>
|
||||||
|
<entry flags="VALUE_WORKSPACE_PATH" kind="libraryPath" name="/SwitchController/Release"/>
|
||||||
|
<entry flags="RESOLVED" kind="libraryFile" name="SwitchController" srcPrefixMapping="" srcRootPath=""/>
|
||||||
|
</externalSetting>
|
||||||
|
</externalSettings>
|
||||||
|
<extensions>
|
||||||
|
<extension id="org.eclipse.cdt.core.ELF" point="org.eclipse.cdt.core.BinaryParser"/>
|
||||||
|
<extension id="org.eclipse.cdt.core.GNU_ELF" point="org.eclipse.cdt.core.BinaryParser"/>
|
||||||
|
<extension id="org.eclipse.cdt.core.GmakeErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
|
||||||
|
<extension id="org.eclipse.cdt.core.GASErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
|
||||||
|
<extension id="org.eclipse.cdt.core.GLDErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
|
||||||
|
<extension id="org.eclipse.cdt.core.CWDLocator" 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="a" artifactName="${ProjName}" buildArtefactType="org.eclipse.cdt.build.core.buildArtefactType.staticLib" buildProperties="org.eclipse.cdt.build.core.buildArtefactType=org.eclipse.cdt.build.core.buildArtefactType.staticLib" cleanCommand="rm -rf" description="Release build" errorParsers="org.eclipse.cdt.core.CWDLocator;org.eclipse.cdt.core.GmakeErrorParser;org.eclipse.cdt.core.GCCErrorParser;org.eclipse.cdt.core.GLDErrorParser;org.eclipse.cdt.core.GASErrorParser" id="com.crt.advproject.config.lib.release.1997903078" name="Release" parent="com.crt.advproject.config.lib.release" postannouncebuildStep="Performing post-build steps" postbuildStep="arm-none-eabi-size "lib${BuildArtifactFileName}" ; # arm-none-eabi-objdump -h -S "lib${BuildArtifactFileName}" >"${BuildArtifactFileBaseName}.lss"">
|
||||||
|
<folderInfo id="com.crt.advproject.config.lib.release.1997903078." name="/" resourcePath="">
|
||||||
|
<toolChain id="com.crt.advproject.toolchain.lib.release.341038737" name="NXP MCU Tools" superClass="com.crt.advproject.toolchain.lib.release">
|
||||||
|
<targetPlatform binaryParser="org.eclipse.cdt.core.ELF;org.eclipse.cdt.core.GNU_ELF" id="com.crt.advproject.platform.lib.release.416522589" name="ARM-based MCU (Debug)" superClass="com.crt.advproject.platform.lib.release"/>
|
||||||
|
<builder buildPath="${workspace_loc:/SwitchController}/Release" id="com.crt.advproject.builder.lib.release.679219730" keepEnvironmentInBuildfile="false" managedBuildOn="true" name="Gnu Make Builder" superClass="com.crt.advproject.builder.lib.release"/>
|
||||||
|
<tool id="com.crt.advproject.cpp.lib.release.1312591124" name="MCU C++ Compiler" superClass="com.crt.advproject.cpp.lib.release">
|
||||||
|
<option id="com.crt.advproject.cpp.thumb.771613122" name="Thumb mode" superClass="com.crt.advproject.cpp.thumb" useByScannerDiscovery="false" value="true" valueType="boolean"/>
|
||||||
|
<option id="com.crt.advproject.cpp.specs.1053608950" name="Specs" superClass="com.crt.advproject.cpp.specs" useByScannerDiscovery="false" value="com.crt.advproject.cpp.specs.newlib" valueType="enumerated"/>
|
||||||
|
<option id="com.crt.advproject.cpp.arch.1997590441" name="Architecture" superClass="com.crt.advproject.cpp.arch" useByScannerDiscovery="true" value="com.crt.advproject.cpp.target.cm3" valueType="enumerated"/>
|
||||||
|
<option IS_BUILTIN_EMPTY="false" IS_VALUE_EMPTY="false" id="gnu.cpp.compiler.option.preprocessor.def.1787439783" name="Defined symbols (-D)" superClass="gnu.cpp.compiler.option.preprocessor.def" useByScannerDiscovery="false" valueType="definedSymbols">
|
||||||
|
<listOptionValue builtIn="false" value="NDEBUG"/>
|
||||||
|
<listOptionValue builtIn="false" value="__CODE_RED"/>
|
||||||
|
<listOptionValue builtIn="false" value="__NEWLIB__"/>
|
||||||
|
<listOptionValue builtIn="false" value="CORE_M3"/>
|
||||||
|
<listOptionValue builtIn="false" value="__USE_LPCOPEN"/>
|
||||||
|
<listOptionValue builtIn="false" value="__LPC15XX__"/>
|
||||||
|
</option>
|
||||||
|
<option id="gnu.cpp.compiler.option.other.other.1481480731" name="Other flags" superClass="gnu.cpp.compiler.option.other.other" useByScannerDiscovery="false" value="-c -fmessage-length=0 -fno-builtin -ffunction-sections -fdata-sections -fno-rtti -fno-exceptions" valueType="string"/>
|
||||||
|
<option id="gnu.cpp.compiler.option.optimization.flags.2082809325" name="Other optimization flags" superClass="gnu.cpp.compiler.option.optimization.flags" useByScannerDiscovery="false" value="-fno-common -Os" valueType="string"/>
|
||||||
|
<option IS_BUILTIN_EMPTY="false" IS_VALUE_EMPTY="false" id="gnu.cpp.compiler.option.include.paths.37758451" name="Include paths (-I)" superClass="gnu.cpp.compiler.option.include.paths" useByScannerDiscovery="false" valueType="includePath">
|
||||||
|
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/inc}""/>
|
||||||
|
<listOptionValue builtIn="false" value=""${workspace_loc:/lpc_board_nxp_lpcxpresso_1549/inc}""/>
|
||||||
|
<listOptionValue builtIn="false" value=""${workspace_loc:/lpc_chip_15xx/inc}""/>
|
||||||
|
<listOptionValue builtIn="false" value=""${workspace_loc://inc}""/>
|
||||||
|
<listOptionValue builtIn="false" value=""${workspace_loc:/DigitalIoPin/inc}""/>
|
||||||
|
<listOptionValue builtIn="false" value=""${workspace_loc:/Timer/inc}""/>
|
||||||
|
<listOptionValue builtIn="false" value=""${workspace_loc:/StateHandler/inc}""/>
|
||||||
|
<listOptionValue builtIn="false" value=""${workspace_loc:/LiquidCrystal/inc}""/>
|
||||||
|
</option>
|
||||||
|
<option id="com.crt.advproject.cpp.misc.dialect.637944562" name="Language standard" superClass="com.crt.advproject.cpp.misc.dialect" useByScannerDiscovery="true" value="com.crt.advproject.misc.dialect.c++11" valueType="enumerated"/>
|
||||||
|
<option id="com.crt.advproject.cpp.hdrlib.538882538" name="Library headers" superClass="com.crt.advproject.cpp.hdrlib" useByScannerDiscovery="false" value="Newlib" valueType="enumerated"/>
|
||||||
|
<inputType id="com.crt.advproject.compiler.cpp.input.957918401" superClass="com.crt.advproject.compiler.cpp.input"/>
|
||||||
|
</tool>
|
||||||
|
<tool id="com.crt.advproject.gcc.lib.release.1056379631" name="MCU C Compiler" superClass="com.crt.advproject.gcc.lib.release">
|
||||||
|
<option id="com.crt.advproject.gcc.thumb.855040891" name="Thumb mode" superClass="com.crt.advproject.gcc.thumb" useByScannerDiscovery="false" value="true" valueType="boolean"/>
|
||||||
|
<option id="com.crt.advproject.gcc.arch.826134437" name="Architecture" superClass="com.crt.advproject.gcc.arch" useByScannerDiscovery="true" value="com.crt.advproject.gcc.target.cm3" valueType="enumerated"/>
|
||||||
|
<option IS_BUILTIN_EMPTY="false" IS_VALUE_EMPTY="false" id="gnu.c.compiler.option.preprocessor.def.symbols.1138392333" name="Defined symbols (-D)" superClass="gnu.c.compiler.option.preprocessor.def.symbols" useByScannerDiscovery="false" valueType="definedSymbols">
|
||||||
|
<listOptionValue builtIn="false" value="NDEBUG"/>
|
||||||
|
<listOptionValue builtIn="false" value="__CODE_RED"/>
|
||||||
|
<listOptionValue builtIn="false" value="CORE_M3"/>
|
||||||
|
<listOptionValue builtIn="false" value="__USE_LPCOPEN"/>
|
||||||
|
<listOptionValue builtIn="false" value="__LPC15XX__"/>
|
||||||
|
<listOptionValue builtIn="false" value="__NEWLIB__"/>
|
||||||
|
</option>
|
||||||
|
<option id="gnu.c.compiler.option.misc.other.1233567268" name="Other flags" superClass="gnu.c.compiler.option.misc.other" useByScannerDiscovery="false" value="-c -fmessage-length=0 -fno-builtin -ffunction-sections -fdata-sections" valueType="string"/>
|
||||||
|
<option id="gnu.c.compiler.option.optimization.flags.331103464" name="Other optimization flags" superClass="gnu.c.compiler.option.optimization.flags" useByScannerDiscovery="false" value="-fno-common" valueType="string"/>
|
||||||
|
<option IS_BUILTIN_EMPTY="false" IS_VALUE_EMPTY="false" id="gnu.c.compiler.option.include.paths.1614125517" name="Include paths (-I)" superClass="gnu.c.compiler.option.include.paths" useByScannerDiscovery="false" valueType="includePath">
|
||||||
|
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/inc}""/>
|
||||||
|
<listOptionValue builtIn="false" value=""${workspace_loc:/lpc_board_nxp_lpcxpresso_1549/inc}""/>
|
||||||
|
<listOptionValue builtIn="false" value=""${workspace_loc:/lpc_chip_15xx/inc}""/>
|
||||||
|
<listOptionValue builtIn="false" value=""${workspace_loc://inc}""/>
|
||||||
|
<listOptionValue builtIn="false" value=""${workspace_loc:/DigitalIoPin/inc}""/>
|
||||||
|
<listOptionValue builtIn="false" value=""${workspace_loc:/Timer/inc}""/>
|
||||||
|
<listOptionValue builtIn="false" value=""${workspace_loc:/StateHandler/inc}""/>
|
||||||
|
<listOptionValue builtIn="false" value=""${workspace_loc:/LiquidCrystal/inc}""/>
|
||||||
|
</option>
|
||||||
|
<option id="com.crt.advproject.c.misc.dialect.1049661750" name="Language standard" superClass="com.crt.advproject.c.misc.dialect" useByScannerDiscovery="true" value="com.crt.advproject.misc.dialect.c11" valueType="enumerated"/>
|
||||||
|
<option id="com.crt.advproject.gcc.hdrlib.334400252" name="Library headers" superClass="com.crt.advproject.gcc.hdrlib" useByScannerDiscovery="false" value="Newlib" valueType="enumerated"/>
|
||||||
|
<option id="com.crt.advproject.gcc.specs.261101461" name="Specs" superClass="com.crt.advproject.gcc.specs" useByScannerDiscovery="false" value="com.crt.advproject.gcc.specs.newlib" valueType="enumerated"/>
|
||||||
|
<inputType id="com.crt.advproject.compiler.input.210987689" superClass="com.crt.advproject.compiler.input"/>
|
||||||
|
</tool>
|
||||||
|
<tool id="com.crt.advproject.gas.lib.release.871760532" name="MCU Assembler" superClass="com.crt.advproject.gas.lib.release">
|
||||||
|
<option id="com.crt.advproject.gas.thumb.377715166" name="Thumb mode" superClass="com.crt.advproject.gas.thumb" value="true" valueType="boolean"/>
|
||||||
|
<option id="com.crt.advproject.gas.arch.1731966612" name="Architecture" superClass="com.crt.advproject.gas.arch" value="com.crt.advproject.gas.target.cm3" valueType="enumerated"/>
|
||||||
|
<option id="gnu.both.asm.option.flags.crt.157705469" name="Assembler flags" superClass="gnu.both.asm.option.flags.crt" value="-c -x assembler-with-cpp -DNDEBUG -D__CODE_RED -DCORE_M3 -D__USE_LPCOPEN -D__LPC15XX__ -D__NEWLIB__" valueType="string"/>
|
||||||
|
<option IS_BUILTIN_EMPTY="false" IS_VALUE_EMPTY="false" id="gnu.both.asm.option.include.paths.804668342" name="Include paths (-I)" superClass="gnu.both.asm.option.include.paths" valueType="includePath">
|
||||||
|
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/inc}""/>
|
||||||
|
<listOptionValue builtIn="false" value=""${workspace_loc:/lpc_board_nxp_lpcxpresso_1549/inc}""/>
|
||||||
|
<listOptionValue builtIn="false" value=""${workspace_loc:/lpc_chip_15xx/inc}""/>
|
||||||
|
<listOptionValue builtIn="false" value=""${workspace_loc://inc}""/>
|
||||||
|
<listOptionValue builtIn="false" value=""${workspace_loc:/DigitalIoPin/inc}""/>
|
||||||
|
<listOptionValue builtIn="false" value=""${workspace_loc:/Timer/inc}""/>
|
||||||
|
<listOptionValue builtIn="false" value=""${workspace_loc:/StateHandler/inc}""/>
|
||||||
|
<listOptionValue builtIn="false" value=""${workspace_loc:/LiquidCrystal/inc}""/>
|
||||||
|
</option>
|
||||||
|
<option id="com.crt.advproject.gas.hdrlib.280079471" name="Library headers" superClass="com.crt.advproject.gas.hdrlib" value="Newlib" valueType="enumerated"/>
|
||||||
|
<option id="com.crt.advproject.gas.specs.284770140" name="Specs" superClass="com.crt.advproject.gas.specs" value="com.crt.advproject.gas.specs.newlib" valueType="enumerated"/>
|
||||||
|
<inputType id="cdt.managedbuild.tool.gnu.assembler.input.2009272380" superClass="cdt.managedbuild.tool.gnu.assembler.input"/>
|
||||||
|
<inputType id="com.crt.advproject.assembler.input.1067911307" name="Additional Assembly Source Files" superClass="com.crt.advproject.assembler.input"/>
|
||||||
|
</tool>
|
||||||
|
<tool id="com.crt.advproject.ar.lib.release.471677686" name="MCU Archiver" superClass="com.crt.advproject.ar.lib.release"/>
|
||||||
|
</toolChain>
|
||||||
|
</folderInfo>
|
||||||
|
<sourceEntries>
|
||||||
|
<entry flags="VALUE_WORKSPACE_PATH|RESOLVED" kind="sourcePath" name="inc"/>
|
||||||
|
<entry flags="VALUE_WORKSPACE_PATH|RESOLVED" kind="sourcePath" name="src"/>
|
||||||
|
</sourceEntries>
|
||||||
|
</configuration>
|
||||||
|
</storageModule>
|
||||||
|
<storageModule moduleId="org.eclipse.cdt.core.externalSettings"/>
|
||||||
|
</cconfiguration>
|
||||||
|
</storageModule>
|
||||||
|
<storageModule moduleId="cdtBuildSystem" version="4.0.0">
|
||||||
|
<project id="SwitchController.com.crt.advproject.projecttype.lib.222385444" name="Static Library" projectType="com.crt.advproject.projecttype.lib"/>
|
||||||
|
</storageModule>
|
||||||
|
<storageModule moduleId="scannerConfiguration">
|
||||||
|
<autodiscovery enabled="true" problemReportingEnabled="true" selectedProfileId=""/>
|
||||||
|
</storageModule>
|
||||||
|
<storageModule moduleId="org.eclipse.cdt.core.LanguageSettingsProviders"/>
|
||||||
|
<storageModule moduleId="com.crt.config">
|
||||||
|
<projectStorage><?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<TargetConfig>
|
||||||
|
<Properties property_2="LPC15xx_256K.cfx" property_3="NXP" property_4="LPC1549" property_count="5" version="100300"/>
|
||||||
|
<infoList vendor="NXP">
|
||||||
|
<info chip="LPC1549" connectscript="LPC15RunBootRomConnect.scp" flash_driver="LPC15xx_256K.cfx" match_id="0x0" name="LPC1549" resetscript="LPC15RunBootRomReset.scp" stub="crt_emu_cm3_gen">
|
||||||
|
<chip>
|
||||||
|
<name>LPC1549</name>
|
||||||
|
<family>LPC15xx</family>
|
||||||
|
<vendor>NXP (formerly Philips)</vendor>
|
||||||
|
<reset board="None" core="Real" sys="Real"/>
|
||||||
|
<clock changeable="TRUE" freq="12MHz" is_accurate="TRUE"/>
|
||||||
|
<memory can_program="true" id="Flash" is_ro="true" type="Flash"/>
|
||||||
|
<memory id="RAM" type="RAM"/>
|
||||||
|
<memory id="Periph" is_volatile="true" type="Peripheral"/>
|
||||||
|
<memoryInstance derived_from="Flash" id="MFlash256" location="0x0" size="0x40000"/>
|
||||||
|
<memoryInstance derived_from="RAM" id="Ram0_16" location="0x2000000" size="0x4000"/>
|
||||||
|
<memoryInstance derived_from="RAM" id="Ram1_16" location="0x2004000" size="0x4000"/>
|
||||||
|
<memoryInstance derived_from="RAM" id="Ram2_4" location="0x2008000" size="0x1000"/>
|
||||||
|
</chip>
|
||||||
|
<processor>
|
||||||
|
<name gcc_name="cortex-m3">Cortex-M3</name>
|
||||||
|
<family>Cortex-M</family>
|
||||||
|
</processor>
|
||||||
|
</info>
|
||||||
|
</infoList>
|
||||||
|
</TargetConfig></projectStorage>
|
||||||
|
</storageModule>
|
||||||
|
<storageModule moduleId="refreshScope"/>
|
||||||
|
<storageModule moduleId="com.crt.advproject">
|
||||||
|
<boardId>LPCXpresso1549</boardId>
|
||||||
|
</storageModule>
|
||||||
|
<storageModule moduleId="org.eclipse.cdt.make.core.buildtargets"/>
|
||||||
|
</cproject>
|
||||||
1
SwitchController/.gitignore
vendored
Normal file
1
SwitchController/.gitignore
vendored
Normal file
@ -0,0 +1 @@
|
|||||||
|
/Debug/
|
||||||
32
SwitchController/.project
Normal file
32
SwitchController/.project
Normal file
@ -0,0 +1,32 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<projectDescription>
|
||||||
|
<name>SwitchController</name>
|
||||||
|
<comment></comment>
|
||||||
|
<projects>
|
||||||
|
<project>lpc_chip_15xx</project>
|
||||||
|
<project>DigitalIoPin</project>
|
||||||
|
<project>Timer</project>
|
||||||
|
<project>StateHandler</project>
|
||||||
|
<project>LiquidCrystal</project>
|
||||||
|
</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.core.ccnature</nature>
|
||||||
|
<nature>org.eclipse.cdt.managedbuilder.core.managedBuildNature</nature>
|
||||||
|
<nature>org.eclipse.cdt.managedbuilder.core.ScannerConfigNature</nature>
|
||||||
|
</natures>
|
||||||
|
</projectDescription>
|
||||||
33
SwitchController/inc/SwitchController.h
Normal file
33
SwitchController/inc/SwitchController.h
Normal file
@ -0,0 +1,33 @@
|
|||||||
|
/*
|
||||||
|
* SwitchController.h
|
||||||
|
*
|
||||||
|
* Created on: Oct 17, 2022
|
||||||
|
* Author: tylen
|
||||||
|
*/
|
||||||
|
|
||||||
|
#ifndef SWITCHCONTROLLER_H_
|
||||||
|
#define SWITCHCONTROLLER_H_
|
||||||
|
|
||||||
|
#include "DigitalIoPin.h"
|
||||||
|
#include "StateHandler.h"
|
||||||
|
#include "Timer.h"
|
||||||
|
|
||||||
|
class SwitchController
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
SwitchController (DigitalIoPin *button, Timer *timer, StateHandler *handler,
|
||||||
|
int button_mode);
|
||||||
|
virtual ~SwitchController ();
|
||||||
|
/** Listen to switch button
|
||||||
|
*/
|
||||||
|
void listen ();
|
||||||
|
|
||||||
|
private:
|
||||||
|
DigitalIoPin *b;
|
||||||
|
Timer *t;
|
||||||
|
StateHandler *h;
|
||||||
|
bool b_state;
|
||||||
|
int b_mode;
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif /* SWITCHCONTROLLER_H_ */
|
||||||
32
SwitchController/liblinks.xml
Normal file
32
SwitchController/liblinks.xml
Normal file
@ -0,0 +1,32 @@
|
|||||||
|
<!-- liblinks.xml
|
||||||
|
|
||||||
|
NXP LPCXpresso IDE "Smart update wizard" script file
|
||||||
|
When executed on a particular application project, will
|
||||||
|
add appropriate links to the specified library project.
|
||||||
|
|
||||||
|
Note that this script assumes that the application project
|
||||||
|
contains the standard 'Debug' and 'Release' build
|
||||||
|
configurations.
|
||||||
|
-->
|
||||||
|
|
||||||
|
<project name="" update="true">
|
||||||
|
<setting id="all.compiler.inc">
|
||||||
|
<value>${MacroStart}workspace_loc:/${ProjName}/inc${MacroEnd}</value>
|
||||||
|
</setting>
|
||||||
|
<setting id="assembler.inc">
|
||||||
|
<value>${MacroStart}workspace_loc:/${ProjName}/inc${MacroEnd}</value>
|
||||||
|
</setting>
|
||||||
|
<setting id="linker.libs">
|
||||||
|
<value>${ProjName}</value>
|
||||||
|
</setting>
|
||||||
|
<setting id="linker.paths" buildType="Debug">
|
||||||
|
<value>${MacroStart}workspace_loc:/${ProjName}/Debug${MacroEnd}</value>
|
||||||
|
</setting>
|
||||||
|
<setting id="linker.paths" buildType="Release">
|
||||||
|
<value>${MacroStart}workspace_loc:/${ProjName}/Release${MacroEnd}</value>
|
||||||
|
</setting>
|
||||||
|
<requires msg="Library project `${ProjName}` not found">
|
||||||
|
<value>${ProjName}</value>
|
||||||
|
</requires>
|
||||||
|
</project>
|
||||||
|
|
||||||
37
SwitchController/src/SwitchController.cpp
Normal file
37
SwitchController/src/SwitchController.cpp
Normal file
@ -0,0 +1,37 @@
|
|||||||
|
/*
|
||||||
|
* SwitchController.cpp
|
||||||
|
*
|
||||||
|
* Created on: Oct 17, 2022
|
||||||
|
* Author: tylen
|
||||||
|
*/
|
||||||
|
|
||||||
|
#include <SwitchController.h>
|
||||||
|
|
||||||
|
SwitchController::SwitchController (DigitalIoPin *button, Timer *timer,
|
||||||
|
StateHandler *handler, int button_mode)
|
||||||
|
{
|
||||||
|
b = button;
|
||||||
|
t = timer;
|
||||||
|
h = handler;
|
||||||
|
b_state = false;
|
||||||
|
b_mode = button_mode;
|
||||||
|
}
|
||||||
|
|
||||||
|
SwitchController::~SwitchController ()
|
||||||
|
{
|
||||||
|
// TODO Auto-generated destructor stub
|
||||||
|
}
|
||||||
|
|
||||||
|
void
|
||||||
|
SwitchController::listen ()
|
||||||
|
{
|
||||||
|
if (b->read ())
|
||||||
|
{
|
||||||
|
b_state = true;
|
||||||
|
}
|
||||||
|
if (!b->read () && b_state)
|
||||||
|
{
|
||||||
|
h->HandleState (Event (Event::eKey, b_mode));
|
||||||
|
b_state = false;
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -46,6 +46,7 @@
|
|||||||
<listOptionValue builtIn="false" value=""${workspace_loc:/I2C/inc}""/>
|
<listOptionValue builtIn="false" value=""${workspace_loc:/I2C/inc}""/>
|
||||||
<listOptionValue builtIn="false" value=""${workspace_loc:/StateHandler/inc}""/>
|
<listOptionValue builtIn="false" value=""${workspace_loc:/StateHandler/inc}""/>
|
||||||
<listOptionValue builtIn="false" value=""${workspace_loc:/Timer/inc}""/>
|
<listOptionValue builtIn="false" value=""${workspace_loc:/Timer/inc}""/>
|
||||||
|
<listOptionValue builtIn="false" value=""${workspace_loc:/SwitchController/inc}""/>
|
||||||
</option>
|
</option>
|
||||||
<option id="com.crt.advproject.cpp.misc.dialect.1893636131" name="Language standard" superClass="com.crt.advproject.cpp.misc.dialect" useByScannerDiscovery="true" value="com.crt.advproject.misc.dialect.c++11" valueType="enumerated"/>
|
<option id="com.crt.advproject.cpp.misc.dialect.1893636131" name="Language standard" superClass="com.crt.advproject.cpp.misc.dialect" useByScannerDiscovery="true" value="com.crt.advproject.misc.dialect.c++11" valueType="enumerated"/>
|
||||||
<inputType id="com.crt.advproject.compiler.cpp.input.1024506123" superClass="com.crt.advproject.compiler.cpp.input"/>
|
<inputType id="com.crt.advproject.compiler.cpp.input.1024506123" superClass="com.crt.advproject.compiler.cpp.input"/>
|
||||||
@ -75,6 +76,7 @@
|
|||||||
<listOptionValue builtIn="false" value=""${workspace_loc:/I2C/inc}""/>
|
<listOptionValue builtIn="false" value=""${workspace_loc:/I2C/inc}""/>
|
||||||
<listOptionValue builtIn="false" value=""${workspace_loc:/StateHandler/inc}""/>
|
<listOptionValue builtIn="false" value=""${workspace_loc:/StateHandler/inc}""/>
|
||||||
<listOptionValue builtIn="false" value=""${workspace_loc:/Timer/inc}""/>
|
<listOptionValue builtIn="false" value=""${workspace_loc:/Timer/inc}""/>
|
||||||
|
<listOptionValue builtIn="false" value=""${workspace_loc:/SwitchController/inc}""/>
|
||||||
</option>
|
</option>
|
||||||
<option id="com.crt.advproject.c.misc.dialect.1885316467" name="Language standard" superClass="com.crt.advproject.c.misc.dialect" useByScannerDiscovery="true" value="com.crt.advproject.misc.dialect.c11" valueType="enumerated"/>
|
<option id="com.crt.advproject.c.misc.dialect.1885316467" name="Language standard" superClass="com.crt.advproject.c.misc.dialect" useByScannerDiscovery="true" value="com.crt.advproject.misc.dialect.c11" valueType="enumerated"/>
|
||||||
<inputType id="com.crt.advproject.compiler.input.1491212950" superClass="com.crt.advproject.compiler.input"/>
|
<inputType id="com.crt.advproject.compiler.input.1491212950" superClass="com.crt.advproject.compiler.input"/>
|
||||||
@ -94,6 +96,7 @@
|
|||||||
<listOptionValue builtIn="false" value=""${workspace_loc:/I2C/inc}""/>
|
<listOptionValue builtIn="false" value=""${workspace_loc:/I2C/inc}""/>
|
||||||
<listOptionValue builtIn="false" value=""${workspace_loc:/StateHandler/inc}""/>
|
<listOptionValue builtIn="false" value=""${workspace_loc:/StateHandler/inc}""/>
|
||||||
<listOptionValue builtIn="false" value=""${workspace_loc:/Timer/inc}""/>
|
<listOptionValue builtIn="false" value=""${workspace_loc:/Timer/inc}""/>
|
||||||
|
<listOptionValue builtIn="false" value=""${workspace_loc:/SwitchController/inc}""/>
|
||||||
</option>
|
</option>
|
||||||
<inputType id="cdt.managedbuild.tool.gnu.assembler.input.486566022" superClass="cdt.managedbuild.tool.gnu.assembler.input"/>
|
<inputType id="cdt.managedbuild.tool.gnu.assembler.input.486566022" superClass="cdt.managedbuild.tool.gnu.assembler.input"/>
|
||||||
<inputType id="com.crt.advproject.assembler.input.255980151" name="Additional Assembly Source Files" superClass="com.crt.advproject.assembler.input"/>
|
<inputType id="com.crt.advproject.assembler.input.255980151" name="Additional Assembly Source Files" superClass="com.crt.advproject.assembler.input"/>
|
||||||
@ -126,6 +129,7 @@
|
|||||||
<listOptionValue builtIn="false" value="I2C"/>
|
<listOptionValue builtIn="false" value="I2C"/>
|
||||||
<listOptionValue builtIn="false" value="StateHandler"/>
|
<listOptionValue builtIn="false" value="StateHandler"/>
|
||||||
<listOptionValue builtIn="false" value="Timer"/>
|
<listOptionValue builtIn="false" value="Timer"/>
|
||||||
|
<listOptionValue builtIn="false" value="SwitchController"/>
|
||||||
</option>
|
</option>
|
||||||
<option IS_BUILTIN_EMPTY="false" IS_VALUE_EMPTY="false" id="gnu.cpp.link.option.paths.804461696" name="Library search path (-L)" superClass="gnu.cpp.link.option.paths" valueType="libPaths">
|
<option IS_BUILTIN_EMPTY="false" IS_VALUE_EMPTY="false" id="gnu.cpp.link.option.paths.804461696" name="Library search path (-L)" superClass="gnu.cpp.link.option.paths" valueType="libPaths">
|
||||||
<listOptionValue builtIn="false" value=""${workspace_loc:/lpc_board_nxp_lpcxpresso_1549/Debug}""/>
|
<listOptionValue builtIn="false" value=""${workspace_loc:/lpc_board_nxp_lpcxpresso_1549/Debug}""/>
|
||||||
@ -135,6 +139,7 @@
|
|||||||
<listOptionValue builtIn="false" value=""${workspace_loc:/I2C/Debug}""/>
|
<listOptionValue builtIn="false" value=""${workspace_loc:/I2C/Debug}""/>
|
||||||
<listOptionValue builtIn="false" value=""${workspace_loc:/StateHandler/Debug}""/>
|
<listOptionValue builtIn="false" value=""${workspace_loc:/StateHandler/Debug}""/>
|
||||||
<listOptionValue builtIn="false" value=""${workspace_loc:/Timer/Debug}""/>
|
<listOptionValue builtIn="false" value=""${workspace_loc:/Timer/Debug}""/>
|
||||||
|
<listOptionValue builtIn="false" value=""${workspace_loc:/SwitchController/Debug}""/>
|
||||||
</option>
|
</option>
|
||||||
<option id="com.crt.advproject.link.cpp.crpenable.8641361" name="Enable automatic placement of Code Read Protection field in image" superClass="com.crt.advproject.link.cpp.crpenable"/>
|
<option id="com.crt.advproject.link.cpp.crpenable.8641361" name="Enable automatic placement of Code Read Protection field in image" superClass="com.crt.advproject.link.cpp.crpenable"/>
|
||||||
<inputType id="cdt.managedbuild.tool.gnu.cpp.linker.input.849613399" superClass="cdt.managedbuild.tool.gnu.cpp.linker.input">
|
<inputType id="cdt.managedbuild.tool.gnu.cpp.linker.input.849613399" superClass="cdt.managedbuild.tool.gnu.cpp.linker.input">
|
||||||
@ -200,6 +205,7 @@
|
|||||||
<listOptionValue builtIn="false" value=""${workspace_loc:/I2C/inc}""/>
|
<listOptionValue builtIn="false" value=""${workspace_loc:/I2C/inc}""/>
|
||||||
<listOptionValue builtIn="false" value=""${workspace_loc:/StateHandler/inc}""/>
|
<listOptionValue builtIn="false" value=""${workspace_loc:/StateHandler/inc}""/>
|
||||||
<listOptionValue builtIn="false" value=""${workspace_loc:/Timer/inc}""/>
|
<listOptionValue builtIn="false" value=""${workspace_loc:/Timer/inc}""/>
|
||||||
|
<listOptionValue builtIn="false" value=""${workspace_loc:/SwitchController/inc}""/>
|
||||||
</option>
|
</option>
|
||||||
<option id="com.crt.advproject.cpp.misc.dialect.1640449237" name="Language standard" superClass="com.crt.advproject.cpp.misc.dialect" useByScannerDiscovery="true" value="com.crt.advproject.misc.dialect.c++11" valueType="enumerated"/>
|
<option id="com.crt.advproject.cpp.misc.dialect.1640449237" name="Language standard" superClass="com.crt.advproject.cpp.misc.dialect" useByScannerDiscovery="true" value="com.crt.advproject.misc.dialect.c++11" valueType="enumerated"/>
|
||||||
<inputType id="com.crt.advproject.compiler.cpp.input.812988440" superClass="com.crt.advproject.compiler.cpp.input"/>
|
<inputType id="com.crt.advproject.compiler.cpp.input.812988440" superClass="com.crt.advproject.compiler.cpp.input"/>
|
||||||
@ -229,6 +235,7 @@
|
|||||||
<listOptionValue builtIn="false" value=""${workspace_loc:/I2C/inc}""/>
|
<listOptionValue builtIn="false" value=""${workspace_loc:/I2C/inc}""/>
|
||||||
<listOptionValue builtIn="false" value=""${workspace_loc:/StateHandler/inc}""/>
|
<listOptionValue builtIn="false" value=""${workspace_loc:/StateHandler/inc}""/>
|
||||||
<listOptionValue builtIn="false" value=""${workspace_loc:/Timer/inc}""/>
|
<listOptionValue builtIn="false" value=""${workspace_loc:/Timer/inc}""/>
|
||||||
|
<listOptionValue builtIn="false" value=""${workspace_loc:/SwitchController/inc}""/>
|
||||||
</option>
|
</option>
|
||||||
<option id="com.crt.advproject.c.misc.dialect.1383624929" name="Language standard" superClass="com.crt.advproject.c.misc.dialect" useByScannerDiscovery="true" value="com.crt.advproject.misc.dialect.c11" valueType="enumerated"/>
|
<option id="com.crt.advproject.c.misc.dialect.1383624929" name="Language standard" superClass="com.crt.advproject.c.misc.dialect" useByScannerDiscovery="true" value="com.crt.advproject.misc.dialect.c11" valueType="enumerated"/>
|
||||||
<inputType id="com.crt.advproject.compiler.input.391538574" superClass="com.crt.advproject.compiler.input"/>
|
<inputType id="com.crt.advproject.compiler.input.391538574" superClass="com.crt.advproject.compiler.input"/>
|
||||||
@ -248,6 +255,7 @@
|
|||||||
<listOptionValue builtIn="false" value=""${workspace_loc:/I2C/inc}""/>
|
<listOptionValue builtIn="false" value=""${workspace_loc:/I2C/inc}""/>
|
||||||
<listOptionValue builtIn="false" value=""${workspace_loc:/StateHandler/inc}""/>
|
<listOptionValue builtIn="false" value=""${workspace_loc:/StateHandler/inc}""/>
|
||||||
<listOptionValue builtIn="false" value=""${workspace_loc:/Timer/inc}""/>
|
<listOptionValue builtIn="false" value=""${workspace_loc:/Timer/inc}""/>
|
||||||
|
<listOptionValue builtIn="false" value=""${workspace_loc:/SwitchController/inc}""/>
|
||||||
</option>
|
</option>
|
||||||
<inputType id="cdt.managedbuild.tool.gnu.assembler.input.1169670567" superClass="cdt.managedbuild.tool.gnu.assembler.input"/>
|
<inputType id="cdt.managedbuild.tool.gnu.assembler.input.1169670567" superClass="cdt.managedbuild.tool.gnu.assembler.input"/>
|
||||||
<inputType id="com.crt.advproject.assembler.input.956763731" name="Additional Assembly Source Files" superClass="com.crt.advproject.assembler.input"/>
|
<inputType id="com.crt.advproject.assembler.input.956763731" name="Additional Assembly Source Files" superClass="com.crt.advproject.assembler.input"/>
|
||||||
@ -280,6 +288,7 @@
|
|||||||
<listOptionValue builtIn="false" value="I2C"/>
|
<listOptionValue builtIn="false" value="I2C"/>
|
||||||
<listOptionValue builtIn="false" value="StateHandler"/>
|
<listOptionValue builtIn="false" value="StateHandler"/>
|
||||||
<listOptionValue builtIn="false" value="Timer"/>
|
<listOptionValue builtIn="false" value="Timer"/>
|
||||||
|
<listOptionValue builtIn="false" value="SwitchController"/>
|
||||||
</option>
|
</option>
|
||||||
<option IS_BUILTIN_EMPTY="false" IS_VALUE_EMPTY="false" id="gnu.cpp.link.option.paths.245096214" name="Library search path (-L)" superClass="gnu.cpp.link.option.paths" valueType="libPaths">
|
<option IS_BUILTIN_EMPTY="false" IS_VALUE_EMPTY="false" id="gnu.cpp.link.option.paths.245096214" name="Library search path (-L)" superClass="gnu.cpp.link.option.paths" valueType="libPaths">
|
||||||
<listOptionValue builtIn="false" value=""${workspace_loc:/lpc_board_nxp_lpcxpresso_1549/Release}""/>
|
<listOptionValue builtIn="false" value=""${workspace_loc:/lpc_board_nxp_lpcxpresso_1549/Release}""/>
|
||||||
@ -289,6 +298,7 @@
|
|||||||
<listOptionValue builtIn="false" value=""${workspace_loc:/I2C/Release}""/>
|
<listOptionValue builtIn="false" value=""${workspace_loc:/I2C/Release}""/>
|
||||||
<listOptionValue builtIn="false" value=""${workspace_loc:/StateHandler/Release}""/>
|
<listOptionValue builtIn="false" value=""${workspace_loc:/StateHandler/Release}""/>
|
||||||
<listOptionValue builtIn="false" value=""${workspace_loc:/Timer/Release}""/>
|
<listOptionValue builtIn="false" value=""${workspace_loc:/Timer/Release}""/>
|
||||||
|
<listOptionValue builtIn="false" value=""${workspace_loc:/SwitchController/Release}""/>
|
||||||
</option>
|
</option>
|
||||||
<option id="com.crt.advproject.link.cpp.crpenable.209534913" name="Enable automatic placement of Code Read Protection field in image" superClass="com.crt.advproject.link.cpp.crpenable"/>
|
<option id="com.crt.advproject.link.cpp.crpenable.209534913" name="Enable automatic placement of Code Read Protection field in image" superClass="com.crt.advproject.link.cpp.crpenable"/>
|
||||||
<inputType id="cdt.managedbuild.tool.gnu.cpp.linker.input.1513506142" superClass="cdt.managedbuild.tool.gnu.cpp.linker.input">
|
<inputType id="cdt.managedbuild.tool.gnu.cpp.linker.input.1513506142" superClass="cdt.managedbuild.tool.gnu.cpp.linker.input">
|
||||||
|
|||||||
@ -10,6 +10,7 @@
|
|||||||
<project>I2C</project>
|
<project>I2C</project>
|
||||||
<project>StateHandler</project>
|
<project>StateHandler</project>
|
||||||
<project>Timer</project>
|
<project>Timer</project>
|
||||||
|
<project>SwitchController</project>
|
||||||
</projects>
|
</projects>
|
||||||
<buildSpec>
|
<buildSpec>
|
||||||
<buildCommand>
|
<buildCommand>
|
||||||
|
|||||||
@ -19,6 +19,7 @@
|
|||||||
#include "DigitalIoPin.h"
|
#include "DigitalIoPin.h"
|
||||||
#include "LiquidCrystal.h"
|
#include "LiquidCrystal.h"
|
||||||
#include "StateHandler.h"
|
#include "StateHandler.h"
|
||||||
|
#include "SwitchController.h"
|
||||||
#include "Timer.h"
|
#include "Timer.h"
|
||||||
|
|
||||||
#include <cr_section_macros.h>
|
#include <cr_section_macros.h>
|
||||||
@ -44,6 +45,7 @@ main (void)
|
|||||||
#endif
|
#endif
|
||||||
/** Lcd & stateHandler */
|
/** Lcd & stateHandler */
|
||||||
Chip_RIT_Init (LPC_RITIMER);
|
Chip_RIT_Init (LPC_RITIMER);
|
||||||
|
Timer glob_time;
|
||||||
DigitalIoPin rs (0, 29, false, true, false);
|
DigitalIoPin rs (0, 29, false, true, false);
|
||||||
DigitalIoPin en (0, 9, false, true, false);
|
DigitalIoPin en (0, 9, false, true, false);
|
||||||
DigitalIoPin d4 (0, 10, false, true, false);
|
DigitalIoPin d4 (0, 10, false, true, false);
|
||||||
@ -58,47 +60,24 @@ main (void)
|
|||||||
|
|
||||||
/** Common pins */
|
/** Common pins */
|
||||||
DigitalIoPin b_up (0, 7, true, true, true); // A5
|
DigitalIoPin b_up (0, 7, true, true, true); // A5
|
||||||
bool b_up_state = false;
|
SwitchController sw_up (&b_up, &glob_time, &ventMachine, BUTTON_CONTROL_UP);
|
||||||
|
|
||||||
DigitalIoPin b_down (0, 6, true, true, true); // A4
|
DigitalIoPin b_down (0, 6, true, true, true); // A4
|
||||||
bool b_down_state = false;
|
SwitchController sw_down (&b_down, &glob_time, &ventMachine,
|
||||||
|
BUTTON_CONTROL_DOWN);
|
||||||
|
|
||||||
DigitalIoPin b_toggle (0, 5, true, true, true); // A3
|
DigitalIoPin b_toggle (0, 5, true, true, true); // A3
|
||||||
bool b_toggle_state = false;
|
SwitchController sw_toggle (&b_toggle, &glob_time, &ventMachine,
|
||||||
|
BUTTON_CONTROL_TOG_MODE);
|
||||||
|
|
||||||
int16_t pressure = 1;
|
int16_t pressure = 1;
|
||||||
|
|
||||||
Timer glob_time;
|
|
||||||
|
|
||||||
while (1)
|
while (1)
|
||||||
{
|
{
|
||||||
if (b_up.read ())
|
|
||||||
{
|
|
||||||
b_up_state = true;
|
|
||||||
}
|
|
||||||
if (!b_up.read () && b_up_state)
|
|
||||||
{
|
|
||||||
ventMachine.HandleState (Event (Event::eKey, BUTTON_CONTROL_UP));
|
|
||||||
b_up_state = false;
|
|
||||||
}
|
|
||||||
if (b_down.read ())
|
|
||||||
{
|
|
||||||
b_down_state = true;
|
|
||||||
}
|
|
||||||
if (!b_down.read () && b_down_state)
|
|
||||||
{
|
|
||||||
ventMachine.HandleState (Event (Event::eKey, BUTTON_CONTROL_DOWN));
|
|
||||||
b_down_state = false;
|
|
||||||
}
|
|
||||||
if (b_toggle.read ())
|
|
||||||
{
|
|
||||||
b_toggle_state = true;
|
|
||||||
}
|
|
||||||
if (!b_toggle.read () && b_toggle_state)
|
|
||||||
{
|
|
||||||
ventMachine.HandleState (
|
|
||||||
Event (Event::eKey, BUTTON_CONTROL_TOG_MODE));
|
|
||||||
b_toggle_state = false;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
sw_up.listen ();
|
||||||
|
sw_down.listen ();
|
||||||
|
sw_toggle.listen ();
|
||||||
/**
|
/**
|
||||||
* TODO:
|
* TODO:
|
||||||
* - Update current pressure to eTick
|
* - Update current pressure to eTick
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user