UKSS_ICE/message.h
nelolik b8a0477c5c init commit.
Проект каким он достался от Димы.
2021-02-15 09:56:27 +03:00

52 lines
927 B
C

#ifndef MESSAGE_H
#define MESSAGE_H
typedef unsigned char CHAR;
#define ANSWER_LEN 0x80 //70 // 16+16+16+16+6
#define REPLY_LEN 0x19
#define byte_hi byte_1
#define byte_lo byte_0
typedef struct
{
unsigned char Address; // Àäðåñ êîíòðîëëåðà
unsigned char Number; // Íîìåð êîìàíäû
BAITE byte0;
BAITE byte1;
BAITE byte2;
BAITE byte3;
BAITE byte4;
BAITE byte5;
BAITE byte6;
BAITE byte7;
unsigned char crc_lo;
unsigned char crc_hi;
unsigned char add_byte;
} CMD_TO_TMS;
extern WORDE Modbus[];
extern WORDE reply[];
extern LONGE* outputs;
extern int DataAnalog1,DataAnalog2;
extern unsigned int Maska[][9];
//void ReceiveCommand(RS_DATA *rs_arr);
void ReceiveCommandModbus3(RS_DATA *rs_arr);
void ReceiveCommandModbus6(RS_DATA *rs_arr);
void reset_errs(int sens, ERROR er);
void Save_params(void);
void Load_params(void);
void Load_caliber(void);
void Default_params(void);
#endif //MESSAGE_H