Hi All.
I am writing for an ESP32 so I have a bit of memory I can work with. My project is a servo controller/playback system.
typedef struct {
int board;
int servo[16];
} ServoLine;
typedef struct {
char Name[16];
int sMin;
int sMax;
int sDef;
int sCurr;
} ServoEnt;
typedef struct {
int Board;
ServoEnt xElem[16];
} xBoard;
The first structure is for the Servo Controller board.. 4 with 16 servo's on each
The second structure is the details about each servo.. readable name, and capabilities
The third structure xBoard is the issue - as the display will handle paging between each - I need an easy way to have a structure that defines a board - and the full details of all of the servo's on that board.
And the pre-compiler does not like xBoard... It comes up with
What are the 16 'int's in the ServoLine struct? Can you move each of those into the corresponding ServoEnt struct? Then the xBoard struct could take over the duty off the ServoLine struct.
Hi.
The Servo Controller board uses 16 channels, as so for storage and manipulation on an SD card it is easier to have a line of servo positions, and the board that the servo's are attached to.
Technically I can address 62 of these boards and thus 992 individual servo's. Not planning to go that high but it does offer expansion.
I'll be storing the data in a file in the format of the structure ServoLine and so reading it in and writing it out will be easier working in this format.