Propagated matiec changes in FB var accessors
authorEdouard Tisserant
Mon, 11 Aug 2014 23:13:35 +0200
changeset 2164 7a959b19d5a4
parent 2163 6ea6d83e7280
child 2165 02a2b5dee5e3
Propagated matiec changes in FB var accessors
etherlab/EthercatCIA402Slave.py
etherlab/pous.xml
--- a/etherlab/EthercatCIA402Slave.py	Wed Apr 02 21:22:35 2014 +0200
+++ b/etherlab/EthercatCIA402Slave.py	Mon Aug 11 23:13:35 2014 +0200
@@ -207,7 +207,7 @@
             blockname = "_".join([ucase_blocktype, location_str])
             
             extract_inputs = "\n".join(["""\
-    __SET_VAR(%s->, %s, %s);""" % (blockname, input_name, input_value)
+    __SET_VAR(%s->, %s,, %s);""" % (blockname, input_name, input_value)
                 for (input_name, input_value) in [
                     ("EXECUTE", "__GET_VAR(data__->EXECUTE)")] + [
                     (input["name"].upper(), 
@@ -217,7 +217,7 @@
             
             
             return_outputs = "\n".join(["""\
-    __SET_VAR(data__->,%(output_name)s, 
+    __SET_VAR(data__->,%(output_name)s,, 
               __GET_VAR(%(blockname)s->%(output_name)s));""" % locals()
                     for output_name in ["DONE", "BUSY", "ERROR"] + [
                         output["name"].upper()
@@ -229,7 +229,7 @@
 void __%(blocktype)s_%(location_str)s(MC_%(ucase_blocktype)s *data__) {
 __DECLARE_GLOBAL_PROTOTYPE(ETHERLAB%(ucase_blocktype)s, %(blockname)s);
 ETHERLAB%(ucase_blocktype)s* %(blockname)s = __GET_GLOBAL_%(blockname)s();
-__SET_VAR(%(blockname)s->, POS, AxsPub.axis->NetworkPosition);
+__SET_VAR(%(blockname)s->, POS,, AxsPub.axis->NetworkPosition);
 %(extract_inputs)s
 ETHERLAB%(ucase_blocktype)s_body__(%(blockname)s);
 %(return_outputs)s
--- a/etherlab/pous.xml	Wed Apr 02 21:22:35 2014 +0200
+++ b/etherlab/pous.xml	Mon Aug 11 23:13:35 2014 +0200
@@ -110,13 +110,13 @@
       VALUE := 'None';
     END_IF;
   1:
-    {if (AcquireSDOLock()) __SET_VAR(data__->,STATE, 2)}
+    {if (AcquireSDOLock()) __SET_VAR(data__->,STATE,, 2)}
   2:
     IF PY0.ACK THEN
       STATE := 3;
     END_IF;
   3:
-    {if (HasAnswer()) __SET_VAR(data__->,STATE, 4)}
+    {if (HasAnswer()) __SET_VAR(data__->,STATE,, 4)}
   4:
     IF PY1.ACK THEN
       ACK := 1;
@@ -231,13 +231,13 @@
       ERROR := 0;
     END_IF;
   1:
-    {if (AcquireSDOLock()) __SET_VAR(data__->,STATE, 2)}
+    {if (AcquireSDOLock()) __SET_VAR(data__->,STATE,, 2)}
   2:
     IF PY0.ACK THEN
       STATE := 3;
     END_IF;
   3:
-    {if (HasAnswer()) __SET_VAR(data__->,STATE, 4)}
+    {if (HasAnswer()) __SET_VAR(data__->,STATE,, 4)}
   4:
     IF PY1.ACK THEN
       ACK := 1;