Pausing pulse count on high speed counter ?

wanher3

Member
Join Date
Feb 2018
Location
USA
Posts
65
Hello,

To make it short, the current system setup is a compact logic with a high speed counter 1769-HSC input module reading pulses from a flow meter. I'm currently trying to, based on an event, paused to pulse count on input channel A0, and then resume the counting operation once that event is gone. Has anyone done such thing ? I read the manual for that module but it wasn't clear which configuration bit can be used to do that.

Thanks
 
From the 1769-HSC Manual:
Counter Enable/Disable
The counter can be enabled or disabled using the CtrnEn control bit. Be aware
that disabling the counter does not inhibit any current count loading functions
(for example, preset or direct write) or any Z function.

So you should be able to put a 0 into the enable bit to turn off the counter. Keep in mind that with the counter turned off it wont count any pulses from the meter. This could affect the meters accuracy so just be aware of that.
 
Hi,

I read that as well but what it doesn't clearly say is whether the counter holds its value when the CtrnEn bit is toggle from 0 (enabled) to 1 (disabled) back to 0. In other world, when I re-enable the counter, will the counter resume where it left off or will it start from zero ?
Were you able to see that anywhere in their manual ? I was thinking about using the Z functions of the module but which bits to use isn't clear either. How do you think the Z functions can be used for this since it seems to have a HOLD function ?

Thanks
 
Last edited:
You are correct, but look at the other counter instructions in the AB world and how they work. If you remove the enable, the counter will hold its ACC value and then start counting from there when you enable the counter. The only way to reset the counter is for it to reach its preset value or do a reset in your code.

So I would be willing to bet the HSC will work exactly like the other counters.
 
When I bring Flow Meter pulses into a HSC I dont use the Z input. Just the A input. The meters I work with only send pulses out on 1 or maybe 2 channels and dont have a Z output.

From what I understand about the Z input is that it is a 1 pulse/Rev of a shaft encoder. I am sure it has many functions but in the Fluid Measurement industry it is normally used to verify that encoder is working properly and sending the proper amount of pulses for one rev. of the shaft. So in other words if the encoder you are using is a 200 pulses/rev, when you see the Z input you would start counting. When the Z input goes high again you would stop counting. That would indicate 1 rev of the encoder and your counter should show 200.

Many years ago we used to mount Shaft Encoders on PD meters so they could send pulses to batch controllers and PLC's. They had a Z output and we would use to test test the encoder during the calibration of the meter. These days most meters only have a A and (sometimes) B pulse output.

What kind of meter do you have? What outputs are available to use?
 
I have an Emerson Micro Motion 2700 flow meter, wired on terminals 5 and 6 to to channels A0+ and A0- of the HSC.

But what I meant by Z functions is that the manual says it can be used to pause the counter but doesn't say how or which bits. See below
Z Input Functions
There are three Z input functions: store, gate, and Z preset.
Store
The Z-input can be used to capture the current count value even when the counter is counting at full 1 MHz speed.
Gate
The Z-inputs can be used to gate (hold) the counter at its current value regardless of incoming A or B inputs. A gating function is typically one that lets pulses reach the counter (gate open) or not (gate closed).
Z Preset
Preset can be programmed to occur based on the actions of the Z-input signal.
 
Well what I described would be like the Gate function. When the Z input comes on it will stop counting. To start counting again you have to "pulse" the Z input again. Could you use the Z input to stop the counter? Yes you could you would have to wire a output to the Z input and trigger the output to open when you want the counter to stop but, I think you may be over thinking this just a bit. That seems unnecessary when you can just use the enable bit to stop and start the counter. I am sure it will do what you need it to do.

I have interfaced MicroMotion Meters with a PLC many times. Mostly with Micrologix 1100 and 1400. It always looks way more complicated than it actually is. The first few times I did it I found myself saying "thats it? There has to be more to it than this!" Out of all the uses for a HSC I think the Flow Meter is by far the most straight forward.
 
I think I inderstand what you mean now. Correct me if I'm wrong but it thought the Z functions would just be a set of bit I could toggle to have the counter behave how I want. But what you saying is that, it is a physical wired input connected to the Z channel that captures external events in order to make the counter behave how I want. Is that correct ?
 
From what I understand the Z is a physical input wired into the card, from a Encoder that has a Z output. You may be able to do something with the Z in the program without it wired up but I dont know how to do that.

If all you are wanting to do is stop the counter for an event and then start it again I would go with the enable bit. If I misunderstand what you are trying to do let me know.
 
I'm just trying to pause and resume the counter. I'll try the enable bit but wanted to understand how the Z function woks in case the enable bit zero out the count on resume.
 
Enable bit doesn't clear the accumulator, just pauses/resumes. No worries.

No need for Z input whatsoever.
 
Because I've had to deal with many different counter modules, and modes of operation, and register widths, I just let the counter count all the time, but I don't actually use the module accumulator for my readings.

I just take a delta between each scan of the current counter value, and the value last scan (just a subtraction). Then I add that delta to my own internal count register. To gate it on and off, I just stop adding the delta when I don't want to count. I also ignore it for a couple seconds after the system powers up, so it will ignore counters that go to a preset value, or are retentive, or clear themselves on a PLC power up.

That method is also very handy where you might have several different re-settable counters driven by a single input, like reel length, shift length, 24 Hour length, statup lengths, etc.
 

Similar Topics

There was no great way to describe the behavior this temperature input is demonstrating, so I attached a video. It ramps, then hesitates, then...
Replies
17
Views
5,247
At issue: I'm trying to get multiple trends to pause (and also hopefully navigate) at the same time from one set of buttons on a display. This is...
Replies
0
Views
1,206
Hello, To make it short, the current system setup is a compact logic with a high speed counter 1769-HSC input module reading pulses from a flow...
Replies
0
Views
1,094
Hello, I am new to the forum. I have been using the Redlion Crimson 3.0 software for about 3 years. I have never had any luck pausing a timer...
Replies
3
Views
1,854
Currently I am using a bunch of TON's and TOF's to start up and turn off a motor sequence. I created a sub routine for the manual sequence and I...
Replies
15
Views
4,691
Back
Top Bottom