2023-08-04 19:34:51 +02:00
|
|
|
#ifndef PROGRAM_H
|
|
|
|
#define PROGRAM_H
|
|
|
|
|
2023-08-11 16:40:06 +02:00
|
|
|
#include <Arduino.h>
|
|
|
|
|
|
|
|
#include "Encoder.h"
|
2023-08-04 19:34:51 +02:00
|
|
|
|
|
|
|
class Program {
|
|
|
|
public:
|
|
|
|
/**
|
|
|
|
* Program startup
|
|
|
|
*/
|
|
|
|
Program();
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Program main loop
|
|
|
|
*/
|
|
|
|
void loop();
|
2023-08-11 16:40:06 +02:00
|
|
|
private:
|
|
|
|
/**
|
|
|
|
* Encoder object
|
|
|
|
*/
|
|
|
|
Encoder* encoder;
|
2023-08-11 17:15:34 +02:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Old encoder position
|
|
|
|
*/
|
|
|
|
long oldPosition;
|
2023-08-04 19:34:51 +02:00
|
|
|
};
|
|
|
|
|
|
|
|
#endif
|