Project

General

Profile

Feature #3320 » ModbusTcpc17pis.h

yan hong, 01/22/2024 02:40 PM

 
1
// ModbusTcpc17pis.h: interface for the CModbusTcpc17pis class.
2
//
3
//////////////////////////////////////////////////////////////////////
4

    
5
#if !defined(AFX_ModbusTcpc17pis_H__EC710A20_96AA_466B_AA0D_5EFBCAB9FF4E__INCLUDED_)
6
#define AFX_ModbusTcpc17pis_H__EC710A20_96AA_466B_AA0D_5EFBCAB9FF4E__INCLUDED_
7

    
8
#if _MSC_VER > 1000
9
#pragma once
10
#endif // _MSC_VER > 1000
11

    
12
#include "daq/daq_protocol.h"
13
#include "daq/daq_cmddef.h"
14
#include <string>
15

    
16
class CModbusTcpc17pis : public CProtocol  
17
{
18
public:
19
	CModbusTcpc17pis();
20
	virtual ~CModbusTcpc17pis();
21
public:
22
	virtual sint32 RxProc();
23
	virtual sint32 TxProc();
24
	virtual sint32 GetZfFlag(){ return 0; };
25
	virtual void Init(S_PROTOCOLCFG *pcfg);
26
	virtual void SetExtendedPara(uint16 no, sint32 val);
27
	void CmdRet(uint8 result);
28
protected:
29
	void CallMeasure();
30
	int GetNowSecond();
31
	void ProcMeasure(uint8 *buf,int buflen);
32
	virtual BOOL ProcCmd();
33
private:
34
	int	m_nRcvTimeOuts;		//??ʱʱ??
35
	WORD m_nNo;              //˳???
36
	int m_nLastSendTime;
37
	uint8 m_nStationNo;
38
	ST_TRACK_ADDR m_CmdSrc;
39
//	E_CMD_SRCSORT	m_cmdprotsort;
40
//	uint16			m_cmdsrc_rtu;
41
};
42

    
43
#endif // !defined(AFX_ModbusTcpc17pis_H__EC710A20_96AA_466B_AA0D_5EFBCAB9FF4E__INCLUDED_)
(2-2/3)