
Operating as A-B-Ref-Counter or Event Counter
The counter can be operated as an A, B, Ref Counter/Encoder or as an event counter. The selection is
made by the variable "SelectEncoder_1". See also
Term2_SelectEncoder_1:=FALSE;
(*A, B, Ref *)
Term2_SelectEncoder_1:=TRUE;
(*Event counter at A*)
(*B=FALSE:down, B=TRUE:up*)
Single-end Multiple Counting
This option is valid in the event counter mode only. The counter can count edges (all rising and falling
edges, i.e. Quadrature Encoder) or pulses (only the rising edges). The selection is made by the variable
"SetResolution_1". See also
Term2_SetResolution_1:=FALSE;
(*all edges*)
Term2_SetResolution_1:=TRUE;
(*Pulses*)
Referencing
The counter can be set to a preset value when a pulse occurs at the Ref input. The preset value can be 0,
but also any other 32-bit number, using SetValue_1 and SetPreset_1.
Task: An encoder with 500 Pulses provides 2000 increments per turn in the all edges mode (Quadrature).
Every Ref pulse shall set the counter to the preset value 2000. It shall be counted down to 0 within 1 turn.
The counting direction is determined by the turning direction of the encoder.
PROGRAM Referencing
VAR
bInit: BOOL := TRUE;
StepInit: USINT;
bInitReady: BOOL;
Step: USINT;
END_VAR
------------------------------------------------------------------------------
(*1. Initializing: Enabling of the counter and setting of the preset value*)
IF bInit THEN
CASE StepInit OF
(*Selecting the options and setting them by a rising edge v. "Set_Options"*)
0:
Term2_EnableCounter_1:=TRUE;
Term2_SetValue_1:=2000;
Term2_SetPreset_1:=TRUE;
Term2_SetOptions_1:=TRUE;
StepInit:=1;
Summary of Contents for PAC
Page 11: ...CHAPTER 1 Product Overview...
Page 18: ......
Page 19: ...CHAPTER 2 Installation...
Page 33: ...CHAPTER 3 System Start up and Configuration...
Page 69: ...CHAPTER 4 PACIO Modules...
Page 143: ...2 After adding the device and code to the project you will configure the IO map as displayed...
Page 155: ...PAC with 400XR series...
Page 156: ...PACIO MODULES 156 Parker Automation Controller Installation Guide...
Page 157: ...PAC with 400LXR...
Page 158: ...PACIO MODULES 158 Parker Automation Controller Installation Guide PAC with SMH sensors...
Page 159: ...CHAPTER 5 Communication Interfaces Optional...
Page 176: ......
Page 177: ...CHAPTER 6 Troubleshooting...
Page 188: ...TROUBLESHOOTING 188 Parker Automation Controller Installation Guide...
Page 189: ...APPENDIX A PAC System Specifications...
Page 195: ...APPENDIX B Additional Information...