/************************** * Data-Structures * *************************** * Designed & Developed by * * Adrien Marquès * * * *************************** * doowap31@gmail.com * **************************/ #ifndef _DATA_H_ #define _DATA_H_ #define TERMREQ_FBK 0x01 #define TERMREQ_CAP 0x02 #define TERMREQ_SPD 0x04 #define TERMREQ_ALT 0x08 #define PLANE_LEN ( sizeof(char)*6+sizeof(int)*5 ) struct plane{ char code[6]; int x; int y; int z; int cap; int spd; }; struct term_req{ char flags; struct plane udpate; }; struct term_res{ char flags; char n; struct plane* data; }; #define BINDHDR_LEN ( sizeof(char)*(1+INET_ADDRSTRLEN)+sizeof(unsigned short) ) #define BINDHEAD_CTL 0x01 // is command terminal (else: view terminal) #define BINDHEAD_SCK 0x02 // ask for com socket (terminal) #define BINDHEAD_TCP 0x04 // ask TCP com socket (plane) struct bind_header{ char flags; char addr[INET_ADDRSTRLEN]; unsigned short port; }; #endif