equal
deleted
inserted
replaced
23 /* One slave node post_sync callback. |
23 /* One slave node post_sync callback. |
24 * Used to align PLC tick-time on CANopen SYNC |
24 * Used to align PLC tick-time on CANopen SYNC |
25 */ |
25 */ |
26 %(post_sync)s |
26 %(post_sync)s |
27 |
27 |
|
28 /* Triggers DCF transission |
|
29 */ |
|
30 %(pre_op)s |
|
31 |
28 #define NODE_FORCE_SYNC(nodename) \ |
32 #define NODE_FORCE_SYNC(nodename) \ |
29 /* Artificially force sync state to 1 so that it is not started */\ |
33 /* Artificially force sync state to 1 so that it is not started */\ |
30 nodename##_Data.CurrentCommunicationState.csSYNC = -1;\ |
34 nodename##_Data.CurrentCommunicationState.csSYNC = -1;\ |
31 /* Force sync period to common_ticktime__ so that other node can read it*/\ |
35 /* Force sync period to common_ticktime__ so that other node can read it*/\ |
32 *nodename##_Data.COB_ID_Sync = 0x40000080;\ |
36 *nodename##_Data.COB_ID_Sync = 0x40000080;\ |
47 |
51 |
48 void InitNodes(CO_Data* d, UNS32 id) |
52 void InitNodes(CO_Data* d, UNS32 id) |
49 { |
53 { |
50 %(slavebootup_register)s |
54 %(slavebootup_register)s |
51 %(post_sync_register)s |
55 %(post_sync_register)s |
|
56 %(pre_op_register)s |
52 %(nodes_init)s |
57 %(nodes_init)s |
53 } |
58 } |
54 |
59 |
55 #define NODE_STOP(nodename) \ |
60 #define NODE_STOP(nodename) \ |
56 if(init_level-- > 0)\ |
61 if(init_level-- > 0)\ |