SimonGoldsworthy
Member
As with most things, the more you look, the more you find out. The restriction for output variables from FC's is that if a completely addressed data operand is assigned to an output, the output must be evaluated in the FC.
This means that outputs Q0.0 etc, DBX0.0 etc will work (as they are completely defined by the area pointer) if you use the set/reset logic in the FC.
It also means that an output assigned DB1.DBX0.0 will not work if you use the set/reset logic.
If you are prepared to accept that you will never assign an address of the type DB1.DBX0.0 to an output, you could carry on using the set/reset logic inside an FC. My advice would be to make the FC usable for all operands and make the variables IN_OUT if you want to use set/reset logic.
This means that outputs Q0.0 etc, DBX0.0 etc will work (as they are completely defined by the area pointer) if you use the set/reset logic in the FC.
It also means that an output assigned DB1.DBX0.0 will not work if you use the set/reset logic.
If you are prepared to accept that you will never assign an address of the type DB1.DBX0.0 to an output, you could carry on using the set/reset logic inside an FC. My advice would be to make the FC usable for all operands and make the variables IN_OUT if you want to use set/reset logic.