02.09.2014 Views

ISPSoft User Manual

ISPSoft User Manual

ISPSoft User Manual

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

Chapter 7 Function Block<br />

In view of this, the concept related to function block instances is introduced into IEC 61131-3.<br />

After users add a POU of the function block type, declare local symbols in the POU, and write a<br />

program in the POU, they will get a function block definition. The function block definition is like a<br />

document. It does not participate in any operation, and does not appropriate any resources that the<br />

PLC uses.<br />

If a POU of the program type wants to call this function block, the users must declare a symbol<br />

whose data type is a function block in advance. In other words, the users have to produce an object<br />

which takes part in an operation according to the function block definition. The object produced is a<br />

function block instance.<br />

When the program is compiled, the system assigns a substantial memory block to the function block<br />

instance and the local symbols in the function block instance according to the definition.<br />

If the same operation is required, and a different memory block is also required, users can make use<br />

of the characteristic of a function block instance. After a different symbol is declared for a function<br />

block which requires a different memory block, the system will regard the different symbol as a<br />

different function block instance. When the program is compiled, a different memory block is<br />

assigned to the different function block instance.<br />

7-13

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!