Add RW data.
This commit is contained in:
@@ -31,8 +31,8 @@ enum TCPIP_CMD
|
||||
{
|
||||
TCPIP_CMD_NONE=0,
|
||||
TCPIP_CMD_HANDSHAKING,
|
||||
TCPIP_CMD_READ_DATA,
|
||||
TCPIP_CMD_WRITE_DATA,
|
||||
TCPIP_CMD_READ_D_DATA,
|
||||
TCPIP_CMD_WRITE_D_DATA,
|
||||
|
||||
TCPIP_CMD_TATAL
|
||||
};
|
||||
@@ -67,13 +67,15 @@ struct struct_so7_tcpip_data
|
||||
{
|
||||
int _type;
|
||||
int _DataSize;
|
||||
double *_dbBuff;
|
||||
int* _iData;
|
||||
} s_recv_data;
|
||||
struct s_status
|
||||
{
|
||||
TCPIP_RETURN_CODE _SendReturnCode;
|
||||
TCPIP_RETURN_CODE _RecvReturnCode;
|
||||
bool _handshaking;
|
||||
bool _HandshakingSucceed;
|
||||
bool _WriteDataCompleted;
|
||||
bool _ReadDataCompleted;
|
||||
} s_status;
|
||||
};
|
||||
#pragma pack(pop)
|
||||
@@ -93,11 +95,12 @@ public:
|
||||
static int m_Thread_State;
|
||||
|
||||
TCPIP_RETURN_CODE Connect(const HWND& _hWnd,const in_addr& _IPAddress,const u_short& _nPortNumber);
|
||||
TCPIP_RETURN_CODE Send(int _Addr,int _Data);
|
||||
TCPIP_RETURN_CODE Recv(int _Addr,int& _Data,bool _bWait);
|
||||
TCPIP_RETURN_CODE DisConnect();
|
||||
TCPIP_RETURN_CODE GetHostIPAddr(in_addr& _IPAddress);
|
||||
TCPIP_RETURN_CODE Handshaking();
|
||||
TCPIP_RETURN_CODE _Send_Cmd_Write_D_Data(const short& _Addr,short* _Data,int _DataSize);
|
||||
TCPIP_RETURN_CODE _Send_Cmd_Read_D_Data(const short& _StartAddr,const short& _DataSize);
|
||||
|
||||
|
||||
LRESULT OnSocket(WPARAM wParam, LPARAM lParam);
|
||||
private:
|
||||
|
||||
Reference in New Issue
Block a user