Make Gcode from .txt data. It is 2D array, for Robot Path.
Dependents: WRS_mechanamu_test WRS2019_master
Diff: MakeSequencer.h
- Revision:
- 4:1e606e2301f9
- Parent:
- 3:09ee560a3007
- Child:
- 5:9b4fcc87af6a
--- a/MakeSequencer.h Thu Oct 11 11:23:53 2018 +0000 +++ b/MakeSequencer.h Wed Oct 17 08:39:42 2018 +0000 @@ -3,32 +3,25 @@ #include "mbed.h" #include "string" -#define CODE_LENGTH 100 -#define ARRAY_EREMENT 10 +#define CODE_LENGTH 15 +#define ARRAY_EREMENT 5 +#define BUF 256 class MakeSequencer { public: MakeSequencer(FILE *fp); - bool FileOpen(); - void getGcode(int _row,int aSize,int* _array); + void getGcode(int row,int aSize,int* array); + int getGcodeSize(); bool ReadGcode(); - int getGcodeSize(); - private: - char _buf[256]; + private: int _data[ARRAY_EREMENT][CODE_LENGTH]; int _codesize; - - int _tempnum[ARRAY_EREMENT]; int _ele; - char _element[ARRAY_EREMENT][CODE_LENGTH]; - char _char; int _count; - bool _check[ARRAY_EREMENT][CODE_LENGTH]; - LocalFileSystem *_local; FILE *_fp; };