Anda di halaman 1dari 60

FOUNDATION fieldbus Control in the Field (FF/CIF)

Macrocycle Estimator
January 15, 2010
Invensys, Foxboro, I/A Series, and InFusion are registered trademarks of Invensys plc, its subsidiaries, and
affiliates.
All other brand names may be trademarks of their respective owners.

Copyright 2010 Invensys Systems, Inc.


All rights reserved

2
Introduction
The FF/CIF Macrocycle Estimator tool is a Windows application for estimating the FBM228
FOUNDATION fieldbus loading, including macrocycle usage, for both publisher/subscriber and
client/server access, and FBM228 resource usage.
Macrocycle estimation in FF/CIF is more involved than in FF without CIF. The main issue is the
effect of parallel execution of function blocks across multiple devices. Those parallel executions
can only be determined if the dependencies among the function blocks are known, that is, “How
are the FF blocks configured into loops?” An estimating tool could accept simple inputs like “# of
input points” and “# of output points”, or even “# of instances of each FF block type”, and try to
estimate a suitable macrocycle for “typical” loops for that set of inputs. But it would only be a
guess, and a wild guess at that. The other extreme is using the released IEE software to completely
configure a segment and get an exact answer. This tool's approach is to have the user do a greatly
simplified configuration of the “loops” in a data grid, with a row for each block. The tool supports
numerous predefined loop types for typical loop configurations to assist with data entry.
The word “estimate” is used loosely with respect to the scheduling of the loops. The tool supports
simplified configuration of a segment as close as possible to the final configuration, then calls the
Scheduler to get an exact schedule. The “estimating” is done by the user, who estimates:
♦ The configuration on a segment
♦ The client/server update periods (“fast” and “slow” are supported by the tool)
♦ The block execution times, if the exact times are not known.

How to Operate the Tool


The tool is implemented as a Microsoft Windows Form application with the following tab pages,
arranged, left to right, in the order that an engineer would typically use them. You can, however,
update the pages as you see fit, in any order, until clicking the “Estimate Schedule” button. When
schedule estimation is done, the tool displays the “Results” page with the results.

Table 1. Overview of Tool Pages

Page Description
Welcome Introduction to the tool with a Quick Start section
Project Info Information about customer, project, engineer and segment
Segment Settings Segment-level settings (for example, macrocycle, CD time, and so
forth)
Loops Data grid for entering loop, block and connection information, with
a row for each block.
Client/Server Settings Allocation of function blocks, resource/transducer blocks, and DCI
blocks to fast or slow update periods. Specify other client/server set-
tings.
Results Display of estimate status, any errors detected, and relevant metrics.

How to Estimate a Segment - Step by Step


The recommended way to enter data into the tool to estimate an initial segment is as follows.

3
1. Select File/New Segment to start a fresh segment or File/Open to start with an existing
xml file.
2. Periodically, save your work with File/Save As and File/Save.

NOTE
Upon a graceful exit, the tool automatically saves the data as of the last estimate (or
explicit save) to file McEstimator.xml.

3. Enter project information in the Project Info page. See “Project Info Page” on page 7.
4. Enter segment settings, in particular, Macrocycle Time, Percent Free Time, and
Requested Min Free Time, in Segment Settings page. See “Segment Settings Page” on
page 8.
5. Enter default block execution times in Edit/Default Block Execution Times dialog.
6. Enter loops in Loops page. See “Loops Page” on page 10.
7. Enter client/server information in Client/Server Info page. See “Client/Server Info
Page” on page 31.
8. Edit as needed on any page.
9. Request a schedule estimate. See “Estimate Schedule” on page 33.
10. Verify results in Results page. See “Results Page” on page 34
11. Repeat Steps 8 - 10 until satisfied.
12. File/Save to save data to XML file.
13. File/Print Preview to check the print output. In particular, you may want to adjust the
column widths of the Loops grid until desired output (that also fits on a page) is
achieved.
14. File/Print to print data to document the estimation in a more readable format.

Welcome Page
The Welcome page provides a starting point for a user who is new to the tool. It includes the tool
version number and a simple overview. See Figure 1.
To display a suggested step by step procedure, click Quick Start: Step by Step…. See
Figure 2.

4
Figure 1. Welcome Page

5
Figure 2. Quick Start Step by Step Procedure

6
Project Info Page
The Project Info page provides several text fields for documenting the segment. None of these
fields has any effect on the schedule. If the Date field is empty, the tool populates it with the cur-
rent date. See Figure 3.

Figure 3. Project Info Page

7
Segment Settings Page
The Segment Settings page provides several fields affecting the schedule. See Figure 4 and Table 2.

Figure 4. Segment Settings Page

Table 2. Segment Setting Descriptions

Segment Setting Description


Segment Name Name of segment. Tool creates Scheduler diagnostic dump
files in directory c:\SchedulerDump\<Segment Name>.
Macrocycle Time Required macrocycle time.
Valid range: 200 to 30000 milliseconds.
Percent Free Time Required minimum percent free time within the macrocycle.
Valid range: 10 to 90.

8
Table 2. Segment Setting Descriptions

Segment Setting Description


Compel Data Time Time for a compel data to be performed.
Valid range: 10 to 50 milliseconds.
Inter Block Gap Time When a device is executing multiple function blocks, the
Scheduler inserts this delay between successive function block
executions in the same device to provide a safety margin.
Valid range: 0 to 50 milliseconds.
Time Between Block and CD For a CD after the execution of a device function block, the
Scheduler inserts this pad time.
Valid range: 0 to 50 milliseconds.
Requested Min Free Time Minimum value for the largest contiguous free time slot.
Note that the FBM takes approximately 100 milliseconds of
free time to provide the capacity for at least a minimum level
of client/server communication.
Valid range: 40 to 200 milliseconds.
Output Compel Data Delay Delay between the beginning of the macrocycle and the first
FBM CD.
Valid range: 0 to 50 milliseconds.
Publish Internal Dev Connections If checked, connections between function blocks within the
same device will be published. If unchecked, such connec-
tions will NOT be published. Exceptions: MAI and MDI
outputs can be forced to be published by specifying those
connections in the “Published Outputs” column of the Loops
grid.
Back Zone If checked, the Scheduler will schedule the following at the
end of the macrocycle, that is, the “back zone”:
♦ Execution of input blocks that publish to the
CP.
♦ CD publications from said input blocks.
If unchecked, those block executions and CDs will be sched-
uled at the “front” of the macrocycle.

9
Loops Page
This section describes how to configure the loops that comprise the schedule.
You can add instances of predefined loop types, then optionally edit them in the grid.
You can also add loops from scratch by copy/paste, selecting various editing features, or by direct
entry in the grid cells.
“Loop Editing Features” on page 28 and “Loops Grid Column Descriptions” on page 25 give
details for various features and grid columns.

Key Concepts
This section describes a few concepts to help you better understand how the tool configures loop
data and why it works the way it does.

Input Parameter Names


To provide a schedule estimate, the Scheduler does not require the actual input parameter names.
Internally, the tool always specifies the input parameter name as “IN” by convention.

Published vs. Non Published Columns


The Scheduler determines which parameters get published on the bus based on its algorithm and
the data the tool passes to it. The tool provides Published and Non Published columns as an indi-
cation/documentation of how the loop will operate on the bus. For a forward output, such as the
OUT parameter of the AI block, you can enter the connection in either the Published Outputs or
Non Published Outputs column. For a backward, that is, feedback output, such as the
BKCAL_OUT parameter of the AO block, you can enter the connection in either the Published
Back Calcs or Non Published Back Calcs column. When you select the Validate Loops or Esti-
mate Schedule feature, the tool automatically positions all connections in the proper column
based on the Scheduler's rules for determining if a parameter gets published.

Outputs vs. Back Calcs


Outputs are forward-looking outputs, such as OUT, OUT_1, and so forth. Back Calcs are back-
ward-looking, that is, feedback outputs, such as BKCAL_OUT, BKCAL_OUT_D, and so forth.
The Scheduler treats such backward-looking outputs differently from forward-looking outputs,
hence the need for separate columns.

CP Block
On a real system, all blocks running in FF devices require a shadow block to be configured in the
CP for the FF block to be scheduled. In the tool, a block with a name starting with CP indicates a
block that is ONLY running in the CP (therefore, Block Exec Time must be zero) and has no
device associated with it (therefore, Device # must be zero). Connections to and from such CP
blocks are always published.

DCI Block
A DCI block is not an FF block, but rather, an I/A Series Distributed Control Interface block that
only runs in the Control Processor. DCI blocks include the following block types: RIN, ROUT,
BIN, BOUT, IIN, IOUT, STRIN, STROUT, PAKIN, and PAKOUT.
A DCI block can:
♦ Publish a parameter to an FF block in a device

10
♦ Subscribe to a parameter publication from an FF block in a device
♦ Read a parameter from an FF block in a device using client/server, or
♦ Write a parameter in an FF block in a device using client/server.
In the tool, any block with a block name starting with “CPDCI” is considered a DCI block for
resource checking purposes. DCI blocks are treated generically; that is, you never specify RIN,
ROUT, and so forth in this tool. As with other blocks, these blocks must have unique names
within the loop.
See Table 3, which includes a description of how the tool defines DCI block names and connec-
tions.

Possible vs. Useful


The tool imposes certain rules and restrictions on how fields are named, connected, and so forth
to suit its purpose as a schedule estimator. For example, you cannot connect an output parameter
to an input block (AI, DI, MAI or MDI). However, the tool does not have, and is not intended to
have, all the validation checks of a production level configurator. Use your process experience and
common sense when configuring loops with this tool.

Block Name Uniqueness and Length


In the Loops grid, the block names only need to be unique within a loop. For example, it is appro-
priate to have two blocks named AI, as long as they are not in the same loop. However, you can
append characters to the block names for descriptive purposes, if you wish. Use discretion when
creating long names; the Loops grid is documented (Print and Print Preview) in the same grid for-
mat that you see. Note that you can shrink (or expand) column widths to make more room for
the block name and connection columns.

Block Execution Order


The block execution order is as defined in the Loops grid. The tool does not support explicitly
changing the block execution order.

Editing Default Block Execution Times


To edit the default block execution times, do one of the following:
♦ Edit/Default Block Execution Times…
♦ Right-click on Loops grid and select Edit Default Block Execution Times…
Enter default block execution times in Default FB Execution Times dialog (Figure 5). You can
change these defaults multiple times. For example, specify one set of defaults, add predefined
loop(s), change the defaults, add more loop(s), and so forth. Changing the defaults only affects
the loop(s) added afterward. The defaults are only examined when a loop is added. After being
added, the block execution times can be edited individually in the grid.

11
Figure 5. Default FB Execution Times Dialog

Adding Predefined Loops


Select the Add Predefined Loop dialog (see Figure 6) using one of the following methods:
♦ Click the Add Predefined Loop… button
♦ Select Edit/Add Predefined Loop…
♦ Right-click in Loops grid and select Add Predefined Loop…
Figure 7 lists the loop types supported. See “Predefined Loop Type Diagrams” on page 50 for a
loop diagram and corresponding Loops grid screen capture for each loop type.
You can create multiple instances of a loop type, and have some control over how the device num-
bers are assigned. See Figure 8. If you uncheck Assign device #s, starting with device
#, the tool assigns the device number as “99”, which forces you to change it to a valid device num-
ber in the Loops grid. If checked, the tool assigns the device numbers to sequential numbers start-
ing with the highest device number assigned plus one.

12
Figure 6. Initial Add Predefined Loop Dialog

Figure 7. Predefined Loop Type Choices

Figure 8. Specifying Loop Count and Device Numbers

Indicator Loop - Single Point


To add an indicator loop with a single point, perform the following:
1. Select Add Predefined Loop dialog (Figure 6).
2. Select the Indicator Loop; i.e., Input to CP loop type (Figure 7).
3. Select the type of publishing FF block, for example, AI or DI. See Figure 9.

13
4. Select the # of loops and assign device numbers as previously described (Figure 8).
5. Click OK.

Figure 9. FF Block Publishes Input(s) Group - Single Input

Figure 10. Indicator Loop - Single Point - Loops Grid Rows

Indicator Loop - Multiple Points


To add an indicator loop with multiple points, do the following:
1. Select Add Predefined Loop dialog.
2. Select Indicator Loop; i.e., Input to CP loop type.
3. Select Publishing FF Block Type, for example, MAI or MDI as shown in Figure 11.
4. Choose the number of points to publish, from 0 to 8. The default is zero (0) to
encourage the use of the client/server to retrieve point data.
5. Select the # of loops and assign device numbers as previously described.
6. Click OK.

Figure 11. FF Block Publishes Input(s) Group - Multiple Inputs

Figure 12. Indicator Loop - Multiple Points - Loops Grid Rows

14
Manual Loader Loop - Single Point
To add a manual loader loop with a single point, perform the following:
1. Select Add Predefined Loop dialog.
2. Select Manual Loader; i.e., Output from CP loop type.
3. Select subscribing FF block type, for example, AO or DO. See Figure 13.
4. Select # loops and how to assign device numbers as previously described.
5. Click OK.

Figure 13. FBM Publishes Output(s) Group - Single Output

Figure 14. Manual Loader Loop - Single Point - Loops Grid Rows

Manual Loader Loop - Multiple Points


To add a manual loader loop with multiple points, do the following:
1. Select the Add Predefined Loop dialog.
2. Select Manual Loader; i.e., Output from CP loop type.
3. Select Subscribing FF Block Type, for example, “MAO” or “MDO”. See Figure 15.
4. Choose the number of points, from 1 to 8.
5. Select # loops and how to assign device numbers as previously described.
6. Click OK.

Figure 15. FBM Publishes Output(s) Group - Multiple Outputs

15
Figure 16. Manual Loader Loop - Multiple Points - Loops Grid Rows

Control in Host Loop


Use this loop type when you have input(s) from the field being published to the CP, block(s) run-
ning in the CP, then output(s) being published back to the field. A typical example is an FF AI
block to a PIDA block in the CP270 to an FF AO block.
To add a Control in Host loop, do the following:
1. Select Add Predefined Loop dialog.
2. Select Control in Host; e.g., Simple PID loop type.
3. Select publishing FF block type and subscribing FF block type. If MAI or MDI are
selected as publishing block type, also specify number of published points. If MAO or
MDO are selected as subscribing block type, also specify number of used points. See
Figure 17.
4. Select # loops and how to assign device numbers as previously described.
5. Click OK.

Figure 17. Block Type Choices for the Control in Host Loop

Figure 18. Control In Host Loop - Loops Grid Rows

16
Other Loop Types - Block Types are Fixed
For predefined loop types other than Indicator Loop, Manual Loader, and Control in Host, the
block types are fixed. See “Predefined Loop Type Diagrams” on page 50 for more details.
To add an instance of one of the other predefined loop types, do the following:
1. Select Add Predefined Loop dialog.
2. Select the desired loop type; for example, Simple PID with Control in Field.
3. Select # loops and how to assign device numbers as previously described.
4. Click OK.

Figure 19. Loop Type with Fixed Block Types

Editing Predefined Loops After Being Added


After adding a predefined loop to the grid, you can edit it if needed. Once a predefined loop has
been added to the grid, it is just rows and columns of text that can be changed as needed. For
more detail, see Table 3, Table , and “Adding Loops From Scratch” on page 17 for step by step
examples of loop editing features.

Adding Loops From Scratch


This section provides step by step examples of how to:
♦ Create a loop in the Loops grid from scratch; for example, a simple PID with all
blocks in the field.
♦ Copy/paste to create a second similar simple PID.
♦ Insert a loop at the beginning, for example, a simple PID but with the control in the
host, renumbering subsequent loop numbers.
♦ Validate loop data and adjust connection placement in the proper pub/non-pub
column.

17
Refer to the figure headings and notes below to follow these examples.

Figure 20. PID From Scratch: Empty Loops Grid

Figure 21. PID From Scratch: Typing (e.g., '1') in Loop # Gives New Row

Tip: Enter Block Names before defining the connections (last 4 columns) so you can take advantage of the tool’s “Auto Complete”
feature.
Note 1: The Block Name must start with the FF block type or 'CP', if block only resides in the CP.
Note 2: In the Loops grid, the Block Name only needs to be unique within the loop. Internally, the tool prefixes the block name with
“L<loop number>_" to make the block names unique within the segment, a requirement of the Scheduler.

Figure 22. PID From Scratch: Enter Device #, Block Exec Time and Block Name for AI

Figure 23. PID From Scratch: Select Row to Enable 'Append Row', etc. Buttons

18
Note: Insert Row works the same, except the row is added before the selected row, instead of after it.

Figure 24. PID From Scratch: Click 'Append Row' Twice to Add Two Rows to Loop

Figure 25. PID From Scratch: Add Device #, Block Exec Time and Block Name
for Other Two Blocks (PID and AO)

Note 1: Why the "O__" prefix?" By convention, the tool looks for an 'o' or 'O' as the first character of an output parameter name.
This allows the tool to present a complete list of all possible output connections, regardless of which letter the actual
FF output parameter name starts with. When the cell loses focus, the tool automatically strips off the "O__" prefix.

Note 2: Possible "Sink blocks": The "auto complete" feature allows a block's output parameter to be connected to any block
within the same loop except itself or an input block (AI, DI, MAI or MDI).

Figure 26. PID From Scratch: Type 'o' To Get AI Block's Possible Output Connections

19
Figure 27. PID From Scratch: Point Mouse to Highlight OUT Connection to PID

Note: Notice how the tool strips off the "O__" parameter name prefix when the cell loses focus.

Figure 28. PID From Scratch: Click AI's OUT Connection to PID

Figure 29. PID From Scratch: Click PID's OUT Connection to AO

Figure 30. PID From Scratch: Click AO's BKCAL_OUT Connection to PID

20
Figure 31. PID From Scratch: Cell Entry Complete

Note: Select the Copy feature with any of the following:


Hit <Ctrl/C> on the keyboard.
Select Edit/Copy.
Right-click on Loops grid and select Copy.

Figure 32. Copy/Paste Loop: Select All Rows in Loop and Select “Copy”

Note: Paste Operation: When the last row is selected, the pasted cells are appended to the end of the grid. When the selection
is within the grid, the pasted cells overwrite subsequent grid cells. If you want to "insert" pasted rows, first use "Insert Loop"
and/or "Insert Row" or "Append Row" to first make room for the pasted cells.

Figure 33. Copy/Paste Loop: Select Last Row

21
Note: Select the Paste feature with any of the following:
Hit <Ctrl/V> on the keyboard.
Select Edit/Paste.
Right-click on Loops grid and select Paste.

Figure 34. Copy/Paste Loop: Select “Paste”

Note: Notice that new loop's rows now have different Loop # and Device #.

Figure 35. Copy/Paste Loop: Update Loop # & Device # for New Loop's Rows

22
Figure 36. Insert Loop: Select Row, Enabling “Insert Loop”, etc.

Figure 37. Insert Loop: Select “Insert Loop”, Adding New Loop & Renumbering Others

23
Figure 38. Insert Loop: Select New Row and Click “Insert Row” Twice

Figure 39. Insert Loop: Add entries for “Control in Host” PID (Loop 1)

24
Table 3. Loops Grid Column Descriptions

Column Description
Left-most Clicking in this unlabeled column header selects all cells.
column The tool numbers cells in this column sequentially, for reference. If the tool detects
an error, it displays a red error icon in this column for the offending row(s). Hover
the mouse over the tooltip to view the error message.

Loop # 1, 2, 3, … All rows with the same loop number belong to the same loop. Rows with
even loop numbers are shaded to visually separate the loops. Loop numbers must
be either equal to, or greater than, preceding loop numbers.
Device # 0, 1 to 16. If the row's block only resides in the Control Processor, enter 0. Other-
wise, enter device number 1 to 16.
Block Exec 0, 1 to 1000. If the row's block only resides in the Control Processor, enter 0. Oth-
Time erwise, enter 1 to 1000.
Block Name “CP[DCI]<User text to make name unique within loop>” OR
“<FF block type>< User text to make name unique within loop >”.

If the row's block only resides in the Control Processor, the block name must start
with “CP”. Otherwise, the block name must start with a valid FF block type. Add
optional, additional characters as needed, to make the block name unique within
the loop.

DCI blocks that publish to an FF block or receive a publication from an FF block


must start with “CPDCI”. The FBM228 supports up to 32 such DCI blocks. This
“CPDCI” syntax allows the tool to check the number of DCI blocks used. The tool
uses the following convention for DCI block names that it creates when the User
selects “Add DCI Pub. Output” or “Add DCI Pub. Input”:
CPDCI<I|O>_<FF block name>_<n>

Where:
I is for input DCI blocks like RIN, BIN, and so forth
O is for output DCI blocks like ROUT, BOUT, and so forth
FF block name is the name of the block publishing to, or subscribing from, the
DCI block.
n is sequential number for uniqueness (1, 2, etc.)

NOTE: The tool prefixes block names, and references to block names, with
“L<loop#>_” before it passes them to the Scheduler, which does require block
names to be unique in the segment.

25
Table 3. Loops Grid Column Descriptions (Continued)

Column Description
Block Name Examples:
(Continued) “AI” - AI block - a good concise choice if only one AI block in the loop.
“AI1”, “AI2” - two AI blocks in the loop.
“AITEMP_A” - with some description.
“CP”, “CPPID” - blocks that only run in the CP.
“CPDCIO_PID2_1” - DCI output (O) block (which only resides in the Control
Processor), that publishes to sink block “PID2”, the “_1” indicating the “first” such
publication.
“CPDCIO_PID2_2” - DCI output (O) block (which only resides in the Control
Processor), that publishes to sink block “PID2”, the “_2” indicating the “second”
such publication.
“CPDCII_PID2_1” - DCI input (I) block (which only resides in the Control Pro-
cessor), that subscribes to the publication from block “PID2”, the “_1” indicating
the “first” such subscription.
Published <output parameter name>-<sink block name>
Outputs
Where:
<output parameter name> is the name of the output parameter in the source block
providing a value to the sink block specified by <sink block name>. The Scheduler
only cares that different connections have different <output parameter name>s -
they need not match actual FF parameter names. The tool DOES use actual FF
parameter names when you use “Add Predefined Loop” to create loop(s), with one
exception - to ensure the required uniqueness of parameters sent to the Scheduler,
output parameter names in “CP” block rows are “CPOUT” or “CPOUT1”,
“CPOUT2”, … “CPOUT8”. The names of parameters published from a “CP”
block row to an FF block must differ from the names of parameters published by
that FF block; otherwise, the Scheduler may omit the scheduling of one of the
CDs.
<sink block name> is the name of the sink block receiving the parameter specified
by <output parameter name>.

The Scheduler doesn't need to know the actual input parameter name; internally,
the tool forces all input parameter names to “IN” by convention.

The “Add DCI Pub. Output” and “Add DCI Pub. Input” features create rows and
add connections with <output parameter name> and <sink block name> assigned
to maintain uniqueness. Within a loop, there can be multiple DCI output blocks
publishing to the same FF block, and an FF block can be publishing to multiple
DCI input blocks.

26
Table 3. Loops Grid Column Descriptions (Continued)

Column Description
Published For uniqueness of connections, the tool uses the following convention for parame-
Outputs ter names that it creates when the User selects “Add DCI Pub. Output” or “Add
(Continued) DCI Pub. Input”:

DCI<I|O><n>

Where:
I is for input, specified for DCI output block (ROUT, BOUT, etc.) connections.
O is for output, specified for DCI input block (RIN, BIN, etc.) connections.
For example, here are rows resulting from adding predefined loop “Simple PID
with Control in Field”, selecting the PID row, then selecting “Add DCI Pub. Out-
put” twice and “Add DCI Pub. Input” three times:

Auto completion Feature:


For a row with an FF block, that is, the block name starts with an FF block type,
when you enter the first character in one of the pub/non-pub columns as an “O”,
the tool offers a list with all possible combinations of the block's output parameters
(or back calc parameters, respectively) and the other non-input blocks in the loop.
Select the desired connection from the list and the tool populates the cell. For
example, in a simple PID loop with an AI, PID and AO block, select the PID row,
and click in the “Published Outputs” column and type 'O'. The tool gives a list
with the choice “O__OUT-AO”. Select “O__OUT-AO” and you've defined the
output connection for your PID. The tool strips off the leading “O__” from the
parameter names when the cell loses focus.
For a row with a CP block, that is, the block name starts with “CP”, when you
enter the first character in one of the pub/non-pub columns as an “O”, the tool
offers a list with all combinations of “O__CPOUT” and the other non-input FF
blocks in the loop.

NOTE: Additional connections must be entered manually in a cell.

27
Table 3. Loops Grid Column Descriptions (Continued)

Column Description
Published Pub/Non-Pub Column Placement:
Outputs When you select “Validate Loops” or “Estimate Schedule”, the tool automatically
(Continued) moves connections as needed to the proper column. Fields affecting this placement
are: the “Publish Internal Dev Connections” checkbox, device numbers, and con-
nections in the last four columns.
Non Same syntax as “Published Outputs”, except the connection does not get published.
Published
Outputs
Published Same syntax as “Published Outputs”, except the connection is for a back calculation
Back Calcs parameter, which is scheduled differently.
Non Pub- Same syntax as “Published Back Calcs”, except the connection does not get pub-
lished Back lished.
Calcs

Table 4. Loop Editing Features

Loop Editing
Feature Description
Add Choose “Add Predefined Loop”. Choose Loop Type.
Predefined For loop type “Indicator Loop; i.e., Input to CP”, choose “Publishing FF Block
Loop Type”, and if MAI or MDI, also choose “# published points” of 0 to 8.
For loop type “Manual Loader; i.e., Output from CP”, choose “Subscribing FF
Block Type”, and if MAO or MDO, also choose “# used points” of 1 to 8.
For loop type “Control in Host; e.g., Simple PID”, choose both publishing and
subscribing FF block type, and if appropriate, the # published points.
For all loop types, enter the number of copies of the loop you desire, and option-
ally, if the tool should assign device numbers (sequentially), and the starting device
number.
Click OK to add the requested loop(s).
Insert Loop Select a row. Click “Insert Loop”. The tool creates a new row before the first row of
the selected loop, then renumbers subsequent loop rows. To create additional rows
for the loop, see “Insert Row” and “Append Row”.
Add New In the last row, the one with the “*” in the row header, type the desired loop num-
Row at End ber. The tool creates a new row with that loop number. You can now fill in the
of Grid other columns as needed.
Insert Row Select a row in a loop. Click “Insert Row”. The tool creates a new row before the
selected row with the same loop number as the selected row.
Append Row Select a row in a loop. Click “Append Row”. The tool creates a new row after the
selected row with the same loop number as the selected row.
Add DCI Select the row for an FF block. Click “Add DCI Pub. Output”. The tool adds a row
Pub. Output for a DCI block in the CP, with a published connection from that DCI block to the
selected FF block.

28
Table 4. Loop Editing Features (Continued)

Loop Editing
Feature Description
Add DCI Select the row for an FF block. Click “Add DCI Pub. Input”. The tool adds a row
Pub. Input for a DCI block in the CP, and adds a published connection from the selected FF
block to that DCI block.
Delete Select the rows you want to delete using standard Windows techniques. Click
Selected “Delete Selected Rows”. The tool deletes those rows.
Rows
Validate Because some fields in the grid are dependent on other fields (e.g., device number
Loops and block name), and because the User can edit cells individually, the grid is not
guaranteed to have 100% valid data at any one time. When required, the tool auto-
matically does a validation; for example, prior to invoking the Scheduler. The User
can do a validation on demand by clicking “Validate Loops”. See “Validating Loop
Data” on page 30.
Copy/Paste Standard Windows copy/paste, via Edit/Copy and Edit/Paste, or Ctrl/C and
within Grid Ctrl/V. The paste operation is an “overwrite”, except for a paste at the end of grid,
which appends rows as needed.
Copy/Paste Standard Windows copy/paste, via Edit/Copy and Edit/Paste, or Ctrl/C and
from Excel Ctrl/V. The paste operation is an “overwrite”, except for a paste at the end of grid,
which appends rows as needed.
Export from The tool's .xml format defines a “Loops” element and one “Loop” element for each
Excel to .xml loop, in addition to “Block” element for each row. With an optional Excel add-in,
the User can export from Excel to .xml, then must edit resulting .xml to conform to
McEstimatorSchema.xsd.
Edit .xml File User can edit .xml, but it must conform to schema file McEstimatorSchema.xsd. If
there are any errors on File/Open, the tool presents a list of errors and ignores the
.xml file.
Edit Loop Although not passed to the Scheduler, the loop name can assist with understanding
Name the purpose of the loop. When you hover the mouse over the loop number, the tool
displays the corresponding loop name. If you create a loop from scratch, the tool
defaults the loop name to “Unnamed Loop”. If you create a loop with “Add Pre-
defined Loop”, the tool defaults the loop name to the loop type.
Edit Device Although not passed to the Scheduler, the device name can assist with understand-
Names ing the purpose of the loop. When you hover the mouse over the device number,
the tool displays the corresponding device name. The tool defaults the device
names to “Device 1”, “Device 2”, … “Device 16”.
View Loop Tools / View Loop Names displays a read-only dialog of the loop numbers and
Names names, for reference. You can keep it in view, while interacting with other UI of the
tool.
View Device Tools / View Device Names displays a read-only dialog of the device numbers and
Names names, for reference. You can keep it in view, while interacting with other UI of the
tool.

29
Table 4. Loop Editing Features (Continued)

Loop Editing
Feature Description
Direct User Enter text in columns as described in Table 3 “Loops Grid Column Descriptions”
Entry into a on page 25.
Cell

Validating Loop Data


Some data validation checks depend on the data in multiple columns. Such checks are made by
the Validate Loops feature.
Select the Validate Loops feature with any of the following:
♦ Click Validate Loops button on the Loops page.
♦ Select Tools/ Validate Loops.
♦ Right-click on Loops grid and select Validate Loops.
♦ Select the Estimate Schedule feature, which automatically does a Validate Loops.
Some features require an error-free loop configuration before proceeding. In those cases, the tool
automatically invokes the Validate Loops feature and only reports the outcome if error(s) were
detected. See Figure 41.
If Validate Loops finds no errors, you will see the dialog in Figure 40. Additionally, connections in
the last four columns will be moved, if necessary, to the proper columns based on the Scheduler's
rules for publications.
If Validate Loops finds error(s), you will see the dialog in Figure 41. Hover the mouse over the red
error icons in the row header column to get a tooltip explaining the error. See Figure 42 for an
example.

Figure 40. Validate Loops Successful Outcome

Figure 41. Validate Loops Error Outcome

30
Figure 42. Error Icon with Tooltip

Client/Server Info Page


The Client/Server Info page provides data grids and text fields for specifying data that affects cli-
ent/server usage of the free time available during the macrocycle. See Figure 46. This includes the
following:
♦ Number of function blocks per device, carried over from the Loops page (read only).
♦ Number of resource and transducer blocks (total) per device, initialized to two for any
device with at least one function block configured. You can increase this count.
♦ Number of DCI block read/writes per device, initialized to zero for all devices. You
can increase this count. Note that the maximum DCI block count allowed for the seg-
ment, including publishing or subscribing DCI blocks and client/server DCI block
read/writes, is 32.
♦ Number of block views (for function blocks and resource/transducer blocks) and
read/writes (for DCI blocks) for each update speed (fast or slow). The limitation to
two update speeds is imposed by the tool for estimating purposes. When you change a
fast count, the tool automatically adjusts the corresponding slow count, and vice
versa. For example, if a device has two function blocks, both in the fast view column,
changing the slow quantity from 0 to 1 automatically changes the fast quantity from 2
to 1. As shown in Figure 43, you can easily force all entries from a grid to be fast or
slow

Figure 43. All Fast and All Slow Buttons

♦ Totals for the above counts, maintained by the tool for reference (read only).
♦ Function block view periods, in seconds, for fast and slow speeds. Read only defaults
are shown, for reference.
♦ Resource and transducer block view periods, in seconds, for fast and slow speeds. Read
only defaults are shown, for reference.
♦ DCI block read/write periods, in seconds, for fast and slow speeds. Read only defaults
are shown, for reference.
♦ You can reset all configured view periods and read/write update periods to their corre-
sponding defaults. See Figure 44.

31
Figure 44. Reset All Periods To Defaults Button

♦ Average Client/Server Access Time, in milliseconds. This value depends on the time it
takes the FBM228 to handle a client/server access. The current recommended value is
100 ms. See Figure 45.

! CAUTION
This value should only be changed as directed by Invensys personnel or at your own
risk!

Figure 45. Average Client/Server Access Time

To configure loops for client/server only access; e.g., MAI blocks, do the following:
1. Click Add Predefined Loop…
2. Take default Loop Type of Indicator Loop; i.e., Input to CP
3. Select Publishing FF Block Type as MAI Multiple Analog Input.
4. Take default # published points as 0.
5. Enter the desired # loops and device assignment.
6. Click OK.
For a client/server only configuration of MAI blocks, the CP rows are not necessary, but they also
do not pose a problem. Leaving the CP rows in the Loops grid allows you to add published con-
nections from the MAI blocks if you change your mind later on. Whether you want an MAI
block with one client/server point or 8 client/server points, you configure the tool's MAI Indica-
tor loop and the client/server page the same.

32
Figure 46. Client/Server Info Page

Estimate Schedule
When you have entered your configuration into the Project Info, Segment Settings, Loops, and
Client/Server Info pages, select the Estimate Schedule feature with either of the following:
♦ Click the Estimate Schedule button in the toolbar:

Figure 47. Toolbar, With Estimate Schedule Button

♦ Select Tools/Estimate Schedule.


Before calculating a schedule estimate, the tool automatically validates the data on the Loops
page.

33
If there are any errors, the tool displays the error dialog in Figure 48. Hover the mouse over the
red error icons in the left-most column (see Figure 49) to get error details. Correct errors and retry
the Estimate Schedule.

Figure 48. Error Dialog When Loops Page Error(s)

Figure 49. Red Error Icon in Loops Grid

If the Loops page data is valid, the tool does the following:
1. Moves output connections to the proper columns, based on the Scheduler's rules for
determining if an output parameter gets published.
2. Calls the Scheduler to calculate a schedule.
3. Calculates client/server usage and compares it against the time available in the macro-
cycle. See “Client/Server Usage Calculations” on page 49 for details.
4. Calculates FBM228 resource usage and compares it against resource limits. See
“FBM228 Resource Usage Calculations” on page 50 for details.
5. Displays results on the Results page. See “Results Page” on page 34 for details.

Results Page
The Results page is shown in Figure 50.
Table 5 “Estimate Value Status” on page 35 describes all possible Estimate Statuses.
Figure 51 shows error message(s) under the Estimate Status.

34
Figure 50. Results Page (OK)

Table 5. Estimate Value Status

Estimate Status Description


No Estimate Yet No estimate has been requested yet.

Schedule is OK, client/server usage does not exceed 75 % of available


capacity, and no FBM228 resource limits are exceeded.

35
Table 5. Estimate Value Status

Estimate Status Description

Last “Estimate Status” was OK, but the configuration has changed.

Schedule is OK, client/server usage exceeds 75 %, but does not exceed


100%, of available capacity, and no FBM228 resource limits are exceeded.

Last “Estimate Status” was Warning, but the configuration has changed.

Schedule has error; for example, macrocycle not long enough, cannot
achieve minimum percent free time, etc., client/server usage exceeds
100% of available capacity, or an FBM228 resource limit is exceeded.

Last “Estimate Status” was ERROR, but the configuration has changed.

Figure 51. Estimate Status Showing Error Message(s)

As mentioned in Table 5, there are three areas that can cause warnings or errors on the Results
page. Those three areas are shown in Figure 52, Figure 53, and Figure 54. For each field, light
green indicates OK, light yellow indicates Warning, and light red indicates ERROR.

Figure 52. Key Schedule Settings Requested

36
Figure 53. Client/Server (C/S) Group

Figure 54. FBM228 Segment Resources Group

If the estimation fails because of an insufficient macrocycle, the tool displays a Calculated macro-
cycle that is large enough to accommodate the schedule. If the macrocycle is sufficient, the tool
displays the “Minimum % free time achieved” and the “Minimum free time slot achieved”.
Figure 55 shows an example of each of these cases, respectively.

Figure 55. Schedule Metrics

See Figure 56 and Figure 57 for visual display of the calculated schedule.
The Graphic Schedule Display can sort by any of the following:
♦ Block Start Time
♦ Compound.Block Name
♦ CP Order of Execution
♦ Device
The Print and Print Preview features present the tabular format of the schedule.

37
Note: Microsoft Visio 2003 Professional or later must be installed to display the graphic schedule.

Figure 56. Graphic Schedule Display

Figure 57. Tabular Schedule Display

Documenting a Segment Estimation


First, do a File/Save or File/Save As to save the data to an .xml file. This xml file makes the estima-
tion completely transportable, as it contains the entire user-entered configuration and all calcu-
lated results. For example, you can email the xml file if communication with Invensys is required.

38
When the tool exits gracefully, it automatically saves the last estimated data to predefined file
McEstimator.xml, regardless of whether or not you have saved the data to another file. This is a
backup, in case you neglect to save the data.
To preview the printing of the data, do a File/Print Preview.
To print the data, do a File/Print and select a printer, and so forth at the Print dialog.
The following figures give examples of the print output.

39
Figure 58. Print: Project Info and Segment Settings

40
Figure 59. Print: Loops

41
Figure 60. Print: Loop Names

42
Figure 61. Print: Device Names

43
Figure 62. Print: Client/Server Info

44
Figure 63. Print: Results

45
Figure 64. Print: Schedule

46
Obtaining Help
To access Help information,
1. Select the Welcome page to view an overview of the tool.
2. At the Welcome page, click Quick Start: Step by Step… to view a brief step by
step procedure showing steps involved in creating, saving, and documenting a sched-
ule estimate.
3. Select Help/ Contents to view the user document as a PDF file. You must have an
Acrobat Reader installed.
4. Hover the mouse over a textbox to obtain help about that field.
5. Hover the mouse over a grid column to obtain help about that column.
6. Select Help/About to view the tool's About box, which displays version information
for the tool and referenced dlls.

Figure 65. Help About Box

47
Troubleshooting
Troubleshooting issues with the use of this tool involve getting answers to the questions in
Table 6.
Table 6. Troubleshooting

Question How To Get Answers


What version of InFusion am I using? This tool was first developed for estimating schedules for
InFusion V2.0. Compatibility of the tool with later ver-
sions of InFusion is to be determined; that is, the tool
may work, unchanged, with newer versions of InFusion,
or the tool may require modification.
What version of the tool and DLLs am I See “Obtaining Help” on page 47.
using?
What is being input to the Scheduler? See file c:\SchedulerDump\<segment name on Seg-
ment Settings page>\InputToScheduler.txt. See
Notes about SchedulerDump files.
What is being returned from the Sched- See file c:\SchedulerDump\<segment name on Seg-
uler? ment Settings page>\OutputFromScheduler.txt.
See Notes about SchedulerDump files.
Why am I getting validation errors Hover the mouse over the red error icons in the row
when I click “Estimate Schedule” or header column to get a tooltip explaining the error.
“Validate Loops” or make other edits?

What do the various grid columns Hover the mouse over the column header to get a tooltip
mean? explaining the column data.
What do the various buttons do? Hover the mouse over the button to get a tooltip explain-
ing the function of the button.
What do the various fields mean? Hover the mouse over the field to get a tooltip explaining
the field.

NOTE
SchedulerDump files:
1. They are internal diagnostic files for interpretation by Invensys personnel.
2. All time fields are in units of 1/32nd of a millisecond.

48
Tool Calculations
This section describes the tool calculations for:
♦ Client/Server usage
♦ FBM228 resource usage
The schedule itself is calculated by the InFusion Scheduler. Those calculations are not docu-
mented here.

Client/Server Usage Calculations


All time measurements are in milliseconds, except client/server periods, which are in seconds.
The approach is to calculate the cost for each category of C/S access and compare to C/S capacity.
The C/S capacity (maxCsBlocksPerMacrocycle) is calculated as:
FBM Link Maintenance (LM) = 0.20
MC = macrocycle
CD_TIME = MC - MinFreeTimeSlotAchieved
CS_TIME = Average Client/Server Access Time (defaults to 100 ms)
maxCsBlocksPerMacrocycle = (MC - (LM x MC) - CD_TIME) / CS_TIME(Number of
C/S requests per Macrocycle)
If maxCsBlocksPerMacrocycle < 0, clamp maxCsBlocksPerMacrocycle at 0.
The C/S usage (avgCsBlocksPerMacrocycle) is calculated as:
The tool contains three categories of Client/Server users, whose usages are summed:
1. Function block views
2. Resource and transducer block views
3. DCI block read/writes
The tool contains fast and slow periods for each category, entered by the User in seconds.
fbFastViewPeriodCfgMsecs = fbFastViewPeriodCfg * 1000;
fbSlowViewPeriodCfgMsecs = fbSlowViewPeriodCfg * 1000;
rbTbFastViewPeriodCfgMsecs = rbTbFastViewPeriodCfg * 1000;
rbTbSlowViewPeriodCfgMsecs = rbTbSlowViewPeriodCfg * 1000;
dciFastRwPeriodCfgMsecs = dciFastRwPeriodCfg * 1000;
dciSlowRwPeriodCfgMsecs = dciSlowRwPeriodCfg * 1000;

fbFastCost = totalFastFBs / (fbFastViewPeriodCfgMsecs / MC);


fbSlowCost = totalSlowFBs / (fbSlowViewPeriodCfgMsecs / MC);
rbTbFastCost = totalFastRBsTBs / (rbTbFastViewPeriodCfgMsecs / MC);
rbTbSlowCost = totalSlowRBsTBs / (rbTbSlowViewPeriodCfgMsecs / MC);
dciFastCost = totalFastCsDcis / (dciFastRwPeriodCfgMsecs / MC);
dciSlowCost = totalSlowCsDcis / (dciSlowRwPeriodCfgMsecs / MC);

49
avgCsBlocksPerMacrocycle = fbFastCost + fbSlowCost + rbTbFastCost + rbTbSlowCost
+ dciFastCost + dciSlowCost;
The C/S % capacity usage (csPctCapacity) is calculated and reported as:
if (maxCsBlocksPerMacrocycle > 0)
csPctCapacity = (avgCsBlocksPerMacrocycle / maxCsBlocksPerMacrocycle) * 100;
else
csPctCapacity = 0;

if (csPctCapacity > 100)


csPctCapacity is in error condition (ERROR)
else if (pctCapacity > 75)
csPctCapacity is in warning condition (Warning)
else
csPctCapacity is ok (OK)

FBM228 Resource Usage Calculations

Table 7. FBM228 Resource Usage

Resource Limit How usage is determined


# Pub/Sub VCRs 64 # connections in “Published Outputs” column + # con-
nections in “Published Back Calcs” column
# DCI Blocks 32 # blocks whose name starts with “CPDCI” + total # of
DCI blocks from Client/Server Info page.
# FF Function Blocks 96 # blocks with device # 1 to 16.

NOTE
The FBM228 has 96 VCRs available for use and reserves 32 VCRs for client/server
use, two for each device. The tool only checks for the usage of the remaining 64
VCRs, by pub/sub connections.

Predefined Loop Type Diagrams


This section contains loop diagrams for the predefined loop types, with a screen capture of the
rows added to the Loop grid to implement that loop.
For Indicator Loop; i.e., Input CP, Manual Loader; i.e., Output from CP, and Control in Host;
e.g., Simple PID loop types, see “Adding Predefined Loops” on page 12.

50
NOTE
The loop diagrams in this section show both the FF input and output parameter
names as they are typically configured, for reference. However, to provide a schedule
estimate, the Scheduler does not require the actual input parameter names. Inter-
nally, the tool always specifies the input parameter name as “IN” by convention.

Figure 66. Diagram & Grid Rows: Simple PID with Control in Field

51
Figure 67. Diagram & Grid Rows: PID with Control in Field, Track and Feedforward

52
Figure 68. Diagram & Grid Rows: Cascade Control with CIF Primary, CIF Secondary

53
Figure 69. Diagram & Grid Rows: Cascade Control with CIH Primary, CIF Secondary

54
Figure 70. Diagram & Grid Rows: Override Control in Field

55
Figure 71. Diagram & Grid Rows: Input Selector in Field

56
Figure 72. Diagram & Grid Rows: Split Range CIF Output Selector

57
Figure 73. Diagram & Grid Rows: Ratio Controller in Field

58
Figure 74. Diagram & Grid Rows: Totalizer with Flow Compensation

59
60

Anda mungkin juga menyukai