Sepasoft MES Module Suite
This example chart contains an Enclosing Chart block with an enclosed chart. As shown below, a single data value is passed in from an Ignition Button script, passed into the enclosed chart, doubled, then passed back out to the main chart and back to the button script, demonstrating how parameters values can be passed to/from a chart and to/from an enclosed chart.

Chart Hierarchy
The chart, Main Chart, contains an Enclosing Chart Block, which 'encloses' the chart Enclosed Chart:
The enclosed chart, Enclosed Chart, contains a Script Block, which reads the value of the Chart Parameter enclosed_in, multiplies it by 2, then writes the result to enclosed_out.
Start Block - Main Chart
The Start Block in Main Chart has two Chart Parameters defined (type Integer):
Start Block - Enclosed Chart
The Start Block in Enclosed Chart also has two Chart Parameters defined (type Integer):
Mapping
The Input tab maps what parameters from the 'parent' chart will get passed down into the selected enclosed chart. In this example, the Chart Parameter main_in in Main Chart is mapped to the Chart Parameter enclosed_in in Enclosed Chart. When execution control is about to pass 'into' the Enclosing Chart Block, the current value of main_in will first get passed into enclosed_in in Enclosed Chart:
The Output tab maps what parameters from the enclosed chart will get passed back up to the 'parent' chart. In this example, the Chart Parameter enclosed_out in Enclosed Chart is mapped to the Chart Parameter main_out in Main Chart. When execution control is about to pass back up to the chart Main Chart, the current value of enclosed_out will first get passed into main_out in Main Chart:
Button Script
A simple script is written to the actionPerformed event handler of the 'Multiply by 2' button, which reads a user-input value from the Text Field component and passes it into Main Chart , waits for the Python dictionary, r, to be returned, retrieves the value for main_out from it and finally writes it to the LED Display component.

Sepasoft MES Module Suite