Moved to ESP32 and added webinterface for PenConfiguration.

Not working and removed:
- AccelStepper: Move to FastAccelStepper for ESP32
- Servo: Changed to ESP32 - check if that is ok
- Serial Comm Interface now at 115200 -> change back to 9600 later
This commit is contained in:
2026-02-08 21:44:06 +01:00
parent cf4c2c6b64
commit 50430b050e
5 changed files with 364 additions and 38 deletions

View File

@@ -30,10 +30,10 @@
//-----------------------------------------------------------------------------------------------------------
//make Objects
AccelStepper rotMotor(AccelStepper::DRIVER, step1, dir1);
AccelStepper penMotor(AccelStepper::DRIVER, step2, dir2);
Servo penServo;
SerialCommand SCmd;
// AccelStepper rotMotor(AccelStepper::DRIVER, step1, dir1);
// AccelStepper penMotor(AccelStepper::DRIVER, step2, dir2);
// Servo penServo;
// SerialCommand SCmd;
//create Buttons
#ifdef prgButton
Button prgButtonToggle(prgButton, setprgButtonState);
@@ -63,19 +63,18 @@ float rotSpeed=0;
float penSpeed=0; // these are local variables for Function SteppermotorMove-Command, but for performance-reasons it will be initialized here
boolean motorsEnabled = 0;
void setup() {
Serial.begin(9600);
makeComInterface();
initHardware();
void setup() {
Serial.begin(115200);
Serial.print("Starting...");
//makeComInterface();
//initHardware();
startWebInterface();
}
void loop() {
moveOneStep();
SCmd.readSerial();
// moveOneStep();
// SCmd.readSerial();
handleWebInterface();
#ifdef penToggleButton
penToggle.check();