Hsc (high speed counter) function block, Hsc commands (hsccmd) – Rockwell Automation 2080-LC50 Micro830 and Micro850 Programmable Controllers User Manual User Manual

Page 151

Advertising
background image

Rockwell Automation Publication 2080-UM002F-EN-E - December 2013

135

Use the High-Speed Counter and Programmable Limit Switch Chapter 8

HSC (High Speed Counter)
Function Block

The HSC function block can be used to start/stop HSC counting, to refresh
HSC status, to reload HSC setting, and to reset HSC accumulator.

HSC Commands (HScCmd)

HscCmd is an input parameter with data type USINT. All HSC commands
(1…4) are Level commands. Users are advised to disable the instruction before
updating the command.

HscCmd = 1

starts the HSC mechanism. Once the HSC is in running mode, the

HscCmd = 2

must be issued to stop counting. Setting the Enable input

parameter to False does not stop counting while in running mode.

HscCmd = 3

reloads the following parameter values: HighPreset, LowPreset,

OverFlow, UnderFlow, HighPreset Output, and LowPreset Output.

The parameter values shown in the Variable Monitor may not match the values in
the Hardware. Command 3 must be executed to load the values from the
variables to the hardware without stopping the HSC.

If the HSC Enable is True, HscCmd = 3 will continuously load the parameters.
Trigger HscCmd = 3 only once.

HSC

HSC

HscCmd

STS

HscAppData

HscStsInfo

PlsData

Enable

45631

HSC Parameters

Parameter

Parameter
Type

Data Type

Parameter Description

Enable

Input

BOOL

Enable function block.
When Enable = TRUE, perform the HSC operation specified in “HSC command”
parameter.
When Enable = FALSE, there is no HSC operation, and no HSC status update.

HscCmd

Input

USINT

Refer to HSC Commands on page 136

HscAppData

Input

See HSC APP Data Structure on
page 117

HSC application configuration. Only initial configuration is needed usually.

PlsData

Input

See array of Programmable Limit
Switch (PLS) Function on page
137

Programmable Limit Switch (PLS) Data

HscStsInfo

Output

See HSC STS (HSC Status) Data
Structure on page 128

HSC dynamic status. Status info is usualy continuously updated during HSC
counting.

Sts

Output

UINT

HSC function block execution status

Advertising
This manual is related to the following products: