/******************************************************************************************
|
--------------------------------file information-------------------------------------------
|
** The Name of File : RelayControl.h
|
** The Date of Last Modified: 2012-05-09
|
** Created By : WinTer
|
** The Version : Original Version
|
** Descriptions : Control the Relays by RS485.
|
******************************************************************************************/
|
|
|
|
#ifndef RelayControl_H
|
#define RelayControl_H
|
|
//-------------CMD-------------
|
#define CMD_StepOut 0xF1 //Get StepOut
|
#define CMD_Vol 0xF2 //Send SumVoltage
|
#define CMD_ST 0xF3 //send stop signal
|
|
|
|
|
unsigned int GetStepOut(void);
|
void SendVoltage(void);
|
void CommWithRelays(const unsigned int CMD,void *TXData,void *RXData);
|
void SendStopCMD(void);
|
void SetCMDenable(unsigned char cmd);
|
void ControlRelays(void);
|
unsigned char GetCMDinf(void);
|
void SetCommError(unsigned char err);
|
unsigned char GetCommError(void);
|
|
|
|
|
|
#endif
|