/** * @file include/di/can/net/discover.h * @brief DI-Net CAN network discovery * @date Oct 17, 2016 * @author jjacobs * @copyright 2016 Dual Inventive Technology Centre B.V. * * CAN network discovery */ #ifndef LIBDI_INCLUDE_DI_CAN_NET_CALLBACKS_H_ #define LIBDI_INCLUDE_DI_CAN_NET_CALLBACKS_H_ struct di_can_msg; struct di_can_ctx; #include #ifdef __cplusplus extern "C" { #endif /** Callback item for net heartbeat publish message */ #define DI_CAN_NET_CALLBACK_HEARTBEAT_PUBLISH_ITEM { \ DI_CAN_CALLBACK_CANID( \ DI_CAN_MSGTYPE_NET, \ DI_CAN_TRANSFERTYPE_PUBLISH, \ DI_CAN_NET_DTYPE_HEARTBEAT \ ), \ di_can_net_cb_heartbeat_publish \ } /** Callback item for net node error publish message */ #define DI_CAN_NET_CALLBACK_NODE_ERROR_PUBLISH_ITEM { \ DI_CAN_CALLBACK_CANID( \ DI_CAN_MSGTYPE_NET, \ DI_CAN_TRANSFERTYPE_PUBLISH, \ DI_CAN_NET_DTYPE_NODE_ERROR \ ), \ di_can_net_cb_node_error_publish \ } void di_can_net_cb_heartbeat_publish(const struct di_can_msg *msg, struct di_can_ctx *ctx); void di_can_net_cb_node_error_publish(const struct di_can_msg *msg, struct di_can_ctx *ctx); #ifdef __cplusplus } #endif #endif /* LIBDI_INCLUDE_DI_CAN_NET_CALLBACKS_H_ */