Up/Down Counter Function Block

ALLEN-BRADLEY
BULLETIN 1336 IMPACT
UP/DOWN COUNTER FUNCTION BLOCK
APPLICATION NOTE # 1336E - 10
August 28, 1997
PURPOSE
The purpose of this document is to provide guidelines for wiring and control
schemes for the Bulletin 1336 IMPACT AC Drive. This document is to be used as
a suggestion only. Users must ensure that installations meet applicable codes
and are suitable for the existing conditions.
The Bulletin 1336E User Manual should be used as a reference to ensure that
proper wire selection, routing and fusing guidelines are followed. Refer to
application note #1336E - 4 for an overview of Function Block concepts.
WHAT THIS NOTE
CONTAINS
This note contains descriptions and possible uses for the Up/Down Counter
function block incorporated into the 1336E drive
INTENDED
AUDIENCE
This application note is intended to be used by personnel familiar with the
hardware components and programming procedure necessary to operate the
Bulletin 1336S.
WHERE IT
IS USED
The diagrams, parameter settings and auxiliary hardware used in this application
note are designed to address specific issues in many different applications. Some
changes by the User may be necessary to apply the concepts of this document to
a specific application.
TERMS AND
DEFINTIONS
[ ] - Indicates a parameter name
Link - A link is a software connection between two parameters that lets one
parameter receive information from another.
- This represents a source which is a link parameter that provides the
information.
- This represents a destination which is a link parameter receiving the
information.
DESCRIPTION
The Up/Down Counter function block is used to configure the drive with a counter
circuit that increments or decrements based upon the programmed “function”
inputs. To configure the drive with the Up/Down Counter circuit the [Function Sel]
parameter (212) must be programmed appropriately. Refer to figure 1.
Faxback Document #3056 Revision Date 7/28/97 Web location Http://WWW.AB.COM
Page 1 of 5
Figure 1
EVALUATING THE
FUNCTION INPUTS
VALUE
0
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
The “Function Evaluation Select” parameters (200,203,206) are used to
precondition the inputs. The numbers 0-15 correspond to the 16 different
evaluations available. Refer to table 1 for the descriptions.
Table 1
EVALUATION (1 = on = true = set = closed) (0 = off = false = reset = open)
Pass the value directly through the function block
Mask the value (logical AND the input value with a value)
Send a true value when all bits that are set in the mask are on in the input value
Send a true value when all bits that are set in the mask are off in the input value
Send a true value when any bits that are set in the mask are on in the input value
Send a true value when any bits that are set in the mask are off in the input value
Send a true value when the input value is equal to the value of the mask
Send a true value when the input value is not equal to the value of the mask
Send a true value when the signed input value is < the value of the mask
Send a true value when the signed input value is < or = to the value of the mask
Send a true value when the signed input value is > the value of the mask
Send a true value when the signed input value is > or = to the value of the mask
Send a true value when the unsigned input value is < the value of the mask
Send a true value when the unsigned input value is < or = to the value of the mask
Send a true value when the unsigned input value is > the value of the mask
Send a true value when the unsigned input value is > or = to the value of the mask
Faxback Document #3056 Revision Date 7/28/97 Web location Http://WWW.AB.COM
Page 2 of 5
Up/Down Counter
When [Function Sel] is set to eleven, the Up/Down Counter function is used to
increment or decrement the output. A rising edge at In1 increments the count by
the value of In4, while In2 decrements the count by the value of In5. In3 is used to
reset the counter. The logical state of In6 determines if the output is a single or
double word (In7 and In8 are not used). Refer to figure 2.
Figure 2
APPLICATION
CONSIDERATION
The Function Input parameters for the up/down counter block are linkable
destination type parameters. This means that other parameter values may be
directly sent to, or linked, to these locations. All function inputs that are used by
the function block must be programmed with a constant value or have a link.
The Function Output parameter is a source parameter. This parameter must be
linked to a destination parameter.
The LINK menu of the Human Interface Module is used to create parameter links.
An example of the link display is shown below.
Drive/Inv Status
<15> <
DESTINATION PARAMETER
Use the ▲ or ▼ keys to select the
desired Destination Parameter.
0
Arrow Indicates the
direction of data
APPLICATION
EXAMPLE
The following example uses the up/down counter to change the speed reference
in precise increments. Three push buttons wired to TB3-26, 27 and 28 perform
the increment, decrement, and reset functions.
Faxback Document #3056 Revision Date 7/28/97 Web location Http://WWW.AB.COM
Page 3 of 5
Faxback Document #3056 Revision Date 7/28/97 Web location Http://WWW.AB.COM
Page 4 of 5
In this example we simulate a precise MOP function. As the increase push-button is pressed the speed will increment
an exact value each time regardless of how long the push-button is depressed. The same for the decrease pushbutton. Each depression of the push-button will decrease the speed and exact value. There was also a reset function
wired in.
Ch1 is the reset push-button. Ch2 is the increase push-button. Ch3 is decrease push-button. Ch4 is speed command.
1.) The increase push-button is pressed and the speed command increments in a fixed value. 2.) Here the reset pushbutton is pressed. The speed command resets to zero speed. 3.) The decrease push-button is pressed and the speed
command falls off in another fixed value.
2
1
3
Faxback Document #3056 Revision Date 7/28/97 Web location Http://WWW.AB.COM
Page 5 of 5