# HG changeset patch # User Laurent Bessard # Date 1365669178 -7200 # Node ID 8e6e6364087e500d729b56cafec0f354b0ccd6fe # Parent 5460eba6c5e0bb733290acbe4d9b77042d4f4bd3# Parent accc4cbca8d306c2eaf330e06169a0121a67e37b Merged diff -r accc4cbca8d3 -r 8e6e6364087e ethercat_tests/wago_higen/ethercat@etherlab/master@EthercatNode/config.xml --- a/ethercat_tests/wago_higen/ethercat@etherlab/master@EthercatNode/config.xml Fri Apr 05 21:47:37 2013 +0900 +++ b/ethercat_tests/wago_higen/ethercat@etherlab/master@EthercatNode/config.xml Thu Apr 11 10:32:58 2013 +0200 @@ -19,6 +19,19 @@ 65536 0 + + + 0 + 0 + + + 0 + 0 + + + + + @@ -31,6 +44,19 @@ 1048576 0 + + + 0 + 0 + + + 0 + 0 + + + + + @@ -55,6 +81,47 @@ 2 0 + + + 0 + 0 + + + 0 + 0 + + + + + II + Configure limit switches signal + 0 + 0 + 8229 + 0 + 07 + + + II + + 0 + 0 + 24800 + 0 + 05DC + + + II + + 0 + 0 + 24801 + 0 + 05DC + + + + diff -r accc4cbca8d3 -r 8e6e6364087e ethercat_tests/wago_higen/ethercat@etherlab/master@EthercatNode/process_variables.xml --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/ethercat_tests/wago_higen/ethercat@etherlab/master@EthercatNode/process_variables.xml Thu Apr 11 10:32:58 2013 +0200 @@ -0,0 +1,7 @@ + + + + + + + diff -r accc4cbca8d3 -r 8e6e6364087e ethercat_tests/wago_higen/ethercat@etherlab/modules/Higen_EDA7000_CoE_ver16_with_variablePDO_modif.xml --- a/ethercat_tests/wago_higen/ethercat@etherlab/modules/Higen_EDA7000_CoE_ver16_with_variablePDO_modif.xml Fri Apr 05 21:47:37 2013 +0900 +++ b/ethercat_tests/wago_higen/ethercat@etherlab/modules/Higen_EDA7000_CoE_ver16_with_variablePDO_modif.xml Thu Apr 11 10:32:58 2013 +0200 @@ -3061,15 +3061,7 @@ - - - PS - #x2025 - 0 - 0004 - Digital Inputs Reverse Setting ([2]ESTOP, [1]CW, [0]CCW) - - + diff -r accc4cbca8d3 -r 8e6e6364087e etherlab/EthercatCIA402Slave.py --- a/etherlab/EthercatCIA402Slave.py Fri Apr 05 21:47:37 2013 +0900 +++ b/etherlab/EthercatCIA402Slave.py Thu Apr 11 10:32:58 2013 +0200 @@ -51,8 +51,7 @@ } """ -BLOCK_FUNTION_DEFINITION_TEMPLATE = """ if (!__CIA402Node_%(location)s.axis->__mcl_func_MC_%(blocktype)s) -__CIA402Node_%(location)s.axis->__mcl_func_MC_%(blocktype)s = __%(blocktype)s_%(location)s;""" +BLOCK_FUNTION_DEFINITION_TEMPLATE = " __CIA402Node_%(location)s.axis->__mcl_func_MC_%(blocktype)s = __%(blocktype)s_%(location)s;" GLOBAL_INSTANCES = [ {"blocktype": "GetTorqueLimit", diff -r accc4cbca8d3 -r 8e6e6364087e etherlab/plc_cia402node.c --- a/etherlab/plc_cia402node.c Fri Apr 05 21:47:37 2013 +0900 +++ b/etherlab/plc_cia402node.c Thu Apr 11 10:32:58 2013 +0200 @@ -55,10 +55,8 @@ int __init_%(location)s() { + __FirstTick = 1; %(init_entry_variables)s - *__IW%(location)s_0 = __MK_Alloc_AXIS_REF(); - __CIA402Node_%(location)s.axis = __MK_GetPublic_AXIS_REF(*__IW%(location)s_0); - __CIA402Node_%(location)s.axis->NetworkPosition = %(slave_pos)d; *(__CIA402Node_%(location)s.ModesOfOperation) = 0x08; return 0; } @@ -69,13 +67,15 @@ void __retrieve_%(location)s() { -%(fieldbus_interface_definition)s - IEC_UINT statusword_inactive = *(__CIA402Node_%(location)s.StatusWord) & __InactiveMask; IEC_UINT statusword_active = *(__CIA402Node_%(location)s.StatusWord) & __ActiveMask; if (__FirstTick) { + *__IW%(location)s_0 = __MK_Alloc_AXIS_REF(); + __CIA402Node_%(location)s.axis = __MK_GetPublic_AXIS_REF(*__IW%(location)s_0); + __CIA402Node_%(location)s.axis->NetworkPosition = %(slave_pos)d; %(init_axis_params)s +%(fieldbus_interface_definition)s __FirstTick = 0; }