Build and Test a
Service Interface Function Block Type
- Start the FBDK.
- Import library elements if and as
needed.
- Create a new Service Interface FB (SIFB) type in the editor
by double-clicking on the ServiceInterface
fb type of the
template
folder in the Library Navigator.
- Edit the function block's elements:
- When your editing is complete, save your work with the Save As... button.
It is a good idea to save
your work from time to time while editing, too!
- Generate and compile a Java® source file with the Save As... button.
Compiled code will run but do
nothing useful.
- Use a text editor or Integrated Development Environment (IDE)
such as Eclipse to fill in the
skeleton
service_XXX(...)
methods in the generated .java
file, including any additional instance variables, supporting
methods, etc., as required.
Don't
forget to set the QO.value field as appropriate and invoke
the serviceEvent(this) method on the appropriate event
output, e.g., INITO.serviceEvent(this) when leaving the service_INIT(...)
method.
- Generate a
.class
file with an appropriate
compiler.
- Test the FB type.
Last updated: 2014-10-21.
©2011,2014 Holobloc Inc.
Licensed under the Academic
Free License version 3.0.
Java
is a registered trademark of Oracle Corporation and/or its
affiliates.