浏览代码

V1.2.0

- Cam Power Pin LOW/HIGH hnadling
master
git_brand 1年前
父节点
当前提交
317ae14550
共有 5 个文件被更改,包括 42 次插入71 次删除
  1. 26
    56
      .cproject
  2. 4
    4
      .project
  3. 6
    5
      .sproject
  4. 5
    5
      FSRemotePowerSwitch.ino
  5. 1
    1
      sloeber.ino.cpp

+ 26
- 56
.cproject 查看文件

@@ -1,8 +1,8 @@
<?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="io.sloeber.core.sketch.0">
<storageModule buildSystemId="org.eclipse.cdt.managedbuilder.core.configurationDataProvider" id="io.sloeber.core.sketch.0" moduleId="org.eclipse.cdt.core.settings" name="Release">
<cconfiguration id="io.sloeber.core.toolChain.release.169290952">
<storageModule buildSystemId="org.eclipse.cdt.managedbuilder.core.configurationDataProvider" id="io.sloeber.core.toolChain.release.169290952" moduleId="org.eclipse.cdt.core.settings" name="Release">
<externalSettings/>
<extensions>
<extension id="org.eclipse.cdt.core.ELF" point="org.eclipse.cdt.core.BinaryParser"/>
@@ -12,89 +12,59 @@
</extensions>
</storageModule>
<storageModule moduleId="cdtBuildSystem" version="4.0.0">
<configuration artifactName="${ProjName}" buildProperties="" cleanCommand="rm -f" description="" id="io.sloeber.core.sketch.0" name="Release" parent="io.sloeber.core.configuration.release">
<folderInfo id="io.sloeber.core.sketch.0." name="/" resourcePath="">
<toolChain id="io.sloeber.core.toolChain.release.1203424416" name="Arduino Toolchain (Sloeber edition)" superClass="io.sloeber.core.toolChain.release">
<targetPlatform archList="all" binaryParser="org.eclipse.cdt.core.ELF" id="io.sloeber.targetplatform.1601321437" name="Arduino Target" osList="all" superClass="io.sloeber.targetplatform"/>
<builder buildPath="${workspace_loc:/FSRemotePowerSwitch}/Release" id="io.sloeber.sketch.builder.1196383202" keepEnvironmentInBuildfile="false" name="Arduino sketch builder" parallelBuildOn="false" superClass="io.sloeber.sketch.builder"/>
<tool id="io.sloeber.tool.sketch.compiler.cpp.1826714851" name="Arduino C++ Compiler" superClass="io.sloeber.tool.sketch.compiler.cpp">
<option IS_BUILTIN_EMPTY="false" IS_VALUE_EMPTY="false" id="io.sloeber.compiler.cpp.sketch.option.incpath.1592749907" name="Include Paths (-I)" superClass="io.sloeber.compiler.cpp.sketch.option.incpath" valueType="includePath">
<configuration artifactName="${ProjName}" buildProperties="" description="" id="io.sloeber.core.toolChain.release.169290952" name="Release" parent="org.eclipse.cdt.build.core.emptycfg">
<folderInfo id="io.sloeber.core.toolChain.release.169290952.1274505742" name="/" resourcePath="">
<toolChain id="io.sloeber.core.toolChain.release.447979534" name="Arduino Toolchain (Sloeber edition)" superClass="io.sloeber.core.toolChain.release">
<targetPlatform archList="all" binaryParser="org.eclipse.cdt.core.ELF" id="io.sloeber.targetplatform.963506584" name="Arduino Target" osList="all" superClass="io.sloeber.targetplatform"/>
<builder buildPath="${workspace_loc:/FSRemotePowerSwitch}/Release" id="io.sloeber.sketch.builder.1683980175" keepEnvironmentInBuildfile="false" managedBuildOn="true" name="Arduino sketch builder" superClass="io.sloeber.sketch.builder"/>
<tool id="io.sloeber.tool.sketch.compiler.cpp.2023035055" name="Arduino C++ Compiler" superClass="io.sloeber.tool.sketch.compiler.cpp">
<option IS_BUILTIN_EMPTY="false" IS_VALUE_EMPTY="false" id="io.sloeber.compiler.cpp.sketch.option.incpath.1878572355" name="Include Paths (-I)" superClass="io.sloeber.compiler.cpp.sketch.option.incpath" valueType="includePath">
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/FSRemotePowerSwitch/core/core}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/FSRemotePowerSwitch/core/variant}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/FSRemotePowerSwitch/libraries/ArduinoJson/src}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/FSRemotePowerSwitch/libraries/AccelStepper/src}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/FSRemotePowerSwitch/libraries/ArduinoJson/src}&quot;"/>
</option>
<inputType id="io.sloeber.compiler.cpp.sketch.input.1774730493" name="CPP source files" superClass="io.sloeber.compiler.cpp.sketch.input"/>
<inputType id="io.sloeber.compiler.cpp.sketch.input.1496076099" name="CPP source files" superClass="io.sloeber.compiler.cpp.sketch.input"/>
</tool>
<tool id="io.sloeber.tool.compiler.c.1228564326" name="Arduino C Compiler" superClass="io.sloeber.tool.compiler.c">
<option IS_BUILTIN_EMPTY="false" IS_VALUE_EMPTY="false" id="io.sloeber.compiler.c.sketch.option.incpath.1887998313" name="Include Paths (-I)" superClass="io.sloeber.compiler.c.sketch.option.incpath" valueType="includePath">
<tool id="io.sloeber.tool.compiler.c.521670227" name="Arduino C Compiler" superClass="io.sloeber.tool.compiler.c">
<option IS_BUILTIN_EMPTY="false" IS_VALUE_EMPTY="false" id="io.sloeber.compiler.c.sketch.option.incpath.1725144655" name="Include Paths (-I)" superClass="io.sloeber.compiler.c.sketch.option.incpath" valueType="includePath">
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/FSRemotePowerSwitch/core/core}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/FSRemotePowerSwitch/core/variant}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/FSRemotePowerSwitch/libraries/ArduinoJson/src}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/FSRemotePowerSwitch/libraries/AccelStepper/src}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/FSRemotePowerSwitch/libraries/ArduinoJson/src}&quot;"/>
</option>
<inputType id="io.sloeber.compiler.c.sketch.input.1528033502" name="C Source Files" superClass="io.sloeber.compiler.c.sketch.input"/>
<inputType id="io.sloeber.compiler.c.sketch.input.280688484" name="C Source Files" superClass="io.sloeber.compiler.c.sketch.input"/>
</tool>
<tool id="io.sloeber.tool.sketch.compiler.s.579855230" name="Arduino Assembler" superClass="io.sloeber.tool.sketch.compiler.s">
<option IS_BUILTIN_EMPTY="false" IS_VALUE_EMPTY="false" id="io.sloeber.compiler.asm.sketch.option.incpath.1692763518" name="Include Paths (-I)" superClass="io.sloeber.compiler.asm.sketch.option.incpath" valueType="includePath">
<tool id="io.sloeber.tool.sketch.compiler.s.1924256987" name="Arduino Assembler" superClass="io.sloeber.tool.sketch.compiler.s">
<option IS_BUILTIN_EMPTY="false" IS_VALUE_EMPTY="false" id="io.sloeber.compiler.asm.sketch.option.incpath.215936531" name="Include Paths (-I)" superClass="io.sloeber.compiler.asm.sketch.option.incpath" valueType="includePath">
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/FSRemotePowerSwitch/core/core}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/FSRemotePowerSwitch/core/variant}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/FSRemotePowerSwitch/libraries/ArduinoJson/src}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/FSRemotePowerSwitch/libraries/AccelStepper/src}&quot;"/>
<listOptionValue builtIn="false" value="&quot;${workspace_loc:/FSRemotePowerSwitch/libraries/ArduinoJson/src}&quot;"/>
</option>
<inputType id="io.sloeber.compiler.S.sketch.input.67304239" name="Assembly source files" superClass="io.sloeber.compiler.S.sketch.input"/>
<inputType id="io.sloeber.compiler.S.sketch.input.288275921" name="Assembly source files" superClass="io.sloeber.compiler.S.sketch.input"/>
</tool>
<tool id="io.sloeber.tool.ar.2137607011" name="Arduino archiver" superClass="io.sloeber.tool.ar"/>
<tool id="io.sloeber.tool.combine.1817061304" name="Arduino combiner" superClass="io.sloeber.tool.combine"/>
<tool id="io.sloeber.tool.objcopy.eep.1918189120" name="Arduino tool objcopy command" superClass="io.sloeber.tool.objcopy.eep"/>
<tool id="io.sloeber.tool.size.1599481882" name="Arduino tool Print Size" superClass="io.sloeber.tool.size"/>
</toolChain>
</folderInfo>
<folderInfo id="io.sloeber.core.sketch.0.libraries/**/._*" resourcePath="libraries/**/._*">
<toolChain id="io.sloeber.core.toolChain5.331292459" superClass="io.sloeber.core.toolChain5">
<targetPlatform id="io.sloeber.core.sketch.0.libraries/**/._*.1217115483" name=""/>
</toolChain>
</folderInfo>
<folderInfo id="io.sloeber.core.sketch.0.libraries/?*/**/test*/**" resourcePath="libraries/?*/**/test*/**">
<toolChain id="io.sloeber.core.toolChain3.514991434" superClass="io.sloeber.core.toolChain3">
<targetPlatform id="io.sloeber.core.sketch.0.libraries/?*/**/test*/**.1259847971" name=""/>
</toolChain>
</folderInfo>
<folderInfo id="io.sloeber.core.sketch.0.libraries/?*/**/?xtras/**" resourcePath="libraries/?*/**/?xtras/**">
<toolChain id="io.sloeber.core.toolChain2.2060562449" superClass="io.sloeber.core.toolChain2">
<targetPlatform id="io.sloeber.core.sketch.0.libraries/?*/**/?xtras/**.1662694404" name=""/>
</toolChain>
</folderInfo>
<folderInfo id="io.sloeber.core.sketch.0.libraries/?*/**/?xamples/**" resourcePath="libraries/?*/**/?xamples/**">
<toolChain id="io.sloeber.core.toolChain1.128336890" superClass="io.sloeber.core.toolChain1">
<targetPlatform id="io.sloeber.core.sketch.0.libraries/?*/**/?xamples/**.91341827" name=""/>
</toolChain>
</folderInfo>
<folderInfo id="io.sloeber.core.sketch.0.libraries/?*/**/third-party/**" resourcePath="libraries/?*/**/third-party/**">
<toolChain id="io.sloeber.core.toolChain4.1404350963" superClass="io.sloeber.core.toolChain4">
<targetPlatform id="io.sloeber.core.sketch.0.libraries/?*/**/third-party/**.1593271477" name=""/>
</toolChain>
</folderInfo>
<folderInfo id="io.sloeber.core.sketch.0.libraries/?*/utility/*/*" resourcePath="libraries/?*/utility/*/*">
<toolChain id="io.sloeber.core.toolChain6.2111493700" superClass="io.sloeber.core.toolChain6">
<targetPlatform id="io.sloeber.core.sketch.0.libraries/?*/utility/*/*.1087276154" name=""/>
<tool id="io.sloeber.tool.ar.992264888" name="Arduino archiver" superClass="io.sloeber.tool.ar"/>
<tool id="io.sloeber.tool.combine.313730498" name="Arduino combiner" superClass="io.sloeber.tool.combine"/>
<tool id="io.sloeber.tool.objcopy.eep.1489468960" name="Arduino tool objcopy command" superClass="io.sloeber.tool.objcopy.eep"/>
<tool id="io.sloeber.tool.size.915204176" name="Arduino tool Print Size" superClass="io.sloeber.tool.size"/>
</toolChain>
</folderInfo>
<sourceEntries>
<entry excluding="libraries/?*/**/?xamples/**|libraries/?*/**/?xtras/**|libraries/?*/**/test*/**|libraries/?*/**/third-party/**|libraries/**/._*|libraries/?*/utility/*/*" flags="VALUE_WORKSPACE_PATH|RESOLVED" kind="sourcePath" name=""/>
<entry excluding="libraries/?*/**/?xamples/**|libraries/?*/**/?xtras/**|libraries/?*/**/test*/**|libraries/?*/**/third-party/**|libraries/**/._*|libraries/?*/utility/*/*" flags="VALUE_WORKSPACE_PATH" kind="sourcePath" name=""/>
</sourceEntries>
</configuration>
</storageModule>
<storageModule moduleId="org.eclipse.cdt.core.externalSettings"/>
</cconfiguration>
</storageModule>
<storageModule moduleId="org.eclipse.cdt.core.LanguageSettingsProviders"/>
<storageModule moduleId="cdtBuildSystem" version="4.0.0">
<project id="FSRemotePowerSwitch.io.sloeber.core.sketch.1960264148" name="Arduino sketch" projectType="io.sloeber.core.sketch"/>
<project id="FSRemotePowerSwitch.null.2111783719" name="FSRemotePowerSwitch"/>
</storageModule>
<storageModule moduleId="scannerConfiguration">
<autodiscovery enabled="true" problemReportingEnabled="true" selectedProfileId=""/>
</storageModule>
<storageModule moduleId="org.eclipse.cdt.core.LanguageSettingsProviders"/>
<storageModule moduleId="org.eclipse.cdt.make.core.buildtargets"/>
<storageModule moduleId="refreshScope"/>
</cproject>

+ 4
- 4
.project 查看文件

@@ -25,10 +25,10 @@
</buildSpec>
<natures>
<nature>org.eclipse.cdt.core.cnature</nature>
<nature>org.eclipse.cdt.managedbuilder.core.managedBuildNature</nature>
<nature>org.eclipse.cdt.core.ccnature</nature>
<nature>io.sloeber.arduinonature</nature>
<nature>org.eclipse.cdt.managedbuilder.core.managedBuildNature</nature>
<nature>org.eclipse.cdt.managedbuilder.core.ScannerConfigNature</nature>
<nature>io.sloeber.arduinonature</nature>
</natures>
<linkedResources>
<link>
@@ -44,12 +44,12 @@
<link>
<name>libraries/AccelStepper</name>
<type>2</type>
<locationURI>ECLIPSE_HOME/arduinoPlugin/libraries/AccelStepper/1.61.0</locationURI>
<locationURI>ECLIPSE_HOME/arduinoPlugin/libraries/AccelStepper/1.64.0</locationURI>
</link>
<link>
<name>libraries/ArduinoJson</name>
<type>2</type>
<locationURI>ECLIPSE_HOME/arduinoPlugin/libraries/ArduinoJson/7.0.2</locationURI>
<locationURI>ECLIPSE_HOME/arduinoPlugin/libraries/ArduinoJson/7.0.3</locationURI>
</link>
</linkedResources>
</projectDescription>

+ 6
- 5
.sproject 查看文件

@@ -1,8 +1,8 @@
Config.Release.board.BOARD.ID=nano
Config.Release.board.BOARD.MENU.cpu=atmega328old
Config.Release.board.BOARD.TXT=${SLOEBER_HOME}/arduinoPlugin/packages/arduino/hardware/avr/1.8.4/boards.txt
Config.Release.board.PROGRAMMER.NAME=Default
Config.Release.board.UPLOAD.PORT=COM3
Config.Release.board.BOARD.MENU.cpu=atmega328
Config.Release.board.BOARD.TXT=C:\bin\Sloeber\4.4.3\arduinoPlugin\packages\arduino\hardware\avr\1.8.4\boards.txt
Config.Release.board.PROGRAMMER.NAME=ArduinoISP
Config.Release.board.UPLOAD.PORT=COM5
Config.Release.compile.sloeber.extra.all=
Config.Release.compile.sloeber.extra.archive=
Config.Release.compile.sloeber.extra.assembly=
@@ -10,7 +10,8 @@ Config.Release.compile.sloeber.extra.c.compile=
Config.Release.compile.sloeber.extra.compile=
Config.Release.compile.sloeber.extra.cpp.compile=
Config.Release.compile.sloeber.extra.link=
Config.Release.compile.sloeber.size.switch=false
Config.Release.compile.sloeber.size.custom=
Config.Release.compile.sloeber.size.type=RAW_RESULT
Config.Release.compile.sloeber.warning_level=NONE
Config.Release.compile.sloeber.warning_level.custom=
Config.Release.other.IS_VERSION_CONTROLLED=false

+ 5
- 5
FSRemotePowerSwitch.ino 查看文件

@@ -15,7 +15,7 @@
#include <HardwareSerial.h>
#include <math.h>

const char *Version = "V1.1.0";
const char *Version = "V1.2.0";

const String CMD_SENDER_PC = "FSRemotePowerSwitch_PC";
const String CMD_SENDER_AN = "FSRemotePowerSwitch_AN";
@@ -125,14 +125,14 @@ void loop() {
} else if (sdr == CMD_SENDER_PC && cmd == CMD_POWER_CAM) {

if (val == CMD_VAL_ON) {
digitalWrite(PWR_CAM_PIN, HIGH);
digitalWrite(PWR_CAM_PIN, LOW);
stepper.move(10);
moveStepper();
} else if (val == CMD_VAL_OFF) {
moveStepper();
digitalWrite(PWR_CAM_PIN, LOW);
digitalWrite(PWR_CAM_PIN, HIGH);
}
if (digitalRead(PWR_CAM_PIN) == HIGH) {
if (digitalRead(PWR_CAM_PIN) == LOW) {
moveStepper();
sendCamPowerStatus(CMD_VAL_ON);
} else {
@@ -142,7 +142,7 @@ void loop() {

} else if (sdr == CMD_SENDER_PC && cmd == CMD_STATUS_CAM) {

if (digitalRead(PWR_CAM_PIN) == HIGH) {
if (digitalRead(PWR_CAM_PIN) == LOW) {
moveStepper();
sendCamPowerStatus(CMD_VAL_ON);
} else {

+ 1
- 1
sloeber.ino.cpp 查看文件

@@ -2,7 +2,7 @@
//This is a automatic generated file
//Please do not modify this file
//If you touch this file your change will be overwritten during the next build
//This file has been generated on 2024-02-21 17:55:44
//This file has been generated on 2024-02-25 15:16:38

#include "Arduino.h"
#include <ArduinoJson.h>

正在加载...
取消
保存