From 56b1ca86274d0e515748ce68459d94de98d98a14 Mon Sep 17 00:00:00 2001 From: Ronald Schaten Date: Sun, 30 Jan 2022 21:00:05 +0100 Subject: [PATCH] implement and react to jog mode --- PhotoStepper/PhotoStepper.ino | 110 +++++++++++++++++++++------------- 1 file changed, 68 insertions(+), 42 deletions(-) diff --git a/PhotoStepper/PhotoStepper.ino b/PhotoStepper/PhotoStepper.ino index deb0134..e500422 100644 --- a/PhotoStepper/PhotoStepper.ino +++ b/PhotoStepper/PhotoStepper.ino @@ -58,6 +58,9 @@ LiquidCrystal lcd(PIN_LCD_RS, PIN_LCD_EN, PIN_LCD_DB4, PIN_LCD_DB5, PIN_LCD_DB6, BasicStepperDriver stepper(STEPPER_STEPS, PIN_STEPPER_DIR, PIN_STEPPER_STEP); +enum State { MENU, JOG, RUN }; +State state = MENU; + // === result doAlert(eventMask e, prompt &item); @@ -122,18 +125,18 @@ MENU(subMenu,"Sub-Menu",doNothing,anyEvent,wrapStyle ,EXIT("