Skip to content
Snippets Groups Projects

Update arduino_code/test_webpage_sensors/test_webpage_sensors.ino

Merged jackjb2 requested to merge jackjb2-main-patch-43703 into main
1 file
+ 7
7
Compare changes
  • Side-by-side
  • Inline
@@ -12,8 +12,8 @@
#include <MultiStepper.h>
// Replace with your network credentials
const char* ssid = "Saloni's iphone (2)";
const char* password = "saloni29";
const char* ssid = "Jack";
const char* password = "temp_pass1234";
const char* input_parameter1 = "output";
const char* input_parameter2 = "state";
@@ -29,7 +29,7 @@ const char* input_parameter2 = "state";
#define motor2IN1 13
#define motor2IN2 14
#define motor2IN3 15
#define motor2IN4 25
#define motor2IN4 4
#define PRESSURE1GOAL 41
#define PRESSURE2GOAL 39
@@ -353,7 +353,7 @@ void loop(){
if (motor1status == "Ankle motor tightening..."){
motor1.setSpeed(60);
motor1.step(500);
motor1.step(500);
digitalWrite(motor1IN1, LOW);
digitalWrite(motor1IN2, LOW);
@@ -373,7 +373,7 @@ void loop(){
motor2status = "Tightened";
}
if (motor1status == "Ankle motor loosening ..."){
if (String(motor1status) == "Ankle motor loosening..."){
motor1.setSpeed(60);
motor1.step(-500);
@@ -386,7 +386,7 @@ void loop(){
motor2status = "Foot motor loosening...";
motor2.setSpeed(60);
motor2.step(500);
motor2.step(300);
digitalWrite(motor2IN1, LOW);
digitalWrite(motor2IN2, LOW);
@@ -445,4 +445,4 @@ void loop(){
}
}
}
\ No newline at end of file
}
Loading