kopia lustrzana https://github.com/espressif/esp-idf
freemodbus: add extern c block into common header for cpp
rodzic
f245a518be
commit
b1fe4c4cc6
|
@ -18,6 +18,10 @@
|
|||
|
||||
#include "driver/uart.h" // for UART types
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#define MB_CONTROLLER_STACK_SIZE (CONFIG_FMB_CONTROLLER_STACK_SIZE) // Stack size for Modbus controller
|
||||
#define MB_CONTROLLER_PRIORITY (CONFIG_FMB_SERIAL_TASK_PRIO - 1) // priority of MB controller task
|
||||
|
||||
|
@ -135,4 +139,8 @@ typedef esp_err_t (*iface_destroy)(void); /*!< Interface method
|
|||
typedef esp_err_t (*iface_setup)(void*); /*!< Interface method setup */
|
||||
typedef esp_err_t (*iface_start)(void); /*!< Interface method start */
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif // _MB_IFACE_COMMON_H
|
||||
|
|
|
@ -21,6 +21,10 @@
|
|||
#include "soc/soc.h" // for BITN definitions
|
||||
#include "esp_modbus_common.h" // for common types
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
/*!
|
||||
* \brief Modbus descriptor table parameter type defines.
|
||||
*/
|
||||
|
@ -238,4 +242,8 @@ esp_err_t mbc_master_get_parameter(uint16_t cid, char* name, uint8_t* value, uin
|
|||
*/
|
||||
esp_err_t mbc_master_set_parameter(uint16_t cid, char* name, uint8_t* value, uint8_t *type);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif // _ESP_MB_MASTER_INTERFACE_H
|
||||
|
|
|
@ -24,6 +24,10 @@
|
|||
#include "freertos/event_groups.h" // for event groups
|
||||
#include "esp_modbus_common.h" // for common types
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
/**
|
||||
* @brief Parameter access event information type
|
||||
*/
|
||||
|
@ -120,4 +124,8 @@ esp_err_t mbc_slave_get_param_info(mb_param_info_t* reg_info, uint32_t timeout);
|
|||
*/
|
||||
esp_err_t mbc_slave_set_descriptor(mb_register_area_descriptor_t descr_data);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
|
|
@ -13,7 +13,7 @@
|
|||
* limitations under the License.
|
||||
*/
|
||||
// mbcontroller.h
|
||||
// mbcontroller common header
|
||||
// mbcontroller - common Modbus controller header file
|
||||
|
||||
#ifndef _MODBUS_CONTROLLER_COMMON
|
||||
#define _MODBUS_CONTROLLER_COMMON
|
||||
|
@ -28,5 +28,6 @@
|
|||
|
||||
#include "esp_modbus_master.h"
|
||||
#include "esp_modbus_slave.h"
|
||||
|
||||
#endif
|
||||
|
||||
|
|
|
@ -73,10 +73,6 @@ components/expat/
|
|||
components/fatfs/vfs/vfs_fat_internal.h
|
||||
components/fatfs/src/ffconf.h
|
||||
|
||||
components/freemodbus/common/include/esp_modbus_common.h
|
||||
components/freemodbus/common/include/esp_modbus_master.h
|
||||
components/freemodbus/common/include/esp_modbus_slave.h
|
||||
|
||||
components/idf_test/include/idf_performance.h
|
||||
|
||||
components/json/cJSON/
|
||||
|
|
Ładowanie…
Reference in New Issue