Professional Documents
Culture Documents
Manual Clients Class Workbook - v5.1 - CBT
Manual Clients Class Workbook - v5.1 - CBT
PI ProcessBook
Exercise 1 - Basics
Objectives
1. Open the Tag Search Window with the button or with the Tag Search option of the Tools
menu.
2. Use “b*” in the tag mask field and click on the Search button to get all the tags beginning by
“b”.
3. Click on the first tag name. Then press the shift key and click on the second tag name. This
will select the first two tags. Click on the Pt. Attr button to access the Point Attributes of those
tags. You can move from one tag to another with the arrow keys on your keyboard.
4. Write “*” in the tag mask field and “*reactor*” in the descriptor field, then press Search to find
all the tags with the string “reactor” in the descriptor.
5. Erase the descriptor field and enter “0” (zero) in the Value field, then press Search to find all
the tags with a snapshot value of 0.
2. Connection Window
1. Open the Connection Window with the Connections option of the File menu.
The information contained in this guide is confidential and may be subject to revision.
No part of this publication may be reproduced or transmitted, in any form or by any
means without prior permission of OSIsoft Inc.
All rights reserved, OSIsoft Inc. 2007
Page 1
PI ProcessBook Exercises
2. Click on “Add” to add a PI server. Enter the PI server name specified by the trainer. Enter
“pidemo” as the user name and let the port number at 5450. Click on OK to create the
specified PI server.
3. Highlight this PI Server and click on Connect. You might be prompted for a password. If so,
enter the password specified by the trainer.
Explore the contents of each tab. To change from one tab to another, simply click on the tab
you want to see
One at a time, open all 3 displays of the Refinery tab. To open a display, you can double-click
on it or click once on the display to highlight it and press the Open button. To close a display,
you can use the Close option of the File Menu or press where indicated below:
Open the Batch Reactor display (see the example below) located on the Refinery
tab. To successfully complete this exercise, you must be able to manipulate the
Reactor Level trend as follows:
The information contained in this guide is confidential and may be subject to revision.
No part of this publication may be reproduced or transmitted, in any form or by any
means without prior permission of OSIsoft Inc.
All rights reserved, OSIsoft Inc. 2007
Page 2
PI ProcessBook Exercises
Find when the maximum value was attained (Hint : use the trend cursor).
Using a Trend
Solution
2. Take a moment to locate the different components of the menu bar: Title, Menu and Tools.
The information contained in this guide is confidential and may be subject to revision.
No part of this publication may be reproduced or transmitted, in any form or by any
means without prior permission of OSIsoft Inc.
All rights reserved, OSIsoft Inc. 2007
Page 3
PI ProcessBook Exercises
3. Open the batch reactor display, (see the example below), located in the Refinery tab.
4. With the Run mode pointer, display a section of the trend display. Drag the pointer diagonally to
draw a rectangle. This area will be magnified when you release the mouse button. To return to
the original time scale, use the View option in the menu bar, then Revert or use this tool .
5. With the Run mode pointer, expand the trend on the entire display window. Double-click within
the trend. To return at the original time scale, double-click within the trend again.
6. Use the time forward and backward buttons to scroll the time range forward or backward on a
trend . To modify the time range, use the View > Time Range. Change the time scale
to 1 day.
7. Use a trend cursor to find when the maximum value of the last day occurred. .
9. Alter the y-axis scale of a trend by double clicking on the y-axis. Use the Trend Scale dialog box
to change the vertical scale for the tag in the trend. You do not have to be in Build mode to edit
the trend.
The information contained in this guide is confidential and may be subject to revision.
No part of this publication may be reproduced or transmitted, in any form or by any
means without prior permission of OSIsoft Inc.
All rights reserved, OSIsoft Inc. 2007
Page 4
PI ProcessBook Exercises
Objectives
Learn the differences between the Run mode and the Build mode.
Use the Book and Outline views to visualize and modify a PI ProcessBook.
Exercise
You are asked to create a new PI ProcessBook into which you will insert new
elements and establish links to other PI ProcessBook components and applications.
You will also assign a level of hierarchy to each element.
1. Create a new PI ProcessBook using the following steps:
ProcessBook Entry (There are five types: display, linked display, linked ProcessBook,
text entry and operating system command).
Click OK.
The information contained in this guide is confidential and may be subject to revision.
No part of this publication may be reproduced or transmitted, in any form or by any
means without prior permission of OSIsoft Inc.
All rights reserved, OSIsoft Inc. 2007
Page 5
PI ProcessBook Exercises
2. Insert a Text type entry on level 1 and name it Exercise book using the steps below:
In Build mode, select the Text option from the Insert menu.
As this is your first entry, its hierarchy level is 1 and it may not be modified.
Click OK.
A title corresponding to “Exercise book” appears in the ProcessBook file created earlier.
In Build mode, select the Display option from the Insert menu.
Click OK.
This will create and open a display. You can add a trend into it or simply close it with the
Close option of the File menu.
Save the PI ProcessBook file with the name “PB exercise My First ProcessBook”
4. Add a Linked Display type entry on Level 3 and name it “Linked display 1”.
To link a display from another ProcessBook file, the file must be opened (open the file
Pidemo.piw).
Press the arrow next to the Browse button and select Display Search. Select the Batch
Reactor Display from the Pidemo.piw ProcessBook file.(Hint: Do not forget to open the
ProcessBook where the display resides.).
Click OK.
This will link the display and open it. You can close it with the Close option of the File Menu.
The information contained in this guide is confidential and may be subject to revision.
No part of this publication may be reproduced or transmitted, in any form or by any
means without prior permission of OSIsoft Inc.
All rights reserved, OSIsoft Inc. 2007
Page 6
PI ProcessBook Exercises
A title on the third hierarchy level corresponding to Linked display 1 appears in the PI
ProcessBook file created earlier.
5. Insert a Linked ProcessBook type entry on level 2 and name it “PB from exercise 1”.
Press the arrow next to the Browse button and select ProcessBook file. Browse to and
select the pidemo.piw ProcessBook used in exercise 1.
Click OK.
This will link the ProcessBook and open it. You can close it with the Close option of the File
menu.
A title on the second hierarchy level corresponding to “PB from exercise 1” appears in the
ProcessBook file.
6. Insert an Operating System Command type entry on level 2 and name it “Calculator”.
Press the arrow next to the Browse button and select Applications. Browse to select the
calc.exe file from the c:\winnt\system32 directory for Windows NT4/2000, or
c:\windows\system32 directory for Windows 95/98/XP/ME/2003.
Click OK.
This will create the OS command and open the calculator. You can close it with the Close
option of the File menu.
7. Modify your PI ProcessBook. Change the order in which the entries appear and modify the
hierarchy to resemble the next figure.
In Build mode, select outline from the view menu. Use the four arrows located in the upper
left corner of the window.
The signs + and – are used to expand or collapse the hierarchy level of the selected entry.
The information contained in this guide is confidential and may be subject to revision.
No part of this publication may be reproduced or transmitted, in any form or by any
means without prior permission of OSIsoft Inc.
All rights reserved, OSIsoft Inc. 2007
Page 7
PI ProcessBook Exercises
Building a ProcessBook
The information contained in this guide is confidential and may be subject to revision.
No part of this publication may be reproduced or transmitted, in any form or by any
means without prior permission of OSIsoft Inc.
All rights reserved, OSIsoft Inc. 2007
Page 8
PI ProcessBook Exercises
Objectives
Build trends.
You are now ready to create a trend with PI tags. To place the trends in the
ProcessBook you created during Exercise 2, you must open the ProcessBook and
then double click on Display 1 entry.
The goal of this exercise is to build a trend similar to the figure below using the
following steps:
Add a trend containing the “SINUSOID” tag. Use the trend item from the tool bar. (Hint :
make sure you are in build mode).
The information contained in this guide is confidential and may be subject to revision.
No part of this publication may be reproduced or transmitted, in any form or by any
means without prior permission of OSIsoft Inc.
All rights reserved, OSIsoft Inc. 2007
Page 9
PI ProcessBook Exercises
Building a Trend
Solution 3A
1. Open Display 1.
2. In Build mode, use the Trend tool . Drag diagonally to create a rectangular area to contain the
trend. When you release the mouse button, the Trend definition dialog box is displayed.
Use the Tag Search button to locate and select the “SINUSOID” tag. To facilitate the query,
use a mask, ie: Sin*;
Specify the time range to display the last 5 days in the Plot Time section.
Add a new display entry in the ProcessBook you created in exercise 2. Place it on
level 2 and name it “Exercise 3B”. Create three trends arranged per the figure
below.
Trend 1
Trend 2
Trend 3
Trends should show units of each tag as well as their names and descriptions.
Refer to the next characteristics to create these trends.
Trend 1 displays BA:LEVEL.1 tag with a green color for y-scale located outside the trend.
Change the line weight and use a different marker type.
Trend 2 displays BA:CONC.1 tag with a blue color for y-scale located inside the trend.
Change the line style and use a different marker type.
Trend 3 displays CDT158 tag with a yellow color for y-scale located inside the trend. Change
the line weight or line style, and use a different marker type.
Solution 3B
1. Add a new display entry in the ProcessBook you created during exercise 2, its level will be 2 and
name it “Exercise 3B”. Refer at Exercise 2 - Building a PI ProcessBook.
2. In Build mode, use the Trend tool . Drag the mouse diagonally to create a rectangular area
to contain the trend. When you release the mouse button the Trend definition dialog box is
displayed.
The information contained in this guide is confidential and may be subject to revision.
No part of this publication may be reproduced or transmitted, in any form or by any
means without prior permission of OSIsoft Inc.
All rights reserved, OSIsoft Inc. 2007
Page 11
PI ProcessBook Exercises
Use the Tag Search button to locate and select the “BA:LEVEL.1” tag.
Click on New Plot button. The plot name is updated to Plot-1 and there is now no tag in Tags
in Plot area.
Type the name for the second trend in the Plot box: Trend 2.
Use the Tag Search button to locate and select “BA:CONC.1” tag. Click OK.
Type the name for the third trend in the Plot box: Trend 3.
Use the Tag Search button to locate and select “CDT158”, then click on the Display Format
tab.
4. In Display Format:
5. In Trace Format:
6. In Layout:
Enter the trends arrangement: [Row : 1 x Col : 2] [ExRow : 1 x ExCol : 1]. An overall view is
shown in the preview area.
Trends are finished. Click on OK. It is important to note that the Layout tab will not appear
after you have edited these trends. Be sure that you have arranged trends properly before you
exit this configuration screen.
The information contained in this guide is confidential and may be subject to revision.
No part of this publication may be reproduced or transmitted, in any form or by any
means without prior permission of OSIsoft Inc.
All rights reserved, OSIsoft Inc. 2007
Page 12
PI ProcessBook Exercises
Objectives
Exercise
The goal is to represent a process as a schematic to make it easy for all personnel
to identify its components. Drawing tools are available to create schematics.
In the ProcessBook you created in Exercise 2, add a new display entry that will be
named Exercise 4.
In this display, reproduce the stirred tank drawn below. If you wish, you can activate the Snap
To Grid option from the Arrange menu.
Using the Symbol Library tool (from the toolbar), create the tank. If you wish, you can modify
the color or fill pattern using the Options button of the symbol library. Select the “Tank”
category and the “Flat vessel 7” symbol.
Using the Symbol Library tool (from the toolbar), create the agitator. If you wish, you can
modify the color or fill pattern using the Options button of the symbol library. Select the
“Mixers” category and the “Mixer blade” symbol.
Using the Symbol Library tool (from the toolbar), create the valve. If you wish, you can modify
the color or fill pattern using the Options button of the symbol library. Select the “Valves”
category and the “Hand valve 2” symbol.
The information contained in this guide is confidential and may be subject to revision.
No part of this publication may be reproduced or transmitted, in any form or by any
means without prior permission of OSIsoft Inc.
All rights reserved, OSIsoft Inc. 2007
Page 13
PI ProcessBook Exercises
Solution
1. Hint: It can be easier to arrange and align objects when the grid is activated.
2. Draw the tank with the “Symbol Library” option of the Draw menu. Once this option is selected,
use the left button of the mouse to select the area where you want the symbol. Select the “Tank”
category, then the “Flat vessel 7” symbol. Click on “Options” if you want to change the color or fill
pattern of the tank. Note that the color can only be changed if the Fill mode is Shaded, Solid or
Hollow.
Start by modifying the line width with the Line Width button . Note that you may also
change the ending of lines to obtain arrows. It is possible to draw lines first and change their
ends later.
The information contained in this guide is confidential and may be subject to revision.
No part of this publication may be reproduced or transmitted, in any form or by any
means without prior permission of OSIsoft Inc.
All rights reserved, OSIsoft Inc. 2007
Page 14
PI ProcessBook Exercises
Draw lines with the Line option from the Draw menu. Select the lines and modify their ends
with the Line Width button. An option is to use the Poly-Line button and draw a line with
multiple sections.
Draw the agitator with the Symbol Library option of the Draw menu. Once this option is
selected, use the left button of the mouse to select the area where you want the symbol.
Select the “Mixers” category, then the “Mixer blade” symbol. Click on Options if you want to
change the color or fill pattern of the tank.
Write in the tank: “Stirred tank” with the Text option of the Draw menu.
Draw the valve with the Symbol Library option of the Draw menu. Once this option is
selected, use the left button of the mouse to select the area where you want the symbol.
Select the “Valves” category, then the “Hand valve 2” symbol. Click on Options if you want to
change the color or fill pattern of the tank. .
OR
The information contained in this guide is confidential and may be subject to revision.
No part of this publication may be reproduced or transmitted, in any form or by any
means without prior permission of OSIsoft Inc.
All rights reserved, OSIsoft Inc. 2007
Page 15
PI ProcessBook Exercises
The information contained in this guide is confidential and may be subject to revision.
No part of this publication may be reproduced or transmitted, in any form or by any
means without prior permission of OSIsoft Inc.
All rights reserved, OSIsoft Inc. 2007
Page 16
PI ProcessBook Exercises
Objectives
Learn how to enhance your displays by adding live elements whose properties
change in time. These elements consist of the following ProcessBook objects:
Bar Graph
Value of a PI Tag
Multi-State Symbol
Command Button
Exercise
Add a low and high visual alarm. (Draw two circles; then modify their properties using Multi-
state Symbol).
Write the text associated with each alarm as shown in the figure below.
Create a bar graph over the tank body and make it the same size as the tank. This might be
easier if the Snap to Grid option of the Arrange menu is not activated.
Insert a command button in your display from the button icon. A configuration dialog box
appears. In the text item, enter « Calculator ». Select Operating system command as its
type. Finally, in the action item, enter the command line that will start the calculator (Typically:
C:\WINDOWS\SYSTEM32\CALC.EXE or C:\WINNT\SYSTEM32\CALC.EXE).
The information contained in this guide is confidential and may be subject to revision.
No part of this publication may be reproduced or transmitted, in any form or by any
means without prior permission of OSIsoft Inc.
All rights reserved, OSIsoft Inc. 2007
Page 17
PI ProcessBook Exercises
Keep the propeller and the text inside the tank, in front of the bar graph. (Hint: use the Bring
to front command in the Arrange menu).
Save the display you created in PDI format (Exercise5.pdi). Use the Save as item of the File
menu.
Solution
Use the Value option from the Draw menu to insert the “BA:LEVEL.1” tag value. Write
“Level (%)” above the value with the Text option from the Draw menu.
With the Ellipse option of the Draw menu, draw two small circles, as shown in the figure below
– they will be activated to become visual alarms;
The information contained in this guide is confidential and may be subject to revision.
No part of this publication may be reproduced or transmitted, in any form or by any
means without prior permission of OSIsoft Inc.
All rights reserved, OSIsoft Inc. 2007
Page 18
PI ProcessBook Exercises
In the Build mode, select the high-level circle and then click on Multi-State button . Select
BA:LEVEL.1 tag. Set the number of states to 2. Define the limit of the first state at <= 90.
Set the color of the first state to green and second state to red.
Repeat the same thing to add the low-level alarm using the same tag. Set the number of
states to 2. Define the limit of the first state at <= 10. Set the color of the first state to red and
second state to green.
Use the Bar item from the Draw menu to create a bar graph. Draw a rectangle over the tank
body and make it the same size as the tank body. This might be easier if the Snap to Grid
option of the Arrange menu is not activated.
Set the graph‟s parameters. Select the BA:LEVEL.1 tag. Keep the default values of upper
and lower limits, and the start value. Click on OK to complete the Bar Graph
In Build mode, right-click on the Bar Graph and choose Format Color. Choose the proper fill
color. Use None for the background and line color.
Use the Bring to front option from the Arrange menu to move the agitator out from under the
bar graph.
Use the Button option from Draw menu to add a command button. In the Define Button dialog
box, put in a name for the button: “Calculator. In the action item, enter the command line that
will start the calculator. You will find the calculator (calc.exe) in the
C:\WINDOWS\SYSTEM32 or C:\WINNT\SYSTEM32 according to the operating system used.
The information contained in this guide is confidential and may be subject to revision.
No part of this publication may be reproduced or transmitted, in any form or by any
means without prior permission of OSIsoft Inc.
All rights reserved, OSIsoft Inc. 2007
Page 19
PI ProcessBook Exercises
The information contained in this guide is confidential and may be subject to revision.
No part of this publication may be reproduced or transmitted, in any form or by any
means without prior permission of OSIsoft Inc.
All rights reserved, OSIsoft Inc. 2007
Page 20
PI ProcessBook Exercises
Objectives
Exercise 1A – PI Summary
In the ProcessBook you created in Exercise 2, add a new display entry named
DataSet1. In it, display in a new trend the hourly minimum value, maximum value
and the tank level average. Synchronize the calculations at 00:00:00 AM. The
trend has to display the results of the last 12 hours in a stairstep trace.
Use the “Sinusoid” PI tag to do this exercise. The figure below illustrates the
resulting trend.
The information contained in this guide is confidential and may be subject to revision.
No part of this publication may be reproduced or transmitted, in any form or by any
means without prior permission of OSIsoft Inc.
All rights reserved, OSIsoft Inc. 2007
Page 21
PI ProcessBook Exercises
Solution 1A
1. Create a new display type entry titled DataSet1 in the ProcessBook you created in Exercise 2 and
open it.
2. Create a dataset with the Data Set/New/PICalculation item of the Tools menu.
Name: Level
Interval: 1 h
The information contained in this guide is confidential and may be subject to revision.
No part of this publication may be reproduced or transmitted, in any form or by any
means without prior permission of OSIsoft Inc.
All rights reserved, OSIsoft Inc. 2007
Page 22
PI ProcessBook Exercises
Synchronization: 00:00:00
4. Build a new trend named “Tank level”. Click PI Calculation from the dropdown menu to select the
curves.
5. Select the dataset you just created. Select the Average, Minimum and Maximum columns by
holding down the Ctrl key. Return to the Define Trend dialog by clicking the OK button.
Start: *-12h
End: *
7. Set the display and trace formats as you want and click on OK.
8. Add the percent good values with the Value item of the Draw menu.
9. Click on the PI Calculation button from the dropdown menu and choose the PctGood column.
10. Set the value‟s format to general, select a tag name position from the drop-down list and click OK.
Exercise 1B – PI Expressions
Two different products (A and B) feed a tank. You want to illustrate in a trend the
product‟s percentage use per 30 minutes. The synchronization of the calculations
starts at 00:00:00 AM (every 30 minutes starting at midnight). The trend should
show the results for the last 8 hours in a stairstep trace. Use the tag name CDT158
as product A and BA:TEMP.1 as product B. Define a column named “%Product A”
for the results of the calculation. Use the following expression:
'CDT158'*100/('CDT158'+'BA:TEMP.1’)
Place the trend in a new display entry named DataSet2 in the ProcessBook created
in Exercise 2. The figure below presents the resulting trend.
Add a tank (static drawing + bar object) that will show the two products at the inlet
and the usage percentage of product A at the outlet.
The information contained in this guide is confidential and may be subject to revision.
No part of this publication may be reproduced or transmitted, in any form or by any
means without prior permission of OSIsoft Inc.
All rights reserved, OSIsoft Inc. 2007
Page 23
PI ProcessBook Exercises
Solution 1B
Add Trend
1. In the PI ProcessBook of Exercise 2, create a display type entry named “DataSet2” and open it.
2. Create a dataset with the Data Set item of the Tools menu.
5. Choose the dataset “Product A” and select the column “%ProductA”. Return to the Define Trend
dialog.
Add Tank
1. Draw a tank with two inlet pipes and an outlet pipe as seen in the figure below.
2. Type the products‟ names and add the CDT158 tag value as product A and the BA:TEMP.1 tag
value as product B.
3. Type “%ProductA =” at the tank‟s outlet and add the value and the timestamp of column
%ProductA of the ProductA dataset.
The information contained in this guide is confidential and may be subject to revision.
No part of this publication may be reproduced or transmitted, in any form or by any
means without prior permission of OSIsoft Inc.
All rights reserved, OSIsoft Inc. 2007
Page 24
PI ProcessBook Exercises
Trend « % Product A »
For the following two exercises to work properly, the following items must be installed
on your system:
LabData_2006.MDB (a Microsoft Access data file)
The ODBC Data Source configured in your system
ODBC tags.xls (with the PI-SMT menu in Microsoft Excel)
The last element in the above list reflects three tags that must be created for this
exercise to work. You can create them individually or use the free SMT download Tag
Configurator for Microsoft Excel to export them into your PI database. Each of these
tags makes use of standard interfaces and needs only be created to begin functioning.
The information contained in this guide is confidential and may be subject to revision.
No part of this publication may be reproduced or transmitted, in any form or by any
means without prior permission of OSIsoft Inc.
All rights reserved, OSIsoft Inc. 2007
Page 25
PI ProcessBook Exercises
The information contained in this guide is confidential and may be subject to revision.
No part of this publication may be reproduced or transmitted, in any form or by any
means without prior permission of OSIsoft Inc.
All rights reserved, OSIsoft Inc. 2007
Page 26
PI ProcessBook Exercises
Objectives
Problem
You want to trend test values from a database used and maintained by your laboratory
that looks like this one:
The information contained in this guide is confidential and may be subject to revision.
No part of this publication may be reproduced or transmitted, in any form or by any
means without prior permission of OSIsoft Inc.
All rights reserved, OSIsoft Inc. 2007
Page 27
PI ProcessBook Exercises
Approach
We will use an ODBC DataSet that uses a SQL Query to filter the data from the lab
database. In that query, we‟ll use placeholders to send the start time and end time of
the graph through with the SQL query. As the trend updates, the query will update
automatically.
Please try to complete the exercise before moving on to the answer below.
The information contained in this guide is confidential and may be subject to revision.
No part of this publication may be reproduced or transmitted, in any form or by any
means without prior permission of OSIsoft Inc.
All rights reserved, OSIsoft Inc. 2007
Page 28
PI ProcessBook Exercises
Step-by-Step Solution
4. Choose “LabData” from the Data Source list (if “LabData” is not available in the choice list,
you will have to create it to point to LabData_2006.mdb).
5. Next we have to build the query; you can type it manually or use the Microsoft Query
application (if available) by clicking on the Design… button. The request is built as follows:
6. The question marks represent Parameters which will be fed from ProcessBook itself. In the
query above, we wish to look for data beginning at the start time of the trend and ending at the
end time of the trend. Hit the Placeholders button to define how each of the question marks
should be treated.
Placeholder 1 must be set as Type=Start Time (don‟t forget to press Set after choosing this
type from the dropdown list) and Placeholder 2 will be Type=End Time. When you have a
window that looks as follows, hit OK.
The information contained in this guide is confidential and may be subject to revision.
No part of this publication may be reproduced or transmitted, in any form or by any
means without prior permission of OSIsoft Inc.
All rights reserved, OSIsoft Inc. 2007
Page 29
PI ProcessBook Exercises
7. Hit „Check Syntax‟. ProcessBook will test the query and once it finds it syntactically correct, it
will allow you to select OK.
8. Back on the blank display, create a trend (use the last 24 hours as a range) using the DataSet
you just created. Trend the “Value” element.
Note here that we can edit the DataSet (SQL query, placeholders, etc.) from this window; if we do so it will
be edited for all elements that use it.
9. Hit OK, finish the trend as usual and the data from the Access database will now be visible in
your trend – you can mix it with PI Data if desired!
The information contained in this guide is confidential and may be subject to revision.
No part of this publication may be reproduced or transmitted, in any form or by any
means without prior permission of OSIsoft Inc.
All rights reserved, OSIsoft Inc. 2007
Page 30