TF85xx TC3 Plastic Application EN
TF85xx TC3 Plastic Application EN
TF85xx
TwinCAT 3 | Plastic Application
Table of contents
1 Foreword .................................................................................................................................................... 7
1.1 Notes on the documentation ............................................................................................................. 7
1.2 For your safety .................................................................................................................................. 7
1.3 Notes on information security............................................................................................................ 9
2 Introduction ............................................................................................................................................. 10
5.5.4 FB_TemperatureGroupHmi.............................................................................................. 85
5.5.5 FB_TempChannelBase.................................................................................................... 87
5.5.6 FB_TempChannel ............................................................................................................ 88
5.5.7 FB_TempChannelHmi...................................................................................................... 89
5.5.8 FB_TempSupply .............................................................................................................. 90
5.5.9 FB_TempSupplyLine........................................................................................................ 90
5.5.10 FB_TempSchedule .......................................................................................................... 91
5.5.11 FB_TempScheduleHmi .................................................................................................... 92
5.5.12 FB_TimerTempHmi.......................................................................................................... 92
5.5.13 T_SHA256........................................................................................................................ 94
5.6 Recipe - recipe management .......................................................................................................... 94
5.6.1 FB_PlcStateToHmi........................................................................................................... 94
5.6.2 I_RecipeState................................................................................................................... 96
5.6.3 FB_Recipe ....................................................................................................................... 96
5.6.4 FB_TempRecipe .............................................................................................................. 98
5.6.5 FB_MoveClusterRecipe ................................................................................................... 99
5.7 MachineData - Machine data ........................................................................................................ 102
5.7.1 FB_MdBaseContainer.................................................................................................... 104
5.7.2 FB_MdBaseComponent................................................................................................. 106
5.7.3 FB_MdCollection............................................................................................................ 106
5.8 OperationData - Production data and statistics............................................................................. 107
5.8.1 FB_ProductionCounter................................................................................................... 107
5.8.2 FB_EnergyMeasurement ............................................................................................... 110
5.9 Alarms - Handling of the Tc3_EventLogger .................................................................................. 116
5.9.1 FB_AlarmHandler........................................................................................................... 116
5.9.2 FB_AppMessage............................................................................................................ 117
5.10 Logging - Recording user input ..................................................................................................... 117
5.10.1 CSV................................................................................................................................ 117
5.10.2 UserLogging................................................................................................................... 125
5.11 Analog - analog value scaling ....................................................................................................... 129
5.11.1 FB_ScaleAnalogHmi ...................................................................................................... 129
5.11.2 FB_Monitoring................................................................................................................ 130
5.11.3 FB_Setpoints.................................................................................................................. 132
5.12 Time - Time-related functions ....................................................................................................... 133
5.12.1 FB_TimerHmi ................................................................................................................. 133
5.12.2 FB_TimerTon ................................................................................................................. 134
5.12.3 FB_TimerTof .................................................................................................................. 134
5.12.4 FB_TimerTp ................................................................................................................... 135
5.12.5 FB_TimerWeekdayHmi .................................................................................................. 136
5.12.6 FB_TimerWeekdayMaster ............................................................................................. 137
5.12.7 FB_Time......................................................................................................................... 138
5.12.8 F_GetLocalSystemtime.................................................................................................. 139
5.12.9 F_GetLocalSystemtimeEx.............................................................................................. 139
5.12.10 F_SecondsToTime() ...................................................................................................... 140
5.12.11 F_TimeToSeconds() ...................................................................................................... 140
5.13 BlowMolding - Blow molding specific classes ............................................................................... 141
1 Foreword
The responsible staff must ensure that the application or use of the products described satisfies all
requirements for safety, including all the relevant laws, regulations, guidelines, and standards.
Disclaimer
The documentation has been prepared with care. The products described are, however, constantly under
development.
We reserve the right to revise and change the documentation at any time and without notice.
No claims to modify products that have already been supplied may be made on the basis of the data,
diagrams, and descriptions in this documentation.
Trademarks
Beckhoff®, TwinCAT®, TwinCAT/BSD®, TC/BSD®, EtherCAT®, EtherCAT G®, EtherCAT G10®, EtherCAT P®,
Safety over EtherCAT®, TwinSAFE®, XFC®, XTS® and XPlanar® are registered and licensed trademarks of
Beckhoff Automation GmbH.
If third parties make use of designations or trademarks used in this publication for their own purposes, this
could infringe upon the rights of the owners of the said designations.
Patents
The EtherCAT Technology is covered, including but not limited to the following patent applications and
patents:
EP1590927, EP1789857, EP1456722, EP2137893, DE102015105702
and similar applications and registrations in several other countries.
EtherCAT® is registered trademark and patented technology, licensed by Beckhoff Automation GmbH,
Germany
Copyright
Exclusion of liability
All the components are supplied in particular hardware and software configurations which are appropriate for
the application. Modifications to hardware or software configurations other than those described in the
documentation are not permitted, and nullify the liability of Beckhoff Automation GmbH & Co. KG.
Personnel qualification
This description is only intended for trained specialists in control, automation, and drive technology who are
familiar with the applicable national standards.
Signal words
The signal words used in the documentation are classified below. In order to prevent injury and damage to
persons and property, read and follow the safety and warning notices.
DANGER
Hazard with high risk of death or serious injury.
WARNING
Hazard with medium risk of death or serious injury.
CAUTION
There is a low-risk hazard that could result in medium or minor injury.
NOTICE
The environment, equipment, or data may be damaged.
In addition, the recommendations from Beckhoff regarding appropriate protective measures should be
observed. Further information regarding information security and industrial security can be found in our
https://www.beckhoff.com/secguide.
Beckhoff products and solutions undergo continuous further development. This also applies to security
functions. In light of this continuous further development, Beckhoff expressly recommends that the products
are kept up to date at all times and that updates are installed for the products once they have been made
available. Using outdated or unsupported product versions can increase the risk of cyber threats.
To stay informed about information security for Beckhoff products, subscribe to the RSS feed at https://
www.beckhoff.com/secinfo.
2 Introduction
The TwinCAT 3 Plastic Application represents the third implementation level of the industry solution for
plastics machines from Beckhoff Automation. In this level, the technology-specific functions of the
TwinCAT 3 Plastic Framework (second level) are implemented in production-specific execution.
In the TwinCAT 3 Plastic Application, precisely these production part processes are implemented and
preconfigured as examples. The source code for the Plastic Application is provided free of charge, which
makes it possible to edit and extend the solution in any way. Therefore, the Base Application is ideal as a
basis for starting a new project.
Concrete structure
In addition to the vertical division into Sample Code and Plastic Base Application, the project can also be
differentiated horizontally: PLC and HMI.
For the horizontal division, there are two projects on the PLC side, which implement the functions of the
Plastic Application in a coordinated manner.
In the vertical distinction, both projects are divided into a general part (Plastic Base Application) and a
machine-specific part (Type specific PLC project). This division ensures that even after the start of a project,
the further development of the Plastic Application can be benefited from.
Dependencies:
As an example of the concept, the wall thickness control (WTC) can be considered here:
This component of a blow molding machine is fundamentally based on the cam core function provided by
TF8560 (Camming). For the user, this is often of secondary importance, since he wants to integrate the
functions based on it, such as Start wall thickness profile or Move to test position, into his procedure.
This step is pre-implemented by the Plastic Base Application so that the scope of tasks to be completed to
the finished machine is minimized as much as possible.
Other concept points are discussed in more detail in the following subsections:
Topic Description
PLC and HMI [} 13] Communication path between PLC and HMI
Inheritance [} 14] Use of inheritance for more efficient use of redundant code and easier function
extension
Interfaces [} 14] Structure of interface in Plastic Base Application and programming with
interfaces to extend control flexibility
Initialization & Cycle Initialization of references, parameters and data
Methods [} 15]
Data handling [} 16] Data handling at machine and product level
Project structure [} 18] Explanation of the TwinCAT project
The concept is for each class with information exchange to be given a second class, which assumes
precisely this function. This results in the parallel-class model. In addition to the main class (FB_Xyz), there
is a parallel class of type FB_XyzHmi for each added class. The parallel class is linked to the main class via
an interface. In the instantiation, the instance of the parallel class must be passed to the instance of the main
class for this purpose. Depending on the use case, the main class of the parallel class can also be passed in
this step.
This arrangement results in a division of control data and user input/display values. In addition, controls from
the T8550 Plastic TC HMI Controls are implicitly supported, greatly improving the integrity of the project. In
the same way, recipe management can be optimally linked to and used with the PLC.
The consistent use of inheritance for changes to the machine controller also enables updates to the Plastic
Base Application to be applied directly by Beckhoff Automation.
In Plastic Application, there are a total of four cases where an inheriting class (EXTENDS) can extend, modify
or remove the inherited class:
• Runtime memory in the class variable declaration
◦ Extension possible with EXTENDS
• Add, overwrite and extend properties or methods
◦ Extension possible with SUPER^. call
• Extend, modify and disable inner procedures
◦ Extension possible with FB_AdaptableSequence [} 157]
• Extend and modify HMI parallel class
◦ Extending the interface and the parallel class with EXTENDS possible
For many practical use cases in programming, access via an interface turns out to be much clearer. For
example, methods for internal communication between two classes as well as other properties are not
visible.
When extending a class using inheritance (see section Inheritance [} 14]), it is also possible to extend the
corresponding standard interface. This can be accomplished in a comparable way to inheriting a class with
the keyword EXTENDS.
The access of invalid reference values mainly concerns the call of cycle methods of a Plastic Base
Application object. For this reason, an object must have been successfully initialized before the cycle method
may be executed.
SetHMI() method
By means of the SetHMI() method an HMI parallel class can be passed to the main class. The method must
always be executed before the Init() method, unless the class also works without HMI parallel class.
Init() method
The Init() method is used to check the initialization state in addition to setting and configuring reference value
assignments. Accordingly, when initializing an object, the HRESULT return value of the method must be
checked. If the execution of the Init() method is unsuccessful, an error exists in the structure of the program
codes. This error must be solved on code level.
Cyclic() method
The Cyclic() cycle method acts as an object-oriented version of a class instance call. I.e., the method is
usually called once per cycle to process procedures and/or updates. The routines implemented in the
Cyclic() method are mostly medium priority mechanisms. Therefore, this method is suitable for the
implementation of a predefined command sequence or the processing of control commands from the HMI
(e.g. the implementation of manual functions).
ParamInit() method
The ParamInit() method is used to initialize parameters. I.e., in this method, hardcoded default values are
defined with which commissioning is started without preconfigured machine data. Since asynchronous
communication may also be required in this method, execution may continue over several cycles until the
HRESULT return value signals the success of the operation. It is recommended to add a timeout to detect a
failure of the execution.
CoreCyclic() method
The special modification of a Cyclic() method as CoreCyclic() can be found again with individual classes
such as FB_Axis. This method handles particularly real-time critical tasks such as calling the cycle method of
a TF8560 axis. Since such an axis also contains control algorithms, it is recommended to choose the cycle
time as small as possible (standard 2 ms).
Essentially, the Plastic Base Application implements three levels for loading parameters and other data.
These levels are executed one after the other during the start-up phase and can partly be executed again
after the start.
After successful execution of the Init() method, the default parameters defined in the code are loaded.
Therefore, this level is considered to be the foundation, but can be overwritten by any subsequent instance.
Machine data includes data that is set only once during the construction, commissioning or modification of
the machine. Since this data can influence the machine behavior, the file is stored in binary format and
roughly secured against external manipulation by a CRC checksum. The management of the machine data
is completely handled by the PLC, but can be set and/or loaded/saved through the HMI.
The implemented machine data handling is based on the TF8560 utilities. The PLC code part is split into two
classes: containers and components.
Containers are integrated into many objects of the Plastic Base Application and serve as a collection object
for the data of a file. A class that contains machine data either has its own container or has a component that
can be added to a container. The classes with their own container inherit from the class FB_BaseMd and
provide an interface to it. In the inheritance structure, multiple components (per inheritance level) are added
to the container. This also allows the scope of the machine data to be further expanded in the end
application.
Since the indices of the parameters must not be chosen arbitrarily for this purpose, the parameters are
stored in the Plastic Base Application according to a defined scheme. This also ensures that the parameters
can be prepared outside the controller in a program that will be provided in the future.
The parameters to be regularly reset for the variation of the production process are summarized under the
recipe data. This includes, for example, the set temperatures of the temperature zones, timings, production
speeds, etc... The recipe data is managed collectively by the HMI and can be expanded as required in
engineering. For more detailed information on recipe management, please refer to the chapter Recipe
management [} 229].
Licenses may be excluded from the project under the following conditions:
NOTICE
Correct cycle time for temperature control
The cycle time of the temperature control should be asynchronous to the frequency of the AC supply
voltage. A synchronous cycle time promotes instability of the control!
The PLC tasks can be split according to the number of cores and the single core performance of the CPU.
For development systems, the project configuration can be adopted; for end devices, the following
configurations have been tested in the field:
The Type System contains the used EventClasses. These EventClasses contain the respective events that
are used in the Plastic Application.
Motion
All exemplarily implemented NC axes (electrical) are created in the NC task. The designations of the axes
are based on the manufacturing significance.
The currently used version of the project can be determined in two ways:
• PLC > PLC > PLC Project > Properties (right click) > Common > Version:
• PLC > PLC > PLC Project > Version > Global_Version
The following libraries are installed in the project in addition to some general libraries from the general
TwinCAT pool:
• Tc2_PfwLib_Processing
◦ Temperature control algorithms
• Tc3_PlasticBaseApplication
◦ Collection of application-oriented classes, explained in this documentation
• Tc3_PlasticFunctions
◦ Abstracted axis interface, actuators and other technology functions
• Tc3_PlasticHydraulic
◦ Hydraulic axes compatible with virtual axis interface
• Tc3_PlasticNc
◦ Electric NC-based axes compatible with the virtual axis interface
NOTICE
Adaptation to an older version not permitted
Do not change the library versions set in the project to an older version. Incompatibilities and unpredictable
behavior of the software may occur!
> _Tasks: Instantiation of the runtime and definition of the task calls
> Version: Automatically generated GVL with the used project version
In the second PLC (SimPlc) a machine simulation is implemented. This can be connected to the main control
via mapping (comparable to the I/O of a machine). This allows the PLC to be implemented without including
simulation elements. In addition, simulation can also be extended with the elements of PLC programming.
This offers the advantage that the control PLC from project preparation does not have to be adapted to
operation with a real machine. Only the mapping to I/O components is required.
The I/O part of the project includes the mapping of the operating elements of the BlowMolding Beckhoff
panel CP2219-1025-0030. The following figure shows how the FB_CP22xx_1025 [} 162] must be connected to
the I/O.
5.1.1 FB_Base
FB_Base is the base class for most of the available classes of the Plastic Base Application.
Internal functions:
• Standard Error and Reset
• Creation of an instance default name
• Provision of the event interface
Syntax:
FUNCTION_BLOCK FB_Base
Properties
Methods
Name Description
Reset() Resets the error state of the class.
FB_Base
SetHMI(ipBase) General assignment method for an FB_BaseHmi extending class.
Notice This method always fails in the FB_Base implementation.
Overwriting is therefore absolutely necessary.
[PROTECTED] Extracts the first part of the instance path as an object namespace.
_QueryNamespace()
[PROTECTED] Extracts the last part of the instance path as the object name.
_QueryObjectName()
Interfaces
Type Description
I_Base Standard interface on FB_Base.
Type Description
I_BaseEmpty For extension without standard interface.
I_BaseDev Covers all methods and properties of the base class.
Requirements
5.1.1.1 E_BaseState
Base State for the state of a Plastic Base Application object.
Syntax:
{attribute 'qualified_only'}
{attribute 'strict'}
TYPE E_BaseState :
(
eFailed := -9999, // Init routine failed
eReinit := -100, // Object has to be reinitialized
Values
Name Description
eFailed Init procedure failed.
eReinit Object must be re-initialized.
eNotHandled Object was not handled.
eInit FB_init was executed successfully.
eReady Init was executed successfully.
eIdle ParamInit was executed successfully.
eBusy Implementation-available busy flag.
eError Implementation-available error flag.
Requirements
5.1.2 FB_BaseHmi
FB_BaseHmi is the base class of all HMI parallel classes. The provided Init(ipBase) method predefines that
the parallel object is passed via the I_Base interface.
Syntax:
FUNCTION_BLOCK FB_BaseHmi EXTENDS FB_Base
Properties
Methods
Name Description
Reset() Resets the error state of the class.
FB_BaseHmi
Init(ipBase) Default initialization method to pass the base class.
Interfaces
Type Description
I_Base Standard interface on FB_Base.
I_BaseHmi Standard interface on FB_BaseHmi.
I_BaseEmpty For extension without standard interface.
I_BaseDev Covers all methods and properties of the base class.
Requirements
5.1.3 FB_BaseMd
Extends the base class FB_Base by the functions of the machine data handling. The structure of the
machine data is explained in more detail in the chapter Machine data [} 102].
Syntax:
FUNCTION_BLOCK FB_BaseMd EXTENDS FB_Base
Properties
Methods
Name Description
Reset() Resets the error state of the class.
FB_BaseMd
[PROTECTED] AddMdComp() Adds a component of type I_MdComponent to the machine data
container.
FB_Base
SetHMI(ipBase) General assignment method for an FB_BaseHmi extending class.
Notice This method always fails in the FB_Base implementation.
Overwriting is therefore absolutely necessary.
[PROTECTED] Extracts the first part of the instance path as an object namespace.
_QueryNamespace()
[PROTECTED] Extracts the last part of the instance path as the object name.
_QueryObjectName()
Cycle methods
Name Description
Cyclic() Cycle method - Call once per PLC cycle (default 10 ms)
Interfaces
Type Description
I_Base Standard interface on FB_Base.
I_BaseMd Standard interface on FB_BaseMd.
I_BaseEmpty For extension without standard interface.
I_BaseDev Covers all methods and properties of the base class.
Requirements
5.1.4 FB_BaseMdHmi
HMI class in parallel with the base machine data class FB_BaseMd. Is necessary for loading and saving the
machine data via the HMI.
Syntax:
FUNCTION_BLOCK FB_BaseMdHmi EXTENDS FB_BaseHmi
Properties
Methods
Name Description
Reset() Resets the error state of the class.
FB_BaseHmi
Init(ipBase) Default initialization method to pass the base class.
FB_Base
SetHMI(ipBase) General assignment method for an FB_BaseHmi extending class.
Notice This method always fails in the FB_Base implementation.
Overwriting is therefore absolutely necessary.
[PROTECTED] Extracts the first part of the instance path as an object namespace.
_QueryNamespace()
[PROTECTED] Extracts the last part of the instance path as the object name.
_QueryObjectName()
Interfaces
Type Description
I_Base Standard interface on FB_Base.
I_BaseMdHmi Standard interface on FB_BaseMdHmi.
I_BaseEmpty For extension without standard interface.
Type Description
I_BaseDev Covers all methods and properties of the base class.
Requirements
The FB_BaseRuntime [} 30] class of the Plastic Base Application is used to simplify cycle calls and
automated initialization of control objects. This greatly simplifies several steps such as creating, initializing,
checking return values, generating error messages, cyclic calls, etc.
Requirements
For an object to be attached to the runtime, one of the following interfaces must be implemented.
Interfaces
Name Description
I_RuntimeInterface General interface for an attachable control object.
I_OneTaskInterface Interface with an executable method.
I_TwoTaskInterface Interface with two executable methods.
I_TempTaskInterface Interface with a slow executable method.
5.2.1 FB_BaseRuntime
The class automates the initialization and cyclic calls of instantiated control objects such as axes, sequence
algorithms, temperature controllers, etc.
Internal functions:
• Initialization (Init(), ParamInit() and MdInit())
• Cycle calls (3-tasks)
• PlcMcManager support function (when using hydraulic axes)
• Software version check
Syntax:
FUNCTION_BLOCK FB_BaseRuntime EXTENDS FB_Base
Properties
Methods
Name Description
Append() [} 32] Appends a control object to the runtime.
Clear() Deletes the list of appended control objects.
MdLoadAll() Starts the loading process of all appended control objects with machine
data container.
MdSaveAll() Starts the saving process of all appended control objects with machine
data container.
SetParamInitTimeout(iObject, Changes the timeout of the ParamInit() function of an appended
fTimeout) control object.
Cycle methods
The cycle methods must be called with programs (PRG) assigned to different tasks, so that the runtime can
assign the appended objects to the individual tasks.
Possible events
ID Description Alarm/Message
1xx Recipe Message
10xx Initialization Alarm + Message
11xx Parameterization Alarm + Message
12xx Version incompatibility Alarm
20xx Machine data Alarm + Message
Interfaces
Type Description
I_BaseRuntime Standard interface on FB_BaseRuntime.
Requirements
5.2.1.1 Append()
Syntax:
METHOD Append : VOID
VAR_INPUT
iObj: I_RuntimeInterface;
iObjHmi: I_BaseHmi;
END_VAR
Inputs
Requirements
5.2.2 I_RuntimeInterface
Represents the general interface for a runtime-compatible control object.
Syntax:
INTERFACE I_RuntimeInterface
Methods
Name Description
Init() Method for checking the initialization of an object
ParamInit() Method for standard parameterization of an object
SetHMI(ipBaseHmi) Method for passing a parallel HMI object
All methods are checked by the FB_BaseRuntime class for the HRESULT return value.
Requirements
5.3.1 FB_Motion
Represents the standard class for all motion objects, based on TF8560 motion objects.
Syntax:
FUNCTION_BLOCK FB_Motion EXTENDS FB_BaseMd
Properties
Methods
Name Description
Reset() Resets the error state of the class.
FB_Motion
CheckAxisState() [} 34] Checks the current state of the axis.
FeedEnable(bFeedEnableP, Enable of a direction of movement.
bFeedEnableN)
JogNegative(bCommand) Starts/stops a jog movement in negative direction.
JogPositive(bCommand) Starts/stops a jog movement in positive direction.
Power(bCommand) Switching on the drive control.
SetMotionRef(iMotion) Assignment method for the TF8560 motion object.
FB_BaseMd
[PROTECTED] AddMdComp() Adds a component of type I_MdComponent to the machine data
container.
Name Description
FB_Base
SetHMI(ipBase) General assignment method for an FB_BaseHmi extending class.
Notice This method always fails in the FB_Base implementation.
Overwriting is therefore absolutely necessary.
[PROTECTED] Extracts the first part of the instance path as an object namespace.
_QueryNamespace()
[PROTECTED] Extracts the last part of the instance path as the object name.
_QueryObjectName()
Cycle methods
Name Description
Cyclic() Cycle method - Call once per PLC cycle (default 10 ms)
CoreCyclic() Cycle method with short cycle time (default: 2 ms).
Possible events
ID Description Alarm/Message
11 Object error state Alarm
21 Command rejected Alarm
Interfaces
Type Description
I_Base Standard interface on FB_Base.
I_Motion Standard interface on FB_Motion
I_TwoTaskInterface Runtime interface for two PLC tasks.
I_BaseMd Standard interface on FB_BaseMd.
I_BaseEmpty For extension without standard interface.
I_BaseDev Covers all methods and properties of the base class.
Requirements
5.3.1.1 CheckAxisState()
Syntax:
METHOD CheckAxisState : BOOL
VAR_INPUT
eState: BOOL;
bSendEvent: BOOL;
END_VAR
Inputs
Outputs
Possible events
ID Description Alarm/Message
1000 Axis is not in state ‘{0}’ Message
Requirements
5.3.1.2 FB_MotionSpecific
Syntax:
FUNCTION_BLOCK FB_MotionSpecific EXTENDS FB_Base
Properties
Interfaces
Type Description
I_MotionSpecific Standard interface on FB_MotionSpecific
Requirements
5.3.1.2.1 FB_ActuatorFunctions
Syntax:
FUNCTION_BLOCK FB_ActuatorFunctions EXTENDS FB_Base
Properties
Interfaces
Type Description
I_ActuatorFunctions Standard interfaces on FB_ActuatorFunctions
I_AttachableMdInterface Interface for containerless machine data components
Requirements
5.3.1.2.2 FB_HydraulicFunctions
Syntax:
FUNCTION_BLOCK FB_HydraulicFunctions EXTENDS FB_Base
Properties
Methods
Name Description
AutoIdent() Characteristic measurement of a hydraulic axis.
Interfaces
Type Description
I_HydraulicFunctions Standard interface on FB_HydraulicFunctions
Requirements
5.3.1.2.3 FB_NcFunctions
Syntax:
FUNCTION_BLOCK FB_NcFunctions EXTENDS FB_Base
Properties
Interfaces
Type Description
I_NcFunctions Standard interface on FB_NcFunctions
I_AttachableMdInterface Interface for containerless machine data components
Requirements
5.3.1.2.4 FB_TrafoFunctions
Syntax:
FUNCTION_BLOCK FB_TrafoFunctions EXTENDS FB_Base
Properties
Methods
Name Description
AssignTableToAxis() Assigns the internal table to the axis instance (means activating the
transformation curve)
ConvDriveEndsToLoadEnds() Calculates the resulting software end positions of the load side using the
transformation table
CopyTableDriveEnds() Copies the start and end position of the TableGenerator class to the
software end positions of the drive axis.
FillDebugTable() Copies the contents of the internal table into a two-dimensional array
ParamListToTableGenerator() Copies the internal parameter list to the parameters of the
TableGenerator
TableGeneratorToParamList() Copies the parameters of the TableGenerator into the internal parameter
list
Possible events
ID Description Alarm/Message
201 Calling the TableGenerator property without previous assignment Message
Interfaces
Type Description
I_TrafoFunctions Standard interface on FB_TrafoFunctions
I_AttachableMdInterface Interface for containerless machine data components
Requirements
5.3.2 FB_Axis
Represents the standard class for all axis objects based on TF8560 axes.
Syntax:
FUNCTION_BLOCK FB_Axis EXTENDS FB_Motion
Properties
Methods
Name Description
Reset() Resets the error state of the class.
FB_Axis
SetPosition(bCommand) Setting the axis position with the FB_AxisHmi.Setpoistion.
1
SetAxisRef() Assignment method for the TF8560 axis.
Alternative: .SetMotionRef().
FB_Motion
CheckAxisState() [} 34] Checks the current state of the axis.
FeedEnable(bFeedEnableP, Enable of a direction of movement.
bFeedEnableN)
JogNegative(bCommand) Starts/stops a jog movement in negative direction.
JogPositive(bCommand) Starts/stops a jog movement in positive direction.
Power(bCommand) Switching on the drive control.
SetMotionRef(iMotion) Assignment method for the TF8560 motion object.
FB_BaseMd
[PROTECTED] AddMdComp() Adds a component of type I_MdComponent to the machine data
container.
FB_Base
SetHMI(ipBase) General assignment method for an FB_BaseHmi extending class.
Notice This method always fails in the FB_Base implementation.
Overwriting is therefore absolutely necessary.
[PROTECTED] Extracts the first part of the instance path as an object namespace.
_QueryNamespace()
[PROTECTED] Extracts the last part of the instance path as the object name.
_QueryObjectName()
1
Obsolete
Possible events
ID Description Alarm/Message
11 Object error state Alarm
21 Command rejected Alarm
10 Axis Errors Alarm
20 Axis command rejected Alarm
Interfaces
Type Description
I_Base Standard interface on FB_Base.
I_Axis Standard interface on FB_Axis.
I_Motion Standard interface on FB_Motion
Type Description
I_TwoTaskInterface Runtime interface for two PLC tasks.
I_BaseMd Standard interface on FB_BaseMd.
I_BaseEmpty For extension without standard interface.
I_BaseDev Covers all methods and properties of the base class.
Requirements
5.3.2.1 FB_Homing
Syntax:
FUNCTION_BLOCK FB_Homing EXTENDS FB_Base
Properties
Methods
Name Description
DoAbort() Cancels the currently active homing.
DoAbsSwitch() Starts axis homing against an absolute position switch.
DoAbsSwitchSequence() Starts a sequence of DoAbsSwitch() and DoFinish().
DoBlock() Starts homing against an end stop.
DoBlockDetect() Starts the position detection at an end stop.
DoBlockSequence() Starts a sequence of DoBlock(), DoBlockDetect() and DoFinish().
DoFinish() Starts the termination of homing.
DoSetZero() Sets the current position of the axis to 0
Name Description
HomingStates() [} 42] State machine of the homing procedures
Name Description
ExtAdaptSeq() Dummy method() for use without "ExternalStates"
Possible events
ID Description Alarm/Message
4000 Homing not allowed Alarm
4001 Homing failed Alarm
4002 Save homing was successful Message
4003 Save homing was not successful Message
Interfaces
Type Description
I_Homing Standard interface on FB_Homing
I_AttachableMdInterface Interface for containerless machine data components
I_AdaptableSeqExt Interface for providing external homing procedures
Requirements
5.3.2.1.1 HomingStates()
Instance type Instance Name
Master fbHomingStates
Slaves aBaseSeqMembers[E_HomingState.eLength]
State diagram:
Requirements
5.3.3 FB_PtpMotion
Implements a segment logic for PTP-based movements. The TF8550 Control Arrow Motion Graph is
supported via the FB_PtpMotionHmi class.
Syntax:
FUNCTION_BLOCK FB_PtpMotion EXTENDS FB_Axis
Properties
Methods
Name Description
Reset() Resets the error state of the class.
FB_PtpMotion
[PROTECTED] Forms the difference of two segment positions.
CmpSegPos(iSeg1, iSeg2)
ContinuePtp(bCommand) Continues a paused MovePtp() command.
MovePtp() [} 46] Starts/stops a PTP movement with the parameterization from the HMI.
ResetPtp() Resets the saved progress of the MovePtp() command.
FB_Axis
SetPosition(bCommand) Setting the axis position with the FB_AxisHmi.Setpoistion.
1
SetAxisRef() Assignment method for the TF8560 axis.
Name Description
Alternative: .SetMotionRef().
FB_Motion
CheckAxisState() [} 34] Checks the current state of the axis.
FeedEnable(bFeedEnableP, Enable of a direction of movement.
bFeedEnableN)
JogNegative(bCommand) Starts/stops a jog movement in negative direction.
JogPositive(bCommand) Starts/stops a jog movement in positive direction.
Power(bCommand) Switching on the drive control.
SetMotionRef(iMotion) Assignment method for the TF8560 motion object.
FB_BaseMd
[PROTECTED] AddMdComp() Adds a component of type I_MdComponent to the machine data
container.
FB_Base
SetHMI(ipBase) General assignment method for an FB_BaseHmi extending class.
Notice This method always fails in the FB_Base implementation.
Overwriting is therefore absolutely necessary.
[PROTECTED] Extracts the first part of the instance path as an object namespace.
_QueryNamespace()
[PROTECTED] Extracts the last part of the instance path as the object name.
_QueryObjectName()
1
Obsolete
Name Description
PtpSeq() [} 46] Procedure for loading a PTP movement.
Possible events
ID Description Alarm/Message
11 Object error state Alarm
21 Command rejected Alarm
200x PTP command error Message
10 Axis Errors Alarm
20 Axis command rejected Alarm
Interfaces
Type Description
I_Base Standard interface on FB_Base.
I_PtpMotion Standard interface on FB_PtpMotion.
I_Axis Standard interface on FB_Axis.
I_Motion Standard interface on FB_Motion
I_TwoTaskInterface Runtime interface for two PLC tasks.
I_BaseMd Standard interface on FB_BaseMd.
I_BaseEmpty For extension without standard interface.
I_BaseDev Covers all methods and properties of the base class.
Requirements
5.3.3.1 PtpSeq()
Instance type Instance Name
Master fbPtpSeq
Slaves aBaseSeqMembers[E_PtpBaseSeq.eLength]
State diagram:
Requirements
5.3.3.2 MovePtp()
Syntax:
METHOD MovePtp : HRESULT
VAR_INPUT
bCommand: BOOL; // TRUE to start move, FALSE to abort running move or rewind old command
MoveIdx: INT; // Selected cluster of segments (By default: Cluster 1 -
negative direction / Cluster 2 - positive direction)
SegmentCount: INT; // Segments to move (0 to move all segments)
END_VAR
Inputs
Outputs
Requirements
5.3.4 FB_PtpMotionHmi
Syntax:
FUNCTION_BLOCK FB_PtpMotionHmi EXTENDS FB_AxisHmi
Properties
Interfaces
Type Description
I_PtpMotionHmi Standard interface on FB_PtpMotionHmi.
I_Recipe Interface for managing structured recipe values.
Requirements
5.3.4.1 FB_AxisMoveHmi
Syntax:
FUNCTION_BLOCK FB_AxisMoveHmi EXTENDS FB_BaseHmi
Properties
Requirements
5.3.4.1.1 FB_MoveCfgHmi
Syntax:
FUNCTION_BLOCK FB_MoveCfgHmi EXTENDS FB_BaseHmi
Properties
Methods
Name Description
GetLastSegInUse() Returns the last segment whose .InUse property is = TRUE.
Requirements
5.3.4.1.1.1 FB_CamCfgHmi
Syntax:
FUNCTION_BLOCK FB_CamCfgHmi EXTENDS FB_BaseHmi
Properties
Requirements
5.3.4.1.1.2 FB_SegCfgHmi
Syntax:
FUNCTION_BLOCK FB_SegCfgHmi EXTENDS FB_BaseHmi
Properties
Methods
Name Description
GetPtpLookup() Returns the segment as a variable of type ST_LookUpPtpPoint.
Interfaces
Name Description
I_SegCfgHmi Standard interface on FB_SegCfgHmi.
Requirements
5.3.5 FB_BaseCammingHmi
Extends the FB_AxisHmi class for camming based axes with the necessary interface to the TF8550
CurveEditor.
Syntax:
FUNCTION_BLOCK FB_BaseCammingHmi EXTENDS FB_AxisHmi
Properties
Methods
Name Description
GetActPoint() Returns an actual value of the displayed curve.
GetSetPoint() Returns a setpoint of the displayed curve.
SetActPoint() Sets an actual value of the displayed curve.
SetSetPoint() Sets a setpoint of the displayed curve.
Interfaces
Type Description
I_BaseCammingHmi Standard interface on FB_BaseCammingHmi
Requirements
5.3.6 FB_Extruder
Inherits from the FB_Axis class and implements further functions for a continuous movement of an extruder.
Syntax:
FUNCTION_BLOCK FB_Extruder EXTENDS FB_Axis
Properties
Methods
Name Description
Reset() Resets the error state of the class.
FB_Extruder
DoBasicRpm(bExecute) Starts a rotary motion with the base speed set in the HMI.
DoNominalRpm(bExecute) Starts a rotary motion at the production speed set in the HMI.
DoTurnrateDown(bExecute) Reduces the speed (continuously).
DoTurnrateUp(bExecute) Increases the speed (continuously).
FB_Axis
SetPosition(bCommand) Setting the axis position with the FB_AxisHmi.Setpoistion.
1
SetAxisRef() Assignment method for the TF8560 axis.
Alternative: .SetMotionRef().
FB_Motion
CheckAxisState() [} 34] Checks the current state of the axis.
FeedEnable(bFeedEnableP, Enable of a direction of movement.
bFeedEnableN)
JogNegative(bCommand) Starts/stops a jog movement in negative direction.
JogPositive(bCommand) Starts/stops a jog movement in positive direction.
Power(bCommand) Switching on the drive control.
SetMotionRef(iMotion) Assignment method for the TF8560 motion object.
FB_BaseMd
[PROTECTED] AddMdComp() Adds a component of type I_MdComponent to the machine data
container.
FB_Base
SetHMI(ipBase) General assignment method for an FB_BaseHmi extending class.
Notice This method always fails in the FB_Base implementation.
Overwriting is therefore absolutely necessary.
Name Description
[PROTECTED] Extracts the first part of the instance path as an object namespace.
_QueryNamespace()
[PROTECTED] Extracts the last part of the instance path as the object name.
_QueryObjectName()
1
Obsolete
Name Description
PowerStates() [} 53] Procedure for executing the continuous rotary motion
Possible events
ID Description Alarm/Message
11 Object error state Alarm
21 Command rejected Alarm
100x Axis switch on/off failed. Message
5000 Start of constant feed (VelocityFeed) failed. Message
10 Axis Errors Alarm
20 Axis command rejected Alarm
Interfaces
Type Description
I_Base Standard interface on FB_Base.
I_Extruder Standard interface on FB_Extruder.
I_Axis Standard interface on FB_Axis.
I_Motion Standard interface on FB_Motion
I_TwoTaskInterface Runtime interface for two PLC tasks.
I_BaseMd Standard interface on FB_BaseMd.
I_BaseEmpty For extension without standard interface.
I_BaseDev Covers all methods and properties of the base class.
Requirements
5.3.6.1 PowerStates()
Instance type Instance Name
Master fbPowerStates
Slaves aSeqBaseMembers[E_ExtruderPowerStates.eLength]
State diagram:
Requirements
5.3.7 FB_Clamp
Syntax:
FUNCTION_BLOCK FB_Clamp EXTENDS FB_PtpMotion
Properties
DisableLockSegment1 BOOL Get, Set FALSE Disables the use of the locking
point segment for NC clamp
axes.
Alternative: .UseClamping
= FALSE
FB_PtpMotion
ClampOnlyLastSeg BOOL Get, Set TRUE Clamping is only possible in
the last segment.
PtpMoveFinished BOOL Get FALSE The PTP movement was
executed successfully.
StackSegmentCount BOOL Get, Set TRUE Aborted segments are taken
into account in the subsequent
command.
UseClamping BOOL Get, Set TRUE Commanded PTP movements
should use the set clamping.
Methods
Name Description
Reset() Resets the error state of the class.
FB_PtpMotion
[PROTECTED] Forms the difference of two segment positions.
CmpSegPos(iSeg1, iSeg2)
ContinuePtp(bCommand) Continues a paused MovePtp() command.
MovePtp() [} 46] Starts/stops a PTP movement with the parameterization from the HMI.
ResetPtp() Resets the saved progress of the MovePtp() command.
FB_Axis
SetPosition(bCommand) Setting the axis position with the FB_AxisHmi.Setpoistion.
1
SetAxisRef() Assignment method for the TF8560 axis.
Alternative: .SetMotionRef().
Name Description
FB_Motion
CheckAxisState() [} 34] Checks the current state of the axis.
FeedEnable(bFeedEnableP, Enable of a direction of movement.
bFeedEnableN)
JogNegative(bCommand) Starts/stops a jog movement in negative direction.
JogPositive(bCommand) Starts/stops a jog movement in positive direction.
Power(bCommand) Switching on the drive control.
SetMotionRef(iMotion) Assignment method for the TF8560 motion object.
FB_BaseMd
[PROTECTED] AddMdComp() Adds a component of type I_MdComponent to the machine data
container.
FB_Base
SetHMI(ipBase) General assignment method for an FB_BaseHmi extending class.
Notice This method always fails in the FB_Base implementation.
Overwriting is therefore absolutely necessary.
[PROTECTED] Extracts the first part of the instance path as an object namespace.
_QueryNamespace()
[PROTECTED] Extracts the last part of the instance path as the object name.
_QueryObjectName()
Name Description
PtpSeq() [} 57] Procedure for loading a PTP movement (extended)
Possible events
ID Description Alarm/Message
11 Object error state Alarm
21 Command rejected Alarm
200x PTP command error Message
10 Axis Errors Alarm
20 Axis command rejected Alarm
Interfaces
Type Description
I_Base Standard interface on FB_Base.
I_Clamp Standard interface on FB_Clamp.
I_PtpMotion Standard interface on FB_PtpMotion.
I_Axis Standard interface on FB_Axis.
I_Motion Standard interface on FB_Motion
I_TwoTaskInterface Runtime interface for two PLC tasks.
I_BaseMd Standard interface on FB_BaseMd.
I_BaseEmpty For extension without standard interface.
I_BaseDev Covers all methods and properties of the base class.
Requirements
5.3.7.1 PtpSeq()
Clamp PTP variant only active with NC transformer axes
fbProvideLockSegment is only inserted when an NC transformer axis is used! For hydraulic
axes, the normal clamping of the FB_PtpMotion class is used.
State diagram:
Requirements
5.3.8 FB_Carriage
Implements additional functions for the operation of a carriage movement (e.g. using a crank drive).
Syntax:
FUNCTION_BLOCK FB_Carriage EXTENDS FB_PtpMotion
Methods
Name Description
DynamicScaler() Scales the axis dynamics based on the velocity in relation to the
maximum velocity.
The methods are implemented as PRIVATE. The call in the cycle
method is activated via the properties of FB_CarriageHmi.
SmoothStart() Enables startup with reduced dynamics in the range outside the end
positions.
The methods are implemented as PRIVATE. The call in the cycle
method is activated via the properties of FB_CarriageHmi.
Interfaces
Type Description
I_Carriage Standard interface on FB_Carriage
Requirements
5.4.1 FB_ManualFunctionHmi
Syntax:
FUNCTION_BLOCK FB_ManualFunctionHmi EXTENDS FB_BaseHmi
Properties
Methods
Name Description
Reset() Resets the error state of the class.
FB_BaseHmi
Init(ipBase) Default initialization method to pass the base class.
FB_Base
SetHMI(ipBase) General assignment method for an FB_BaseHmi extending class.
Notice This method always fails in the FB_Base implementation.
Overwriting is therefore absolutely necessary.
[PROTECTED] Extracts the first part of the instance path as an object namespace.
_QueryNamespace()
[PROTECTED] Extracts the last part of the instance path as the object name.
_QueryObjectName()
Interfaces
Type Description
I_Base Standard interface on FB_Base.
I_ManualFunctionHmi Standard interface on FB_ManualFunctionHmi.
I_BaseHmi Standard interface on FB_BaseHmi.
I_BaseEmpty For extension without standard interface.
I_BaseDev Covers all methods and properties of the base class.
Requirements
5.4.1.1 FB_ManualFunctionCmdHmi
Syntax:
FUNCTION_BLOCK FB_ManualFunctionCmdHmi
Properties
Interfaces
Type Description
I_ManualFunctionCmdHmi Standard interface on FB_ManualFunctionCmdHmi
Requirements
5.4.1.2 FB_ManualFunctionStateHmi
Internal functions:
• The MovingToXy properties set automatically when the respective signal of the
FB_ManualFunctionCmd [} 60] is set.
Syntax:
FUNCTION_BLOCK FB_ManualFunctionCmdHmi
Properties
Interfaces
Type Description
I_ManualFunctionStateHmi Standard interface on FB_ManualFunctionStateHmi.
Requirements
5.4.1.3 T_ManualSelectCmd
Command variable for the choice of a central operating function.
Syntax:
TYPE T_ManualSelectCmd : BYTE; END_TYPE
Values
bit Description
0 Selecting
1 Reserved
bit Description
2 Reserved
3 Reserved
4 Reserved
5 Reserved
6 Reserved
7 Reserved
Requirements
5.4.1.4 T_ManualSelectState
Status variable for using a central operating function.
Syntax:
TYPE T_ManualSelectState : BYTE; END_TYPE
Values
bit Description
0 A central operating function is available.
1 The central operating function can be selected.
2 The central operating function is connected and controls this manual function.
3 Reserved
4 Reserved
5 Reserved
6 Reserved
7 Reserved
Requirements
5.4.2 FB_Manual
Class is abstract
Since the class is defined as ABSTRACT, the class cannot be instantiated and must be implemented
using inheritance.
Internal functions:
• Provides triggers for the buttons in both directions
Syntax:
FUNCTION_BLOCK ABSTRACT FB_Manual EXTENDS FB_Base
Properties
Methods
Name Description
Reset() Resets the error state of the class.
FB_Base
SetHMI(ipBase) General assignment method for an FB_BaseHmi extending class.
Notice This method always fails in the FB_Base implementation.
Overwriting is therefore absolutely necessary.
[PROTECTED] Extracts the first part of the instance path as an object namespace.
_QueryNamespace()
[PROTECTED] Extracts the last part of the instance path as the object name.
_QueryObjectName()
Cycle methods
Name Description
Cyclic() Cycle method
Interfaces
Type Description
I_Base Standard interface on FB_Base.
I_ManualFunction Universal interface to a manual function.
I_ManualDev Extended interface to a manual function.
I_BaseEmpty For extension without standard interface.
I_BaseDev Covers all methods and properties of the base class.
Requirements
5.4.3 FB_ManualMotion
Class is abstract
Since the class is defined as ABSTRACT, the class cannot be instantiated and must be implemented
using inheritance.
Internal functions:
• Signals the error state of a motion object.
Syntax:
FUNCTION_BLOCK ABSTRACT FB_ManualMotion EXTENDS FB_Manual
Properties
Methods
Name Description
Reset() Resets the error state of the class.
FB_Base
SetHMI(ipBase) General assignment method for an FB_BaseHmi extending class.
Notice This method always fails in the FB_Base implementation.
Overwriting is therefore absolutely necessary.
Name Description
[PROTECTED] Extracts the first part of the instance path as an object namespace.
_QueryNamespace()
[PROTECTED] Extracts the last part of the instance path as the object name.
_QueryObjectName()
Cycle methods
Name Description
Cyclic() Cycle method
Interfaces
Type Description
I_Base Standard interface on FB_Base.
I_ManualFunction Universal interface to a manual function.
I_ManualDev Extended interface to a manual function.
I_BaseEmpty For extension without standard interface.
I_BaseDev Covers all methods and properties of the base class.
Requirements
5.4.4 FB_ManualBaseWork
Implements a ready-made version of a manual function for controlling the end positions of a motion object.
Internal functions:
• Signals the active movement of a motion object.
• Signals that the end position of a motion object has been reached.
Syntax:
FUNCTION_BLOCK FB_ManualBaseWork EXTENDS FB_ManualMotion
Properties
Methods
Name Description
Reset() Resets the error state of the class.
FB_ManualBaseWork
Init(iMotion, Initializes the manual function with a motion object and the associated
iManualFunctionHmi) HMI.
SetWorkBasePos() [} 67] Configuration of the end positions to display the status.
FB_Base
SetHMI(ipBase) General assignment method for an FB_BaseHmi extending class.
Notice This method always fails in the FB_Base implementation.
Overwriting is therefore absolutely necessary.
[PROTECTED] Extracts the first part of the instance path as an object namespace.
_QueryNamespace()
[PROTECTED] Extracts the last part of the instance path as the object name.
_QueryObjectName()
Cycle methods
Name Description
Cyclic() Cycle method
Interfaces
Type Description
I_Base Standard interface on FB_Base.
I_ManualBaseWork Standard interface on FB_ManualBaseWork.
I_ManualFunction Universal interface to a manual function.
I_ManualDev Extended interface to a manual function.
I_BaseEmpty For extension without standard interface.
I_BaseDev Covers all methods and properties of the base class.
Requirements
5.4.4.1 SetWorkBasePos()
Configures the end positions for indication in the TF8550 ManualOperation control.
Syntax:
METHOD SetWorkBasePos
VAR_INPUT
fWorkPos: LREAL; // Workpos to watch
fBasePos: LREAL; // Basepos to watch
fTolerance: LREAL; // > 0 for reacting on actuals with tolerance, = 0 for reacting on
setpoints
END_VAR
Inputs
Requirements
5.4.5 FB_ManualPower
Implements a predefined version of a manual function for switching on the axis control.
Internal functions:
• Switches the power enable depending on the current Power.Status.
• Automatically gives both or the configured direction enables.
Syntax:
FUNCTION_BLOCK FB_ManualPower EXTENDS FB_ManualMotion
Properties
Methods
Name Description
Reset() Resets the error state of the class.
FB_ManualPower
Init(ipAxis, ipAxisHmi) Initializes the manual function with the interfaces of an axis.
SetFeedEnableUse() Configures the direction enable of the axis control.
FB_Base
SetHMI(ipBase) General assignment method for an FB_BaseHmi extending class.
Notice This method always fails in the FB_Base implementation.
Overwriting is therefore absolutely necessary.
[PROTECTED] Extracts the first part of the instance path as an object namespace.
_QueryNamespace()
[PROTECTED] Extracts the last part of the instance path as the object name.
_QueryObjectName()
Cycle methods
Name Description
Cyclic() Cycle method
Interfaces
Type Description
I_Base Standard interface on FB_Base.
I_ManualFunction Universal interface to a manual function.
I_ManualDev Extended interface to a manual function.
I_BaseEmpty For extension without standard interface.
I_BaseDev Covers all methods and properties of the base class.
Requirements
5.4.6 FB_ManualTurnrate
Implements a standard limit and display for tactile manual functions to adjust the turn rate of an axis.
Internal functions:
• Forwards the signal of the pressed button.
• Limits the pressing of buttons to adjustable limits.
Syntax:
FUNCTION_BLOCK FB_ManualTurnrate EXTENDS FB_ManualMotion
Properties
Methods
Name Description
Reset() Resets the error state of the class.
FB_ManualTurnrate
Init(ipAxis, Initializes the manual function with the interface to an axis and the HMI.
ipManualFunctionHmi)
SetTurnrateLimits() Configures the minimum and maximum number of revolutions and the
use of the limit options.
FB_Base
SetHMI(ipBase) General assignment method for an FB_BaseHmi extending class.
Name Description
Notice This method always fails in the FB_Base implementation.
Overwriting is therefore absolutely necessary.
[PROTECTED] Extracts the first part of the instance path as an object namespace.
_QueryNamespace()
[PROTECTED] Extracts the last part of the instance path as the object name.
_QueryObjectName()
Cycle methods
Name Description
Cyclic() Cycle method
Interfaces
Type Description
I_Base Standard interface on FB_Base.
I_ManualFunction Universal interface to a manual function.
I_ManualDev Extended interface to a manual function.
I_BaseEmpty For extension without standard interface.
I_BaseDev Covers all methods and properties of the base class.
Requirements
5.4.7 FB_ManualWheel
Implements the handling of a central operating unit as incremental encoder of a Beckhoff BlowMolding
Panel, implemented as FB_CP22xx-1025 [} 162].
Syntax:
FUNCTION_BLOCK FB_ManualWheel EXTENDS FB_Base
Properties
Methods
Name Description
Reset() Resets the error state of the class.
FB_ManualWheel
AppendManual(iManual) Append a manual function for selection management.
Init(iWheel) Initialization with the wheel [} 166] of an FB_CP22xx-1025 [} 162].
FB_Base
SetHMI(ipBase) General assignment method for an FB_BaseHmi extending class.
Notice This method always fails in the FB_Base implementation.
Overwriting is therefore absolutely necessary.
[PROTECTED] Extracts the first part of the instance path as an object namespace.
_QueryNamespace()
[PROTECTED] Extracts the last part of the instance path as the object name.
_QueryObjectName()
Cycle methods
Name Description
Cyclic() Cycle method
Name Description
States() [} 72] Procedure for selecting and changing the operation via the incremental
encoder
Name Description
ExtAdaptSeq() Dummy method() for the support of the interface I_AdaptableSeqExt
[} 162].
Interfaces
Type Description
I_Base Standard interface on FB_Base.
I_AdaptableSeqExt Interface for providing external implementation of the control.
I_BaseEmpty For extension without standard interface.
I_BaseDev Covers all methods and properties of the base class.
Requirements
5.4.7.1 States()
Instance type Instance Name
Master fbList
Slaves fbReady, fbIdle, ExternalStates
State diagram:
Requirements
5.5.1 FB_Temperature
Main class of temperature control to manage all temperature channels and groups.
Internal functions:
• Handling of the TcPfw temperature control (TF8540)
Syntax:
FUNCTION_BLOCK FB_Temperature EXTENDS FB_BaseMd
Properties
Methods
Name Description
Reset() Resets the error state of the class.
FB_Temperature
Channels(x) Returns an interface to the xth temperature channel of TF8540.
CreateDefaultParams() [} 75] Creates a default parameterization for all temperature channels.
EnableAll() [} 76] Enables all temperature channels on the PLC side.
Groups(x) Returns an interface to the xth temperature group
Name Description
LinkGroup() [} 76] Assigns a linear arrangement of temperature channels to a group.
LinkSupply() [} 77] Assigns a group to a supply channel.
LinkZone() [} 78] Assigns a temperature channel to a group.
SetScheduler(iScheduler) Assigns a schedule to the temperature control.
StandbyAll() [} 78] Sets all temperature channels to standby.
Supply(x) Returns an interface to the xth supply unit.
SupplyLines(x) Returns an interface to the xth supply channel.
UnlinkGroup(x) Removes all temperature channels from the xth group.
FB_BaseMd
[PROTECTED] AddMdComp() Adds a component of type I_MdComponent to the machine data
container.
FB_Base
SetHMI(ipBase) General assignment method for an FB_BaseHmi extending class.
Notice This method always fails in the FB_Base implementation.
Overwriting is therefore absolutely necessary.
[PROTECTED] Extracts the first part of the instance path as an object namespace.
_QueryNamespace()
[PROTECTED] Extracts the last part of the instance path as the object name.
_QueryObjectName()
Exceptions avoidance
The list access functions (e.g. Channels(x), Groups(x), etc...) return a pseudo variable if the
requested index is invalid. In addition, a message is thrown in the EventLogger.
Cycle methods
Name Description
Cyclic() Slow cycle method (default 25 ms)
Possible events
ID Description Alarm/Message
20x Invalid interface queried Message
Interfaces
Type Description
I_Base Standard interface on FB_Base.
I_Temperature Standard interface on FB_Temperature.
I_TempTaskInterface Runtime interface for a slow PLC task.
I_BaseMd Standard interface on FB_BaseMd.
I_BaseEmpty For extension without standard interface.
I_BaseDev Covers all methods and properties of the base class.
Requirements
5.5.1.1 CreateDefaultParams()
Syntax:
METHOD CreateDefaultParams : HRESULT
VAR_INPUT
bAllInUse: BOOL;
eSensor: E_TcPfw_TempSensType;
eTerminal: E_TcPfw_TerminalType;
nChPerTerm: INT;
eOutHeating: E_TcPfw_TctrlOutSelect;
eOutCooling: E_TcPfw_TctrlOutSelect;
fSetpoint: LREAL;
fStandbySetp: LREAL;
fPwmCycleTime: LREAL;
END_VAR
Inputs
Outputs
Requirements
5.5.1.2 EnableAll()
Syntax:
METHOD EnableAll
VAR_INPUT
bCmd: BOOL;
bGroups: BOOL;
END_VAR
Inputs
Outputs
Requirements
5.5.1.3 LinkGroup()
Syntax:
METHOD LinkGroup : HRESULT
VAR_INPUT
nStartIdx: INT;
nEndIdx: INT;
nGroupIdx: INT;
bOverwrite: BOOL;
END_VAR
Inputs
Outputs
Requirements
5.5.1.4 LinkSupply()
Syntax:
METHOD LinkSupply : HRESULT
VAR_INPUT
nGroupIdx: INT;
nSupplyIdx: INT;
nLine: INT;
END_VAR
Inputs
Outputs
Requirements
5.5.1.5 LinkZone()
Syntax:
METHOD LinkZone : HRESULT
VAR_INPUT
nLinearIdx: INT;
nGroupIdx: INT;
nGroupMemberIdx: INT;
bOverwrite: BOOL;
END_VAR
Inputs
Outputs
Requirements
5.5.1.6 StandbyAll()
Syntax:
METHOD StandbyAll : HRESULT
VAR_INPUT
bCmd: BOOL;
bGroups: BOOL;
END_VAR
Inputs
Outputs
Requirements
5.5.2 FB_TemperatureHmi
Syntax:
FUNCTION_BLOCK FB_TemperatureHmi EXTENDS FB_BaseMdHmi
Properties
Methods
Name Description
Reset() Resets the error state of the class.
FB_TemperatureHmi
Groups(x) Returns an interface to the xth temperature group (HMI class).
FB_BaseHmi
Init(ipBase) Default initialization method to pass the base class.
FB_Base
Name Description
SetHMI(ipBase) General assignment method for an FB_BaseHmi extending class.
Notice This method always fails in the FB_Base implementation.
Overwriting is therefore absolutely necessary.
[PROTECTED] Extracts the first part of the instance path as an object namespace.
_QueryNamespace()
[PROTECTED] Extracts the last part of the instance path as the object name.
_QueryObjectName()
Exceptions avoidance
The list access functions (e.g. Channels(x), Groups(x), etc...) return a pseudo variable if the
requested index is invalid. In addition, a message is thrown in the EventLogger.
Interfaces
Type Description
I_Base Standard interface on FB_Base.
I_TemperatureHmi Standard interface on FB_TemperatureHmi.
I_Recipe Interface for managing structured recipe values.
I_BaseEmpty For extension without standard interface.
I_BaseDev Covers all methods and properties of the base class.
Requirements
5.5.3 FB_TemperatureGroup
Syntax:
FUNCTION_BLOCK FB_TemperatureGroup EXTENDS FB_BaseMd
Properties
Methods
Name Description
Reset() Resets the error state of the class.
FB_TemperatureGroup
EnablePLC(bCmd) Enables all zones of the group on the PLC side.
Force(bHeating, bCooling) Forces all zones of the group to heating/cooling 100%.
UpdateGroup() Updates the internal listing of the assigned groups.
Zones(x) Returns an interface to the xth zone [} 87] of the group.
FB_BaseMd
[PROTECTED] AddMdComp() Adds a component of type I_MdComponent to the machine data
container.
FB_Base
SetHMI(ipBase) General assignment method for an FB_BaseHmi extending class.
Notice This method always fails in the FB_Base implementation.
Overwriting is therefore absolutely necessary.
[PROTECTED] Extracts the first part of the instance path as an object namespace.
_QueryNamespace()
[PROTECTED] Extracts the last part of the instance path as the object name.
_QueryObjectName()
Exceptions avoidance
The list access functions (e.g. Channels(x), Groups(x), etc...) return a pseudo variable if the
requested index is invalid. In addition, a message is thrown in the EventLogger.
Type Description
GroupStates() [} 84] Procedure for loading, executing and saving tuning.
Possible events
ID Description Alarm/Message
20x Invalid interface queried Message
401x Temperature operation monitoring Alarm
402x Tuning parameters loading process Alarm + Message
403x Tuning parameters saving process Alarm + Message
404x File operation not available Alarm
Interfaces
Type Description
I_Base Standard interface on FB_Base.
I_TemperatureGroup Standard interface on FB_TemperatureGroup.
I_AttachableMdInterface Interface for containerless machine data components.
I_BaseMd Standard interface on FB_BaseMd.
I_BaseEmpty For extension without standard interface.
I_BaseDev Covers all methods and properties of the base class.
Requirements
5.5.3.1 GroupStates()
Instance type Instance Name
Master fbGroupStates
Slaves aBaseSeqMembers[E_GroupStates.eLength]
State diagram:
Requirements
5.5.4 FB_TemperatureGroupHmi
Syntax:
FUNCTION_BLOCK FB_TemperatureGroupHmi EXTENDS FB_BaseMdHmi
Properties
Methods
Name Description
Reset() Resets the error state of the class.
FB_TemperatureGroupHmi
[INTERN] Queries whether a property to be saved persistently has been set (.Set).
_CollectRemainingSave()
[INTERN] UpdateState() Sets the active operation mode
FB_BaseHmi
Init(ipBase) Default initialization method to pass the base class.
FB_Base
SetHMI(ipBase) General assignment method for an FB_BaseHmi extending class.
Notice This method always fails in the FB_Base implementation.
Overwriting is therefore absolutely necessary.
[PROTECTED] Extracts the first part of the instance path as an object namespace.
_QueryNamespace()
Name Description
[PROTECTED] Extracts the last part of the instance path as the object name.
_QueryObjectName()
Interfaces
Type Description
I_Base Standard interface on FB_Base.
I_TemperatureGroupHmi Standard interface on FB_TemperatureGroupHmi.
I_BaseEmpty For extension without standard interface.
I_BaseDev Covers all methods and properties of the base class.
Requirements
5.5.5 FB_TempChannelBase
Syntax:
FUNCTION_BLOCK FB_TempChannelBase EXTENDS FB_BaseHmi
Properties
Interfaces
Type Description
I_Base Standard interface on FB_Base.
I_TempZoneHmi Interface compatible with FB_TempZoneHMI.
I_BaseEmpty For extension without standard interface.
I_BaseDev Covers all methods and properties of the base class.
Requirements
5.5.6 FB_TempChannel
Syntax:
FUNCTION_BLOCK FB_TempChannel EXTENDS FB_TempChannelBase
Properties
Methods
Type Description
EnablePLC() Enables the temperature channel on the PLC side
Force() Forces the temperature channel to heating/cooling 100%.
Standby() Sets the temperature channel to standby
Possible events
ID Description Alarm/Message
400x Temperature operation monitoring Alarm
Interfaces
Type Description
I_TempChannel Standard interface on FB_TempChannel
I_AttachableMdInterface Interface for containerless machine data components
I_TempZone Compatible interface with FB_TempZone
Requirements
5.5.7 FB_TempChannelHmi
Syntax:
FUNCTION_BLOCK FB_TempChannelHmi EXTENDS FB_TempChannelBase
Properties
Interfaces
Type Description
I_TempChannelHmi Standard interface on FB_TempChannelHmi
Requirements
5.5.8 FB_TempSupply
Syntax:
FUNCTION_BLOCK FB_TempSupply EXTENDS FB_BaseHmi
Properties
Methods
Type Description
Line(x) Returns the xth supply channel of the supply group
Exceptions avoidance
The list access functions (e.g. Channels(x), Groups(x), etc...) return a pseudo variable if the
requested index is invalid. In addition, a message is thrown in the EventLogger.
Interfaces
Type Description
I_TempSupply Standard interface on FB_TempSupply
Requirements
5.5.9 FB_TempSupplyLine
Syntax:
FUNCTION_BLOCK FB_TempSupplyLine EXTENDS FB_BaseHmi
Properties
Interfaces
Type Description
I_TempSupplyLine Standard interface on FB_TempSupplyLine
I_AttachableMdInterface Interface for containerless machine data components
Requirements
5.5.10 FB_TempSchedule
Class for the use of weekday timers in connection with temperature control
Syntax:
FUNCTION_BLOCK FB_TempSchedule EXTENDS FB_TimerWeekdayMaster
Methods
Type Description
MemberSchedule(x) Returns an interface to the first timer assigned to the group (member) x
MemberScheduledActive(x) Returns an interface to the first timer assigned to the group (member) x
and currently active
Exceptions avoidance
The member access functions return a dummy instance in the absence of an overlap with member
x.
Interfaces
Type Description
I_TempSchedule Standard interface on FB_TempSchedule
I_OneTaskInterface Runtime interface for a PLC task
Requirements
5.5.11 FB_TempScheduleHmi
Syntax:
FUNCTION_BLOCK FB_TempScheduleHmi EXTENDS FB_BaseMdHmi
Properties
Methods
Type Description
Timers(x) Returns an interface to the xth timer
Exceptions avoidance
The list access functions (e.g. Channels(x), Groups(x), etc...) return a pseudo variable if the
requested index is invalid. In addition, a message is thrown in the EventLogger.
Requirements
5.5.12 FB_TimerTempHmi
Syntax:
FUNCTION_BLOCK FB_TimerTempHmi EXTENDS FB_TimerWeekdayHmi
Properties
Methods
Type Description
Clear() Empties the list of members (groups)
Exists(x) Checks whether member (group) x is assigned to the timer
Members() [} 93] Returns an interface to the member
Subscribe(x) Makes group x become a member of the timer
Interfaces
Type Description
I_TimerTempHmi Standard interface on FB_TimerTempHmi
Requirements
5.5.12.1 Members()
Syntax:
METHOD Members : I_TemperatureGroup
VAR_INPUT
idx: INT;
iTemp: I_Temperature;
END_VAR
Inputs
Outputs
Requirements
5.5.13 T_SHA256
Data type that can store a hash value of type SHA-256 (256 bits).
Syntax:
TYPE T_SHA256 : ARRAY[0..3] OF LWORD; END_TYPE
Requirements
// ==============================================
// communication PLC <> HMI
fbPlcStateToHmi: FB_PlcStateToHmi;
// ==============================================
END_VAR
5.6.1 FB_PlcStateToHmi
Implements the handshake procedure for the TF8550 recipe management on the PLC side.
Syntax:
FUNCTION_BLOCK FB_PlcStateToHmi EXTENDS FB_BaseHmi
Properties
Methods
Name Description
DeclareBeta() Adds a beta label to the display version of the Plastic Base Application.
Interfaces
Type Description
I_RecipeState Interface for the handshake variables to be processed in the main
procedure.
Requirements
5.6.2 I_RecipeState
Interface to the PLC variables of the TF8550 Beckhoff.TwinCAT.HMI.Plastic.RecipeHelper class
FB_PlcStateToHmi
Syntax:
INTERFACE I_RecipeState EXTENDS I_BaseEmpty
Properties
Methods
Name Description
DeclareBeta() Adds a beta label to the display version of the Plastic Base Application.
Requirements
5.6.3 FB_Recipe
Recipe management class for summarizing structured recipe values. These are used in integrated TcHMI
controls.
Class is abstract
Since the class is defined as ABSTRACT, the class cannot be instantiated and must be implemented
using inheritance.
Syntax:
FUNCTION_BLOCK ABSTRACT FB_Recipe EXTENDS FB_Base
Properties
Methods
Name Description
Reset() Resets the error state of the class.
FB_Recipe
Lock() Locks the recipe variables
• The next execution of .Update() writes the recipe values to the PLC.
• Can be called/executed from the HMI.
Reset() Resets the lock state.
Update() [ABSTRACT] Updates the recipe variables to the current PLC value.
• Can be called/executed from the HMI.
FB_Base
SetHMI(ipBase) General assignment method for an FB_BaseHmi extending class.
Notice This method always fails in the FB_Base implementation.
Overwriting is therefore absolutely necessary.
[PROTECTED] Extracts the first part of the instance path as an object namespace.
_QueryNamespace()
[PROTECTED] Extracts the last part of the instance path as the object name.
_QueryObjectName()
Interfaces
Type Description
I_Base Standard interface on FB_Base.
I_Recipe Standard interface on FB_Recipe.
I_BaseEmpty For extension without standard interface.
I_BaseDev Covers all methods and properties of the base class.
Requirements
5.6.4 FB_TempRecipe
Syntax:
FUNCTION_BLOCK FB_TempRecipe EXTENDS FB_Recipe
Properties
Methods
Name Description
Reset() Resets the error state of the class.
FB_TempRecipe
Init(iChannel) Initialization with the interface to a temperature channel.
FB_Recipe
Lock() Locks the recipe variables
• The next execution of .Update() writes the recipe values to the PLC.
• Can be called/executed from the HMI.
Reset() Resets the lock state.
Update() [ABSTRACT] Updates the recipe variables to the current PLC value.
• Can be called/executed from the HMI.
FB_Base
Name Description
SetHMI(ipBase) General assignment method for an FB_BaseHmi extending class.
Notice This method always fails in the FB_Base implementation.
Overwriting is therefore absolutely necessary.
[PROTECTED] Extracts the first part of the instance path as an object namespace.
_QueryNamespace()
[PROTECTED] Extracts the last part of the instance path as the object name.
_QueryObjectName()
Interfaces
Type Description
I_Base Standard interface on FB_Base.
I_Recipe Standard interface on FB_Recipe.
I_BaseEmpty For extension without standard interface.
I_BaseDev Covers all methods and properties of the base class.
Requirements
5.6.5 FB_MoveClusterRecipe
Syntax:
FUNCTION_BLOCK FB_MoveClusterRecipe EXTENDS FB_Recipe
Properties
Methods
Name Description
Reset() Resets the error state of the class.
FB_MoveClusterRecipe
Init(iCluster) Initialization with the interface on a cluster.
FB_Recipe
Lock() Locks the recipe variables
• The next execution of .Update() writes the recipe values to the PLC.
• Can be called/executed from the HMI.
Reset() Resets the lock state.
Update() [ABSTRACT] Updates the recipe variables to the current PLC value.
• Can be called/executed from the HMI.
FB_Base
SetHMI(ipBase) General assignment method for an FB_BaseHmi extending class.
Notice This method always fails in the FB_Base implementation.
Overwriting is therefore absolutely necessary.
[PROTECTED] Extracts the first part of the instance path as an object namespace.
_QueryNamespace()
[PROTECTED] Extracts the last part of the instance path as the object name.
_QueryObjectName()
Interfaces
Type Description
I_Base Standard interface on FB_Base.
I_Recipe Standard interface on FB_Recipe.
I_BaseEmpty For extension without standard interface.
I_BaseDev Covers all methods and properties of the base class.
Requirements
5.6.5.1 FB_MoveSegRecipe
Syntax:
FUNCTION_BLOCK FB_MoveSegRecipe EXTENDS FB_Recipe
Properties
Methods
Name Description
Reset() Resets the error state of the class.
FB_MoveSegRecipe
Init(iSegment) Initialization with the interface to a segment.
FB_Recipe
Lock() Locks the recipe variables
• The next execution of .Update() writes the recipe values to the PLC.
• Can be called/executed from the HMI.
Reset() Resets the lock state.
Update() [ABSTRACT] Updates the recipe variables to the current PLC value.
• Can be called/executed from the HMI.
FB_Base
SetHMI(ipBase) General assignment method for an FB_BaseHmi extending class.
Notice This method always fails in the FB_Base implementation.
Overwriting is therefore absolutely necessary.
Name Description
[PROTECTED] Extracts the first part of the instance path as an object namespace.
_QueryNamespace()
[PROTECTED] Extracts the last part of the instance path as the object name.
_QueryObjectName()
Interfaces
Type Description
I_Base Standard interface on FB_Base.
I_Recipe Standard interface on FB_Recipe.
I_BaseEmpty For extension without standard interface.
I_BaseDev Covers all methods and properties of the base class.
Requirements
The \MachineData\Base\ subfolder contains the base classes of the machine data handling.
Classes
Name Description
FB_MdBaseContainer [} 104] Represents the base container for machine data.
FB_MdBaseComponent Represents the base class for machine components.
[} 106]
Components
The \MachineData\Components\ subfolder contains all the machine data components that have already
been implemented. All included components inherit from the FB_MdBaseComponent class and have an
enumeration that defines the index (without offset) of the individual parameters.
Classes
Hmi
In the \MachineData\Hmi\ subfolder, classes are defined that summarize the data stored per component for
the HMI.
Subitems
The \MachineData\Subitems\ subfolder contains several classes, interfaces and enumerations that
contribute to the functionality of the machine data classes.
Requirements
5.7.1 FB_MdBaseContainer
The class extends the TF8560 FB_MdContainer by the machine data encoding of the TwinCAT 3 Plastic
Application. In addition, errors that occur can be evaluated using Boolean values and file storage is
simplified.
Syntax:
FUNCTION_BLOCK FB_MdBaseContainer EXTENDS FB_MdContainer
Properties
Methods
Name Description
AbortLoading() Cancels the loading process of a file
AbortSaving() Cancels the saving process of a file
AddComponent(iNew) Adds another component to the container.
[INTERN] CompareFileVersion() Compares the passed versions with the defined version in the source
code.
CreateFilepath(sNamespace) Creates a new file path based on the container name
[INTERN] OverwriteFromFile() Used by the FB_MdFileInfo class to update the loaded version in the
container.
Interfaces
Type Description
I_MdBaseContainer Standard interface on FB_MdBaseContainer
I_MdBaseContainerDev Extended interface with access to the methods marked as "[INTERN]"
I_MdBaseContainerDetails Interface to the properties with file-related information (e.g.
CreationDate)
I_MdBaseContainerErrors Interface to the properties with error information
Requirements
5.7.2 FB_MdBaseComponent
The class extends the standard component FB_MdComponent of the TF8560 utilities by functions of the
index coding of the Plastic Base Application.
Syntax:
FUNCTION_BLOCK FB_MdBaseComponent EXTENDS FB_MdComponent
Properties
Methods
Name Description
ConfigCompType() Used with inheriting classes to initialize the encoding offset to
E_StandardCompType.
ConfigCompTypeEx() Used with the inheriting class to initialize the encoding offset.
Both methods are declared as PROTECTED and can only be used within the class.
Interfaces
Type Description
I_MdBaseComponent Standard interface on FB_MdBaseComponent
Requirements
5.7.3 FB_MdCollection
The class can store a collection of components of a class type. When attaching the class to
FB_BaseRuntime, components of objects implementing the interface I_AttachableMdInterface can
be collected and attached to the collection.
Syntax:
FUNCTION_BLOCK FB_MdCollection EXTENDS FB_Base
Properties
Methods
Name Description
AddComponent() Adds a component to the collection:
• Automatically increments .ComponentIndex of the attached
components
• Refuses components that do not match the prototype
CheckType() [PROTECTED] Returns an ID used among the supported types
SetPrototype() Fixes the type of the component to be collected by the runtime
Interfaces
Type Description
I_MdCollection Standard interface on FB_MdCollection
I_OneTaskInterface Runtime interface for a PLC task
Requirements
5.8.1 FB_ProductionCounter
Implements a general counter for production-dependent data such as a piece counter or a production time
counter.
Syntax:
FUNCTION_BLOCK FB_ProductionCounter EXTENDS FB_BaseMd
Properties
Methods
Name Description
Reset() Resets the error state of the class.
FB_ProductionCounter
NewPart(bCLK) Logs a new part for the part counter.
Producing(bIsProducing) Indicates that production is actively running.
FB_BaseMd
[PROTECTED] AddMdComp() Adds a component of type I_MdComponent to the machine data
container.
FB_Base
SetHMI(ipBase) General assignment method for an FB_BaseHmi extending class.
Notice This method always fails in the FB_Base implementation.
Overwriting is therefore absolutely necessary.
[PROTECTED] Extracts the first part of the instance path as an object namespace.
_QueryNamespace()
[PROTECTED] Extracts the last part of the instance path as the object name.
_QueryObjectName()
Cycle methods
Name Description
Cyclic() Cycle method - Call once per PLC cycle (default 10 ms)
Interfaces
Type Description
I_Base Standard interface on FB_Base.
I_ProductionCounter Standard interface on FB_ProductionCounter.
I_BaseMd Standard interface on FB_BaseMd.
I_BaseEmpty For extension without standard interface.
Type Description
I_BaseDev Covers all methods and properties of the base class.
Requirements
5.8.1.1 FB_ProductionCounterComponent
Syntax:
FUNCTION_BLOCK FB_ProductionDataComponent EXTENDS FB_MdBaseComponent
Properties
Methods
Name Description
Connect() Connects references to the class.
Name Description
MdNextParameter() Container call to save the parameters to a file.
MdSetParameter() Container call to load the parameters into the runtime.
Interfaces
Type Description
I_ProductionCounterComponent Standard interface on FB_ProductionCounterComponent.
Requirements
5.8.2 FB_EnergyMeasurement
Implements the measurement of a power measurement terminal over time. This allows the machine's energy
consumption to be analyzed.
Internal functions:
• Calculates the energy used over several time periods
• Saves "energy meter readings" persistently in a machine data file
• Logs the hourly meter readings in a CSV file
Syntax:
FUNCTION_BLOCK FB_EnergyMeasurement EXTENDS FB_BaseMd
Properties
Methods
Name Description
Reset() Resets the error state of the class.
FB_EnergyMeasurement
AddInput(iNew) Adds an I/O element with energy measurement values
Input(x) Returns an interface to the xth I/O element of the energy measurement
NewPart(bCLK) Logs a new part to evaluate the energy per part
Producing(bIsProducing) Indicates that production is active.
FB_BaseMd
[PROTECTED] AddMdComp() Adds a component of type I_MdComponent to the machine data
container.
FB_Base
SetHMI(ipBase) General assignment method for an FB_BaseHmi extending class.
Notice This method always fails in the FB_Base implementation.
Overwriting is therefore absolutely necessary.
[PROTECTED] Extracts the first part of the instance path as an object namespace.
_QueryNamespace()
[PROTECTED] Extracts the last part of the instance path as the object name.
_QueryObjectName()
Exceptions avoidance
The list access functions (e.g. Channels(x), Groups(x), etc...) return a pseudo variable if the
requested index is invalid. In addition, a message is thrown in the EventLogger.
Cycle methods
Name Description
Cyclic() Cycle method - Call once per PLC cycle (default 10 ms)
Interfaces
Type Description
I_Base Standard interface on FB_Base.
I_EnergyMeasurement Standard interfaces on FB_EnergyMeasurement
I_OneTaskInterface Runtime interface for a PLC task
I_BaseMd Standard interface on FB_BaseMd.
I_BaseEmpty For extension without standard interface.
I_BaseDev Covers all methods and properties of the base class.
Requirements
5.8.2.1 FB_EnergyCalc
Contains the energy meter data for a defined period. The current and previous time periods are always
saved.
Syntax:
FUNCTION_BLOCK FB_EnergyCalc EXTENDS FB_MdBaseComponent
Properties
Methods
Name Description
Connect() Connects references to the class.
Enable(bExecute) Switches the recording on.
Init(iTimeRef) Initializes the class with the reference to a system time.
Latch(bCmd) Starts a new measurement start time.
Cycle methods
Name Description
Cyclic() Cycle method - Call once per PLC cycle (default 10 ms)
Name Description
MdNextParameter() Container call to save the parameters to a file.
MdSetParameter() Container call to load the parameters into the runtime.
Interfaces
Type Description
I_EnergyCalc Standard interface on FB_EnergyCalc.
I_EnergyCalcQuery Reduced query interface to FB_EnergyCalc.
Requirements
5.8.2.2 FB_EL3443
Syntax:
FUNCTION_BLOCK FB_EL3443 EXTENDS FB_InputBase
I/O variables
Properties
Interfaces
Type Description
I_EL3443 Standard interface on FB_EL3443.
I_InputEnergy General interface for power measuring elements.
Requirements
5.8.2.2.1 FB_EmPhase
Syntax:
FUNCTION_BLOCK FB_EmPhase
I/O variables
Properties
Interfaces
Type Description
I_EmPhase Standard interface on FB_EmPhase.
Requirements
5.8.2.2.2 FB_EmPhaseGuarded
Syntax:
FUNCTION_BLOCK FB_EmPhaseGuarded EXTENDS FB_EmPhase
I/O variables
Properties
Interfaces
Type Description
I_EmPhase Standard interface on FB_EmPhase.
I_EmPhaseGuarded Standard interface on FB_EmPhaseGuarded.
Requirements
5.9.1 FB_AlarmHandler
The class implements a handling of pending alarms to influence the process sequence. This means, for
example, that an alarm with the severity "Error" can be responded to by stopping the machine directly.
Syntax:
FUNCTION_BLOCK FB_AlarmHandler EXTENDS FB_ListenerBase2
Properties
Methods
Name Description
ClearAlarms() Confirms and clears all pending alarms.
Interfaces
Type Description
I_AlarmHandler Standard interface on FB_AlarmHandler
I_OneTaskInterface Runtime interface for a PLC task
Requirements
5.9.2 FB_AppMessage
This class is part of the FB_Base class and provides an interface to the EventLogger for almost every
TwinCAT 3 Plastic Base Application object.
Syntax:
FUNCTION_BLOCK FB_AppMessage EXTENDS FB_TcMessage
Methods
Name Description
ClearAlarm() Clears a specific alarm.
ConfirmAlarm() Acknowledges a specific alarm.
Reset() Resets all alarms generated by this instance.
SendAlarm() Triggers an alarm.
SendEqualMessage() Logs a message in the EventLogger.
SendHresult() Logs a message in the EventLogger with the hexadecimal
representation of the error code.
SendMessage() Logs a message in EventLogger, unless the message has been sent
before.
Interfaces
Type Description
I_AppMessage Standard interface on FB_AppMessage.
Requirements
5.10.1 CSV
5.10.1.1 FB_CsvBase
Class is abstract
Since the class is defined as ABSTRACT, the class cannot be instantiated and must be implemented
using inheritance.
Syntax:
FUNCTION_BLOCK ABSTRACT FB_CsvBase EXTENDS FB_Base
Properties
Methods
Name Description
Reset() Resets the error state of the class.
FB_Base
SetHMI(ipBase) General assignment method for an FB_BaseHmi extending class.
Notice This method always fails in the FB_Base implementation.
Overwriting is therefore absolutely necessary.
[PROTECTED] Extracts the first part of the instance path as an object namespace.
_QueryNamespace()
[PROTECTED] Extracts the last part of the instance path as the object name.
_QueryObjectName()
Cycle methods
Name Description
Cyclic() Cycle method - 1 time per cycle (default 10 ms).
Type Description
CsvStates() [} 119] Procedure for processing CSV commands.
Possible events
ID Description Alarm/Message
8001 CSV object is in error state Alarm
Interfaces
Type Description
I_Base Standard interface on FB_Base.
I_CsvBase Standard interface on FB_CsvBase.
I_BaseEmpty For extension without standard interface.
I_BaseDev Covers all methods and properties of the base class.
Requirements
5.10.1.1.1 CsvStates()
Instance type Instance Name
Master fbCsvStates
Slaves aBaseSeqMembers[E_CsvStates.eLength]
State diagram:
Requirements
5.10.1.1.2 E_FileMode
Enumeration of file modes for CSV-based functions.
Syntax:
{attribute 'qualified_only'}
{attribute 'strict'}
TYPE E_FileMode :
(
eModeTextAppend := FOPEN_MODEAPPEND OR FOPEN_MODETEXT,
eModeTextRead := FOPEN_MODEREAD OR FOPEN_MODETEXT
)UDINT;
END_TYPE
Values
Name Description
eModeTextAppend Open file in text mode and append information.
eModeTextRead Open and read file in text mode.
Requirements
5.10.1.1.3 I_CsvField
Interface to a CSV field of the internal buffer of FB_CsvBase.
Syntax:
INTERFACE I_CsvField
Properties
Requirements
5.10.1.2 FB_CsvLogger
Syntax:
FUNCTION_BLOCK FB_CsvLogger EXTENDS FB_CsvBase
Properties
Methods
Name Description
Reset() Resets the error state of the class.
FB_CsvLogger
Field(sValue) Logging a textual value.
This function can be called in a chain.
Float(fValue, nDecimals) Logging a floating point value, specifying the decimal places.
This function can be called in a chain.
NewLine() Logging a line break.
This function can be called in a chain.
Timestamp() Logging the current system time.
This function can be called in a chain.
FB_Base
SetHMI(ipBase) General assignment method for an FB_BaseHmi extending class.
Notice This method always fails in the FB_Base implementation.
Overwriting is therefore absolutely necessary.
[PROTECTED] Extracts the first part of the instance path as an object namespace.
_QueryNamespace()
[PROTECTED] Extracts the last part of the instance path as the object name.
_QueryObjectName()
Cycle methods
Name Description
Cyclic() Cycle method - 1 time per cycle (default 10 ms).
Type Description
CsvStates() [} 122] Procedure for processing CSV commands (extended).
Possible events
ID Description Alarm/Message
8001 CSV object is in error state Alarm
Interfaces
Type Description
I_Base Standard interface on FB_Base.
I_CsvLogger Standard interface on FB_CsvLogger.
I_CsvLoggerCmd Chaining interface for logging commands.
I_CsvBase Standard interface on FB_CsvBase.
I_BaseEmpty For extension without standard interface.
I_BaseDev Covers all methods and properties of the base class.
Requirements
5.10.1.2.1 CsvStates()
Instance type Instance Name
Master fbCsvStates
Slaves aBaseSeqMembers[E_CsvStates.eLength]
State diagram:
Requirements
5.10.1.3 FB_CsvReader
Syntax:
FUNCTION_BLOCK FB_CsvReader EXTENDS FB_CsvBase
Properties
Methods
Name Description
Reset() Resets the error state of the class.
FB_CsvLogger
Init() Initializes the class.
Next() Loads the next value for reading and returns this as the return value.
Read(bExecute) Triggers the read process of the file.
FB_Base
SetHMI(ipBase) General assignment method for an FB_BaseHmi extending class.
Notice This method always fails in the FB_Base implementation.
Overwriting is therefore absolutely necessary.
[PROTECTED] Extracts the first part of the instance path as an object namespace.
_QueryNamespace()
[PROTECTED] Extracts the last part of the instance path as the object name.
_QueryObjectName()
Cycle methods
Name Description
Cyclic() Cycle method - 1 time per cycle (default 10 ms).
Type Description
CsvStates() [} 125] Procedure for processing CSV commands (extended).
Possible events
ID Description Alarm/Message
8001 CSV object is in error state Alarm
Interfaces
Type Description
I_Base Standard interface on FB_Base.
I_CsvBase Standard interface on FB_CsvBase.
I_BaseEmpty For extension without standard interface.
I_BaseDev Covers all methods and properties of the base class.
Requirements
5.10.1.3.1 CsvStates()
Instance type Instance Name
Master fbCsvStates
Slaves fbStateDone, aBaseSeqMembers[E_CsvStates.eLength]
State diagram:
Requirements
5.10.2 UserLogging
5.10.2.1 FB_UserLogging
Internal functions:
• Automatically creates one file per day.
• Limits the maximum number of logging entries.
Syntax:
FUNCTION_BLOCK FB_UserLogging EXTENDS FB_CsvLogger
Properties
Methods
Name Description
Reset() Resets the error state of the class.
FB_CsvLogger
Field(sValue) Logging a textual value.
This function can be called in a chain.
Float(fValue, nDecimals) Logging a floating point value, specifying the decimal places.
This function can be called in a chain.
NewLine() Logging a line break.
This function can be called in a chain.
Timestamp() Logging the current system time.
This function can be called in a chain.
FB_Base
SetHMI(ipBase) General assignment method for an FB_BaseHmi extending class.
Notice This method always fails in the FB_Base implementation.
Overwriting is therefore absolutely necessary.
[PROTECTED] Extracts the first part of the instance path as an object namespace.
_QueryNamespace()
[PROTECTED] Extracts the last part of the instance path as the object name.
_QueryObjectName()
Cycle methods
Name Description
Cyclic() Cycle method - 1 time per cycle (default 10 ms)
Type Description
CsvStates() [} 127] Procedure for processing the logging (extended)
Possible events
ID Description Alarm/Message
8001 CSV object is in error state Alarm
Interfaces
Type Description
I_Base Standard interface on FB_Base.
I_UserLogging Standard interface on FB_UserLogging.
I_CsvLogger Standard interface on FB_CsvLogger.
I_CsvLoggerCmd Chaining interface for logging commands.
I_CsvBase Standard interface on FB_CsvBase.
I_BaseEmpty For extension without standard interface.
I_BaseDev Covers all methods and properties of the base class.
Requirements
5.10.2.1.1 CsvStates()
Instance type Instance Name
Master fbCsvStates
Slaves aBaseSeqMembers[E_CsvStates.eLength]
aUserLogSeq[E_UserLogStates.eLength]
State diagram:
Requirements
5.10.2.2 FB_UserLoggingHmi
Syntax:
FUNCTION_BLOCK FB_UserLoggingHmi EXTENDS FB_BaseHmi
Properties
Methods
Name Description
Reset() Resets the error state of the class.
FB_UserLoggingHmi
Logg(...) Logging a changed parameter from the HMI.
This method can be called from the HMI.
FB_BaseHmi
Init(ipBase) Default initialization method to pass the base class.
Interfaces
Type Description
I_Base Standard interface on FB_Base.
I_UserLoggingHmi Standard interface on FB_UserLoggingHmi.
I_BaseHmi Standard interface on FB_BaseHmi.
I_BaseEmpty For extension without standard interface.
I_BaseDev Covers all methods and properties of the base class.
Requirements
5.11.1 FB_ScaleAnalogHmi
Implements functions for scaling analog values with parameterization via the HMI.
Syntax:
FUNCTION_BLOCK FB_ScaleAnalogHmi EXTENDS FB_ScaleHmi
Properties
Methods
Name Description
Reset() Resets the error state of the class.
FB_ScaleAnalogHmi
ElectricalToRaw(fElectrical) Scales the electrical voltage to the raw analog measured value (bit/
numeric).
ElectricalToValue(fElectrical) Scales the electrical voltage to the unit of the final scaling.
RawToElectrical(nRaw) Scales the raw analog measured value (bit/numeric) to the electrical
voltage.
RawToValue(nRaw) Scales the raw analog measured value (bit/numeric) to the unit of the
final scaling.
ValueToElectrical(fValue) Scales the unit of the final scaling to the electrical voltage.
ValueToRaw(fValue) Scales the unit of the final scaling to the raw analog measured value (bit/
numeric).
FB_ScaleHmi
[PROTECTED] XtoY(...) Scales a value x to a value y, using the minimum and maximum value of
both scales
FB_BaseHmi
Init(ipBase) Default initialization method to pass the base class.
Interfaces
Type Description
I_Base Standard interface on FB_Base.
I_ScaleAnalogHmi Standard interface on FB_ScaleAnnalogHmi.
I_ScaleAnalogScalings Interface to the scaling minima and maxima.
I_BaseHmi Standard interface on FB_BaseHmi.
I_BaseEmpty For extension without standard interface.
I_BaseDev Covers all methods and properties of the base class.
Requirements
5.11.2 FB_Monitoring
Implements a monitoring function for analog signals. The threshold values for monitoring can be set variably
on the HMI.
Syntax:
FUNCTION_BLOCK FB_Monitoring EXTENDS FB_Base
Properties
Possible events
ID Description Alarm/Message
300x Exceeding/falling below the set tolerances Alarm
Interfaces
Type Description
I_Monitoring Standard interface on FB_Monitoring
I_AttachableMdInterface Interface for containerless machine data components
I_OneTaskInterface Runtime interface for a PLC task
Requirements
5.11.2.1 FB_MonitoringTemp
Implements monitoring of a temperature channel with direct connection to TF8540. The adjustable limits are
synchronized with the temperature zone.
Syntax:
FUNCTION_BLOCK FB_MonitoringTemp EXTENDS FB_Monitoring
Properties
Interfaces
Type Description
I_MonitoringTemp Standard interface on FB_MonitoringTemp
Requirements
5.11.2.2 FB_MonitoringIPC
Syntax:
FUNCTION_BLOCK FB_MonitoringIPC EXTENDS FB_Monitoring
Properties
Interfaces
Type Description
I_MonitoringIPC Standard interface on FB_MonitoringIPC
Requirements
5.11.3 FB_Setpoints
Implements scaling of analog setpoints that can be adjusted via the HMI.
Syntax:
FUNCTION_BLOCK FB_Setpoints EXTENDS FB_Base
Properties
Interfaces
Type Description
I_Setpoints Standard interface on FB_Setpoints
I_AttachableMdInterface Interface for containerless machine data components
I_OneTaskInterface Runtime interface for a PLC task
Requirements
5.12.1 FB_TimerHmi
Syntax:
FUNCTION_BLOCK FB_TimerHmi EXTENDS FB_BaseHmi
Properties
Interfaces
Type Description
I_TimerHmi Standard interface on FB_TimerHmi
Requirements
5.12.2 FB_TimerTon
Implements IEC 61131-3 timer function with integrated interface for PLC and HMI.
Syntax:
FUNCTION_BLOCK FB_TimerTon EXTENDS FB_Base
Properties
Interfaces
Type Description
I_Timer General interface for IEC 61131-3 timer
Requirements
5.12.3 FB_TimerTof
Implements IEC 61131-3 timer function with integrated interface for PLC and HMI.
Syntax:
FUNCTION_BLOCK FB_TimerTof EXTENDS FB_Base
Properties
Interfaces
Type Description
I_Timer General interface for IEC 61131-3 timer
Requirements
5.12.4 FB_TimerTp
Implements IEC 61131-3 timer function with integrated interface for PLC and HMI.
Syntax:
FUNCTION_BLOCK FB_TimerTp EXTENDS FB_Base
Properties
Interfaces
Type Description
I_Timer General interface for IEC 61131-3 timer
Requirements
5.12.5 FB_TimerWeekdayHmi
HMI interface for a weekday timer for use with the TF8550 Control TimeScheduler.
Syntax:
FUNCTION_BLOCK FB_TimerWeekdayHmi EXTENDS FB_TimerHmi
Properties
Interfaces
Type Description
I_TimerWeekday Standard interface on FB_TimerWeekdayMaster
I_TimerWeekdayHmiQuery Interface for internal queuing of multiple weekday timers
I_AttachableMdInterface Interface for containerless machine data components
Requirements
5.12.5.1 E_Weekday
Enumeration of the weekdays on which a schedule is to start.
Syntax:
TYPE E_Weekday :
(
// invalid - inactive
eNone := 2#0000_0000,
// One day
eMonday := 2#0000_0001,
eTuesday := 2#0000_0010,
eWednesday := 2#0000_0100,
eThursday := 2#0000_1000,
eFriday := 2#0001_0000,
eSaturday := 2#0010_0000,
eSunday := 2#0100_0000
Values
Name Description
eNone Inactive or no weekday
eMonday Monday
eTuesday Tuesday
eWednesday Wednesday
eThursday Thursday
eFriday Friday
eSaturday Saturday
eSunday Sunday
5.12.6 FB_TimerWeekdayMaster
Syntax:
FUNCTION_BLOCK FB_TimerWeekdayMaster EXTENDS FB_BaseMd
Properties
Interfaces
Type Description
I_TimerWeekday Standard interface on FB_TimerWeekdayMaster
Requirements
5.12.7 FB_Time
Class (FB) saves a point in time. The class makes it possible to interpret the time in various partial
information and data types.
Syntax:
FUNCTION_BLOCK FB_Time
Properties
Methods
Type Description
DiffTo(iDiff) Returns a timespan [s] between this and the transferred time.
Now() Sets this class equal to the current system time and returns an interface
to it.
Interfaces
Type Description
I_Time Standard interface on FB_Time.
Requirements
5.12.8 F_GetLocalSystemtime
Returns the local system time, taking into account the time zone. Is suitable for creating system time-related
timestamps.
Syntax:
FUNCTION F_GetLocalSystemtime : ULINT
Outputs
Requirements
5.12.9 F_GetLocalSystemtimeEx
Returns the system time of a device with AMS-NetID, taking into account the time zone. Is suitable for
creating system time-related timestamps.
Syntax:
FUNCTION F_GetLocalSystemtimeEx : ULINT
Inputs
Outputs
Requirements
5.12.10 F_SecondsToTime()
Syntax:
FUNCTION F_SecondsToTime : TIME
VAR_INPUT
fTime: LREAL;
END_VAR
Inputs
Outputs
Requirements
5.12.11 F_TimeToSeconds()
Syntax:
FUNCTION F_SecondsToTime : LREAL
VAR_INPUT
tTime: TIME;
END_VAR
Inputs
Outputs
Requirements
5.13.1 FB_Blowing
Implements a typical blowing sequence in two blowing phases with adjustable pressure.
Syntax:
FUNCTION_BLOCK FB_Blowing EXTENDS FB_Base
Properties
Methods
Name Description
Start() Starts the blowing process.
Name Description
BlowSeq() [} 142] Procedure for blowing pressure output
Interfaces
Type Description
I_Blowing Standard interface on FB_Blowing
I_AttachableMdInterface Interface for containerless machine data components
Requirements
5.13.1.1 BlowSeq()
Instance type Instance Name
Master fbBlowSeq
Slaves aBaseSeqMembers[E_BlowingSequence.eLength]
State diagram:
Requirements
5.13.2 FB_IntervalBlowing
Extends the FB_Blowing class with an alternating blowing interval during the main blowing phase.
Syntax:
FUNCTION_BLOCK FB_IntervalBlowing EXTENDS FB_Blowing
Properties
Name Description
BlowSeq() [} 143] Procedure for blowing pressure output (advanced)
Interfaces
Type Description
I_IntervalBlowing Standard interface on FB_IntervalBlowing
Requirements
5.13.2.1 BlowSeq()
Instance type Instance Name
Master fbBlowSeq
Slaves fbStateBlowing
fbStateInterval1
fbStateInverval2
State diagram:
Requirements
5.13.3 FB_Blowpin
Syntax:
FUNCTION_BLOCK FB_Blowpin EXTENDS FB_PtpMotion
Properties
Methods
Name Description
Reset() Resets the error state of the class.
FB_PtpMotion
[PROTECTED] Forms the difference of two segment positions.
CmpSegPos(iSeg1, iSeg2)
ContinuePtp(bCommand) Continues a paused MovePtp() command.
MovePtp() [} 46] Starts/stops a PTP movement with the parameterization from the HMI.
ResetPtp() Resets the saved progress of the MovePtp() command.
FB_Axis
SetPosition(bCommand) Setting the axis position with the FB_AxisHmi.Setpoistion.
1
SetAxisRef() Assignment method for the TF8560 axis.
Alternative: .SetMotionRef().
FB_Motion
CheckAxisState() [} 34] Checks the current state of the axis.
FeedEnable(bFeedEnableP, Enable of a direction of movement.
bFeedEnableN)
JogNegative(bCommand) Starts/stops a jog movement in negative direction.
JogPositive(bCommand) Starts/stops a jog movement in positive direction.
Power(bCommand) Switching on the drive control.
SetMotionRef(iMotion) Assignment method for the TF8560 motion object.
FB_BaseMd
[PROTECTED] AddMdComp() Adds a component of type I_MdComponent to the machine data
container.
FB_Base
SetHMI(ipBase) General assignment method for an FB_BaseHmi extending class.
Notice This method always fails in the FB_Base implementation.
Overwriting is therefore absolutely necessary.
[PROTECTED] Extracts the first part of the instance path as an object namespace.
_QueryNamespace()
[PROTECTED] Extracts the last part of the instance path as the object name.
_QueryObjectName()
Name Description
PtpSeq() [} 146] Procedure for loading a PTP movement (extended).
Possible events
ID Description Alarm/Message
11 Object error state Alarm
21 Command rejected Alarm
200x PTP command error Message
ID Description Alarm/Message
10 Axis Errors Alarm
20 Axis command rejected Alarm
Interfaces
Type Description
I_Base Standard interface on FB_Base.
I_Blowpin Standard interface on FB_Blowpin.
I_PtpMotion Standard interface on FB_PtpMotion.
I_Axis Standard interface on FB_Axis.
I_Motion Standard interface on FB_Motion
I_TwoTaskInterface Runtime interface for two PLC tasks.
I_BaseMd Standard interface on FB_BaseMd.
I_BaseEmpty For extension without standard interface.
I_BaseDev Covers all methods and properties of the base class.
Requirements
5.13.3.1 PtpSeq()
Blowpin PTP variant only active for NC axes
fbSeqProvideClamping is only inserted when using an NC axis. For hydraulic axes, the normal
clamping of the FB_PtpMotion class is used.
State diagram:
Requirements
5.13.4 FB_BlowMoldingExtruder
Syntax:
FUNCTION_BLOCK FB_BlowMoldingExtruder EXTENDS FB_Extruder
Properties
Interfaces
Type Description
I_BlowMoldingExtruder Standard interface on FB_BlowMoldingExtruder
Requirements
5.13.4.1 FB_ParisonLengthControl
Implements parison length control in the typical use case of the blow molding process.
Syntax:
FUNCTION_BLOCK FB_ParisonLengthControl EXTENDS FB_Base
Properties
Methods
Name Description
Activate() Activates the parison length control.
Interfaces
Type Description
I_ParisonLengthControl Standard interface on FB_ParisonLengthControl
Requirements
5.13.5 FB_Wtc
Implements wall thickness control for the extruded hose in blow molding applications.
Syntax:
FUNCTION_BLOCK FB_Wtc EXTENDS FB_Axis
Properties
Methods
Name Description
Reset() Resets the error state of the class.
FB_Wtc
CamIn(bCmd) Loads the current curve and starts camming.
DieWaitPosition(bCmd) Commands the WTC to the waiting position.
Power(bCmd) Activates the axis including the connection to the cam plate.
SetMaster(iMaster) Sets the current master to be used by the WTC.
Notice If the WTC is not in the idle state, the new master is
considered requested and is only assigned when idle.
Testposition(bCmd) Commands the WTC to the test position.
FB_Axis
SetPosition(bCommand) Setting the axis position with the FB_AxisHmi.Setpoistion.
1
SetAxisRef() Assignment method for the TF8560 axis.
Alternative: .SetMotionRef().
FB_Motion
CheckAxisState() [} 34] Checks the current state of the axis.
FeedEnable(bFeedEnableP, Enable of a direction of movement.
bFeedEnableN)
JogNegative(bCommand) Starts/stops a jog movement in negative direction.
JogPositive(bCommand) Starts/stops a jog movement in positive direction.
Power(bCommand) Switching on the drive control.
SetMotionRef(iMotion) Assignment method for the TF8560 motion object.
FB_BaseMd
[PROTECTED] AddMdComp() Adds a component of type I_MdComponent to the machine data
container.
FB_Base
SetHMI(ipBase) General assignment method for an FB_BaseHmi extending class.
Notice This method always fails in the FB_Base implementation.
Overwriting is therefore absolutely necessary.
[PROTECTED] Extracts the first part of the instance path as an object namespace.
_QueryNamespace()
[PROTECTED] Extracts the last part of the instance path as the object name.
_QueryObjectName()
Name Description
WtcStates() [} 150] Procedure for executing commands and coupling and decoupling from
the cam plate.
Possible events
ID Description Alarm/Message
11 Object error state Alarm
21 Command rejected Alarm
100x Axis switch on/off failed. Message
300x Failed to switch on/off the cam plate. Message
10 Axis Errors Alarm
20 Axis command rejected Alarm
Interfaces
Type Description
I_Base Standard interface on FB_Base.
I_Wtc Standard interface on FB_Wtc.
I_Axis Standard interface on FB_Axis.
I_Motion Standard interface on FB_Motion
I_TwoTaskInterface Runtime interface for two PLC tasks.
I_BaseMd Standard interface on FB_BaseMd.
I_BaseEmpty For extension without standard interface.
I_BaseDev Covers all methods and properties of the base class.
Requirements
5.13.5.1 WtcStates()
Instance type Instance Name
Master fbWtcStates
Slaves aBaseSeqMembers[E_WtcState.eLength]
State diagram:
Requirements
5.13.6 FB_WtcTimer
Syntax:
FUNCTION_BLOCK FB_WtcTimer EXTENDS FB_Base
Properties
Methods
Name Description
Reset() Resets the error state of the class.
FB_WtcTimer
ProfileStartAck(bAck) Resets the ProfileStarted feedback signal.
Name Description
Start(bCommand) Starts the timer.
FB_Base
SetHMI(ipBase) General assignment method for an FB_BaseHmi extending class.
Notice This method always fails in the FB_Base implementation.
Overwriting is therefore absolutely necessary.
[PROTECTED] Extracts the first part of the instance path as an object namespace.
_QueryNamespace()
[PROTECTED] Extracts the last part of the instance path as the object name.
_QueryObjectName()
Interfaces
Type Description
I_Base Standard interface on FB_Base.
I_WtcTimer Standard interface on FB_WtcTimer.
I_WtcMaster General interface of a WTC master axis.
I_TwoTaskInterface Runtime interface for two PLC tasks.
I_AttachableMdInterface Interface for containerless machine data components.
I_BaseEmpty For extension without standard interface.
I_BaseDev Covers all methods and properties of the base class.
Requirements
5.13.7 FB_WtcAccumulator
Syntax:
FUNCTION_BLOCK FB_WtcAccumulator EXTENDS FB_Axis
Properties
Methods
Name Description
Reset() Resets the error state of the class.
FB_WtcAccumulator
Filling(bCommand) Starts the filling process of the accumulator.
Pushout(bCommand) Starts the push-out process of the filling volume.
FB_Axis
SetPosition(bCommand) Setting the axis position with the FB_AxisHmi.Setpoistion.
1
SetAxisRef() Assignment method for the TF8560 axis.
Name Description
Alternative: .SetMotionRef().
FB_Motion
CheckAxisState() [} 34] Checks the current state of the axis.
FeedEnable(bFeedEnableP, Enable of a direction of movement.
bFeedEnableN)
JogNegative(bCommand) Starts/stops a jog movement in negative direction.
JogPositive(bCommand) Starts/stops a jog movement in positive direction.
Power(bCommand) Switching on the drive control.
SetMotionRef(iMotion) Assignment method for the TF8560 motion object.
FB_BaseMd
[PROTECTED] AddMdComp() Adds a component of type I_MdComponent to the machine data
container.
FB_Base
SetHMI(ipBase) General assignment method for an FB_BaseHmi extending class.
Notice This method always fails in the FB_Base implementation.
Overwriting is therefore absolutely necessary.
[PROTECTED] Extracts the first part of the instance path as an object namespace.
_QueryNamespace()
[PROTECTED] Extracts the last part of the instance path as the object name.
_QueryObjectName()
1
Obsolete
Name Description
AccuStates() [} 155] Procedure for processing the states of the accumulator.
Possible events
ID Description Alarm/Message
11 Object error state Alarm
21 Command rejected Alarm
7000 Insufficient filling volume Alarm
10 Axis Errors Alarm
20 Axis command rejected Alarm
Interfaces
Type Description
I_Base Standard interface on FB_Base.
I_WtcAccumulator Standard interface on FB_WtcAccumulator.
I_WtcMaster General interface of a WTC master axis.
I_Axis Standard interface on FB_Axis.
I_Motion Standard interface on FB_Motion
I_TwoTaskInterface Runtime interface for two PLC tasks.
I_BaseMd Standard interface on FB_BaseMd.
I_BaseEmpty For extension without standard interface.
I_BaseDev Covers all methods and properties of the base class.
Requirements
5.13.7.1 AccuStates()
Instance type Instance Name
Master fbAccuStates
Slaves aBaseSeqMembers[E_WtcAccuState.eLength]
State diagram:
Requirements
5.13.8 FB_WtcAccumulatorHmi
Syntax:
FUNCTION_BLOCK FB_AccumulatorHmi EXTENDS FB_AxisHmi
Properties
Interfaces
Type Description
I_WtcAccumulatorHmi Standard interface on FB_WtcAccumulatorHmi.
Requirements
5.13.8.1 E_PushoutMode
Push-out mode for the push-out process of a WTC accumulator.
Syntax:
{attribute 'qualified_only'}
{attribute 'strict'}
TYPE E_PushoutMode :
(
eInvalid := 0,
eExact,
eAdapted,
eSpareFirst,
eSpareLast,
eComplete
);
END_TYPE
Values
Name Description
eInvalid Invalid setting.
eExact The precisely configured volume is pushed out.
Name Description
Notice If the option AbortOnMissingVolume is not used, the fill level must
be checked in the sequence program.
eAdapted The available volume (except buffer) is pushed out.
eSpareFirst The excess is pushed out first and then the exact volume.
eSpareLast The exact volume is pushed out first and then the excess.
eComplete The entire volume is pushed out.
The "entire" volume includes the BufferVolume .
Requirements
5.14 Utilities
5.14.1 FB_AdaptableSequence
Allows variable extension of implemented procedures of a class. The class itself is used to manage all
sequences and to indicate the state of a single sequence with reference to the management (master).
Syntax:
FUNCTION_BLOCK FB_AdaptableSequence
Properties
Methods
Name Description
Append(iNew) Appends a step to the procedure.
Check() [} 158] Checks whether the current step of the procedure has been processed.
Clear() [} 159] Deletes all sequences from the master.
Exists() [} 159] Checks whether a sequence is included in the master.
Idx() [} 160] Returns the xth step from the procedure.
Insert() [} 160] Inserts a step in the procedure.
Jump() [} 161] Requests jumping to a sequence that does not follow.
Reset() Slave: Resets the state of the procedure step.
Master: Resets the progress of the entire procedure.
[INTERN] SetMaster(ipMaster) Assigns a master to the procedure step.
Notice Used by the Insert() method and does not need to be called
separately.
Interfaces
Type Description
I_AdaptableSeqItf Interface for implementation as slave.
I_AdaptableSeqState Interface for reading the sequence state.
I_AdaptableSeqQuery Advanced interface for editing by the master.
I_AdaptableSeqMaster Interface for implementation as master.
Requirements
5.14.1.1 Check()
Checks whether the current step of the procedure has been processed. If this is the case, the method also
causes switching to the next sequence.
Syntax:
METHOD Check : BOOL
Outputs
Requirements
5.14.1.2 Clear()
Syntax:
METHOD Clear : HRESULT
Outputs
Requirements
5.14.1.3 Exists()
Syntax:
METHOD Exists : HRESULT
VAR_INPUT
iSeq: I_AdaptableSeqItf;
END_VAR
Inputs
Outputs
Requirements
5.14.1.4 Idx()
Syntax:
METHOD Idx : I_AdaptableSeqItf
VAR_INPUT
nIdx: INT;
END_VAR
Inputs
Outputs
Invalid indexes
To avoid exceptions caused by an invalid value on input nIdx, the function returns the master in
case of an error. Therefore, the method should be treated comparable to an array index by
considering the total length of the sequence list.
Requirements
5.14.1.5 Insert()
Syntax:
METHOD Insert : HRESULT
VAR_INPUT
iCurrent: I_AdaptableSeqItf;
iNew: I_AdaptableSeqItf;
bOverwrite: BOOL;
END_VAR
Inputs
Outputs
Requirements
5.14.1.6 Jump()
Syntax:
METHOD Jump : HRESULT
VAR_INPUT
iTarget: I_AdaptableSeqItf;
END_VAR
Inputs
Outputs
Requirements
5.14.1.7 I_AdaptableSeqExt
Allows the implementation of procedure steps outside the procedure-implementing class.
Syntax:
INTERFACE I_AdaptableSeqExt EXTENDS I_BaseEmpty
Name Description
ExtAdaptSeq(bInit, iMaster) Called from the implemented procedure to process the procedure steps
outside.
Requirements
5.14.2 FB_CP22xx_1025
The class implements the I/O functions of the Beckhoff BlowMolding Panel CP2219-1025-0030.
Internal functions:
• Handling of the push buttons (incl. control of the colors).
• Processing the incremental encoder (incl. LED ring).
◦ See the explanation of the integration into the application here [} 284].
• Control of the info LED.
Syntax:
FUNCTION_BLOCK FB_CP22xx_1025 EXTENDS FB_Base
Properties
Methods
Name Description
Reset() Resets the error state of the class.
FB_Base
SetHMI(ipBase) General assignment method for an FB_BaseHmi extending class.
Notice This method always fails in the FB_Base implementation.
Overwriting is therefore absolutely necessary.
[PROTECTED] Extracts the first part of the instance path as an object namespace.
_QueryNamespace()
[PROTECTED] Extracts the last part of the instance path as the object name.
_QueryObjectName()
Cycle methods
Name Description
Cyclic() Cycle method - Call once per PLC cycle (default 10 ms).
Interfaces
Type Description
I_Base Standard interface on FB_Base.
I_CP22xx_1025 Standard interface on FB_CP22xx_1025.
I_BaseEmpty For extension without standard interface.
I_BaseDev Covers all methods and properties of the base class.
Requirements
5.14.2.1 FB_Button
Syntax:
FUNCTION_BLOCK FB_Button EXTENDS FB_Base
Properties
Methods
Name Description
Reset() Resets the error state of the class.
FB_Base
SetHMI(ipBase) General assignment method for an FB_BaseHmi extending class.
Notice This method always fails in the FB_Base implementation.
Overwriting is therefore absolutely necessary.
[PROTECTED] Extracts the first part of the instance path as an object namespace.
_QueryNamespace()
[PROTECTED] Extracts the last part of the instance path as the object name.
_QueryObjectName()
Cycle methods
Name Description
Cyclic() Cycle method - Call once per PLC cycle (default 10 ms).
Interfaces
Type Description
I_Base Standard interface on FB_Base.
I_Button Standard interface on FB_Button.
I_BaseEmpty For extension without standard interface.
I_BaseDev Covers all methods and properties of the base class.
Requirements
5.14.2.2 FB_ButtonRGB
Implements a push button from a control panel with RGB indicator light.
Syntax:
FUNCTION_BLOCK FB_ButtonRGB EXTENDS FB_Button
Properties
Methods
Name Description
Reset() Resets the error state of the class.
FB_Base
SetHMI(ipBase) General assignment method for an FB_BaseHmi extending class.
Notice This method always fails in the FB_Base implementation.
Overwriting is therefore absolutely necessary.
[PROTECTED] Extracts the first part of the instance path as an object namespace.
_QueryNamespace()
[PROTECTED] Extracts the last part of the instance path as the object name.
_QueryObjectName()
Cycle methods
Name Description
Cyclic() Cycle method - Call once per PLC cycle (default 10 ms).
Interfaces
Type Description
I_Base Standard interface on FB_Base.
I_ButtonRGB Standard interface on FB_ButtonRGB.
I_Button Standard interface on FB_Button.
I_BaseEmpty For extension without standard interface.
I_BaseDev Covers all methods and properties of the base class.
Requirements
5.14.2.3 FB_CP22xx_Wheel
Implements the CP22xx_1025 specific incremental encoder including the 10-segment LED ring.
Syntax:
FUNCTION_BLOCK FB_CP22xx_Wheel EXTENDS FB_ScaleHmi
Properties
Methods
Name Description
Reset() Resets the error state of the class.
FB_CP22xx_Wheel
SetPosition(fSetPos) Sets the encoder position to the transferred position value.
SetZero() Sets the encoder position to 0.
FB_ScaleHmi
[PROTECTED] XtoY(...) Scales a value x to a value y, using the minimum and maximum value of
both scales
FB_BaseHmi
Name Description
Init(ipBase) Default initialization method to pass the base class.
FB_Base
SetHMI(ipBase) General assignment method for an FB_BaseHmi extending class.
Notice This method always fails in the FB_Base implementation.
Overwriting is therefore absolutely necessary.
[PROTECTED] Extracts the first part of the instance path as an object namespace.
_QueryNamespace()
[PROTECTED] Extracts the last part of the instance path as the object name.
_QueryObjectName()
Cycle methods
Name Description
Cyclic() Cycle method - Call once per PLC cycle (default 10 ms).
Interfaces
Type Description
I_Base Standard interface on FB_Base.
I_CP22xx_Wheel Sum interface on FB_CP22xx_Wheel.
I_CP22xx_WheelEnc Encoder functions of the FB_CP22xx_Wheel.
I_CP22xx_WheelLed LED functions of the FB_CP22xx_Wheel.
I_BaseHmi Standard interface on FB_BaseHmi.
I_BaseEmpty For extension without standard interface.
I_BaseDev Covers all methods and properties of the base class.
Requirements
5.14.2.4 FB_RGBLed
Syntax:
FUNCTION_BLOCK FB_RGBLed EXTENDS FB_Base
Properties
Methods
Name Description
Reset() Resets the error state of the class.
FB_Base
SetHMI(ipBase) General assignment method for an FB_BaseHmi extending class.
Notice This method always fails in the FB_Base implementation.
Overwriting is therefore absolutely necessary.
[PROTECTED] Extracts the first part of the instance path as an object namespace.
_QueryNamespace()
[PROTECTED] Extracts the last part of the instance path as the object name.
_QueryObjectName()
Cycle methods
Name Description
Cyclic() Cycle method - Call once per PLC cycle (default 10 ms).
Interfaces
Type Description
I_Base Standard interface on FB_Base.
I_RGBLed Standard interface on FB_RGBLed.
I_BaseEmpty For extension without standard interface.
I_BaseDev Covers all methods and properties of the base class.
Requirements
5.14.3 FB_CreateDirRecurse
Implements the FB_CreateDir function and calls it several times until all components of the transferred path
have been created.
Syntax:
FUNCTION_BLOCK FB_CreateDirRecurse EXTENDS FB_Base
Properties
Methods
Name Description
Reset() Resets the error state of the class.
FB_Base
SetHMI(ipBase) General assignment method for an FB_BaseHmi extending class.
Name Description
Notice This method always fails in the FB_Base implementation.
Overwriting is therefore absolutely necessary.
[PROTECTED] Extracts the first part of the instance path as an object namespace.
_QueryNamespace()
[PROTECTED] Extracts the last part of the instance path as the object name.
_QueryObjectName()
Cycle methods
Name Description
Cyclic() Cycle method
Interfaces
Type Description
I_Base Standard interface on FB_Base.
I_CreateDirRecurse Standard interfaces on FB_CreateDirRecurse.
I_BaseEmpty For extension without standard interface.
I_BaseDev Covers all methods and properties of the base class.
Requirements
5.14.4 FB_FlexValue
Class (FB) comparable to the structured data type ST_FlexValue from TF8560. Represents a variable
without a specified data type.
Syntax:
FUNCTION_BLOCK FB_FlexValue
Properties
NOTICE
Online Change handling
The interpretation of the _IBASE value is not handled during an Online Change! It must be ensured that the
return value of the interface is a valid instance of a class!
Interfaces
Type Description
I_FlexValue Standard interface on FB_FlexValue.
Requirements
5.14.5 FB_LatchTrigger
Syntax:
FUNCTION_BLOCK FB_LatchTrigger EXTENDS FB_Trigger
Properties
Methods
Name Description
Reset() Resets LF and LR.
Interfaces
Type Description
I_LatchTrigger Standard interface on FB_LatchTrigger
Requirements
5.14.6 FB_LibVersion
Syntax:
FUNCTION_BLOCK FB_LibVersion
Properties
Methods
Name Description
Copy(iVersion) Adopts another version in this class.
FB_LibVersion
Increase(nPlace) Increases the version, depending on the transferred position.
IsEqualTo(iCompare) Compares if another version matches.
IsNewerThan(iCompare) Checks if this version is newer than the passed comparison version.
IsOlderThan(iCompare) Checks if this version is older than the passed comparison version.
SetVersion(…) Sets the version number.
SetVersionStruct(stVersion) Sets the version number based on a version of type ST_LibVersion.
Interfaces
Type Description
I_LibVersion Standard interface on FB_LibVersion.
Requirements
5.14.7 FB_LibVersionBeta
Defines the structure of the version number of a library, plus a beta tag. The property
FB_LibVersionBeta.Version thus presents itself as 'v5.3.32.9-beta554', for example.
Syntax:
FUNCTION_BLOCK FB_LibVersionBeta EXTENDS FB_LibVersion
Properties
Methods
Name Description
Copy(iVersion) Adopts another version in this class.
FB_LibVersion
Increase(nPlace) Increases the version, depending on the transferred position.
IsEqualTo(iCompare) Compares if another version matches.
IsNewerThan(iCompare) Checks if this version is newer than the passed comparison version.
IsOlderThan(iCompare) Checks if this version is older than the passed comparison version.
SetVersion(…) Sets the version number.
SetVersionStruct(stVersion) Sets the version number based on a version of type ST_LibVersion.
Interfaces
Type Description
I_LibVersion Standard interface on FB_LibVersion.
I_LibVersionBeta Standard interface on FB_LibVersionBeta.
Requirements
5.14.8 FB_LimitMemory
The class analyzes the size of files in a directory. By setting limits, the files can be cleaned up as required by
deleting the oldest variants.
Syntax:
FUNCTION_BLOCK FB_LimitMemory EXTENDS FB_Base
Properties
Methods
Name Description
Reset() Resets the error state of the class.
FB_LimitMemory
Check(bExecute) Checks the size of the directory.
CheckWithClean(bExecute) Triggers the commands Check() and Clean() in succession.
Clean(bExecute) Cleans up the excess, starting with the oldest files.
FB_Base
SetHMI(ipBase) General assignment method for an FB_BaseHmi extending class.
Notice This method always fails in the FB_Base implementation.
Overwriting is therefore absolutely necessary.
[PROTECTED] Extracts the first part of the instance path as an object namespace.
_QueryNamespace()
[PROTECTED] Extracts the last part of the instance path as the object name.
_QueryObjectName()
Cycle methods
Name Description
Cyclic() Cycle method
Name Description
States() [} 176] Procedure for executing the file check and cleanup.
Interfaces
Type Description
I_Base Standard interface on FB_Base.
I_LimitMemory Standard interface on FB_LimitMemory.
I_BaseEmpty For extension without standard interface.
I_BaseDev Covers all methods and properties of the base class.
Requirements
5.14.8.1 States()
Instance type Instance Name
Master fbStates
Slaves aBaseSeqMembers[E_LimitMemoryStates.eLength]
State diagram:
Requirements
5.14.9 FB_Parameter
Allows concatenation of multiple 64-bit floating point (LREAL) values with assignable name.
Syntax:
FUNCTION_BLOCK FB_Parameter EXTENDS FB_Base
Properties
Methods
Name Description
Idx() Returns the element of the xth position of the list.
Exceptions avoidance
The Idx() function returns the first element (root) of the list on invalid requested index.
Interfaces
Type Description
I_Parameter Standard interface on FB_Parameter
I_ParameterQuery Extension of the I_Parameter interface with set access to next and root
properties
Requirements
5.14.10 FB_ScaleHmi
Syntax:
FUNCTION_BLOCK FB_ScaleHmi EXTENDS FB_BaseHmi
Properties
Methods
Name Description
Reset() Resets the error state of the class.
FB_ScaleHmi
[PROTECTED] XtoY(...) Scales a value x to a value y, using the minimum and maximum value of
both scales
FB_BaseHmi
Init(ipBase) Default initialization method to pass the base class.
Interfaces
Type Description
I_Base Standard interface on FB_Base.
I_BaseHmi Standard interface on FB_BaseHmi.
Type Description
I_BaseEmpty For extension without standard interface.
I_BaseDev Covers all methods and properties of the base class.
Requirements
5.14.11 FB_TableGeneratorAsciiFile
Drive Load
0.0 100.0
1.0 110.0
2.0 121.0
3.0 131.0
4.0 142.0
…
Syntax:
FUNCTION_BLOCK FB_TableGeneratorAsciiFile EXTENDS Tc3_PlasticFunctions.FB_TrafoTableGenerator
Properties
Requirements
5.14.12 FB_TrendHmi
Support class for the TwinCAT HMI SQLiteTrend with pre-implemented views. The TF8550 function
TcHmi.Functions.Plastic.UpdateTrend() is required for use. The selected view is additionally determined by
the property SelectedView. The following objects with corresponding interface can be attached to the
trend:
Internal functions:
• The first x views are pre-reserved for displaying the temperature groups
◦ Default x := 5
◦ Automatically adapting to the set number of groups [} 188]
◦ When the FB_Temperature [} 72] group configuration is changed, the views are automatically
adapted as well
• All values attached via Append() are available for configuration by the ConfigXyz() methods
Syntax:
FUNCTION_BLOCK FB_TrendHmi EXTENDS FB_Base
Properties
Methods
Name Description
Append() [} 181] Append a value to be recorded in the trend and selected in views.
AppendTempChannels() [} 181] Append the temperature zones of an FB_Temperature instance
CheckSupport() [PROTECTED] Checks the support of the appended object
ConfigDisplayName() [} 182] Overwrites the instance name of a display value.
ConfigDisplayLocalisation() [} 183] Overwrites the instance name with a localization key.
ConfigDisplayLocalisationNuget() Overwrites the instance name with a localization key from the
TF8550.Localisation package.
ConfigView() [} 183] Configures a value in a selectable view.
Idx() Returns the object at the xth position.
AppendTempZones() 1 Append the temperature zones of an FB_TempCtrl instance.
1
Obsolete
Exceptions avoidance
The Idx() function returns the first element (root) of the list on invalid requested index.
Requirements
5.14.12.1 Append()
Syntax:
METHOD Append : HRESULT
VAR_INPUT
iObj: I_Base;
nStandardView: INT;
nYAxisID: INT;
END_VAR
Inputs
ID Unit Description
1 °C Temperature
2 A Current
3 Bar Pressure
4 RPM Turnrate
Outputs
Requirements
5.14.12.2 AppendTempChannels()
Appends the temperature configuration to the trend. If the group configuration of all zones changes, this is
automatically taken over by FB_TrendHmi.
Syntax:
METHOD AppendTempChannels : HRESULT
VAR_INPUT
ipTemp: I_Temperature;
nYAxisID: INT;
END_VAR
Inputs
ID Unit Description
1 °C Temperature
2 A Current
3 Bar Pressure
4 RPM Turnrate
Outputs
Requirements
5.14.12.3 ConfigDisplayName()
Syntax:
METHOD ConfigDisplayName : HRESULT
VAR_INPUT
iObj: I_Base;
sName: STRING(255);
bAppend: BOOL;
END_VAR
Inputs
Outputs
Requirements
5.14.12.4 ConfigDisplayLocalisation()
Syntax:
METHOD ConfigDisplayName : HRESULT
VAR_INPUT
iObj: I_Base;
sLocalisation: STRING(255);
bAppend: BOOL;
END_VAR
Inputs
Outputs
Requirements
5.14.12.5 ConfigView()
Syntax:
METHOD ConfigView : HRESULT
VAR_INPUT
iObj: I_Base;
nViewIdx: INT;
bShow: BOOL;
END_VAR
Inputs
Outputs
Requirements
5.14.13 FB_Trigger
Syntax:
FUNCTION_BLOCK FB_Trigger
Properties
Methods
Name Description
Cyclic() Cycle method by which the signal is sampled
Interfaces
Type Description
I_Trigger Standard interface on FB_Trigger
Requirements
5.14.14 F_BaseDirectory
Creates the path to the default directory of the Plastic Base Application.
Syntax:
FUNCTION F_BaseDirectory : T_MaxString
Outputs
Requirements
5.14.15 F_CutDecimals
Syntax:
FUNCTION F_CutDecimals : LREAL
Inputs
Outputs
Requirements
5.14.16 F_GetCycleTime()
Returns the cycle time of the calling task as LREAL floating point value in seconds.
Syntax:
FUNCTION F_GetCycleTime : LREAL
Outputs
Requirements
5.14.17 F_Round
Syntax:
FUNCTION F_Round : LREAL
Inputs
Outputs
Requirements
5.14.18 F_TryDivide()
Syntax:
FUNCTION F_TryDivide : HRESULT
VAR_INPUT
fNominator: LREAL;
fDenominator: LREAL;
refResult: REFERENCE TO LREAL;
END_VAR
Inputs
Outputs
Requirements
5.14.19 T_PlasticStatus
Status variable for linking to a TF8550 StateIndicator. This variable is interpreted bit by bit.
Syntax:
TYPE T_PlasticStatus : BYTE; END_TYPE
Values
bit Description
0 Successful (Green)
1 Warning (Orange)
2 Error (Red)
3 Reserved
4 Reserved
5 Reserved
6 Reserved
7 State is invalid
Requirements
Syntax:
{attribute 'qualified_only'}
VAR_GLOBAL CONSTANT
// ===============================================================
// available
// Trend
{attribute 'TcHmiSymbol.Hide'}
cnTrendSize: INT := 50;
// Logger
{attribute 'TcHmiSymbol.Hide'}
cnLoggerBufferSize: UINT := 100;
// Runtime handling
{attribute 'TcHmiSymbol.Hide'}
cnRuntimeObjects: INT := 100;
// maximum of global alarms active at the same time
{attribute 'TcHmiSymbol.Hide'}
cnMaxAlarms: UINT := 50;
// Data on FileSystem
{attribute 'TcHmiSymbol.Hide'}
csHardDisk: STRING := 'C:';
{attribute 'TcHmiSymbol.Hide'}
csDataFolderName: STRING := 'Data\Machine';
{attribute 'TcHmiSymbol.Hide'}
csMachineName: STRING := 'Beckhoff';
// obsolete support
{attribute 'TcHmiSymbol.Hide'}
cbSupportObsoleteVars: BOOL := FALSE;
// ===============================================================
// obsolete
{attribute 'hide'}
cnNoOfTrafoPoints: INT := cnMaxTrafoPoints;
{attribute 'hide'}
cnTempZonesPerGroup: INT := 20;
// ===============================================================
END_VAR
Values
Requirements
Since the Plastic Application HMI project does not provide a fully comprehensive user interface for every
plastics processing machine, the project must be adapted to specific machines. For this purpose, the project
can be extended and modified as desired.
6.1 References
NuGet packages can be added to the project under the References folder via the NuGet package
management system.
The following NuGet packages from the product can be used specifically for plastics processing machines:
The NuGet packages of the TF8550 product can be integrated into any TwinCAT HMI project. For this
purpose, the corresponding license for TF8550 is required in the PLC. The package provides the NuGet
packages described in chapters. The NuGet packages can be included via the NuGet package management
system. To do this, the package source under which the NuGet packages are located must be included.
After that, the NuGet packages can be located and installed via the search. The installed NuGet packages
are available in the project after a restart of the project.
6.2 Themes
In the folder Themes you will find the Plastic theme. The Plastic theme references the
Beckhoff.TwinCAT.HMI.Plastic.Themes NuGet package and includes design adaptations of existing
controls and classes used in the Plastic Application HMI project. The file can be customized to change the
design as desired, as long as it has been loaded into the project.
6.3 Contents
The folder Contents contains in further subfolders all existing pages or .content files of the project. The
contents are built according to certain structures. These are only recommendations.
The folder Contents/Navigation contains all Contents categorized in folders that can be found in the
navigation of the Plastic Application HMI project.
The Contents/Popup folder contains all contents that appear as pop-up windows in the Plastic Application
HMI project.
The folder Contents/Slider contains all contents categorized in folders that are applied in the slider area of
the Plastic Application HMI project.
The subfolders of the two folders Contents/Navigation and Contents/Slider have the same structure in order
to recognize the affiliation of the contents from the slider area and the contents of the main area (contained
in the navigation).
As desired, additional files of the type .content can be created or the existing contents can be deleted or
edited.
Naming controls
The naming (Identifier) of the controls within a content is done according to a special scheme to avoid
duplicate naming, as this leads to errors.
The naming in the Plastic Application HMI project follows the following scheme:
ContentName_XYZ_ControlType
1. ContenName
The name, i.e. the ID of the content (the identifier of the control of type
TcHmi.Controls.System.TcHmiContent).
◦ Example: Temperature_Parameter_Settings
2. XYZ
Any description of the control is possible. The hierarchical arrangement within the content can be
observed.
◦ Example: Group1_Active_On
3. ControlType
Type of the control. An abbreviation is used.
◦ Example: For the control of type TcHmi.Controls.Beckhoff.TcHmiButton the abbreviation
Button would be used.
Most contents are built using grids. The grids make it easier to align the other controls that are in that grid to
allow for the tile design that is consistent throughout the project. The contents or controls added to the grid
are also arranged in smaller grids to make it easier to align the controls contained within a tile. The grid,
which is to represent a tile, can be assigned the CSS class from the
Beckhoff.TwinCAT.HMI.Plastic.Themes NuGet package with the name Tiles via the ClassNames
property of the Common category to color the background color white, round the corners and add a slight
shadow. Using the CSS class TilesHeadline from the same NuGet package, you can quickly customize
the appearance of the text block for the tile heading. The class colors the background of the text block in an
appropriate shade of gray, the text color becomes white and the corners are adjusted according to the tile. A
height of 45 px is usually used for the heading text block.
Use of grids
When using grids in grids, pay attention to the Z-index of the controls. If a control (e.g. a TcHmiGrid) is
located within a TcHmiGrid control and its size exceeds the specified range of the corresponding location in
the grid, this may mean that some contained controls (such as TcHmiButton controls) can no longer be
operated. Thus, the Zindex property of the Layout category of the control that is inside a grid should be
given a higher value. For the outer grid, for example, the Zindex property can be set to 0.
The content intended for the slider area can be larger than the actual available space. Thus, for example, the
width of the content can be twice as wide as the actual available space of the TcHmiRegion control if a
second page is to be created. By changing the Left properties from the Layout category, the included grid
that fills the entire content will be shifted accordingly to display the specific content that is desired. This can
be done, as in the Plastic Application HMI project, using controls of type TcHmiRadioButton.
The start page of the user interface consists of a collection of important data and information. The page
contains the following components:
1 2 3
4 5
6.3.2 Navigation
Navigation.content
The navigation page is called in the slider area via the 1st tab. It consists of controls from the NuGet
package Beckhoff.TwinCAT.HMI.ResponsiveNavigation. The TcHmiNavigationBar control is used
to define the pages that appear in the navigation and to display the top categories. In addition, the following
controls must be set:
• TcHmiNavigationContent: Display the available pages in the navigation depending on the selected
category in the TcHmiNavigationBar control (also located on the Navigation.content)
• TcHmiRegion: Area for displaying the selected content (main content of View [} 258])
• TcHmiBreadcrumb: Display of the breadcrumb (located directly on the View [} 258])
The MenuData property of the Common category of the TcHmiNavigationBar control is used to determine the
navigation content. This property can be connected to the NavBarMenuData property of the Configurator
control. This means that all settings related to navigation can be made in the NavigationConfig property
of the Configurator control and do not have to be set multiple times.
6.3.3 Info
Info.content
The info page contains the most important machine data. This page is displayed in the slider area with the
info tab (2nd tab). The page must be adapted to the specific machine. The variables are assigned to the
corresponding machine components with the help of icons. The page contains the following components:
1 2 3 4 5
6 7 8 9
The manual function page contains all manual functions and must be adapted to the specific machine. This
page is displayed in the slider area with the Manual tab (3rd tab). With the help of the ManualOperation
controls and the instances of the type FB_ManualFunctionHmi [} 58], controls for manual functions can easily
be created. The content is divided into three pages.
1 2 3 4 5
1 2 3 4 5
1. Switching on the main extruder and increasing and decreasing the turn rate.
2. Switching on the co-extruder and increasing and decreasing the turn rate.
3. Movement of the carriage.
4. Movement of the clamping unit.
5. Movement of the blow pin.
1 2 3 4 5
1 2 3 4 5
1 2 3 4
1 2 3 4
6.3.5 Axes
The folders named Axes (Contents/Navigation/Axes and Contents/Slider/Axes) contain all contents needed
for the axes of the machine. This includes a subfolder for each of the three axes included in the project (blow
pin [} 204], carriage [} 208] and clamping unit [} 208]) as well as a common oscilloscope page [} 209] for all
axes.
Content Description
Blowpin.content [} 204] The main page of the blow pin.
Blowpin_Settings.content [} 204] Displayed in the slider area under the 4th tab when
Blowpin.content is in the main area.
Blowpin_Homing.content [} 206] The homing page of the blow pin.
Blowpin_Homing_Settings.content [} 206] Displayed in the slider area under the 4th tab when
Blowpin_Homing.content is in the main area.
6.3.5.1.1 Movement
Blowpin.content
The main page of the blow pin consists on the one hand of the use of the ArrowMotionGraph control and is
used to set and display the blow pin movement in segments. The control allows the adjustment of velocity
and position, acceleration and deceleration, as well as in both directions of movement with up to 5 segments
each.
On the other hand, the blow pin main page contains the cam control twice, once for each direction of
movement of the axis. The two controls are used to set and display the cams by entering the length and
position per segment. Up to 5 segments can be added per control.
Blowpin_Settings.content
In addition to the main page of the blow pin there is a supplementary page for the slider area. The content is
divided into two pages.
1. Activating and resetting the settings and add and remove segments of the blow pin movement
2. Activating and resetting the settings of the cams in the downward movement of the blow pin
3. Activating and resetting the settings of the cams in the upward movement of the blow pin
4. Area for navigation to other related pages
1 2 4
1 2
6.3.5.1.2 Homing
Blowpin_Homing.content
The homing page for the blow pin consists of the following components:
1. Homing block
2. Homing block detection
3. Homing finish
4. Encoder zero offset shift
1 2
3 4
Blowpin_Homing_Settings.content
Supplementary to the homing page of the blow pin, there is page for the slider area. This page contains the
following components:
1 2 3
6.3.5.2 Carriage
The folders named Carriage (Contents/Navigation/Axes/Carriage and Contents/Slider/Axes/Carriage)
contain all contents needed for the carriage.
Content Description
Carriage.content The main page of the carriage.
Carriage_Settings.content Displayed in the slider area under the 4th tab when
Carriage.content is in the main area.
Carriage_Homing.content The homing page of the carriage.
Carriage_Homing_Settings.content Displayed in the slider area under the 4th tab when
Carriage_Homing.content is in the main area.
The contents have almost the same structure as the contents of the Blow pin [} 204] axis.
Content Description
Clamp.content The main page of the clamping unit.
Clamp_Settings.content Displayed in the slider area under the 4th tab when
Clamp.content is in the main area.
Clamp_Homing.content The homing page of the clamping unit.
Clamp_Homing_Settings.content Displayed in the slider area under the 4th tab when
Clamp_Homing.content is in the main area.
The contents have almost the same structure as the contents of the blow pin [} 204] axis.
6.3.5.4 Oscilloscope
Scope.content
The oscilloscope page is used to display the following historized symbol values per axis:
• Actual value of the position.
• Actual value of the velocity.
• Actual value of the torque.
1. Blow pin
2. Carriage
3. Clamp
4. WTC
5. Accumulator (only visible when the accumulator is in use)
In addition, an icon for the respective axis can be displayed via the TcHmiStateImage control.
1 2 3 4 5
6.3.6 Extruder
The folders named Extruder (Contents/Navigation/Extruder and Contents/Slider/Extruder) contain all the
contents needed for the extruders.
Content Description
Extruder.content [} 210] The extruder overview page.
MainExtruder.content [} 211] The page for the main extruder.
Content Description
CoExtruder.content [} 213] The page for the co-extruder.
Trend.content [} 214] The trend page for extruders and temperature zones.
Trend_Settings.content [} 214] Displayed in the slider area under the 4th tab when
Trend.content is in the main area.
6.3.6.1 Overview
Extruder.content
The page provides an overview of all extruders and can be expanded as required depending on the number
of extruders. Click on the name in the top left-hand corner to go to the corresponding page
(MainExtruder.content or CoExtruder.content).
1. Main extruder:
◦ Name of the main extruder (MainExtruder)
◦ Temperature status of the main extruder
◦ Illustration of the main extruder
◦ Actual value display of the turn rate as a value and setpoint and actual value display of the turn
rate in the graph
◦ Reduce and increase turn rate
◦ Display of melt pressure, melt temperature and current as a value and in the graph
2. Co-extruder:
◦ Name of the co-extruder (CoExtruder)
◦ Temperature status of the co-extruder
◦ Illustration of the co-extruder
◦ Actual value display of the turn rate as a value and setpoint and actual value display of the turn
rate in the graph
◦ Reduce and increase turn rate
◦ Switching synchronous mode on and off
◦ Display of the gear factor
◦ Display of the current as a value and in the graph
MainExtruder.content
1 2 3
5 6
MainExtruder_Settings.content
In addition to the main extruder page, there is also an additional page for the slider area. The page enables
parison length control settings.
6.3.6.3 Co-extruder
CoExtruder.content
1 2
4 5
6.3.6.4 Trend
Trend.content
The trend page is used to display curves of extruder and temperature values in a trend graph (Historized
Symbols). Using the function UpdateTrend from the Beckhoff.TwinCAT.HMI.Plastic.Functions
NuGet package and the FB_TrendHmi [} 179], the TcHmiTrendLineChart control is adjusted depending on
the TcHmiToggleButton control clicked. In addition, an icon for the selection can be displayed via the
TcHmiStateImage control.
Trend_Settings.content
This content can be used to adjust the colors of the curves. The hexadecimal color code is entered via
TcHmiInput controls. The TcHmiButton control triggers the function ResetTrendAxisColors from the
Beckhoff.TwinCAT.HMI.Plastic.Functions NuGet package to be able to overwrite the changes with
standard colors again.
6.3.7 Parameter
The folders named Parameters (Contents/Navigation/Parameters and Contents/Slider/Parameters) contain
all contents needed for the configuration of the machine data.
Content Description
Parameters.content [} 216] The overview page of the machine data.
Parameters_Actuators.content The configuration page of the machine data for the
actuators.
Parameters_Blowpin.content [} 218] The configuration page of the machine data for the
blow pin.
Parameters_Carriage.content The configuration page of the machine data for the
carriage.
Parameters_Clamp.content The configuration page of the machine data for the
clamping unit.
Parameters_CoExtruder.content The configuration page of the machine data for the
co-extruder.
Parameters_MainExtruder.content The configuration page of the machine data for the
main extruder.
Parameters_Monitoring.content The configuration page of the machine data for the
monitoring values.
Parameters_Setpoints.content The configuration page of the machine data for the
setpoints.
Parameters_Temperature.content [} 220] The configuration page of the machine data for the
temperature zones and the temperature supply.
Parameters_Wtc.content The configuration page of the machine data for the
WTC.
Parameters_Settings.content Displayed in the slider area under the 4th tab when
one of the configuration pages is in the main area.
A configuration page is built using the Table control. The control offers the possibility to create various
variables in different data types with units and to distribute them to different subpages. With the help of the
function FillParamTable from the Beckhoff.TwinCAT.HMI.Plastic.Functions NuGet package, the
table control can be automatically filled with the appropriate values based on the parameters passed.
Changes in the PLC are automatically applied to the table. Additional rows can be added by adjusting the
FirstTable attribute of the table control.
Parameters_Settings.content
The content specially made for the slider area serves as a supplement. It can be selected via the 4th tab of
the slider area when the main area displays one of the configuration pages. Included is information about the
saved file and functions for loading and saving this data. The displayed texts and functions of the buttons are
automatically adapted depending on the displayed configuration page in the main area of the user interface
using the function UpdateParametersSettingsControlsEx from the
Beckhoff.TwinCAT.HMI.Plastic.Functions NuGet package. To do this, the corresponding symbols
are set in the NavigationConfig property of the Configurator control under the slider symbols for each table
or sub-table. You can also choose whether the tables in the main area should display the parameters as one
page with a scrollbar or as several pages with a predefined number of parameters per page.
6.3.7.1 Overview
Parameters.content
This page serves as an overview page for the machine data. All machine data can be loaded or saved at
once. New machine data must be added manually. The following information about the individual machine
data is displayed in the table (in some cases the table can be sorted accordingly):
• The descriptive name of the file (sortable)
• The creation date of the file (sortable)
• The date on which the file was last stored (sortable)
• The total number of storage operations
• The loading status of the file
• The saving status of the file
Parameters_Blowpin.content
The configuration page of the machine data for the blow pin consists of three sub-pages. The variables are
categorized by subheadings. The FillParamTable function automatically fills and updates the table when there
are changes in the PLC.
6.3.7.3 Temperature
Parameters_Temperature.content
The machine data configuration page for temperature consists of two table controls that are toggled using
the TcHmiToggleSwitch control:
6.3.8 Process
The folders named Process (Contents/Navigation/Process and Contents/Slider/Process) contain all contents
needed for the process of the machines.
Content Description
Blowing.content [} 221] The page for the blowing process.
Monitoring.content [} 222] The page for monitoring values.
Setpoints.content [} 224] The page for setpoints.
Timer.content [} 225] The page for time values.
EnergyMeasurement.content [} 226] The page for energy measurement.
6.3.8.1 Blowing
Blowing.content
1 2
4 5
6.3.8.2 Monitoring
Monitoring.content
The monitoring page is built using the Monitoring control from the
Beckhoff.TwinCAT.HMI.Plastic.Functions NuGet package and instances of type
FB_MonitoringHmi. It contains one area per value for displaying the current value and for setting the
threshold values. In addition, the set and measured values are illustrated in a graph. The values currently
included are the following:
1 2
3 4
5 6
6.3.8.3 Setpoints
Setpoints.content
The setpoint page offers the possibility of setting setpoints. Currently, the setpoint of the hydraulic system
pressure is included.
6.3.8.4 Times
Timer.content
The timer page is used for setting and monitoring times. Timer controls and the FB_TimerHmi [} 133] can be
used to create controls for times.
EnergyMeasurement.content
This page provides an overview of energy measurement. It consists of the following components:
1. Display of the power, energies depending on the operation mode and date of the last reset with button
for resetting.
2. Display of the voltages and currents per phase or voltages between the phases as well as the
frequency.
3. Display of the power factor as a value and in the graph.
4. Display of the power quality factor as a value and in the graph.
5. Table for displaying the energy per hour in idle and production mode.
1 2
3 4
1 2
3 4
6.3.9 System
The folders named System (Contents/Navigation/System and Contents/Slider/System) contain all system
relevant contents of the machine.
Content Description
Administration.content [} 228] The page for the administration.
Alarms.content [} 229] The page for events and alarms.
RecipeManagement.content [} 229] The recipe management page.
RecipeManagement_Settings.content [} 229] Displayed in the slider area under the 4th tab when
RecipeManagement.content is in the main area.
FileManagement.content [} 231] The page for file management.
Content Description
Materials.content [} 233] The page for the materials.
AddMaterial.content [} 233] Is displayed as a pop-up when a material is to be
added to Materials.content.
UserLogging.content [} 236] The page for user changes.
6.3.9.1 Administration
Administration.content
The administration page is used to manage and set the user interface and contains the following
components:
1. TcHmiUserManagement control to logout, change users, edit user properties and manage users
2. Area for changing the language with one TcHmiToggleButton control per language and flag
respectively
3. Area for displaying the software versions
4. MeasurementUnitSelector control for toggling the units in the Plastic Application HMI project
1 4
Alarms.content
The alarm and event page contains a TcHmiEventGrid control that displays all events and alarms
transmitted by the PLC by means of an appropriate configuration. The control offers further filter settings to
limit the display of events. The events can be viewed and acknowledged in more detail. Additionally
implemented TcHmiButton controls simplify the TcHmiEventGrid control with predefined filters. The page
contains the following components:
1 2 3 4
RecipeManagement.content
1. TcHmiDatagrid control as a table to display all recipes with the date of the last update
2. Area for the active recipe:
1 2
RecipeManagement_Settings.content
This content is displayed in the slider area and serves as a supplement. This consists of the following
elements:
1 2 3
FileManagement.content
The file management page allows you to move, copy and delete certain files that can be accessed through
the TcHmiSrv setting using the virtual directories. The project only contains the appropriate settings for
Remote, so that this page is only fully functional after a publish to the target system.
1 2 3
1 2 3
6.3.9.5 Materials
Materials.content
This page is used to manage the materials that can be used for the extruders. It consists of the following
components:
1 2
1 2
AddMaterial.content
This page is displayed in the pop-up window and is used to add a material. The parameters of the material
can be entered there. In addition, an existing material, which may have come to the machine via a recipe,
can be imported using the checkbox and the choice in the combo box. When adding a new material, please
note that the ID must be unique. This information can be accessed via the information button. If the material
has been added, it will then be listed in the table.
UserLogging.content
This page is used to view the changes made to the machine by the user. Each change contains the following
parameters, which are saved:
• The timestamp of the change.
• The page on which the change was made.
• The name to describe the change (e.g. the symbol name of the changed symbol).
• The old value, i.e. before the change (if the value is unknown, a - is displayed).
• The new value, i.e. after the change.
• The name of the user who made the change.
The UserLoggingViewer control is used for display. This allows the following settings to be made:
1. Selection of the start date from which the files are to be displayed (using the pop-up window).
2. Selection of the end date up to which the files are to be displayed (using the pop-up window).
3. Display of the number of pages and the number of the displayed page from the defined time frame,
whereby the displayed page can be customized using the input field.
4. Button to display the previous page.
5. Button to display the next page.
6. Pop-up window for setting the date (start and end).
1 2 3 4 5
1 2 3 4 5
6.3.10 Temperature
The folders named Temperature (Contents/Navigation/Temperature and Contents/Slider/Temperature)
contain all contents needed for the temperature control on the machine.
Content Description
Temperature_Overview.content [} 238] The page for single zone monitoring of temperatures.
Temperature_Overview_Settings.content [} 238] Displayed in the slider area under the 4th tab when
Temperature_Overview.content is in the main
area.
Temperature_Configuration.content [} 241] The page for setting the temperature zone
parameters.
Temperature_Configuration_Settings.content [} 241] Displayed in the slider area under the 4th tab when
Temperature_Configuration.content is in the
main area.
Temperature_TimeScheduling.content [} 243] The page for time control of the temperature zones
and temperature groups.
Temperature_TimeScheduling_Settings.content Displayed in the slider area under the 4th tab when
[} 243] Temperature_TimeScheduling.content is in
the main area.
Temperature_Grouping.content [} 244] The page for grouping the temperature channels into
temperature groups.
Temperature_Layout.content [} 246] The page for creating layouts with temperature
zones.
Temperature_Layout_Settings.content [} 246] Displayed in the slider area under the 4th tab when
Temperature_Layout.content is in the main
area.
6.3.10.1 Overview
Temperature_Overview.content
This page is used for the temperature zone overview on the machine. Using the ZoneImageLayout control in
display mode, the configurations from the Layout [} 246] page can be displayed on this page and the
temperatures can be set. Clicking on the temperature group name in the top left corner of the two extruders
(MainExtruder [} 211] and CoExtruder [} 213]) navigates to the associated overview page.
Temperature_Overview_Settings.content
In addition to the temperature overview page, there is a supplementary page in the slider area that is used to
navigate to other related pages.
6.3.10.2 Configuration
Temperature_Configuration.content
The configuration page of the temperatures contains the ZoneConfiguration control and is used for grouped
display and setting of the temperature zones. An instance of FB_TemperatureHmi [} 79] is required to use the
control.
Temperature_Configuration_Settings.content
This page serves as a supplement in the slider area and contains the following components:
1 2 3
1 2 3
6.3.10.3 Scheduling
Temperature_TimeScheduling.content
The page for scheduling the temperature zones and temperature groups contains a ProcessScheduler
control. The control requires an instance of the FB_TempScheduleHmi [} 92] for the TimerList property of
the Scheduler category.
Temperature_TimeScheduling_Settings.content
The page serves as a supplement in the slider area and includes the following functionalities:
1. Activate and reset the changes, add new elements, remove or edit the selected element
2. Selection of the timer via arrow keys, setting of the temperature group via the combo box and
selection of the standby mode via the checkbox
3. Area for navigation to other related pages
1 2 3
1 2 3
6.3.10.4 Grouping
Temperature_Grouping.content
This page is used to group the temperature channels. Only the temperature channels that are enabled via
the temperature parameter page [} 215] are made available in the list. The page consists of the following
functions:
1 5 6 3
2 4
1 5 6 3
2 4
6.3.10.5 Layout
Temperature_Layout.content
This page is used to create layouts that can be reused throughout the HMI. A background image can be
selected and customized for each layout added, and temperature zones can be selected and positioned on
the image as desired. Only the temperature zones that are assigned to a group via the temperature
grouping page [} 244] are made available in the list. The page consists of the following functions:
1
4
Temperature_Layout_Settings.content
The page serves as a supplement in the slider area and includes the following functionalities:
1. Switching on the configuration mode, selecting the layout via a combo box, activating and resetting the
changes
2. Select background image and edit background image properties via separate pop-up windows
1 2
1 2
6.3.11 WTC
The folders named Wtc (Contents/Navigation/Wtc and Contents/Slider/Wtc) contain all contents needed for
the wall thickness control (WTC) of the machine.
Content Description
Wtc.content [} 249] The main page of the WTC.
Wtc_Settings.content [} 249] Displayed in the slider area under the 4th tab when
Wtc.content is in the main area.
Wtc_Homing.content [} 252] The homing page of the WTC.
Wtc_Homing_Settings.content [} 252] Displayed in the slider area under the 4th tab when
Wtc_Homing.content is in the main area.
Accumulator.content [} 254] The main page of the accumulator.
Accumulator_Settings.content [} 254] Displayed in the slider area under the 4th tab when
Accumulator.content is in the main area.
Accumulator_Homing.content [} 254] The homing page of the accumulator.
Accumulator_Homing_Settings.content [} 254] Displayed in the slider area under the 4th tab when
Accumulator_Homing.content is in the main
area.
6.3.11.1 Curve
Wtc.content
The main content of the WTC adapts to the use of the accumulator and consists of the following
components:
1 2 3 4 6
1 2 4
1 2 3 6
Wtc_Settings.content
There is a supplementary page for the slider area in addition to the main page of the WTC. This content is
split into three pages.
1 3 5 7 8
2 4 6
1. Add, remove, and edit marker points, and choose how to use them
2. Add, remove and edit fix points
3. Adjustment of die geometry by switching between Converging and Diverging, switching between Pin
move and Die move, and adjustment of tool stroke
4. Table for displaying the fix points
1 2 3 4
1 3
2 4
6.3.11.2 Homing
Wtc_Homing.content
The homing page for the WTC consists of the following components:
1. Homing block
2. Homing block detection
3. Homing finish
4. Encoder zero offset shift
1 2
3 4
Wtc_Homing_Settings.content
There is also a supplementary page for the slider area in addition to the homing page of the WTC. This page
contains the following components:
1 2 3
6.3.11.3 Accumulator
Accumulator.content
1
2
Accumulator_Settings.content
In addition to the main page of the accumulator, there is also an additional page for the slider area. This
content is split into three pages.
1 3 5 7 8
2 4 6
1 2 3
1 3
2 4
Accumulator_Homing.content
The homing page for the accumulator consists of the following components:
1. Homing block
1 2
3 4
Accumulator_Homing_Settings.content
There is an additional page for the slider area in addition to the homing page of the accumulator. This page
contains the following components:
1 2 3
6.4 Localization
The folder Localization manages the different languages that should be available in the project. New
languages can be added. In addition, new Localized Symbols can be created, for which the translation can
then be entered in all required languages.
6.5 View
A View is a file with the extension .view and contains the overall structure of the user interface. A project
can contain several Views. At the beginning it has to be defined in the engineering which View should be
used as Start View to build the HMI. The structure of the user interface is defined by the View selected as
Start View.
Portrait.view
Unless the Portrait.view file is modified, this user interface has a portrait aspect ratio (4:5) with a width
of 1024 px and a height of 1280 px. It consists of the following components:
1. Header:
◦ Application name (click on it to display the Home.content [} 198] in the main area).
◦ Currently loaded recipe (click on it to display the RecipeManagement.content [} 229] in the main
area).
◦ Current operation mode.
Configurator control
The Configurator control serves as a general control for setting control-wide configurations. The instance of
the control only needs to exist and does not require visibility. The following attributes are required for further
setting of the HMI:
• UnitConfig (Link): Path to the JSON file with the corresponding unit switching scheme. The file is
supplied by default with the Beckhoff.TwinCAT.HMI.Plastic.Controls NuGet package, but it can also be
copied and modified so that a different path must be set.
• NavigationConfig (Link): Setting of the navigation structure with additional information like icons,
slider content etc.
• RecipeHandshakeSymbol: Setting of the symbol for recipe management. An instance of
FB_PlcStateToHmi [} 94] is required for this.
• Temperature symbol: Setting the symbol for the temperatures. An instance of FB_TemperatureHmi
[} 79] is required for this.
• UserLoggerSymbol: Setting of the symbol for user changes. An instance of FB_UserLoggerHmi
[} 128] is required for this.
7 Samples / instructions
7.1.1 General
2. Change the fixed version of the library to the newly installed version.
3. When you create the project, check that the new library has been adopted correctly.
END_VAR
3. Create the new variables in the VAR section.
FUNCTION_BLOCK FB_CustomAxis EXTENDS FB_Axis
VAR
bNewVariable1: BOOL;
nNewVariable2: INT;
fNewVariable3: LREAL;
END_VAR
The following steps must be completed in advance for all three procedures:
1. Create a new class (FB) and remove VAR_INPUT and VAR_OUTPUT.
FUNCTION_BLOCK FB_CustomAxis
VAR_INPUT
END_VAR
VAR_OUTPUT
END_VAR
VAR
END_VAR
2. Add the class to be inherited to the class definition using the EXTENDS keyword.
FUNCTION_BLOCK FB_CustomAxis EXTENDS FB_Axis
VAR
END_VAR
3. So that you can also address the class and the added elements via an interface, create an interface with
the same name.
INTERFACE I_CustomAxis
4. Let the interface inherit from the interface of the inherited class.
INTERFACE I_CustomAxis EXTENDS I_Axis
5. Implement the interface in the previously created class (FB).
FUNCTION_BLOCK FB_CustomAxis EXTENDS FB_Axis IMPLEMENTS I_CustomAxis
VAR
END_VAR
2. Copy the method into the created interface, if the method should be accessible from outside.
ð You have successfully added a new method and can start the implementation.
2. If you want to extend the method/property rather than overwrite it, you must call the base implementation
at the appropriate place.
METHOD Power : HRESULT
VAR_INPUT
bCommand: BOOL;
END_VAR
VAR
nValue: INT;
END_VAR
IF bCommand THEN
nValue := 10;
END_IF
SUPER^.Power(bCommand);
3. Check the return value and the INPUT variables for consistency. You can view the base implementation
by selecting the SUPER^.MethodName() and then pressing the F12 key.
4. Implement their own lines of code in the method.
1. Add a method/property to the class with the name of the method/property to be removed.
2. Leave the contents of the method/property empty and do not call the SUPER^.Method().
METHOD Power : HRESULT
VAR_INPUT
bCommand: BOOL;
END_VAR
VAR
END_VAR
3. Optional: Add {attribute ‘hide‘} to the method/property to hide the method/property in the
development environment.
ð You have successfully disabled a method/property.
IF bAdditionalAction THEN
nSaveValueToThis := 10;
// command a jump to a state that is not the default "next" element
iSeq.Jump(fbSetProdTurnrate);
// feedback on finishing the sequence state
iSeq.Done := TRUE;
END_IF
IF bAdditionalAction THEN
nSaveValueToThis := 10;
iSeq.Done := TRUE;
END_IF
RETURN;
END_IF
6. [Only when adding]: Instantiate an instance of type FB_AdaptableSequence in the class with the name
of the sequence.
FUNCTION_BLOCK FB_AdaptableClass EXTENDS FB_Extruder
VAR
fbSetProdTurnrate: FB_AdaptableSequence;
END_VAR
fbPowerStates.Insert [} 160](
iCurrent := aSeqBaseMembers[E_ExtruderPowerStates.eMasterMode],
iNew := fbSetProdTurnrate,
bOverwrite := FALSE);
8. Apply the changes to your target system and restart the PLC.
ð You have successfully extended an inner procedure of a class.
3. Add the class to be inherited to the class definition using the EXTENDS keyword.
FUNCTION_BLOCK FB_CustomAxisHmi EXTENDS FB_AxisHmi
VAR
END_VAR
4. So that you can also address the class and the added elements via an interface, create an interface with
the same name.
INTERFACE I_CustomAxisHmi
5. Let the interface inherit from the interface of the inherited class.
INTERFACE I_CustomAxisHmi EXTENDS I_AxisHmi
6. Implement the interface in the previously created class (FB).
FUNCTION_BLOCK FB_CustomAxisHmi EXTENDS FB_AxisHmi IMPLEMENTS I_CustomAxisHmi
VAR
END_VAR
7. Instantiate the interface in the base class (FB).
FUNCTION_BLOCK FB_CustomAxis EXTENDS FB_Axis IMPLEMENTS I_CustomAxis
VAR
iCustomAxisHmi: I_CustomAxisHmi;
END_VAR
8. Overwrite the SetHMI() method of the base class.
// Setter method for HMI-Class
METHOD SetHMI : HRESULT
VAR_INPUT
ipBaseHmi: I_BaseHmi; // interface on hmi object
END_VAR
SetHmi := S_OK;
9. Extend the Init() method and add a __QUERYINTERFACE() operation for the new interface.
METHOD Init : HRESULT
RETURN;
ELSIF NOT F_SucceededHr(SUPER^.Init(), Init) THEN
RETURN;
END_IF
13. Create a similarly named variable in the HMI class where the value can be cached.
FUNCTION_BLOCK FB_CustomAxisHmi EXTENDS FB_AxisHmi IMPLEMENTS I_CustomAxisHmi
VAR
fNewHmiProperty: LREAL;
END_VAR
14. Add the 'TcHmiSymbol.Hide' attribute to the declaration so that the variable is not seen by the HMI.
This ensures that the variable is not mistakenly used by the HMI instead of the property. If you set the
ADS mapping in the HMI to Use whitelisting, you can basically hide all variables. To continue showing
the HMI classes, you must add the {attribute 'TcHmiSymbol.ShowRecursively'} to the declaration.
FUNCTION_BLOCK FB_CustomAxisHmi EXTENDS FB_AxisHmi IMPLEMENTS I_CustomAxisHmi
VAR
{attribute 'TcHmiSymbol.Hide'}
fNewHmiProperty: LREAL;
END_VAR
15. Implement the property write and read operation in the Get and Set method.
ð You have successfully added a property.
3. In the Init() method, perform a __QUERYINTERFACE() operation from the base interface passed to the
last interface instantiated.
Init := F_HresultFailure(E_AdsErr.DEVICE_NOTINIT);
Init := F_HresultSuccess(NOERR);
4. [If inheriting from FB_BaseHmi] Implement the call to the HMI-Init() in the Init() method of the base
class.
Init:=F_HresultFailure(E_AdsErr.DEVICE_NOTINIT);
IF iCustomAxisHmi = 0 THEN
RETURN;
ELSIF NOT F_SucceededHr(iCustomAxisHmi.Init(THIS^), Init) THEN
RETURN;
ELSIF NOT F_SucceededHr(SUPER^.Init(), Init) THEN
RETURN;
END_IF
8. Program the access to the property of the interface in the Get (and if necessary Set) method of the
property.
IF iCustomAxis <> 0 THEN
SecondNewHmiProperty := iCustomAxis.ExistingValue;
END_IF
9. For further properties with reference access, steps 1 to 4 are omitted accordingly.
ð You have successfully added a property with reference access to the main class.
7.1.3 Axes
fbCarriageHmi: FB_CarriageHmi;
END_VAR
2. Create/link an NC axis in the project to the created instance of the fbCarriage axis.
If the TF8560 axes from the PLC do not appear in the selection dialog, the project has not been
created. Only once the PLC project has been successfully created after the instance has been
created, the instances become visible in the mapping.
3. It is recommended that you create a PLC task with the same cycle time of the NC (default 2 ms) for the
drive control part (if an axis does not already exist).
If you do not want to work with FB_BaseRuntime, the following further steps are necessary:
6. Assign the HMI interface to the specific axis.
Axes.fbCarriage.SetHMI(Axes.fbCarriageHmi);
7. Initialize the axis with a single call to the Init() method and check the return values.
IF NOT bInit THEN
bInit := TRUE;
Axes.fbCarriage.SetAxisRef(Axes.fbCarriageAxis);
Axes.fbCarriage.SetHMI(Axes.fbCarriageHmi);
hr := Axes.fbCarriage.Init();
bInitFailed := FAILED(hr);
END_IF
8. After successful initialization, call the CoreCyclic() method of the axis with a fast task.
IF NOT PRG_AxisApplication.bInitFailed THEN
Axes.fbCarriage.CoreCyclic();
END_IF
9. In parallel with the CoreCyclic() method, call the Cyclic() method in a slower task and initialize the
default parameterization using the ParamInit() method.
VAR
bInit: BOOL;
bInitFailed: BOOL;
bParamInit: BOOL;
hr: HRESULT;
END_VAR
Axes.fbCarriage.SetAxisRef(Axes.fbCarriageAxis);
Axes.fbCarriage.SetHMI(Axes.fbCarriageHmi);
hr := Axes.fbCarriage.Init();
bInitFailed := FAILED(hr);
Axes.fbCarriage.Cyclic();
END_IF
fbClampHmi: FB_ClampHmi;
END_VAR
2. Create/link two NC axes in the project for the drive and load sides of the created instance of the
fbClamp axis.
If the TF8560 axes from the PLC do not appear in the selection dialog, the project has not been
created. Only once the PLC project has been successfully created after the instance has been
created, the instances become visible in the mapping.
// Assign geometries
fbTableGen.BaseDistance := 672.0; // [mm]
fbTableGen.DriveArm := 228.0; // [mm]
fbTableGen.LoadArm := 325.2; // [mm]
fbTableGen.ToolArm_1 := 602.52; // [mm]
fbTableGen.ToolArm_2 := 455.4; // [mm]
fbTableGen.ToolArm_3 := 114.0; // [mm]
fbTableGen.ToolArm_Angle := 216.0; // [mm]
fbTableGen.ToolOffset := 288.0; // [mm]
fbTableGen.DriveLowEnd := 0.0; // [°]
fbTableGen.DriveHighEnd := 180.0; // [°]
If you do not want to work with FB_BaseRuntime, the following further steps are necessary:
10. Assign the HMI interface to the specific axis.
Axes.fbClamp.SetHMI(Axes.fbClampHmi);
11. Initialize the axis with a single call to the Init() method and check the return value.
IF NOT bInit THEN
bInit := TRUE;
Axes.fbClamp.SetAxisRef(Axes.fbClampAxis);
Axes.fbClamp.SetHMI(Axes.fbClampHmi);
hr := Axes.fbClamp.Init();
bInitFailed := FAILED(hr);
END_IF
12. After successful initialization, call the CoreCyclic() method of the axis with a fast task.
IF NOT PRG_AxisApplication.bInitFailed THEN
Axes.fbClamp.CoreCyclic();
END_IF
13. In parallel with the CoreCyclic() method, call the Cyclic() method in a slower task and initialize the
default parameterization using the ParamInit() method.
VAR
bInit: BOOL;
bInitFailed: BOOL;
bParamInit: BOOL;
hr: HRESULT;
fbTableGen: FB_TableGeneratorClampStandard_1;
END_VAR
Axes.fbClamp.SetAxisRef(Axes.fbClampAxis);
Axes.fbClamp.Specific.Trafo.TableGenerator := fbTableGen;
Axes.fbClamp.SetHMI(Axes.fbClampHmi);
hr := Axes.fbClamp.Init();
bInitFailed := FAILED(hr);
hr := DefineTable();
bParamInit := SUCCEEDED(hr);
hr := Axes.fbClamp.ParamInit();
bParamInit := bParamInit AND SUCCEEDED(hr);
END_IF
Axes.fbClamp.Cyclic();
END_IF
2. Instantiate the FB_ManualXyz manual function in the class of the axis. This is not necessary for the
manual function of the forward/backward movement, since this is already instantiated by the
FB_Carriage class.
FUNCTION_BLOCK FB_CustomCarriage EXTENDS FB_Carriage
VAR
fbManualPower: FB_ManualPower;
END_VAR
3. The FB_CarriageHmi class used here already provides an HMI interface for both manual functions. For
more manual functions, you need to extend the class with respective instances of the
FB_ManualFunctionHmi class.
4. Afterwards, the newly instantiated manual function must be initialized. For convenience, you can use the
F_SucceededHr() function to check the return value of the initialization function for success and copy it
to a local variable.
METHOD Init : HRESULT
Init := SUPER^.Init();
5. To process the inner algorithms of the manual functions, you must call the respective cycle methods in
Cyclic().
METHOD Cyclic
fbManualPower.Cyclic();
fbManualForBack.Cyclic();
6. In the same method you can additionally define when the manual function should be activated for use
and/or which method is called by the manual function.
fbManualPower.Enable := bManualMode OR bSetupMode OR bAutomaticMode;
fbManualPower.Cyclic();
IF bSetupMode THEN
IF fbManualForBack.TrigCmdWorkPos.RQ THEN
JogNegative(TRUE);
ELSIF fbManualForBack.TrigCmdWorkPos.FQ THEN
JogNegative(FALSE);
ELSIF fbManualForBack.TrigCmdBasePos.Q THEN
JogPositive(fbManualForBack.TrigCmdBasePos.Q);
END_IF
ü For the sequence of steps described below, the use of the FB_BaseRuntime is assumed.
1. Start the PLC runtime.
2. Call the FB_BaseRuntime.MdSaveAll() method once.
3. Wait for the saving process to be completed.
Depending on the amount of data to be saved, the processing time may vary. In PLC online mode
the variable bMdSaveAll can be monitored to check the completion of the saving process.
ð You have successfully generated a first set of machine data
2. Create an instance of FB_Temperature and FB_TemperatureHmi and assign the mapping to the
newly created task.
{attribute 'qualified_only'}
VAR_GLOBAL
{attribute 'TcHmiSymbol.Hide'}
{attribute 'TcContextName':=‘TempTask‘}
fbTemperature: FB_Temperature;
END_IF
• Alternatively, you can also manually connect and initialize the objects. To do this, call the SetHMI()
and Init() methods of the FB_Temperature and check the return value for successful execution. If
this is the case, you can call the ParamInit() method for parameter initialization and the cycle
method.
VAR
bInit: BOOL;
bInitFailed: BOOL;
bParamInit: BOOL;
hr: HRESULT;
END_VAR
bParamInit := TRUE;
END_IF
END_IF
fbTempCtrl.Cyclic();
END_IF
After setting the number of zones, the project must be created successfully so that the mapping
is updated, otherwise the mapping will not have the set number of zones.
3. Link your digital outputs of the heating and cooling relays to the array .out_pfwTempCtrlOutput[].
Before the subsequent steps, the preparation of the TwinCAT project has to be done according to the
example from section Mapping and configuration of temperature zones [} 280].
Set the appropriate input and output signal types and devices for all their temperature zones
3. Repeat step 2 for all channels used. If necessary, use a FOR loop or the FB_Temperature
[} 72].CreateDefaultParams() [} 75] method to assign an identical parameter for multiple zones.
FOR i := 3 TO MIN(5, fbTemperatureHmi.CountPfwChannels) DO
fbTemperature.Channels(i).OutputSel_C := E_TcPfw_TctrlOutSelect.eTcPfwTcOut_PWM;
END_FOR
4. Execute the created code segment once.
5. Log on to the controller.
6. Save the parameters on your target device via fbTemperature.MachineData.Save.
4. Observe via the value ActualTemperature whether the temperature change occurs in the expected
zone.
Repeat step 2 to 4 for each zone.
fbManual1Hmi: FB_ManualFunctionHmi;
fbManual1: FB_ManualBaseWork;
fbManual2Hmi: FB_ManualFunctionHmi;
fbManual2: FB_ManualBaseWork;
END_VAR
4. Instantiate your class (here still FB_Sample).
5. Optional (if not already present): Also create instances of type FB_CP22xx_1025 [} 162] and
FB_CP22xx_1025Hmi for integration of the panel PC I/O.
VAR
fbSample: FB_Sample;
fbPanel: FB_CP22xx_1025;
fbPanelHmi: FB_CP22xx_1025Hmi;
END_VAR
6. Append the instance of FB_Sample to the runtime.
7. Optional (if not already present): Also append the instances of the panels to the runtime.
fbRuntime.Append(fbSample, 0);
fbRuntime.Append(fbPanel, fbPanelHmi);
8. Initialize manual functions (including those of the wheel) in the Init()-method of FB_Sample.
9. Then assign the class FB_Sample to the external implementation of the wheel manual function.
METHOD Init : HRESULT
F_SucceededHr(fbManualWheel.Init(fbPanel.Wheel), Init);
fbManualWheel.ExternalState := THIS^;
10. Insert the cycle call of the manual functions into a Cyclic()-method of FB_Sample.
11. Also specify when the manual function should be selectable.
METHOD Cyclic
fbManualWheel.Cyclic();
fbManual1.Cyclic();
fbManual2.Cyclic();
12. Add a new method called ExtAdaptSeq() to the class FB_Sample so that it can be called from
fbManualWheel.
METHOD ExtAdaptSeq
VAR_INPUT
bInit: BOOL; // TRUE, if the external states should insert themse
lf to iMaster
iMaster: I_AdaptableSeqMaster; // Interface on the state master
END_VAR
13. In this new method, define an initialization with the transfer of the manual functions that are to be
selectable from the wheel.
IF bInit THEN
fbManualWheel.AppendManual(fbManual1);
fbManualWheel.AppendManual(fbManual2);
ELSE
// Wheel control logic will be placed here
END_IF
14. Program the logic of your manual function.
The following sample implements a Jog command with control of the Override via the position of the
wheel.
METHOD ExtAdaptSeq
VAR_INPUT
bInit: BOOL; // TRUE, if the external states should insert thems
elf to iMaster
iMaster: I_AdaptableSeqMaster; // Interface on the state master
END_VAR
VAR
iqAxis: I_Axis;
fOverride: LREAL;
iSeq: I_AdaptableSeqItf;
END_VAR
VAR_INST
iqAxisLast: I_Axis;
fbTrigCmd: FB_Trigger;
END_VAR
IF bInit THEN
// ...
ELSE
// fetch selected manual function
IF fbManual1.State.IsActive THEN
iqAxis := fbAxis1;
iSeq := fbManual1.State;
ELSIF fbManual2.State.IsActive THEN
iqAxis := fbAxis2;
iSeq := fbManual2.State;
ELSE
iqAxis := 0;
END_IF
// on selecting a function
IF fbTrigCmd.RQ THEN
// setup wheel behaviour, see FB_CP22xx_Wheel [} 166]
fbPanel.Wheel.Leds.GuidingMid := 0;
fbPanel.Wheel.Leds.GuidingMidWindow := 1.0;
fbPanel.Wheel.Leds.GuidingMax := 100.0;
fbPanel.Wheel.Leds.GuidingMin := -100.0;
fbPanel.Wheel.Leds.FillMode := TRUE;
fbPanel.Wheel.Enc.LimitOverflow := TRUE;
fbPanel.Wheel.Enc.PositionScale := 2;
fbPanel.Wheel.Enc.SetZero();
fbPanelHmi.WheelClaimed := TRUE;
// on active usage
ELSIF fbTrigCmd.CLK THEN
// apply override
fOverride := LIMIT(-100.0, fbPanel.Wheel.Enc.Position, 100.0);
fbPanel.Wheel.Leds.GuidingValue := fOverride;
iqAxis.Axis.Power.Override := ABS(fOverride);
// determine direction
IF fOverride > 0 THEN
iqAxis.JogPositive(TRUE);
ELSIF fOverride < 0 THEN
iqAxis.JogNegative(TRUE);
ELSE
iqAxis.JogNegative(FALSE);
iqAxis.JogPositive(FALSE);
END_IF
fbPanelHmi.WheelClaimed := FALSE;
fbPanel.Wheel.Leds.FillMode := FALSE;
fbPanel.Wheel.Leds.GuidingValue := -1000;
END_IF
iqAxisLast := iqAxis;
END_IF
Before the subsequent steps, the preparation of the TwinCAT project has to be done according to the
example from section Mapping and configuration of temperature zones [} 280].
Set the appropriate input and output signal types and devices for all their temperature zones
1. Log in with administrator rights (default user = 4th administrator, password = 4).
2. Navigate via the navigation (≡-symbol) to Temperature > Grouping.
3. Group thermally connected zones into one group each (in the order shown in the following diagram).
1
2
4
5
1. Select the fourth tab (1) in the slider area and start tuning using the corresponding button (2) of the
group.
2. Execute step 1 for all groups to be commissioned.
1. As soon as the display element on the button is no longer yellow, the tuning is finished.
2. If the display element on the button is green, the tuning has been completed successfully.
For each required layout a single position in the ZoneImageLayoutConfigList array is needed
For this purpose it is recommended to create a dynamic array of this type. This is done in the TwinCAT HMI
configuration window:
1. Creation of the data type
2. Creation of a server symbol under the category TcHmiSrv of the corresponding data type
Using the server symbol in the configuration mode of the ZoneImageLayout control
1. Select ZoneImageLayout control in the Toolbox and drag it to a content.
2. Set Mode parameter under the category Configuration to Config.
3. For example, using a TcHmiCombobox control to configure the number of layouts available in LiveView
via the .onSelectionChanged event.
4. For this purpose, a new CASE can be created with the value 4 for the SelectedId parameter of the
combo box.
5. Copy and paste the CreateBinding function into the new CASE and select a different array location
such as ZoneImageLayoutConfigList[3] for the symbol transfer parameter.
ð Server symbol is used correctly in configuration mode.
3. The set width and height of the ZoneImageLayout control must be set in the server symbol
(LayoutHeight, LayoutHeightUnit, LayoutWidth and LayoutWidthUnit). To do this, right-click
on the server symbol in the TwinCAT HMI Configuration window and adjust the default value.
ð Server symbol is used correctly in display mode.
1. In the TwinCAT HMI configuration window under the All Symbols tab, right-click on the instance to be
mapped and click on Map Symbol.
The abbreviated symbol names shown in the following table are used in the Plastic Application HMI project:
• Emergency stop: Can be activated in an emergency to stop the machine and interrupt the current
flow.
• RFID (iDTRONIC): Can be integrated into the control, for example for user login.
• Button with LED (left): Used to start automatic mode (yellow flashing: homing is required, yellow:
during homing, green flashing: automatic mode can be started, green: automatic mode).
• Button with LED (center): Used to stop automatic mode (red flashing: during stop, red: is stopped).
• Button with LED (right): Can be used to acknowledge alarms (flashing blue: alarms are pending).
• Rotary encoder with LEDs: Can be used to manually move axes [} 202] and set the WTC curve
[} 249] (the individual green LED sections are controlled depending on the mode).
The function blocks FB_CP22xx_1025 [} 162] and FB_CP22xx_1025Hmi can be used to fully integrate the
industrial panel PC into the control system.
8 Appendix
8.1.1 F_TryDevide()
Function is 'obsolete'
This function is marked as obsolete and should not be used anymore!
Original version:
Syntax:
FUNCTION F_TryDevide : HRESULT
VAR_INPUT
fNominator: LREAL;
fDenominator: LREAL;
refResult: REFERENCE TO LREAL;
END_VAR
Inputs
Outputs
Requirements
8.1.2 FB_TrafoTableGenerator
Class is 'obsolete'
This class is marked as obsolete and should not be used anymore!
Original version:
Represents the base class for generation algorithms of transformation cam plates.
Class is abstract
Since the class is defined as ABSTRACT, the class cannot be instantiated and must be implemented
using inheritance.
Syntax:
FUNCTION_BLOCK ABSTRACT FB_TrafoTableGenerator
Properties
Methods
Name Description
CalculateScope() Calculates the diagnostic values of the Scope property.
DefineTable() Starts the calculation of the transformation table.
ReadFromParamList() Reads parameters from the list of special parameters.
WriteToParamList() Writes local variables to the list of special parameters.
Interfaces
Type Description
I_TrafoTableGenerator Standard interface on FB_TrafoTableGenerator
Requirements
8.1.2.1 FB_TrafoScope
Class is 'obsolete'
This class is marked as obsolete and should not be used anymore!
Original version:
Syntax:
FUNCTION_BLOCK FB_TrafoScope
Properties
Interfaces
Type Description
I_TrafoScope Standard interface on FB_TrafoScope
Requirements
8.1.2.2 FB_TableGeneratorClampStandard_1
Class is 'obsolete'
This class is marked as obsolete and should not be used anymore!
Original version:
Syntax:
FUNCTION_BLOCK FB_TableGeneratorClampStandard_1 EXTENDS FB_TrafoTableGenerator
Properties
Requirements
8.1.2.3 FB_TableGeneratorCrankStandard
Class is 'obsolete'
This class is marked as obsolete and should not be used anymore!
Original version:
Constructive assumption
The calculation assumes that the motion axis of the load side is in alignment with the center of
rotation of the drive side. This is indicated in the sketch by the horizontal dashed line!
Syntax:
FUNCTION_BLOCK FB_TableGeneratorCrankStandard EXTENDS FB_TrafoTableGenerator
Properties
Requirements
8.1.2.4 FB_TableGeneratorScotchYoke
Class is 'obsolete'
This class is marked as obsolete and should not be used anymore!
Original version:
Syntax:
FUNCTION_BLOCK FB_TableGeneratorScotchYoke EXTENDS FB_TrafoTableGenerator
Properties
Requirements
8.1.3 FB_MonitoringZone
Class is 'obsolete'
This class is marked as obsolete and should not be used anymore!
Original version:
Implements monitoring of a temperature zone with direct connection to TF8540. The adjustable limits are
synchronized with the temperature zone.
Syntax:
FUNCTION_BLOCK FB_MonitoringZone EXTENDS FB_Monitoring
Properties
Methods
Name Description
SetTempZone() Sets the temperature zone to be monitored
Interfaces
Type Description
I_MonitoringZone Standard interface on FB_MonitoringZone
Requirements
8.1.4 FB_TempCtrl
Class is 'obsolete'
This class is marked as obsolete and should not be used anymore!
Original version:
Main class of temperature control to manage all temperature zones and groups.
Syntax:
FUNCTION_BLOCK FB_TempCtrl EXTENDS FB_BaseMd
Properties
Methods
Name Description
CreateDefaultParams() [} 308] Creates a default parameterization for all temperature zones.
EnableAll() [} 309] Enables all temperature zones on the PLC side.
LinkGroup() [} 309] Assigns a linear arrangement of zones to a group.
LinkSupply() [} 310] Assigns a group to a supply unit.
LinkZone() [} 311] Assigns a zone to a group.
SetOpMode() [} 311] Configures the current operation mode.
SetScheduler() Assigns a schedule to the temperature control.
StandbyAll() [} 312] Sets all zones to standby.
UnlinkGroup() Removes all links to a group.
Interfaces
Type Description
I_TempCtrl Standard interface on FB_TempCtrl
I_TempCtrlMdRef Interface for the transfer of zone machine data
I_TempTaskInterface Runtime interface for a slow PLC task
Requirements
8.1.4.1 CreateDefaultParams()
Syntax:
METHOD CreateDefaultParams : HRESULT
VAR_INPUT
bAllInUse: BOOL;
eSensor: E_TcPfw_TempSensType;
eTerminal: E_TcPfw_TerminalType;
nChPerTerm: INT;
eOutHeating: E_TcPfw_TctrlOutSelect;
eOutCooling: E_TcPfw_TctrlOutSelect;
fSetpoint: LREAL;
fStandbySetp: LREAL;
fPwmCycleTime: LREAL;
END_VAR
Inputs
Outputs
Requirements
8.1.4.2 EnableAll()
Syntax:
METHOD EnableAll
VAR_INPUT
bCmd: BOOL;
bGroups: BOOL;
END_VAR
Inputs
Outputs
Requirements
8.1.4.3 LinkGroup()
Syntax:
METHOD LinkGroup : HRESULT
VAR_INPUT
nStartIdx: INT;
nEndIdx: INT;
nGroupIdx: INT;
bOverwrite: BOOL;
END_VAR
Inputs
Outputs
Requirements
8.1.4.4 LinkSupply()
Syntax:
METHOD LinkSupply : HRESULT
VAR_INPUT
nGroupIdx: INT;
nSupplyIdx: INT;
END_VAR
Inputs
Outputs
Requirements
8.1.4.5 LinkZone()
Syntax:
METHOD LinkZone : HRESULT
VAR_INPUT
nLinearIdx: INT;
nGroupIdx: INT;
nGroupMemberIdx: INT;
bOverwrite: BOOL;
END_VAR
Inputs
Outputs
Requirements
8.1.4.6 SetOpMode()
Syntax:
METHOD SetOpMode : HRESULT
VAR_INPUT
OpMode: INT;
END_VAR
Inputs
Outputs
Requirements
8.1.4.7 StandbyAll()
Syntax:
METHOD StandbyAll : HRESULT
VAR_INPUT
bCmd: BOOL;
bGroups: BOOL;
END_VAR
Inputs
Outputs
Requirements
8.1.5 FB_TempCtrlHmi
Class is 'obsolete'
This class is marked as obsolete and should not be used anymore!
Original version:
Syntax:
FUNCTION_BLOCK FB_TempCtrlHmi EXTENDS FB_BaseMdHmi
Properties
Interfaces
Type Description
I_TempCtrlHmi Standard interface on FB_TempCtrlHmi
Requirements
8.1.6 FB_TempGroup
Class is 'obsolete'
This class is marked as obsolete and should not be used anymore!
Original version:
Syntax:
FUNCTION_BLOCK FB_TempGroup EXTENDS FB_Base
Properties
Methods
Name Description
Enable() Enables all zones of the group on the PLC side.
Force() Forces all zones of the group to heating/cooling 100%.
Interfaces
Type Description
I_TempGroup Standard interface on FB_TempGroup
Requirements
8.1.7 FB_TempGroupHmi
Class is 'obsolete'
This class is marked as obsolete and should not be used anymore!
Original version:
Syntax:
FUNCTION_BLOCK FB_TempGroupHmi EXTENDS FB_BaseMdHmi
Properties
Methods
Name Description
SetZoneData() [INTERNAL] Connects the temperature zones of a group with the
machine data.
Interfaces
Type Description
I_TempGroupHmi Standard interface on FB_TempGroupHmi
Requirements
8.1.8 FB_TempGroupOpModeHmi
Class is 'obsolete'
This class is marked as obsolete and should not be used anymore!
Original version:
Class for controlling the temperature operation mode (in FB_TempCtrl OpMode "Standard").
Syntax:
FUNCTION_BLOCK FB_TempGroupOpModeHmi
Properties
Requirements
8.1.9 FB_TempZone
Class is 'obsolete'
This class is marked as obsolete and should not be used anymore!
Original version:
Syntax:
FUNCTION_BLOCK FB_TempZone EXTENDS FB_Base
Properties
Interfaces
Type Description
I_TempZone Standard interface on FB_TempZone
Requirements
8.1.10 FB_TempZoneHmi
Class is 'obsolete'
This class is marked as obsolete and should not be used anymore!
Original version:
Syntax:
FUNCTION_BLOCK FB_TempZoneHmi
Properties
Requirements
8.1.11 FB_AxisSpecific
Class is 'obsolete'
This class is marked as obsolete and should not be used anymore!
Original version:
Syntax:
FUNCTION_BLOCK FB_AxisSpecific EXTENDS FB_Base
Properties
Interfaces
Type Description
I_AxisSpecific Standard interface on FB_AxisSpecific
Requirements
8.1.12 FB_WtcTimeMaster
Class is 'obsolete'
This class is marked as obsolete and should not be used anymore!
Original version:
Syntax:
FUNCTION_BLOCK FB_WtcTimeMaster EXTENDS FB_Base
Properties
Methods
Name Description
ProfileStartAck() Resets the "ProfileStarted" feedback signal.
Start() Starts the timer.
Interfaces
Type Description
I_WtcTimeMaster Standard interface on FB_WtcTimeMaster
Type Description
I_WtcMaster General interface of a WTC master axis
Requirements
8.1.13 FB_WtcAccuMaster
Class is 'obsolete'
This class is marked as obsolete and should not be used anymore!
Original version:
Syntax:
FUNCTION_BLOCK FB_WtcAccuMaster EXTENDS FB_Axis
Properties
Methods
Name Description
Filling() Starts the filling process of the accumulator.
Pushout() Starts the pushing-out the filling volume.
Interfaces
Type Description
I_WtcAccuMaster Standard interface on FB_WtcAccuMaster
I_WtcMaster General interface of a WTC master axis
Requirements
8.1.14 FB_ManualPtp
Class is 'obsolete'
This class is marked as obsolete and should not be used anymore!
Original version:
Syntax:
FUNCTION_BLOCK FB_ManualPtp EXTENDS FB_Base
Properties
Methods
Name Description
Cyclic() Cycle method
SetWorkBasePos() Sets the base and working position for indication on the HMI
Interfaces
Type Description
I_ManualFunction Universal interface to a manual function
Requirements
8.1.15 PlasticStatusHmi
Function is 'obsolete'
This function is marked as obsolete and should not be used anymore!
Original version:
Status variable for linking to an HMI StateIndicator. This variable is interpreted bit by bit.
Syntax:
TYPE PlasticStatusHmi : BYTE; END_TYPE
Values
bit Description
0 Successful (Green)
1 Warning (Orange)
2 Error (Red)
3 Reserved
4 Reserved
5 Reserved
6 Reserved
7 State is invalid
Requirements