瀏覽代碼

new Pin numbers alfter pcb layouting

master
Flo Smilari 3 年之前
父節點
當前提交
f91ac1602d
共有 2 個文件被更改,包括 12 次插入10 次删除
  1. 11
    9
      Fraestisch_SFTools.ino
  2. 1
    1
      sloeber.ino.cpp

+ 11
- 9
Fraestisch_SFTools.ino 查看文件

@@ -35,18 +35,17 @@
#define STEP 2
#define DIR 4
#define LIMIT_SWITCH 5
#define MOTOR_LED 15

static const byte led_gpio = 15;
static const int WLS_Pin = 14;
static const int WLS_DETECT_Pin = 12;

static const int WLS_Pin = 34;
static const int WLS_DETECT_Pin = 35;

static const int GreenBtn_Pin = 12;
static const int GreenBtn_Pin = 35;
static const int RedBtn_Pin = 13;
static const int BlueBtn_Pin = 14;
static const int BlueBtn_Pin = 34;

static const int RotEnc_Switch_Pin = 25;
static const int RotEnc_Clk_Pin = 32;
static const int RotEnc_Switch_Pin = 26;
static const int RotEnc_Clk_Pin = 25;
static const int RotEnc_Dta_Pin = 33;

static const int MOVE_DOWNWARD = -1; // motor rotation counter clock wise
@@ -141,7 +140,7 @@ void setup() {
Display.init();
Display.display();

pinMode(led_gpio, OUTPUT);
pinMode(MOTOR_LED, OUTPUT);
pinMode(GreenBtn_Pin, INPUT);
pinMode(RedBtn_Pin, INPUT);
pinMode(BlueBtn_Pin, INPUT);
@@ -176,6 +175,8 @@ void loop() {
Display.setWlsConnected(WlsDetect.isConnected());
Display.showFrame(actualStatus);

digitalWrite(MOTOR_LED, LOW);

switch (actualStatus) {

case INITIALIZATION:
@@ -324,6 +325,7 @@ void loop() {

case MOVING_ELEVATOR:
//printStatus("MOVING_ELEVATOR");
digitalWrite(MOTOR_LED, HIGH);
if (Router_Elevator.isLimitSwitchTriggerd()) {
delay(200);
SetActualStatus(RELEASE_SWITCH);

+ 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 2022-03-01 17:52:01
//This file has been generated on 2022-03-04 21:14:46

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

Loading…
取消
儲存