#include "states.h"
#include "lifegrd.h"
#include "sync.h"
+#include "nmtSlave.h"
#include "nmtMaster.h"
#include "emcy.h"
#ifdef CO_ENABLE_LSS
#include "lss.h"
#endif
-/* This structurs contains all necessary information for a CanOpen node */
+/**
+ * @ingroup od
+ * @brief This structure contains all necessary information for a CanOpen node
+ */
struct struct_CO_Data {
/* Object dictionary */
UNS8 *bDeviceNodeId;
const indextable *objdict;
s_PDO_status *PDO_status;
- quick_index *firstIndex;
- quick_index *lastIndex;
- UNS16 *ObjdictSize;
+ const quick_index *firstIndex;
+ const quick_index *lastIndex;
+ const UNS16 *ObjdictSize;
const UNS8 *iam_a_slave;
valueRangeTest_t valueRangeTest;
preOperational_t preOperational;
operational_t operational;
stopped_t stopped;
-
+ void (*NMT_Slave_Node_Reset_Callback)(CO_Data*);
+ void (*NMT_Slave_Communications_Reset_Callback)(CO_Data*);
+
/* NMT-heartbeat */
UNS8 *ConsumerHeartbeatCount;
UNS32 *ConsumerHeartbeatEntries;
/* General */
UNS8 toggle;
- CAN_HANDLE canHandle;
+ CAN_PORT canHandle;
scanIndexOD_t scanIndexOD;
storeODSubIndex_t storeODSubIndex;
/* LSS */
lss_transfer_t lss_transfer;
lss_StoreConfiguration_t lss_StoreConfiguration;
- lss_ChangeBaudRate_t lss_ChangeBaudRate;
#endif
};
0, /* LSSNext */\
0, /* LSSPos */\
LSS_FS_RESET, /* FastScan_SM */\
- -1 /* timerFS */
+ -1, /* timerFS */\
+ {{0,0,0,0},{0,0,0,0}} /* lss_fs_transfer */
#else
#define lss_fs_Initializer
#endif
0 /* LSSanswer */\
lss_fs_Initializer /*FastScan service initialization */\
},\
- NULL, /* _lss_StoreConfiguration*/\
- NULL /* _lss_ChangeBaudRate */
+ NULL /* _lss_StoreConfiguration*/
#else
#define lss_Initializer
#endif
_preOperational, /* preOperational */\
_operational, /* operational */\
_stopped, /* stopped */\
+ NULL, /* NMT node reset callback */\
+ NULL, /* NMT communications reset callback */\
\
/* NMT-heartbeat */\
& NODE_PREFIX ## _highestSubIndex_obj1016, /* ConsumerHeartbeatCount */\