Merged
authorEdouard Tisserant
Fri, 19 Jun 2015 22:36:35 +0200
changeset 1467 68ba08b3a152
parent 1466 805826ba48c5 (current diff)
parent 1463 de311ffe3961 (diff)
child 1468 7df108e8cb18
Merged
--- a/runtime/PLCObject.py	Fri Jun 19 21:56:35 2015 +0200
+++ b/runtime/PLCObject.py	Fri Jun 19 22:36:35 2015 +0200
@@ -142,9 +142,9 @@
             self._PLClibraryHandle = dlopen(self._GetLibFileName())
             self.PLClibraryHandle = ctypes.CDLL(self.CurrentPLCFilename, handle=self._PLClibraryHandle)
 
-            self.PLCID = ctypes.c_char_p.in_dll(self.PLClibraryHandle, "PLCID")
+            self.PLC_ID = ctypes.c_char_p.in_dll(self.PLClibraryHandle, "PLC_ID")
             if len(md5) == 32 : 
-                self.PLCID.value = md5 
+                self.PLC_ID.value = md5 
 
             self._startPLC = self.PLClibraryHandle.startPLC
             self._startPLC.restype = ctypes.c_int
--- a/targets/plc_main_head.c	Fri Jun 19 21:56:35 2015 +0200
+++ b/targets/plc_main_head.c	Fri Jun 19 22:36:35 2015 +0200
@@ -25,7 +25,7 @@
 IEC_TIME __CURRENT_TIME;
 IEC_BOOL __DEBUG = 0;
 unsigned long __tick = 0;
-char *PLCID = NULL;
+char *PLC_ID = NULL;
 
 /*
  *  Variable generated by C softPLC and plugins
--- a/tests/python/c_code@c_ext/cfile.xml	Fri Jun 19 21:56:35 2015 +0200
+++ b/tests/python/c_code@c_ext/cfile.xml	Fri Jun 19 22:36:35 2015 +0200
@@ -14,7 +14,7 @@
 volatile char PtoC=1,CtoP=2;
 
 extern long AtomicCompareExchange(long*,long, long);
-extern char *PLCID;
+extern char *PLC_ID;
 
 int Simple_C_Call(int val){
   return val+1;
@@ -35,7 +35,7 @@
     res=1;
   }
   printf("C code called by Python: toC %d fromC %d\n",toC,*fromC);
-  printf("PLCID id %s\n",PLCID);
+  printf("PLC_ID id %s\n",PLC_ID);
   return res;
 }