Creating and Editing .CGM Files

To display the configuration manager:

Utilities -> System Configuration -> Select an Application

To edit the current configuration and/or a CGM file, highlight the file name in the left scrolling window and click on Edit and that file will be displayed in the CGM Editor.

To edit only a CGM file, select the file in the right scrolling window and click on Edit.

To create a new file, click on Create CGM File and a new, empty file will be displayed in the CGM Editor.

CGM Editor Options

A CGM file is composed of sections (marked by square brackets []) and entries under each section.

1

This area shows the name of the plug-in being edited, the CGM file name, the author and the version of the CGM file.

2

This area shows the contents of the CGM file. You edit this file using the options described below in items 3 - 8. The possible sections are described in CGM Editor Sections.

3

This is the editing area. You make new entries and edit existing entries in this area. Double clicking on a entry will display an editing page that will ask you for specific items needed for an entry and then build the entry for you.

4

The edit an existing entry in the CGM file, highlight the entry you want to edit and then click on the Edit button. The contents of the entry will be shown in item 3 for editing.

5

To add a new entry above the currently highlighted entry, click on this button. A new entry will be added.

6

To append a new entry to the bottom of the currently highlighted section, click on this button. A new entry will be added.

7

The remove an entry from the CGM file, highlight the entry and then click on this button.

8

To add a new section to the CGM file, click on this button. The following window will be displayed and you can select from the sections described in CGM Editor Sections.

9 When a CGM file is processed, all the entries in the file are read into the configuration database. When AIM is initialized the options are read from this database and all specified plug-ins are loaded to memory and initialized. Save to Database saves the items to the configuration database but does not update a CGM file. Save to file updates the CGM file but does not add the items to the configuration database. Done Save to Database saves the items to the configuration database and closes the CGM editor. Close closes the CGM editor without saving any changes.

CGM Editor Sections

The following table describes the various options the configuration manager has for incorporating your custom plug-in module into the AIM system.

Table 11-2. Custom Module Options
Option
Description
CGM Section
CGM type
The valid entries are; APPLICATION which creates a new AIM application, SYSTEM which defines AIM system options or PLUGIN which defines a plug-in file.
[TYPE]
Plug-in module name
This CGM section adds the name of the custom plug-in to the window displayed when the user selects Help -> System ID
[NAME]
Initialization string
This CGM sections specifies a string that will be displayed on the AIM initialization window during AIM start-up.
[DESCRIPTION]
Validation criteria
This CGM section specifies a V+ instruction to execute that will verify that conditions necessary for use of the plug-in have been met (e.g., the system has a vision system for options that require vision).
[VALIDATE]
Copy files during plug-in installation
This section contains the names of the files to be copied from the source to the destination drive when a user installs a plug-in using the Plu-in Manager.
[COPY]
Load a V+ file
Specify a V+ file to load and, optionally, a program to execute.
[LOAD]
Initialize an AIM database
Set up a database for use as either a disk-resident or run-time database.
[DATABASE]
Process a SYSTEM file
Specify a SYSTEM CGM file to be processed.
[SYSTEM]
Process a PLUGIN file
Specify a PLUGIN CGM file to be processed.
[PLUGIN]
Load an overlay file
Specify an overlay (.OVR) file to be loaded and, optionally, a program to be executed.
[OVERLAY]
Define a servoed device used by the system
This CM section specifies a device name for use by tasks that will control servoed devices.
[DEVICE]
Initialize additional AIM runtime or background tasks
The CGM section specifies a task name, task ID and V+ task number for a new AIM task. It also allows you to specify task priorities, any devices associated with the task, and whether the task is a runtime task.
[TASK]
Initialize V+ variables
Assign values to a V+ global variable or execute a DOS program instruction.
[SET VARIABLE]
Load a program file and optionally CALL a V+ program
Specify a program and its calling arguments. This program will be executed during initialization.
[PROGRAM}
Add a pulldown menu item
Specify a pulldown menu group, list and item and the action to take when the pulldown item is selected.
[MENU]
Set a global variable to indicate success/failure of the module initialization
Specify a V+ global variable that will be set to TRUE if all sections of the CGM file complete successfully, otherwise it will be set to FALSE. If a VALIDATE section returns failure, this variable will be set to FALSE.
[OPTION SET]
Process and initialization database
Specify an initialization database that will be processed during startup.
[LOAD INIT]
Load an icon file
Specify an icon file to be loaded during initialization.
[ICON]