Blueprint Help Send comments on this topic.
Entering State and Workspace

Glossary Item Box

Overview

This section explains how integral data objects are associated with active objects (threads, methods and call-back functions) and circuits.  See Entering Harness Code and Process Code for examples of accessing state and workspace.

Adding Code

To specify a state or workspace object you must perform the following steps:

(When the circuit is translated a number of header files will be generated, two for state (for methods) and two for workspace (for each active object or circuit).  These files contain the basic class definitions and default functionality and can be edited in steps 1 and 2 below)

  1. Edit the <>Data.hpp file, by selecting State/Workspace Object Class from the Edit Code submenu for the object. This will open the file in the VS editor.  For most state/workspaces this step is not required (see State and workspace Objects for details of variable sized state/workspace objects).
  2. Edit the <>State.hpp or <>Workspace.hpp file, by selecting State/Workspace Data Class from the Edit Code submenu for the object. This will open the file in the VS editor.  This file is a standard C++ header file containing a stub for a data class.  This class can be edited as a normal C++ class header.  Users should add their own variables and access functions to this class (see State and Workspace for details of variable sized data objects).

The names of the files relate to their parent object name, its circuit name and its type ( eg. Cct1_FftMthdData.hpp, Cct1_FftMthdState.hpp ).

 

 

Examples

See State and Workspace Objects.