diff --git a/src/Lanes.cpp b/src/Lanes.cpp index 42a8401..ba56000 100644 --- a/src/Lanes.cpp +++ b/src/Lanes.cpp @@ -1 +1,37 @@ -#include "Lanes.h" \ No newline at end of file +#include "Lanes.h" + +/* +private: + int pin; + int pos; + int time; + int track[4][64]; + int end; + + Table for Expo curve with sign manipulation to alter direction and exp/log. Use linear interpolation to avoid aliasing on slow slopes. + + array of function pointers which share index with curve type. +*/ + +Lane::Lane(int OutputPin){ + pin = OutputPin; + analogWrite( pin, 0); + pos = 0; + time = 0; + end = 16; +}; +void Lane::Update(int CurrentTime){ + +}; +void Lane::Randomize(){ + +}; +int Lane::Positiion(){ + +}; +void Lane::StepUpdate(int Step, int Voltage, int Curve, int Param){ + +}; +void Lane::EndUpdate(int NewEnd){ + +}; \ No newline at end of file diff --git a/src/Lanes.h b/src/Lanes.h index cd93485..5e00564 100644 --- a/src/Lanes.h +++ b/src/Lanes.h @@ -1,14 +1,27 @@ #ifndef Lanes_h #define Lanes_h +#include + +const int CurveTable[2] = {0, 1}; class Lane { public: - Lane(int Pin); - void output(); + Lane(int OutputPin); + void Update(int CurrentTime); + void Randomize(); + int Positiion(); + void StepUpdate(int Step, int Voltage, int Curve, int Param); + void EndUpdate(int NewEnd); + private: + int pin; + int pos; + int time; + int track[4][64]; + int end; }; #endif \ No newline at end of file