Grouped Blocks and Library Functionality

Any set of blocks can be consolidated into a single grouped block. In addition to the ease of replication and enabling a "cleaner" canvas, grouping a set of blocks allows the user to virtualize or save the group to a library for future use.

Creating a grouped block

To create a grouped block:

  1. Select the blocks you want to add to the group.

  2. Right-click on any of the selected blocks and select Group from the context menu.

    The selected blocks are consolidated into a single block with ports for each of the connected inputs.

From the grouped block context menu, you can access the following options:

  • Ungroup to restore the internal algo blocks to the parent algo.

  • Virtualize to allow new copies of the grouped block to be created every time a discrete event message enters the virtualized group block. See Rules of Virtualization for more information.

  • Show internal algo to show the grouped block's internal algo in the ADL canvas.

  • Add/Save to Library to store and quickly reproduce a set of blocks. You can save the grouped block to an existing library or create a new library.

  • Add Input Connector, Add Output Connector to attach extra ports providing additional input values to and output values from the grouped block for the following data types:

    • Boolean
    • Numeric
    • Instrument
    • Discrete message

Opening a grouped block

To open a grouped block, do either of the following:

  • Double-click the grouped block.
  • Select Show internal algo from the grouped block's context menu.

The ADL canvas replaces the parent algo with the contents of the grouped block, as shown:

Use the icons located at the top portion of the Designer canvas to navigate back to the root or parent algo.

Adding input and output ports to a grouped block

You can add ports to a grouped block directly to the block or add them to the internal algo within the grouped block.

To add ports to a grouped block:

  1. Right-click on the block and navigate to the type of connector and value type to pass through the port.

    The new port is added to the grouped block.

  2. Double-click the grouped block to open it; then connect the new block in the internal algo.

To add ports to a grouped block from within the block:

  1. Double-click the group block to open it.

  2. Anywhere on the ADL canvas (not on a block or edge), right-click to display the context menu; then select the type of connector and value type.

  3. Connect the new port to a block, if desired.

  4. Return to the parent algo to see the new port on the block.

Managing a library of grouped blocks

ADL enables you to create your own libraries of custom grouped blocks that you can reuse when creating other algos.

To add a grouped block to a library:

  1. From the grouped block context menu, select Add/Save to Library, the select either New or the name of an existing library.

    For a new library, the following dialog appears.

  2. Enter a name for the library and an optional description, if desired. Then click Save.

To load a library of grouped blocks:

  1. Anywhere on the ADL canvas (not on a block or edge), right-click to display the context menu.

  2. Select Load Block Library.

  3. Click the upload icon for the library you want to load.