Home
last modified time | relevance | path

Searched refs:pucFrame (Results 1 – 25 of 28) sorted by relevance

12

/hal_espressif-3.4.0/components/freemodbus/modbus/functions/
Dmbfuncholding.c78 eMBFuncWriteHoldingRegister( UCHAR * pucFrame, USHORT * usLen ) in eMBFuncWriteHoldingRegister() argument
86 usRegAddress = ( USHORT )( pucFrame[MB_PDU_FUNC_WRITE_ADDR_OFF] << 8 ); in eMBFuncWriteHoldingRegister()
87 usRegAddress |= ( USHORT )( pucFrame[MB_PDU_FUNC_WRITE_ADDR_OFF + 1] ); in eMBFuncWriteHoldingRegister()
91 eRegStatus = eMBRegHoldingCB( &pucFrame[MB_PDU_FUNC_WRITE_VALUE_OFF], in eMBFuncWriteHoldingRegister()
111 eMBFuncWriteMultipleHoldingRegister( UCHAR * pucFrame, USHORT * usLen ) in eMBFuncWriteMultipleHoldingRegister() argument
122 usRegAddress = ( USHORT )( pucFrame[MB_PDU_FUNC_WRITE_MUL_ADDR_OFF] << 8 ); in eMBFuncWriteMultipleHoldingRegister()
123 usRegAddress |= ( USHORT )( pucFrame[MB_PDU_FUNC_WRITE_MUL_ADDR_OFF + 1] ); in eMBFuncWriteMultipleHoldingRegister()
126 usRegCount = ( USHORT )( pucFrame[MB_PDU_FUNC_WRITE_MUL_REGCNT_OFF] << 8 ); in eMBFuncWriteMultipleHoldingRegister()
127 usRegCount |= ( USHORT )( pucFrame[MB_PDU_FUNC_WRITE_MUL_REGCNT_OFF + 1] ); in eMBFuncWriteMultipleHoldingRegister()
129 ucRegByteCount = pucFrame[MB_PDU_FUNC_WRITE_MUL_BYTECNT_OFF]; in eMBFuncWriteMultipleHoldingRegister()
[all …]
Dmbfunccoils.c70 eMBFuncReadCoils( UCHAR * pucFrame, USHORT * usLen ) in eMBFuncReadCoils() argument
82 usRegAddress = ( USHORT )( pucFrame[MB_PDU_FUNC_READ_ADDR_OFF] << 8 ); in eMBFuncReadCoils()
83 usRegAddress |= ( USHORT )( pucFrame[MB_PDU_FUNC_READ_ADDR_OFF + 1] ); in eMBFuncReadCoils()
86 usCoilCount = ( USHORT )( pucFrame[MB_PDU_FUNC_READ_COILCNT_OFF] << 8 ); in eMBFuncReadCoils()
87 usCoilCount |= ( USHORT )( pucFrame[MB_PDU_FUNC_READ_COILCNT_OFF + 1] ); in eMBFuncReadCoils()
96 pucFrameCur = &pucFrame[MB_PDU_FUNC_OFF]; in eMBFuncReadCoils()
149 eMBFuncWriteCoil( UCHAR * pucFrame, USHORT * usLen ) in eMBFuncWriteCoil() argument
159 usRegAddress = ( USHORT )( pucFrame[MB_PDU_FUNC_WRITE_ADDR_OFF] << 8 ); in eMBFuncWriteCoil()
160 usRegAddress |= ( USHORT )( pucFrame[MB_PDU_FUNC_WRITE_ADDR_OFF + 1] ); in eMBFuncWriteCoil()
163 if( ( pucFrame[MB_PDU_FUNC_WRITE_VALUE_OFF + 1] == 0x00 ) && in eMBFuncWriteCoil()
[all …]
Dmbfunccoils_m.c114 eMBMasterFuncReadCoils( UCHAR * pucFrame, USHORT * usLen ) in eMBMasterFuncReadCoils() argument
154 ( ucByteCount == pucFrame[MB_PDU_FUNC_READ_COILCNT_OFF] ) ) in eMBMasterFuncReadCoils()
157 …eRegStatus = eMBMasterRegCoilsCB( &pucFrame[MB_PDU_FUNC_READ_VALUES_OFF], usRegAddress, usCoilCoun… in eMBMasterFuncReadCoils()
220 eMBMasterFuncWriteCoil( UCHAR * pucFrame, USHORT * usLen ) in eMBMasterFuncWriteCoil() argument
230 usRegAddress = ( USHORT )( pucFrame[MB_PDU_FUNC_WRITE_ADDR_OFF] << 8 ); in eMBMasterFuncWriteCoil()
231 usRegAddress |= ( USHORT )( pucFrame[MB_PDU_FUNC_WRITE_ADDR_OFF + 1] ); in eMBMasterFuncWriteCoil()
234 if( ( pucFrame[MB_PDU_FUNC_WRITE_VALUE_OFF + 1] == 0x00 ) && in eMBMasterFuncWriteCoil()
235 ( ( pucFrame[MB_PDU_FUNC_WRITE_VALUE_OFF] == 0xFF ) || in eMBMasterFuncWriteCoil()
236 ( pucFrame[MB_PDU_FUNC_WRITE_VALUE_OFF] == 0x00 ) ) ) in eMBMasterFuncWriteCoil()
239 if( pucFrame[MB_PDU_FUNC_WRITE_VALUE_OFF] == 0xFF ) in eMBMasterFuncWriteCoil()
[all …]
Dmbfuncinput.c61 eMBFuncReadInputRegister( UCHAR * pucFrame, USHORT * usLen ) in eMBFuncReadInputRegister() argument
72 usRegAddress = ( USHORT )( pucFrame[MB_PDU_FUNC_READ_ADDR_OFF] << 8 ); in eMBFuncReadInputRegister()
73 usRegAddress |= ( USHORT )( pucFrame[MB_PDU_FUNC_READ_ADDR_OFF + 1] ); in eMBFuncReadInputRegister()
76 usRegCount = ( USHORT )( pucFrame[MB_PDU_FUNC_READ_REGCNT_OFF] << 8 ); in eMBFuncReadInputRegister()
77 usRegCount |= ( USHORT )( pucFrame[MB_PDU_FUNC_READ_REGCNT_OFF + 1] ); in eMBFuncReadInputRegister()
86 pucFrameCur = &pucFrame[MB_PDU_FUNC_OFF]; in eMBFuncReadInputRegister()
Dmbfuncdisc.c65 eMBFuncReadDiscreteInputs( UCHAR * pucFrame, USHORT * usLen ) in eMBFuncReadDiscreteInputs() argument
77 usRegAddress = ( USHORT )( pucFrame[MB_PDU_FUNC_READ_ADDR_OFF] << 8 ); in eMBFuncReadDiscreteInputs()
78 usRegAddress |= ( USHORT )( pucFrame[MB_PDU_FUNC_READ_ADDR_OFF + 1] ); in eMBFuncReadDiscreteInputs()
81 usDiscreteCnt = ( USHORT )( pucFrame[MB_PDU_FUNC_READ_DISCCNT_OFF] << 8 ); in eMBFuncReadDiscreteInputs()
82 usDiscreteCnt |= ( USHORT )( pucFrame[MB_PDU_FUNC_READ_DISCCNT_OFF + 1] ); in eMBFuncReadDiscreteInputs()
91 pucFrameCur = &pucFrame[MB_PDU_FUNC_OFF]; in eMBFuncReadDiscreteInputs()
Dmbfuncholding_m.c125 eMBMasterFuncWriteHoldingRegister( UCHAR * pucFrame, USHORT * usLen ) in eMBMasterFuncWriteHoldingRegister() argument
133 usRegAddress = ( USHORT )( pucFrame[MB_PDU_FUNC_WRITE_ADDR_OFF] << 8 ); in eMBMasterFuncWriteHoldingRegister()
134 usRegAddress |= ( USHORT )( pucFrame[MB_PDU_FUNC_WRITE_ADDR_OFF + 1] ); in eMBMasterFuncWriteHoldingRegister()
138 eRegStatus = eMBMasterRegHoldingCB( &pucFrame[MB_PDU_FUNC_WRITE_VALUE_OFF], in eMBMasterFuncWriteHoldingRegister()
203 eMBMasterFuncWriteMultipleHoldingRegister( UCHAR * pucFrame, USHORT * usLen ) in eMBMasterFuncWriteMultipleHoldingRegister() argument
289 eMBMasterFuncReadHoldingRegister( UCHAR * pucFrame, USHORT * usLen ) in eMBMasterFuncReadHoldingRegister() argument
316 if( ( usRegCount >= 1 ) && ( 2 * usRegCount == pucFrame[MB_PDU_FUNC_READ_BYTECNT_OFF] ) ) in eMBMasterFuncReadHoldingRegister()
319 …eRegStatus = eMBMasterRegHoldingCB( &pucFrame[MB_PDU_FUNC_READ_VALUES_OFF], usRegAddress, usRegCou… in eMBMasterFuncReadHoldingRegister()
395 eMBMasterFuncReadWriteMultipleHoldingRegister( UCHAR * pucFrame, USHORT * usLen ) in eMBMasterFuncReadWriteMultipleHoldingRegister() argument
428 if( ( 2 * usRegReadCount ) == pucFrame[MB_PDU_FUNC_READWRITE_READ_BYTECNT_OFF] ) in eMBMasterFuncReadWriteMultipleHoldingRegister()
[all …]
Dmbfuncinput_m.c96 eMBMasterFuncReadInputRegister( UCHAR * pucFrame, USHORT * usLen ) in eMBMasterFuncReadInputRegister() argument
123 if( ( usRegCount >= 1 ) && ( 2 * usRegCount == pucFrame[MB_PDU_FUNC_READ_BYTECNT_OFF] ) ) in eMBMasterFuncReadInputRegister()
126 …eRegStatus = eMBMasterRegInputCB( &pucFrame[MB_PDU_FUNC_READ_VALUES_OFF], usRegAddress, usRegCount… in eMBMasterFuncReadInputRegister()
Dmbfuncdisc_m.c97 eMBMasterFuncReadDiscreteInputs( UCHAR * pucFrame, USHORT * usLen ) in eMBMasterFuncReadDiscreteInputs() argument
136 if ((usDiscreteCnt >= 1) && ucNBytes == pucFrame[MB_PDU_FUNC_READ_DISCCNT_OFF]) in eMBMasterFuncReadDiscreteInputs()
139 …eRegStatus = eMBMasterRegDiscreteCB( &pucFrame[MB_PDU_FUNC_READ_VALUES_OFF], usRegAddress, usDiscr… in eMBMasterFuncReadDiscreteInputs()
Dmbfuncother.c83 eMBFuncReportSlaveID( UCHAR * pucFrame, USHORT * usLen ) in eMBFuncReportSlaveID() argument
85 memcpy( &pucFrame[MB_PDU_DATA_OFF], &ucMBSlaveID[0], ( size_t )usMBSlaveIDLen ); in eMBFuncReportSlaveID()
/hal_espressif-3.4.0/components/freemodbus/modbus/include/
Dmbfunc.h38 eMBException eMBFuncReportSlaveID( UCHAR * pucFrame, USHORT * usLen );
42 eMBException eMBFuncReadInputRegister( UCHAR * pucFrame, USHORT * usLen );
46 eMBException eMBFuncReadHoldingRegister( UCHAR * pucFrame, USHORT * usLen );
50 eMBException eMBFuncWriteHoldingRegister( UCHAR * pucFrame, USHORT * usLen );
54 eMBException eMBFuncWriteMultipleHoldingRegister( UCHAR * pucFrame, USHORT * usLen );
58 eMBException eMBFuncReadCoils( UCHAR * pucFrame, USHORT * usLen );
62 eMBException eMBFuncWriteCoil( UCHAR * pucFrame, USHORT * usLen );
66 eMBException eMBFuncWriteMultipleCoils( UCHAR * pucFrame, USHORT * usLen );
70 eMBException eMBFuncReadDiscreteInputs( UCHAR * pucFrame, USHORT * usLen );
74 eMBException eMBFuncReadWriteMultipleHoldingRegister( UCHAR * pucFrame, USHORT * usLen );
Dmb_m.h367 eMBMasterFuncReportSlaveID( UCHAR * pucFrame, USHORT * usLen );
369 eMBMasterFuncReadInputRegister( UCHAR * pucFrame, USHORT * usLen );
371 eMBMasterFuncReadHoldingRegister( UCHAR * pucFrame, USHORT * usLen );
373 eMBMasterFuncWriteHoldingRegister( UCHAR * pucFrame, USHORT * usLen );
375 eMBMasterFuncWriteMultipleHoldingRegister( UCHAR * pucFrame, USHORT * usLen );
377 eMBMasterFuncReadCoils( UCHAR * pucFrame, USHORT * usLen );
379 eMBMasterFuncWriteCoil( UCHAR * pucFrame, USHORT * usLen );
381 eMBMasterFuncWriteMultipleCoils( UCHAR * pucFrame, USHORT * usLen );
383 eMBMasterFuncReadDiscreteInputs( UCHAR * pucFrame, USHORT * usLen );
385 eMBMasterFuncReadWriteMultipleHoldingRegister( UCHAR * pucFrame, USHORT * usLen );
[all …]
Dmbframe.h91 UCHAR ** pucFrame,
95 const UCHAR * pucFrame,
/hal_espressif-3.4.0/components/freemodbus/modbus/ascii/
Dmbascii.c81 static UCHAR prvucMBLRC( UCHAR * pucFrame, USHORT usLen );
144 eMBASCIIReceive( UCHAR * pucRcvAddress, UCHAR ** pucFrame, USHORT * pusLength ) in eMBASCIIReceive() argument
166 *pucFrame = ( UCHAR * ) & ucASCIIBuf[MB_SER_PDU_PDU_OFF]; in eMBASCIIReceive()
177 eMBASCIISend( UCHAR ucSlaveAddress, const UCHAR * pucFrame, USHORT usLength ) in eMBASCIISend() argument
190 pucSndBufferCur = ( UCHAR * ) pucFrame - 1; in eMBASCIISend()
459 prvucMBLRC( UCHAR * pucFrame, USHORT usLen ) in prvucMBLRC() argument
465 ucLRC += *pucFrame++; /* Add buffer byte without carry */ in prvucMBLRC()
Dmbascii.h51 eMBErrorCode eMBASCIIReceive( UCHAR * pucRcvAddress, UCHAR ** pucFrame,
53 eMBErrorCode eMBASCIISend( UCHAR slaveAddress, const UCHAR * pucFrame,
66 eMBErrorCode eMBMasterASCIIReceive( UCHAR * pucRcvAddress, UCHAR ** pucFrame,
68 eMBErrorCode eMBMasterASCIISend( UCHAR slaveAddress, const UCHAR * pucFrame,
Dmbascii_m.c88 static UCHAR prvucMBLRC( UCHAR * pucFrame, USHORT usLen );
149 eMBMasterASCIIReceive( UCHAR * pucRcvAddress, UCHAR ** pucFrame, USHORT * pusLength ) in eMBMasterASCIIReceive() argument
171 *pucFrame = ( UCHAR * ) & ucMasterASCIIRcvBuf[MB_SER_PDU_PDU_OFF]; in eMBMasterASCIIReceive()
182 eMBMasterASCIISend( UCHAR ucSlaveAddress, const UCHAR * pucFrame, USHORT usLength ) in eMBMasterASCIISend() argument
197 pucMasterSndBufferCur = ( UCHAR * ) pucFrame - 1; in eMBMasterASCIISend()
559 prvucMBLRC( UCHAR * pucFrame, USHORT usLen ) in prvucMBLRC() argument
565 ucLRC += *pucFrame++; /* Add buffer byte without carry */ in prvucMBLRC()
/hal_espressif-3.4.0/components/freemodbus/modbus/rtu/
Dmbrtu.h47 eMBErrorCode eMBRTUReceive( UCHAR * pucRcvAddress, UCHAR ** pucFrame, USHORT * pusLength );
48 eMBErrorCode eMBRTUSend( UCHAR slaveAddress, const UCHAR * pucFrame, USHORT usLength );
59 eMBErrorCode eMBMasterRTUReceive( UCHAR * pucRcvAddress, UCHAR ** pucFrame, USHORT * pusLength );
60 eMBErrorCode eMBMasterRTUSend( UCHAR slaveAddress, const UCHAR * pucFrame, USHORT usLength );
Dmbrtu.c148 eMBRTUReceive( UCHAR * pucRcvAddress, UCHAR ** pucFrame, USHORT * pusLength ) in eMBRTUReceive() argument
170 *pucFrame = ( UCHAR * ) & ucRTUBuf[MB_SER_PDU_PDU_OFF]; in eMBRTUReceive()
182 eMBRTUSend( UCHAR ucSlaveAddress, const UCHAR * pucFrame, USHORT usLength ) in eMBRTUSend() argument
196 pucSndBufferCur = ( UCHAR * ) pucFrame - 1; in eMBRTUSend()
Dmbrtu_m.c154 eMBMasterRTUReceive( UCHAR * pucRcvAddress, UCHAR ** pucFrame, USHORT * pusLength ) in eMBMasterRTUReceive() argument
176 *pucFrame = ( UCHAR * ) & ucMasterRTURcvBuf[MB_SER_PDU_PDU_OFF]; in eMBMasterRTUReceive()
188 eMBMasterRTUSend( UCHAR ucSlaveAddress, const UCHAR * pucFrame, USHORT usLength ) in eMBMasterRTUSend() argument
204 pucMasterSndBufferCur = ( UCHAR * ) pucFrame - 1; in eMBMasterRTUSend()
Dmbcrc.c88 usMBCRC16( UCHAR * pucFrame, USHORT usLen ) in usMBCRC16() argument
96 iIndex = ucCRCLo ^ *( pucFrame++ ); in usMBCRC16()
Dmbcrc.h34 USHORT usMBCRC16( UCHAR * pucFrame, USHORT usLen );
/hal_espressif-3.4.0/components/freemodbus/port/
Dport.c79 prvvMBTCPLogFrame( const CHAR * pucMsg, UCHAR * pucFrame, USHORT usFrameLen ) in prvvMBTCPLogFrame() argument
87 assert( pucFrame != NULL ); in prvvMBTCPLogFrame()
130 res = snprintf( &arcBuffer[iBufPos], iBufLeft, "%02X", pucFrame[i] ); in prvvMBTCPLogFrame()
/hal_espressif-3.4.0/components/freemodbus/modbus/tcp/
Dmbtcp.h46 eMBErrorCode eMBTCPReceive( UCHAR * pucRcvAddress, UCHAR ** pucFrame,
48 eMBErrorCode eMBTCPSend( UCHAR _unused, const UCHAR * pucFrame,
Dmbtcp_m.h46 eMBErrorCode eMBMasterTCPReceive( UCHAR * pucRcvAddress, UCHAR ** pucFrame,
48 eMBErrorCode eMBMasterTCPSend( UCHAR _unused, const UCHAR * pucFrame,
Dmbtcp.c134 eMBTCPSend( UCHAR _unused, const UCHAR * pucFrame, USHORT usLength ) in eMBTCPSend() argument
137 UCHAR *pucMBTCPFrame = ( UCHAR * ) pucFrame - MB_TCP_FUNC; in eMBTCPSend()
Dmbtcp_m.c133 eMBMasterTCPSend( UCHAR _unused, const UCHAR * pucFrame, USHORT usLength ) in eMBMasterTCPSend() argument
136 UCHAR *pucMBTCPFrame = ( UCHAR * ) pucFrame - MB_TCP_FUNC; in eMBMasterTCPSend()

12