API  2.3.0
TSmarT Software Library
 All Data Structures Functions Variables Typedefs Enumerations Enumerator Groups Pages
xMBMInternalHandle Struct Reference

Every MODBUS master instance has a handle which contains pointers to functions and a buffer for assembling MODBUS frames. More...

#include <mbmi.h>

Data Fields

xMBPTimerHandle xRespTimeoutHdl
 
xMBPEventHandle xFrameEventHdl
 
xMBMFrameHandle xFrameHdl
 
UBYTE ubIdx
 
USHORT usFrameMBPDULength
 
UBYTE * pubFrameMBPDUBuffer
 
peMBMFrameSend pFrameSendFN
 
peMBMFrameReceive pFrameRecvFN
 
peMBMFrameClose pFrameCloseFN
 

Detailed Description

Every MODBUS master instance has a handle which contains pointers to functions and a buffer for assembling MODBUS frames.

Field Documentation

peMBMFrameClose pFrameCloseFN

Pointer to a function used for shutdown.

peMBMFrameReceive pFrameRecvFN

Pointer to a function used to receive MODBUS frames.

peMBMFrameSend pFrameSendFN

Pointer to a function used to transmit MODBUS frames.

UBYTE* pubFrameMBPDUBuffer

Buffer to assemble MODBUS PDUs.

UBYTE ubIdx

The internal index used to lookup handles.

USHORT usFrameMBPDULength

The size of the request or response FRAME.

xMBPEventHandle xFrameEventHdl

Receives MBM_EV_SENT, MBM_EV_TIMEOUT and MBM_EV_RECEIVED events.

xMBMFrameHandle xFrameHdl

Private data for the ASCII/RTU or TCP implementations.

xMBPTimerHandle xRespTimeoutHdl

Timer for implementing the response timeout.