plugger.py
changeset 288 7ee96191c476
parent 286 a2a8a52b0d4f
child 290 3bd617ae7a05
equal deleted inserted replaced
287:5b3083695c8c 288:7ee96191c476
  1103 
  1103 
  1104         python_eval_fb_list = []
  1104         python_eval_fb_list = []
  1105         for v in self._VariablesList :
  1105         for v in self._VariablesList :
  1106             if v["vartype"] == "FB" and v["type"] == "PYTHON_EVAL":
  1106             if v["vartype"] == "FB" and v["type"] == "PYTHON_EVAL":
  1107                 python_eval_fb_list.append(v)
  1107                 python_eval_fb_list.append(v)
  1108         python_eval_fb_count = len(python_eval_fb_list)
  1108         python_eval_fb_count = max(1, len(python_eval_fb_list))
  1109         
  1109         
  1110         # prepare debug code
  1110         # prepare debug code
  1111         python_code = targets.code("plc_python") % {
  1111         python_code = targets.code("plc_python") % {
  1112            "python_eval_fb_count": python_eval_fb_count}
  1112            "python_eval_fb_count": python_eval_fb_count}
  1113         return python_code
  1113         return python_code