Documentation

Access to inputs/outputs of inner blocks

If a user-defined function block contains other embedded function blocks, the inputs/outputs of these internal blocks may have to be accessed from the program.

This can be achieved by creating an input in the block definition, and assigning of this input to an input of the embedded block. However, for more complex schemas and/or large amount of embedded blocks this approach would not be very efficient. Therefore each input/output contains the Publish attribute. This function works over more levels of embedding.

So of there is a user block "A" in which a function block "B" is used, then at the inputs/output of the "B" block the Publish attribute may be activated.

After the attribute is checked, the Visible property is set to On automatically. The input/output becomes visible in the FUPLA editor and will be coloured as dark green. 

Such input shall not be connected to a line anymore. If a line is connected to it, the Publish attribute is disabled automatically.

The property "Publish an input / output" may be compared to automatic creation of an input / output in the "A" block, and drawing a line to the input / output of the "B" block.  

Such input/output is then visible and accessible from the higher level of the blocks hierarchy. If the "A" block is used in a program or another function block, the inputs/outputs marked as Publish are available among the "A" block inputs/outputs, and can be accessed in the same way as any other block "A" input/output.