mirror of
https://github.com/apache/nuttx-apps.git
synced 2026-10-12 00:10:14 +00:00
Macros PR_BEGIN_EXTERN_C and PR_END_EXTERN_C were not defined in all contexts. Remove definition and replace with explicit expansion. From Stefan Kolb
This commit is contained in:
parent
84dbf4ee7c
commit
71d944a5d0
12 changed files with 38 additions and 27 deletions
|
|
@ -65,7 +65,8 @@
|
|||
#include <termios.h>
|
||||
|
||||
#ifdef __cplusplus
|
||||
PR_BEGIN_EXTERN_C
|
||||
extern "C"
|
||||
{
|
||||
#endif
|
||||
|
||||
#include "mbport.h"
|
||||
|
|
@ -431,6 +432,6 @@ eMBErrorCode eMBRegDiscreteCB(uint8_t *pucRegBuffer, uint16_t usAddress,
|
|||
uint16_t usNDiscrete);
|
||||
|
||||
#ifdef __cplusplus
|
||||
PR_END_EXTERN_C
|
||||
}
|
||||
#endif
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -67,7 +67,8 @@
|
|||
#include <termios.h>
|
||||
|
||||
#ifdef __cplusplus
|
||||
PR_BEGIN_EXTERN_C
|
||||
extern "C"
|
||||
{
|
||||
#endif
|
||||
|
||||
#include "mbport.h"
|
||||
|
|
@ -459,7 +460,7 @@ void vMBMasterSetErrorType(eMBMasterErrorEventType errorType);
|
|||
eMBMasterReqErrCode eMBMasterWaitRequestFinish(void);
|
||||
|
||||
#ifdef __cplusplus
|
||||
PR_END_EXTERN_C
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* __APPS_INCLUDE_MODBUS_MB_M_H */
|
||||
|
|
|
|||
|
|
@ -33,7 +33,8 @@
|
|||
#define __APPS_INCLUDE_MODBUS_MBFRAME_H
|
||||
|
||||
#ifdef __cplusplus
|
||||
PR_BEGIN_EXTERN_C
|
||||
extern "C"
|
||||
{
|
||||
#endif
|
||||
|
||||
/****************************************************************************
|
||||
|
|
@ -84,7 +85,7 @@ typedef eMBErrorCode (*peMBFrameSend)(uint8_t slaveAddress,
|
|||
typedef void (*pvMBFrameClose)(void);
|
||||
|
||||
#ifdef __cplusplus
|
||||
PR_END_EXTERN_C
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* __APPS_INCLUDE_MODBUS_MBFRAME_H */
|
||||
|
|
|
|||
|
|
@ -33,7 +33,8 @@
|
|||
#define __APPS_INCLUDE_MODBUS_MBFUNC_H
|
||||
|
||||
#ifdef __cplusplus
|
||||
PR_BEGIN_EXTERN_C
|
||||
extern "C"
|
||||
{
|
||||
#endif
|
||||
|
||||
/****************************************************************************
|
||||
|
|
@ -81,7 +82,7 @@ eMBException eMBFuncReadWriteMultipleHoldingRegister(uint8_t *pucFrame, uint16_t
|
|||
#endif
|
||||
|
||||
#ifdef __cplusplus
|
||||
PR_END_EXTERN_C
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* __APPS_INCLUDE_MODBUS_MBFUNC_H */
|
||||
|
|
|
|||
|
|
@ -44,7 +44,8 @@
|
|||
****************************************************************************/
|
||||
|
||||
#ifdef __cplusplus
|
||||
PR_BEGIN_EXTERN_C
|
||||
extern "C"
|
||||
{
|
||||
#endif
|
||||
|
||||
typedef enum
|
||||
|
|
@ -185,7 +186,7 @@ bool xMBTCPPortSendResponse(const uint8_t *pucMBTCPFrame, uint16_t usTCPLength);
|
|||
#endif
|
||||
|
||||
#ifdef __cplusplus
|
||||
PR_END_EXTERN_C
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* __APPS_INCLUDE_MODBUS_MBPORT_H */
|
||||
|
|
|
|||
|
|
@ -33,7 +33,8 @@
|
|||
#define __APPS_INCLUDE_MODBUS_MBPROTO_H
|
||||
|
||||
#ifdef __cplusplus
|
||||
PR_BEGIN_EXTERN_C
|
||||
extern "C"
|
||||
{
|
||||
#endif
|
||||
|
||||
/****************************************************************************
|
||||
|
|
@ -87,7 +88,7 @@ typedef struct
|
|||
} xMBFunctionHandler;
|
||||
|
||||
#ifdef __cplusplus
|
||||
PR_END_EXTERN_C
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* __APPS_INCLUDE_MODBUS_MBPROTO_H */
|
||||
|
|
|
|||
|
|
@ -33,7 +33,8 @@
|
|||
#define __APPS_INCLUDE_MODBUS_MBUTILS_H
|
||||
|
||||
#ifdef __cplusplus
|
||||
PR_BEGIN_EXTERN_C
|
||||
extern "C"
|
||||
{
|
||||
#endif
|
||||
|
||||
/****************************************************************************
|
||||
|
|
@ -104,7 +105,7 @@ void xMBUtilSetBits(uint8_t *ucByteBuf, uint16_t usBitOffset,
|
|||
uint8_t xMBUtilGetBits(uint8_t *ucByteBuf, uint16_t usBitOffset, uint8_t ucNBits);
|
||||
|
||||
#ifdef __cplusplus
|
||||
PR_END_EXTERN_C
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* __APPS_INCLUDE_MODBUS_MBUTILS_H */
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue