Function block calls

Function blocks do not return a value.

Example

Description

Ton1( IN:= bStart1,     PT:=T#300ms ,
    Q=> bEnd1 ,
    ET=> tEv1 );

Function block arguments with formal parameters

  • For arguments with formal parameters, the order of parameters does not matter.
Ton1(bStart1,
    T#300ms,
    bEnd1,
    tEv1);

Function block arguments without formal parameters

  • For arguments without formal parameters, the order of parameters is important.

Ton1.IN:=bStart1;
Ton1.PT:=T#300ms;
Ton1();
IF Ton1.Q THEN 
    ....
END_IF;

Assignments to inputs or from outputs separate from the call.

Modified on: 2019-01-26Feedback on this pagePanasonic hotline