Building and Testing Data Types

  1. Start the FBEditor.
  2. Create a new data type in the editor by:
    • Clicking the New... => Data Type => XXXX menu item, where XXXX is the kind of IEC 61131-3 derived data type that you wish to create; possible values are Array, Direct, Enumerated, Structured and Subrange; or
    • Opening a file containing an existing data type of the desired subtype; for instance, in the src\ita folder, the ANALOG_16_INPUT_DATAI, FREQ, ANALOG_SIGNAL_TYPE, ANALOG_CHANNEL_CONFIGURATION and ANALOG_DATA types corrrespond to the Array, Direct, Enumerated, Structured and Subrange subtypes, respectively.
  3. Edit the data type's elements:
    • Edit the data type's properties. 
    • Edit the data type elements in the XML area.
      • You can edit elements of a structured data type graphically in the same manner as input variables of a function block type.
    • From time to time as you are editing, use the File Parse menu item or its equivalent Alt+S keychord to check the syntax and update the graphical display. Syntax errors are displayed in the status line under the menu bar and the offending line of code is (usually) highlighted in the Text window.
  4. 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!
  5. Generate and compile a Java® source file with the Save As... button.
  6. Since data types are not event-triggered elements like function blocks, they cannot be tested directly using the Run=>Launch menu item. However, they can be tested by launching appropriate HMI Elements.
Last updated: 2011-02-12.
©2011 Holobloc Inc.
Licensed under the Academic Free License version 3.0.
Java is a registered trademark of Oracle Corporation and/or its affiliates.