Micro 850 Accumulator reset

Jody Collins

Member
Join Date
Aug 2015
Location
VA
Posts
6
Greetings all. I was hoping that some one that uses connected components by AB can help me with programming a accumulator reset in my program. I am using a quadrature encoder and everything is working fine but I need to be able to reset the accumulator to 0 on the fly. I don't see a specific instruction for this. I use latter logic style programming with function blocks. I see that I can use a accumulator set up with the Z function but this method, I think, also causes you to use a input point for hold - something I don't need.

I found this:

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.
HscCmd = 4 (reset) sets the Acc value to the HSC AppData.Accumalator value.
The HscCmd =4 does not stop HSC counting. If HSC is counting when the
HscCmd =4 is issued, some counting may be lost.
To reset the Acc value and then continue the counting, trigger the HscCmd =4
only once. If the command is enabled continuously, it may cause errors.
HSC AppData.Accumalator value is updated automatically by the HSC
mechanism with the same value as the HSC Sts.Accumulator. To set one specific
value to HSC Acc while counting, write the value to HSC AppData.Accumalator
immediately before HscCmd =4 is issued.
HSC Commands
HSC Command Description
0x00 Reserved
0x01 HSC RUN
• Start HSC (if HSC in Idle mode and Rung is Enabled)
• Update HSC Status Info only (if HSC already in RUN mode and Rung
is Enabled)
• Update HSC status Info only (if Rung is disabled)
0x02 HSC Stop: Stop a HSC counting (if HSC is in RUN mode and Rung is Enabled.)
0x03 HSC Load: reload HSC Configuration (if Rung is Enabled) for 6 input elements:
HPSetting, LPSetting, HPOutput, LPOutput, OFSetting, and UFSetting. HSC
accumulator is NOT reloaded by cmd = 0x03.
0x04 HSC Reset: set Accumulator to assigned value, and reset HSC status
information (if Rung is Enabled)

In the users manual I don't understand how to implement the 0x04 HSC instruction

does anyone know how to implement ---HscCmd =4 in the logic>? (if this is what I need....

Thanks in advance
 

Similar Topics

I am trying to read and write data from Control Logix L23E and a Micro 850. My path in the message is 2, 192.168.2.183 192.168.2.183 is the ip...
Replies
2
Views
696
Hello. I have an issue with a Micro 850 PLC. Issue is when it is in RUN mode, and an output is energized, the whole PLC just turns off, then turns...
Replies
3
Views
746
Hello. I have an issue with a Micro 850 PLC. Issue is when it is in RUN mode, and an output is energized, the whole PLC just turns off, then turns...
Replies
1
Views
547
I am using a Micro 850E PLC (the new one with implicit messaging capability) to drive a Kinetix 5100 servo drive. The error code number on the...
Replies
7
Views
1,687
Hello, and thanks in advance I am working on a project with two micro 850 controllers and want to send bool bit from one to the other. I am in...
Replies
6
Views
1,115
Back
Top Bottom