tests/ethercat/wago_higen/beremiz.xml
author Andrey Skvortsov <andrej.skvortzov@gmail.com>
Wed, 01 Aug 2018 13:09:45 +0300
changeset 2258 c9915bc620cd
parent 2165 02a2b5dee5e3
permissions -rw-r--r--
Fix wrong code generation if EN/ENO are used in FBD/LD/SFC

This problem appears for example here

--------
------- | MOVE |
| MOVE1 |------|EN ENO|
------- | |
| |
------- | | -----------
| 23 |------|IN OUT|---| LocalVar0 |
------- -------- -----------


--------
------- | MOVE |
| MOVE2 |------|EN ENO|
------- | |
| |
------- | | -----------
| 15 |------|IN OUT|---| LocalVar0 |
------- -------- -----------

Before wrong code was generated for this case:

MOVE6_OUT := MOVE(EN := move1, IN := 23, ENO => MOVE6_ENO);
LocalVar0 := MOVE6_OUT;
MOVE4_OUT := MOVE(EN := move2, IN := 15, ENO => MOVE4_ENO);
LocalVar0 := MOVE4_OUT;

With this patch now following code is generated:

MOVE6_OUT := MOVE(EN := move1, IN := 23, ENO => MOVE6_ENO);
IF MOVE6_ENO THEN
LocalVar0 := MOVE6_OUT;
END_IF;
MOVE4_OUT := MOVE(EN := move2, IN := 15, ENO => MOVE4_ENO);
IF MOVE4_ENO THEN
LocalVar0 := MOVE4_OUT;
END_IF;


See discussion here:
https://sourceforge.net/p/beremiz/mailman/message/36378805/
2050
6da739ac1346 Fixed example build with installer 1.1
Edouard Tisserant
parents: 2047
diff changeset
     1
<?xml version="1.0" encoding="UTF-8"?>
6da739ac1346 Fixed example build with installer 1.1
Edouard Tisserant
parents: 2047
diff changeset
     2
<BeremizRoot>
2087
8421bd1f8b06 Updating ethercat example for higen drive adding an example of Ethercat SDO upload block usage
Laurent Bessard
parents: 2050
diff changeset
     3
  <TargetType/>
2050
6da739ac1346 Fixed example build with installer 1.1
Edouard Tisserant
parents: 2047
diff changeset
     4
</BeremizRoot>