Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
0% found this document useful (0 votes)
2 views

Module 4 Introduction to Calogix and Logic Module

The document outlines the setup and operation of a PID control system, detailing the configuration of module outputs, setpoints, and burn-out states. It provides step-by-step instructions for controlling a process, specifically a water level in a tank, and includes guidance on setting up alarm conditions and chart displays for monitoring system performance. Additionally, it introduces logic programming capabilities for the CALogix system, allowing for the integration of logic functions in controlling various devices.

Uploaded by

Dimas Ridhwana
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
2 views

Module 4 Introduction to Calogix and Logic Module

The document outlines the setup and operation of a PID control system, detailing the configuration of module outputs, setpoints, and burn-out states. It provides step-by-step instructions for controlling a process, specifically a water level in a tank, and includes guidance on setting up alarm conditions and chart displays for monitoring system performance. Additionally, it introduces logic programming capabilities for the CALogix system, allowing for the integration of logic functions in controlling various devices.

Uploaded by

Dimas Ridhwana
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 40

Experiment 4 Process Control

Setting up the PID module output


We have configured the PID module input to conditions that suit our requirements but before the
controller can be run we must set up the appropriate conditions for the module output. Notice for
channel 1 on the controller panel that module 1 has three outputs; one 4-20 mA and two relay
switched outputs. These correspond to outputs a, b, and c respectively on the controller 38-541-PC
panel.

Figure below shows the range of output settings for module 1.

Figure 5-1 Output setting window for PID control

Setpoint Output
The first three settings relate to the set point for each one of the controller channel 1 outputs a,b, and
c.

Step 1: Double click on the ‘Value’ setting for each one of these to see the option available. Note that
these in each case are for none and outputs 1, 2, and 3. It is possible that any one of the three physical
outputs can be assigned as Setpoint1 and so on for setpoint 2 and setpoint 3.

The physical outputs on the controller have been designated a, b, and c to avoid confusion with
numerical outputs 1, 2, and 3 and the software use of numerical designations that are used throughout
the programming of the module.

Instead of setpoint 1 set to output 1, setpoint 2 set to output 2, setpoint 3 set to output 3, this can be
stated as setpoint 1 set to output a, setpoint2 set to output b, and setpoint 3 set to output c.

Note that when any one of the set points are set to a particular value the controller PC screen mimic
indicates this by SP1,2,or3 on the appropriate module of the controller.

Step 2: For this exercise set the three set point outputs to 1, 2, and 3, respectively.

This means that the action of outputs (a), (b), and (c) are referenced to the values of settings entered
into ‘Module 1 Setpoint1 Control’, a setting that we will dealing with shortly.

19
Burntout state
The next three settings in figure 5-1 are for the ‘Burntout state’ for the outputs (a), (b), and (c).

The ‘Burntout’ state relates to a failure in the input signal (4-20 mA) that may become open circuit or
described as ‘Burntout’. In the event of this happening the outputs can be set to specific conditions
depending on the process under control to prevent dangerous situations arising, set alarms and
prevent the loss of the process material that may be considered to be of high value.

Step 3: For this exercise set these values to Energise.

We will verify the action of these settings when running the controller program.

Output inversion
Each one of the outputs can be set to a true or false state. The next three settings in the output
settings table are for this purpose.

Step 4: Set all three outputs for ‘false’.

Note that the ‘output settings’ description is ‘output inversion’ so if the setting is ‘False’ then the
physical output is non-inverted.

Output Cycle count


This records the number of operating cycles for the outputs and is particularly useful in the case of
relay outputs where the number of operations can be check against the specified life time of the relay.

Controlling the Process


Setpoint control
The parameter settings shown in figure 4-8 named Setpoint1 Control are for the control of the process
connected to the 4-20 mA input of module 1. In this case we have the Level Probe connected and
calibrated to operate over the range 0-100% of the water level in the process tank.

Figure 5-2 window setting for PID control

As we shall be controlling the water level in the process tank the Setpoint1 value can be entered in the
range 0-100 %.

Step 5: Enter a value of 50 for Setpoint 1.

20
Step 6: To set the controller ‘Mode’ double click on ‘Park’ to see the type of control that can be
applied. Set the mode to Park.

Step 7: Set all other values as shown in figure 4-8.

Before we can run the controller we need to connect up the 4-20 mA output from module one.

Step 8: Disconnect the two leads to the pump input sockets and connect the 4-20 mA output from the
controller module 1 to the pump input sockets, plus to plus, and minus to minus.

Step 9: Ensure that the process tank valve A is set to have a small drain on the tank to enable the
control action to function properly. (Lever at approximately 30 degrees from the vertical).

Step 10: Set the controller Band to 10 and Mode to P, Proportional.

The controller should start the pump on maximum flow and begin to fill the process tank. This process
will continue until the tank water level approaches the set point, i.e. 50%, at which point the pump
flow is gradually reduced until the desired water level is reached. The pump will continue to run to
maintain the desired level replacing the water steadily draining from the tank as set by valve A.

Step 11: Examine the controller action by slowly opening and closing valve A and note that the pump
flow increases as the flow is reduced.

Step 12: Try using PI, PD, and PID control.

Setting up a chart display


Ti appreciate he controller action and see in more detail the response of the system a chart displaying
time against the process variable and the set point can be set up to show this.

Within the charting software there are many parameters that if required can be ‘tagged; to be
displayed on the chart with the traces shown in various colors and names attached. We will set up a
chart that displays the current process and examine the response of the system to various changes in
controller PID values.

Step 13: Click on the icon at the top of the screen that looks like a small graph

Figure 5-3 graphic icon

The window shown in figure 5-4 will be revealed.

Step 14: Enter a filename and set the major time scale interval to the values shown.

This is a scrolling chart and in this case for every centimeter if he chart represents a time interval of ten
seconds and in that ten seconds period five samples will be taken and the chart updated once every
two seconds.

21
Step 15: Complete the rest of the chart settings as shown in figure 5-4 and then click Next.

Another window will open that will list the controller(s) that are available to have their data displayed
on the chart.

Step 16: Click on the Add button to list the available controllers.

Figure 5-4 Chart configuration window

You should find the controller(s) listed in the Select data source window.

Step 17: Double click on the controller to list the available modules. From the list select module 1, this
is the one that is being used to control the level in the process tank.

The window shown in figure 5-5 should now be viewable listing the parameters available to be ‘tagged;
and displayed on the chart.

Figure 5-5 Data source window

Step 18: From the tag list select Input 1 Formatted Process Value. This will become highlighted on blue.
Select Next to see the window as shown in figure 5-6.

22
Figure 5-6 Trace properties window

Step 19: Enter the unit to be charted, in this case Percent and choose a trace color from the drop down
menu by clicking on the color tab

Step 20: Enter the maximum scale, minimum scale, and scale step as shown in figure 5-6, then click on
the finish tab.

Step 21: In the next window, click on ‘Add’. This window will allow a second trace of interest to be
included in the chart.

Step 22: Select the controller as before and Module 1.

Step 23: From the tag list select ‘Setpoint1 Formatted Value’ and then click on the ‘Next’ tab.

Step 24: Select the trace color if necessary and check the scaling settings, then click on finish.

You should now have two items listed in the Chart trace selection window as shown in figure 5-7.

The top trace is the process variable (PV) and the second one is the set point (SP). At this stage we
could change the tag information through the Delete, Edit, and Add tabs and you may wish to do this if
your settings are not as shown in Figure 4-13.

Figure 5-7 Chart trace selection window

Step 25: Click on the next tab to see the window in figure 5-8.

23
Figure 5-8 Chart format properties window

The chart background, grid and cursor can be changed so as not to mask any of the previous color
settings so if necessary change the cursor color to blue to avoid the same color as chosen by the
default settings.

The date/time format may be completed if desired but it is no necessary for this to be done for this
exercise.

Step 26: Click on Finish to see the chart and to begin recording Data.

The chart in figure 5-9 Shows the result obtained with the set point set to 50%, left hand side of the
chart, and the response of the system process with the set point changed to 70%, right hand side of
the chart.

Note the two areas where there are small reductions in the process variable (tank level). These are due
to the opening and closure of the tank drain valves to observe the controllers response to these
changes.

Figure 5-9 typical chart result

Step 27: Try his for yourself by opening the tank drain valve fully, noting the increase output of the
pump in an attempt to maintain the water level, waiting for about 30 seconds before closing the drain
valve almost fully, and allowing a small drain into the sump tank.

24
The controller should be seen to stabilize at the set point. Changing the PID values will change the
system response.

Step 28: Make the graph of PI, PD, and PID controller, try disturbing the system by opening Valve A
(flowing the water down to reservoir).

Step 29: Close the Process Tank drain valve and remove the connection to the positive input to the
pump 4-20 mA socket before moving on to the next exercise, Setting Alarms.

25
Experiment 5 Alarming
Step 1: Complete previous setting and the system condition is set as at the previous exercise
(Chart running, PID control set ‘P’ with a proportional band setting of 5)

Step 2: “Right click” on controller graphic > select “Properties” > Click”Module1” to reveal the setting
option

Figure 6-1 Select Properties

Step 3: Select “Module 1” then double click “Setpoint1 control”

Figure 6-2 Select Module1 to set the Set Point

Step 4: Set mode “Park” from right hand column and click “Apply”
(hold the controller preventing any further output action )

Figure 6-3 Set mode “Park”

26
Step 5: Set Setpoint1 to “70” and click “Apply”

Figure 6-4 Set Setpoint1 to “70”

Step 6: Double click on “Setpoint2 Control” and set Operating mode to “FSHI” (Full Scale HIgh)
(this Setpoint2 output to alarm if process value increase above the value of Setpoint2)

Figure 6-5 Set Operating Mode to “FSHI”

Step 7: Set Setpoint2 to “80”, mode “P” and click “Apply”

Figure 6-6 Set Setpoint2 to “80”, mode “P”

27
Step 8: Double click on “Setpoint3 Control” and set Operating mode to “FSLO” (Full Scale LOw)
(this Setpoint3 output to alarm if process value decrease under the value of Setpoint3)

Figure 6-7 Set Operating Mode to “FSLO”

Step 9: Set Setpoint3 to “20”, mode “P” and click “Apply”

Figure 6-8 Set Setpoint3 to “20”, mode “P”

Step 10: Follow wiring diagram of below figure

Figure 6-9 Connection the cable

28
The Alarm setting are more easily understood if they are represented in a graphical

Figure 6-10 Alarm setting

Ex1. As an exercise to reinforce your understanding of setting up the alarm re-programs the controller
such that alarm HI occurs at 55% and alarm LO at 35%. Check that the alarm lamps operate in the
correct way using the previous procedure as a guide

Ex2. Set up an alarm sequence that will indicate when the process tank level is below 30% using a lamp
and a second alarm that uses the sounder when the level reduces to 10%.

29
QUESTIONS

Be sure to answer these questions in your report 

1) Mention 3 functions of the Process Controller module!


2) Explain how to calibrate the CALogix readings!
3) Draw a graph of reading in CALogix versus reading in the process tank! Include minimum
7points in CALogix reading: 0 %, 20%, 40%, 50%, 60%, 80%, and 100%! Explain about Process
Controller linearity!
4) Explain qualitatively by your observations in process tank pumping the differences between P,
PI, PD, and PID control!
5) Include the graph of P, PI, PD, and PID control! Don’t forget to disturb the system! Does the
graph support your qualitative observations?

30
Instrumentation System Laboratory
Module 5 Introduction to Logic Module
Version 1.0 June 2014

Class of 1st semester 2014/2015

Devised by:

Muhammad Wildan Gifari Bandung Institute of Technology

Worrameth Sheranorrawanish King Mongkut’s University of Technology Thonburi

CONTROL AND COMPUTER SYSTEM LABORATORY

SCHOOL OF ELECTRICAL ENGINEERING AND INFORMATICS

BANDUNG INSTITUTE OF TECHNOLOGY

0
Objective

1) Students can operate module 3 to implement logic function

2) Students can operate logic for various devices and instruments

3) Students understand how to make logic function

4) Students understand to preprogrammed the PID controller

1
Introduction

Logic I/O and Logic Programming

OVERVIEW:

CALogix has integrated logic function capability that can be used for controlling a system by linking
associated inputs and outputs using logic, timer, counter and comparator functions.

LOGIC I/O MODULE SETTINGS:

To access logic I/O settings right mouse click on the controller image, mouse over properties then
click on the module number (module slot number must have logic I/O module fitted)

Figure 1-1 Setting window

A user-defined label (name) for the module can be entered in the module name field

Input 1, 2, 3 range

The voltage range of inputs 1, 2 and 3 can be user-defined as one of three voltage ranges i.e. 0-24V,
0-10V and 0-5V.These voltages are used to determine high and low states for logic functions and
also for comparator switching levels. Voltages above 66% of the input range will be considered as
high state and below 33% as low state e.g. for a 0-10V input range <3.3V = low logic state (0) and
>6.6V = high logic state (1).

Comparators will convert the input level to a percentage of full scale and will be compared against
other inputs or a constant. e.g. With an input range of 0 - 24V, an input voltage of 2.4V will be
considered to have a value of 10.0 in a comparator block.

Each of the inputs can be independently set for a different voltage level input. Once each input has
been set, write the settings to the controller by clicking the apply button.

2
LOGIC PROGRAMMING

ACCESSING LOGIC PROGRAMMING

1) Click icon on main toolbar


2) Logic programming desktop should now open

THE LOGIC TOOL BAR

Create Boolean function block


AND, OR, XOR, LATCH, NAND, NOR, XNOR boolean function block can be created
See section on Boolean function blocks.

Create comparator function block


Compare two I/O module inputs or compare an I/O block input with a constant. “greater
than” or “less than” comparator options. See section on comparator blocks.

Create timer/counter function block


Select one of eleven timer types or two counter types. See timers/counters overview
section.

Create input function block


I/O module inputs, power up or output status can be used as logic input function blocks.

Create output function block


Function blocks for a switching a physical output, changing setpoint, selecting manual
power, starting autotune, event input and running a program can be created.

Function block linking tool


Creates a link between two function blocks in a logic program.

Read logic data from controller


Existing logic data in desktop is overwritten by logic program read from controller.

Write logic data to controller


Logic program is written from desktop to the controller. Logic data is also validated at this
time.

Clear logic data


Clears logic data on the desktop. Logic programs within the controller are NOT cleared,
unless a blank desktop is written to controller.

Validate logic data


Logic validation ensures that a logic program is created as a functional program. If function
blocks are not used in the correct way or links to inputs or outputs are missing a message
will be displayed giving details of the error.

3
Logic program trace mode
Trace mode allows monitoring of a logic program that is running in a controller. Green lines
show the active part of the program. Counter and timer values can also be read.
Note: Windows is not a real-time operating system therefore there may be a delay before changes in the
controller are visible on PC screen.
If other applications are running in addition to CALogix-sw the delay may be greater.
Note: When in trace mode the logic desktop will be in read-only mode.

Stop logic program


The logic programs running within the controller are stopped. Note. The ‘logic program
running’ LED on the CALogix base unit will switch OFF.

Run logic program


The logic program within the controller memory will run. The ‘logic program running’ LED on
the CALogix base unit will switch ON.

Align function blocks to left


Align all highlighted function blocks with the blocks to the left.

Align function blocks to right


Align all highlighted function blocks with the blocks to the right

Align function blocks to top


Align all highlighted function blocks to the top.

Align function blocks to bottom


Align all highlighted function blocks to the bottom.

Resize function blocks to same width


Resize all highlighted function blocks to the same width.

Resize function blocks to same height


Resize all highlighted function blocks to the same height.

Resize function blocks to same height and same width


Resize all function blocks to the height and width of the blocks to that of the widest and
highest blocks.

Apply grid to desktop


Apply grid to the logic desktop to assist with aligning and creating programs.

4
Logic Function Blocks
Placing a Function Block on the Logic Desktop
1) Left-Click on the icon for the logic function block type you require
2) Continuing to hold the mouse button, drag the mouse pointer into the logic desktop area
3) Once mouse pointer is in position that you want to place function block, release the mouse
button.
4) The function block should now be visible.

Arranging Function Blocks


1) Click and drag an area encapsulating function blocks.
2) Function blocks that require rearranging should now be highlighted
3) Click on left, right, up, or down icons to arrange function
4) The function blocks will now align

Linking Function Blocks


1) Create required function blocks on logic desktop
2) Click on function block linking tool icon
3) Click and hold left mouse button in the center of first block
4) Drag mouse pointer to the center of second function block
5) Release left mouse button
6) The two function blocks should now be linked
7) Repeat from step 2 to link additional function blocks
Note: All timers have one input, whereas counters, Boolean, and comparators have two. Output blocks have one input. All
timers, counters, Boolean, comparators can have multiple outputs. Inputs can connect to multiple timers, counters,
Boolean, and comparators simultaneously. You cannot link physical outputs to inputs, to do so use Output (In) blocks.

Function Blocks-Selecting Operation


Each type of function block has a number of variations in operation. Once a block has been dropped
on the logic desktop, right click on the block and select properties.

Figure 2-1 properties window

A window will open up with the function block setting window.

Figure 2-2 Operation Type window

By clicking on the drop down menu for operation type (or mode in some blocks) the operation type
can be selected.

5
The various function block options and how they are configured is shown below.

Logic Blocks
Boolean
Operation mode for a Boolean function block can be selected as AND, NAND, OR, NOR, XOR, XNOR
or LATCH (see selecting operation above). Truth table for Boolean functions are given in the
appendix.

Each Boolean function block requires a two inputs from either an input block or other function
blocks. The output of the block must be connected to another function block or an output block.

Timers
A number of timer functions are available with CALogix, these are: on-delay, on-off delay, on-pulse,
off-pulse, delayed pulse, symmetrical & asymmetrical recycler pulse, and symmetrical &
asymmetrical recycler pause. Timer charts showing the operation of these are shown in appendix.

Figure 2-3 Timer window

The time settings are entered by clicking on the time required and entering the data in HH. MM.SS.S
format. Once entered click on OK to accept the settings change.

All timers require a single input from either an input block or another function block. The block
output must be connected to another function block or an output block.

Time settings for standard timer types are set via CALogix software. To adjust timer settings
remotely via an operator panel, SCADA or field device ensure that the ‘remote’ box is ticked in the
function block ‘properties’. This feature is only available for ‘on’ and ‘off’ delay timers, other timer
types can be created from these basic timer blocks, contact CAL for more information. The data
register in which the timer can be accessed remotely is shown outlined in the function block when
the logic program has been downloaded to CALogix, see below.

Figure 2-4 Timer has been set

6
Counters
Counters blocks will give an output after the input has received a user specified number of input
pulses. Two types of counter blocks can be selected: counter reset and high speed counter. The high
speed counter can count pulses up to 1 kHz and counter reset to a frequency of 10 Hz. Otherwise
both counters function in a similar way.

If using a high speed counter, the physical input for the counter must be from input 1 on the logic
I/O module.

Figure 2-5 Counter window

To set a count value, enter the required number in counts.

A counter requires two inputs to operate, a count input and a control input. As pulses are received
at the count input the counter will increment, an output is given when the set number of counts is
received. The counts received will reset to 0 when the control input goes to a high-state (1), the
block output is also reset to a low-state (0) if the count value had been previously reached.

The operation of each of the input 1 and 2 can be selected in the properties window shown above.

It is also possible to select whether the counter will increment on a rising edge (low to high state) or
level triggered (i.e. when input reaches and is stable at a high state). This is set within the trigger
parameter within the properties window.

Comparator
Comparator blocks take a voltage level from a logic I/O module and compare the value with either a
constant or the value of another logic I/O module input.

Figure 2-6 Comparator window

Comparators convert the input level to a percentage of full scale e.g On a logic I/O module input
with range of 0-24V, an input voltage of 2.4V will be considered to have a value of 10.0 in a

7
comparator block. The compare function allows a greater or a less than comparison with the input. If
the comparison is true the block will have a high-state output (1).

The block will require one input for comparing with a constant or two when comparing inputs. The
output must be connected to an output or another function block.

Inputs
Inputs block provide a link from physical inputs to control logic functions. There are four types of
input:

1) Physical input – the input block status mirrors the current state of a physical input on a logic
I/O module.
2) Power Up - the input status is high (1) when the CALogix unit is powered on.
3) Output (In) - The input block status mirrors the output state of a PID or a logic I/O block.
4) Soft I/P – Soft inputs allow logic to be triggered remotely from an operator panel, SCADA, or
field device. There are 8 soft inputs (0-7) available within a CALogix base unit and restored in
a single register.

Figure 2-7 Input window

Outputs
Output blocks require a single input from other function blocks or an input block. Do not connect the
output of an output block to other function blocks.

Physical output
To control output on a logic I/O module a physical output block is used. To configure an output block
select the module number and the output. When connected to logic function blocks the specified
physical output will switch as the logic driving the output changes state.

Figure 2-8 Physical output window

Changing Set point


Setpoint of a PID module can be changed using an output function block. By entering the required
value the setpoint will be changed when switching from low (0) to high (1) logic state. The setpoint
change can be selected to apply to SP1, SP2, or SP3 of a specified module.

8
Figure 2-9 Setpoint value window

Manual Power
PID control can be suspended and replaced by a constant proportional output by using a manual
power function block. The value is entered as a % of full power (i.e. 100% = output fully on).

Figure 2-10 manual power window

Manual power can be selected to apply to SP1, SP2, or SP3 of a specified module and will operate
when input to block switches from low (0) to high (1) logic state. To return to PID control to manual
power an additional block can be created within the logic program to set manual power value to 0.

Autotune
A PID module can be tuned using an output logic block. Autotune@75%SP (3/4 setpoint) or
Autotune@ATSP( at setpoint) can be selected for the required PID module.

Figure 2-11Autotune window

PARK can also be selected to disable the controller outputs. In a situation where PARK is activated
using a logic function, the controller can only be taken out of PARK by changing the mode settings in
CALogix-sw or via an operator panel.

Event Input
Event inputs are set within the programmer functions of CALogix. If required within a program, a
profile will be held in his current position until an event input is received.

9
Select the module number and give the event a numerical tag that corresponds to the required
event input.

Figure 2-12 Event-input window

For easy identification it is recommended that you give an event input the same number as the
segment in the program. For instance if the EIP segment is 4 then set the event input to number 4 in
the logic. This means that when the EIP segment is displayed it will appear as EIP4.

Program
A program output can be used to run, stop or hold a program (profile). Select the module and the
program number along with the control mode.

Figure 2-13 Program window

When the input to block is high (1), the chosen programmer function will be activated.

Inverting inputs
Function blocks inputs can be inverted in the following way:

1) Right click on function block


2) Click on inputs

Figure 2-14 Input window

3) Click on invert boxes for the inputs that require inverting.

Figure 2-15 Inverting input

10
4) Click on OK to accept the setting.

Validating a Program
Once a logic program is complete click icon on the logic toolbar. A check is hen carried out for
program validity and any errors are displayed. See example below.

Figure 2-16 Validation of a program

Writing a Program to Controller


Programs are written to the controller by clicking on the logic toolbar. Any changes made to the
program before writing to the controller are only stored on the logic desktop.

Figure 2-17 writing a program is on the go

As the program is being written to the controller a progress bar is visible.

Running and Stopping a Logic Program


Click on the logic toolbar to start a program that is written to the controller, the Logic running
LED on the base unit should be ON when a logic program is running. To stop a logic program running

click on the logic toolbar and the logic running LED should switch off.

Trace Mode
Trace mode allows a user to monitor a logic program as it is running. After a logic program is started

click on the logic tool bar.

Any active parts of the circuit are highlighted in green.

11
Figure 2-18 Green means the logic is ‘1’

As the output of a function block becomes active (1) a green triangle is shown on the top left corner
of the block.

Figure 2-19 Logic and physical output function blocks are active

Current timer and counter values are also shown within the logic block and will show changes as
they occur. While trace mode is on the logic desktop will be in read only mode, no changes to the

function block can be made. To exit trace mode click on .

Note: As windows is not a real time operating system there may be a delay from when an action occurs at the controller to
when it is displayed within a CALogix-sw. This delay may be reduced by closing down other applications whilst CALogix-sw
is running.

12
Exercise 1 Setting up a logic sequence (Channel3, Module3)
Step 1: Right click on the image of the controller. Click on the: “Properties” and click “Module 3”
(You will notice that there are settings for three inputs and that these correspond to the three inputs on the 38-54-PC
controller. Each input has an associated output; input1 to output a, input 2 to output b and input 3 to output c.)

Figure 3-1 Select Module 3

Step 2: Double click on the right-hand side column and from the drop down option set the input
voltage for all three inputs to 24 V. OK these settings.
(This will be the operating voltage that we will use to operate the logic control sequence using the 24V dc supply available
on the controller panel)

Figure 3-2 Setting input voltage 24V dc supply

Step 3: Click “Logic icon” on the tool bar to open the logic circuit construction window

Figure 3-3 Logic icon on tool bar

Step 4: Click “Red square” icon to stop the logic module operation.

Figure 3-4 Stop logic icon

13
For this ‘First exercise’ we will use ‘basic logic gates’ to perform simply tasks.

Consider a requirement where two signals have to be the same logic level such as in the case of a
heating furnace with an access door.

We would want to ensure that before the door is opened that

We have two things to consider


1. The door open or closed positions
2. The furnace temperature, too hot or acceptable to either

One way to approach this problem is to build a truth table applying logical requirement.

Heat Temperature Furnace Door release


On Low No
On High No
Off High No
Off Low Yes

From above we can form a logic function block using a


‘1’ for On, High, Yes and ‘0’ for off , Low, No.
This result for Logic truth table is show below.

Heat input 1 Temperature input 2 Door release


1 0 0
1 1 0
0 1 0
0 0 1

Only when the heat is off and the temperature is at a safe level will the door lock be
released such that the furnace can be entered.

To implement this we need a logic gate that when both inputs are ‘0’ the output is at ‘1’.
This type of logic gate is called a ‘NOR’ gate. When input1 NOR input2 is at ‘1’ the output is at ‘1’

14
Step 5: Click “Boolean logic” holding down the left button of the mouse to place a logic AND gate on
the desk top.(This is always the first logic gate in the series.)

Figure 3-5 Boolean Block icon

Step 6: Left click to highlight the graphic and then right click to select “Properties”.

Step 7: Left click on the down arrow to open a drop down box and select the “NOR” gate from the
options and click “OK”. (The NOR gate should now be on its own in the logic window. We need now to attach the
inputs that represent the interlock switches.)

Figure 3-6 Select NOR Gate

Step 8: Click and hold down the left mouse button on “Module Input” icon

Figure 3-7 Module Input icon

(Drag across the INPUT and locate it slightly above and on left hand side of the NOR symbol. Release the mouse
button to see the INPUT symbol. Note that this will show the module number and input.)

15
Figure 3-8 Module Input block

Step 9: Right click on the “input” symbol and select the appropriate module; in this case “module 3”.
Select the input that will be used for one of the interlock switches to input 1. Click OK to set the input to module 3, input 1

(To reposition any of the symbols left click to highlight, move the mouse over to the shaded area of the box to obtain a fine
cross near the mouse pointer. Click the left mouse button and hold down, drag the symbol to the desired position, release
the mouse button. )

Figure 3-9 Change Input Module

Step10: Connect the “Input block” to the “Logic gate input”

Figure 3-10 Click on the Link icon (arrow symbol) on the tool bar

Figure 3-11 Drawing a dotted line between the edges of the two symbols

16
Figure 3-12 Release the mouse button when the link is in position

Step 11: Add a second input block and allocate it to “Module3” and “Input2”.
(Connect this second input block to the logic gate as previously described. Note the linking tool will remain in operation
until the Arrow icon is clicked off. If it remains on further logic circuit construction will be prevented)

Figure 3-13 Second input

Step 12: Left click on the “Module Output” hold down the mouse and move the mouse to place the
output block in front of the logic block.

Figure 3-14 Module Output icon

Figure 3-15 Module Output block

17
Step 13: Connect a link between “Logic block” to the “Output block”.

Figure 3-16 Connect ‘Logic Gate’ to ‘Output’

When the circuit is complete it can be validated by clicking. Click on this symbol to validate your
circuit.

Figure 3-17 Validate Logic Data icon

If there is an error in the connectivity or the logic functionality it will be indicated in the logic window. Should an error be
displayed check and correct if necessary and re-validated the circuit.

Step 14: Write the logic program to the CPU by selecting the “Write logic data”.

Figure 3-18 Write Logic Data icon

Step 15: Check that the changes have been recorded by selecting the “Read logic data”.

Figure 3-19 Read Logic Data icon

The next step is to connect the physical input and output connection of the logic module (channel 3)
to the appropriate external components. We will use the two switches, SW1 and SW2 on the
controller panel for the inputs and for the output, the release door signal, LP2.

18
Figure 3-20 Physical Input and Output Connection

From our truth table it can seen that both input should be initially at a ‘1’ (high) state.

It is often the case that available component do not match the required function such that an
alternative has to be considered. This situation exists with the switch type (push to make contact)
that is available. To use this type of switch with the logic it is necessary to connect a ‘1’ to our logic
input when the button is pressed.

Changing the logic function. We now have: when both inputs are at ‘1’ the condition for opening the
furnace door, the output will be at ‘1’ to release the door mechanism. The logic for these condition is
an AND gate. Substitute 24V for logic ‘1’ and we have a workable circuit to match the components
available.

In your previously configured circuit, change the NOR gate to an AND gate and write the change to
the controller. The resulting circuit should be as show in Figure below

Figure 3-21 Change NOR Gate to NOR Gate

19
Make the connections as show below

Figure 3-20 Wire Connection

Run the configuration by selecting the “Start Run Mode” icon, this removes the ‘hold’ on the
module operation.

Figure 3-21 Start Run Mode

Step16: Test the function of the logic circuit by pressing SW1 and SW2 separately at first and then
together.

(You will see that LP2 is lit(door release) when both inputs are active, meeting the criteria that when the furnace heat has
been turned off and the temperature is at a low save value it is safe to open the door and enter the furnace.)

Step17: Select the “Trace function” to instigate

Figure 3-22 Trace Mode

Step18: Press and hold SW1 for a few seconds and you will see the input route highlighted.

Step19: Repeat for SW2 and then for both switches pressed together.

(You must select the run mode (green square icon) for the trace facility to work. To return to normal operation select the
trace off by clicking on the trace icon)

20
Experiment 2 Exercises on Logic Function
Exercise 1
Goal: Modify the existing circuit such that when SW1 is pressed the LP1 lamp cycles on and off and
the pressing of SW2 with SW1 brings on LP2.

Step 1: Press the stop run mode (red square)

Step 2: Click on the third icon (clock face) and place theOn delay block above the AND block

Step 3: Right click on the block and select from Properties from the drop down list the Symmetrical
Recycler pulse.

Step 4: Click into the time box on the lower section and enter HHH:MM:S2.S. This will appear as 2
seconds in the timer block. Click OK.

Step 5: Place an output block (5th icon) above the existing output block.

Step 6: Right click on the output block and select properties.

Step 7: Set the module to 3 and the output to 2 and click OK.

Step 8: Click on the Arrow icon and link from module 3 input 1 block to Sym Pulse block.

Step 9: Link Sym Pulse block to Physical output 2 block.

Step 10: Check the circuit using the validation function, tenth icon .

Make the physical connections to the external components as follows:

Output (b) on CH3 is required to be connected to PL1 to indicate when SW1 is pressed.

Step 11: Connect the + terminal of LP1 to the +24V output socket.

Step 12: Connect the – terminal of LP1 to CH3, relay b.

Step 13: Connect the other terminal on relay b to the 24V – terminal.

Step 14: Set the logic to Run.

Step 15: Test by pressing SW1, LP2 will not lit but LP1 will be cycling on and off at a rate of
approximately 2 seconds.

Step 16: Test by pressing SW2, LP2 and LP1 won’t lit.

Step 17: Test by pressing SW1 and SW2, LP2 will lit and LP1 will be cycling on and off.

21
Figure 4-1 the block diagram of Logic Exercise 1

The resulting logic circuit should look like the figure above.

Exercise 2
Goal: Configure a 24V logic circuit that will light LP1 when either one of two input switches are
activated. When both switches are activated together, an audible alarm is set off with time interval
of 2 seconds on and 5 seconds off.

Investigate the logic circuit using the Trace mode to verify functionality and test the full circuit with
input switches, LP1 and alarm already wired correctly.

Hint: The resulting circuit should look like figure below.

Figure 4-2 the block diagram of Logic Exercise 2

22
Exercise 3 Using Process Controller Panel to control water level

Step 1: Click “Logic icon” on the tool bar to open the logic circuit construction window

Figure 5-1 Logic icon on tool bar

Step 2:Setting “Input Block” to ‘Module 1’ and ‘Input 1’ for Level sensor.

Figure 5-2 Input setting

Step 3: Setting “Compare Block” icon and setting the ‘Compare Input To Constant’ and Value “80”

Figure 5-3 Compare setting

23
Step 4: Setting “Output” to ‘Module 1’ and ‘Output 1’ for Water pump.

Figure 5-4 Output setting

Step 5: Using “Link” to connect all block together

Figure 5-5 Connect block

Step 6: Click on “Validate Logic Data” to validate your circuit.

Figure 5-6 Validate Logic Data icon

Step 7: Click on “Write logic data” to write the logic program to the CPU.

Figure 5-7 Write Logic Data icon

24
Step 8: Click on “Read logic data” to check that the changes have been recorded.

Figure 5-8 Read Logic Data icon

Step 9: Connect “Input”, from “Level sensor” to “4-20 mA i/p” on process controller panel

Figure 5-9 Input connection

Step 10: Connect “Output”, from “4-20 mA o/p” to “Pump 4-20mA input”

Figure 5-10 Output connection

25
Step 11: The result connection

Figure 5-11 Result connection

26
QUESTIONS

1) Explain the differences of various Logic Output types:


a. Physical Output
b. Changing set-point
c. Manual power
d. Autotune Event Input
e. Program
2) In Exercise 1, what is the icon used to check error in logic function connection? How to
correct the error?
3) How to check whether the process is working according to your settings?
4) Why when we use trace mode, change of values in PIT does not followed immediately by the
change of value on monitor (why there is a delay)?
5) Try make logic functions of situation below:
a. Alarm rings when temperature is above 40 degrees or water level fall below 20 %
b. Lamp 1 on when water flow faster than 2 liters/minutes and pressure is above 2 g,
lamp 1 on when water flow slower than 2 liters/minutes or pressure is below 2 g.

27

You might also like