pass LCD to scenerunner()
This commit is contained in:
parent
c78aae8aed
commit
e574248a7f
@ -62,7 +62,7 @@ BasicStepperDriver stepper(STEPPER_STEPS, PIN_STEPPER_DIR, PIN_STEPPER_STEP);
|
|||||||
enum State { STATE_MENU, STATE_JOG, STATE_RUN };
|
enum State { STATE_MENU, STATE_JOG, STATE_RUN };
|
||||||
State state = STATE_MENU;
|
State state = STATE_MENU;
|
||||||
|
|
||||||
Scenerunner scenerunner;
|
Scenerunner scenerunner(&lcd);
|
||||||
|
|
||||||
void lcd_print(int line, String string) {
|
void lcd_print(int line, String string) {
|
||||||
Serial.print("lcd_print(");
|
Serial.print("lcd_print(");
|
||||||
|
@ -1,8 +1,10 @@
|
|||||||
#include "Arduino.h"
|
#include "Arduino.h"
|
||||||
|
#include <LiquidCrystal.h>
|
||||||
|
|
||||||
#include "Scenerunner.h"
|
#include "Scenerunner.h"
|
||||||
|
|
||||||
Scenerunner::Scenerunner() {
|
Scenerunner::Scenerunner(LiquidCrystal *lcd) {
|
||||||
// TODO: initialize
|
_lcd = lcd;
|
||||||
}
|
}
|
||||||
|
|
||||||
void Scenerunner::nextAction(){
|
void Scenerunner::nextAction(){
|
||||||
|
@ -2,6 +2,7 @@
|
|||||||
#define Scenerunner_h
|
#define Scenerunner_h
|
||||||
|
|
||||||
#include "Arduino.h"
|
#include "Arduino.h"
|
||||||
|
#include <LiquidCrystal.h>
|
||||||
|
|
||||||
class Scenerunner {
|
class Scenerunner {
|
||||||
|
|
||||||
@ -17,10 +18,11 @@ class Scenerunner {
|
|||||||
int nSteps = 10;
|
int nSteps = 10;
|
||||||
float distance = 0.5;
|
float distance = 0.5;
|
||||||
|
|
||||||
Scenerunner();
|
Scenerunner(LiquidCrystal *lcd);
|
||||||
void nextAction();
|
void nextAction();
|
||||||
|
|
||||||
private:
|
private:
|
||||||
|
LiquidCrystal *_lcd;
|
||||||
enum RunStep { RUN_OFF, RUN_SETTLE, RUN_FOCUS, RUN_SHUTTER, RUN_RETURN };
|
enum RunStep { RUN_OFF, RUN_SETTLE, RUN_FOCUS, RUN_SHUTTER, RUN_RETURN };
|
||||||
RunStep runStep = RUN_OFF;
|
RunStep runStep = RUN_OFF;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user