forked from SZV10X_Software/SZV103_FM33A0xxEV_SiZhu

jinlicong
2024-05-20 e61d1595ebb1fa76b499cddec2df4bd66ec92b97
Function/modbus/tcp/mbtcp.h
copy from Soft/mbcrc.h copy to Function/modbus/tcp/mbtcp.h
File was copied from Soft/mbcrc.h
@@ -27,11 +27,26 @@
 *
 */
#ifndef _MB_CRC_H
#define _MB_CRC_H
#ifndef _MB_TCP_H
#define _MB_TCP_H
#include "port.h"
#ifdef __cplusplus
PR_BEGIN_EXTERN_C
#endif
USHORT          usMBCRC16(USHORT usInit, UCHAR * pucFrame, ULONG usLen );
/* ----------------------- Defines ------------------------------------------*/
#define MB_TCP_PSEUDO_ADDRESS   255
/* ----------------------- Function prototypes ------------------------------*/
    eMBErrorCode eMBTCPDoInit( USHORT ucTCPPort );
void            eMBTCPStart( void );
void            eMBTCPStop( void );
eMBErrorCode    eMBTCPReceive( UCHAR * pucRcvAddress, UCHAR ** pucFrame,
                               USHORT * pusLength );
eMBErrorCode    eMBTCPSend( UCHAR _unused, const UCHAR * pucFrame,
                            USHORT usLength );
#ifdef __cplusplus
PR_END_EXTERN_C
#endif
#endif