Nyame Ephraim

Hi Experts, the pulses counted in my flow meter are not the same with what it counts in my PLC.

20 posts in this topic

Hi experts, the pulses counted in my flow meter are not the same with what is counted in my PLC.

my flow meter is set at 1 liter per pulse, and the pulse width is 100 mili-seconds 

my PLC filter is set at 5 micro-seconds.

example for 12-13 seconds in my flow meter readings 23 liters will be dispense

for the same 12-13 second it shows 12 liters dispensed on my HMI.

please what settings are required to make both the PLC and flow meter count the same ?

am using high speed counter for this application.

Please i will appreciate any contribution to enable me solve this problem 

thanks 

 

 

Share this post


Link to post
Share on other sites

With a 100msec pulse, I would just try a regular DC input for the signal and see what you get. 
Part numbers would help on the flow meter, PLC and high-speed counter card if applicable. 

Regards,
Garry

Share this post


Link to post
Share on other sites

You have asked a variety of questions about this project for the past several months, including correspondence directly with other Forum members.

If you are taking it up again, please provide details.

You have repeatedly claimed that your PLC "pulse count" does not match your HMI "pulse count" but you have not explained if they use different instruments, or if the HMI shows a value from inside the PLC.

 

Do not start posting a new question and expect Forum users to research your past to understand the history of the system you are analyzing.

Share this post


Link to post
Share on other sites

Hello Sir, thanks for the reply.

am using E+H promag 50 that's flow meter and Allen Bradley 1400. In builder HSC.

thanks 

Share this post


Link to post
Share on other sites

Can you provide the complete part number of the E+H Promag unit. Also a diagram of its output wiring to the AB 1400 would be helpful.

Share this post


Link to post
Share on other sites

What kind of HMI device are you using ?

How does the HMI read the flowrate ?

If the HMI reads from the MicroLogix 1400 data tables, that's fine.    We can figure out where the data is being scaled incorrectly by examining the MicroLogix 1400 program and the HMI program.

If the HMI is reading directly from the Promag 50, or from some other instrument, we need to know that to figure out the difference between those signals.
 

Share this post


Link to post
Share on other sites

He didn't mention an HMI. I believe he is reading liters directly on the flowmeter display and comparing that to the count recorded in the PLC.

Share this post


Link to post
Share on other sites

Hello Sir, thanks for the reply 

the HMI reads from the micrologix data table.

Am using Delta DOP B series HMI

Share this post


Link to post
Share on other sites

Hello all thanks for the Verious contributions. 

After going through the program detaily I realize that the flow meter actually counts the same with my PLC HSC. But now my HSC does not count the same with my count up  CTU.

For example the HSC is counting on 5 and CTU on 3

Please is there any possibilities for the both to count the same ?

Edited by Nyame Ephraim

Share this post


Link to post
Share on other sites

yes... make sure that pulses are slow enough and have clean edges

Share this post


Link to post
Share on other sites

Panic mode thanks for your contribution.

pulse width is 100  milliseconds I believe that's slow, secondly the reading from the flow meter aligns with the PLC HSC, but it's the CTU and HSC counts that does not align.

Share this post


Link to post
Share on other sites

Post the program and we'll tell you what to fix.

Share this post


Link to post
Share on other sites

100ms pulse is long if input filter and PLC scan time are short enough. also pulse of 100ms duration does not tell anything about duty cycle of your signal.

Share this post


Link to post
Share on other sites

Oh my god... if there ever was a plc program that screamed "please kill me", this is it :-0

 

You stated that while HSC counts 5, CTU counts 3.

this program shows that CPU counts pulses from L30.0, which is LSB of L30 and L30 is a copy of HSC accumulator.

let's see what HSC accumulator and L30 look like while counting from 0 to 5:

0000 

0001

0010

0011

0100

0101

CTU counts 3 because that is exactly number of times LSB changes from 0 to 1 by the time HSC reached 5

 

Share this post


Link to post
Share on other sites

Panic mode.

Okay thanks for the identification'

please how do I rectify this ?

Share this post


Link to post
Share on other sites

few things come to mind:

1. why do you want two separate counters to keep track of same thing? if one of them has correct value, just use that one. 

2. this program needs some serious comments

3. this program needs some structure. there are way too many circular references. 

Share this post


Link to post
Share on other sites

Thanks panic mode, I will restructure the program.

but I need to use the count up. For accumulation and pre-set for my application.

Share this post


Link to post
Share on other sites

no worries, 

i would recommend to CLEARLY state problem, system configuration and define goals. 

based on what i glanced over, you have:

1. single PLC output controlling the pump. it is unclear if pump has any other controls that will affect the flow rate or if there is any flow control valve etc. this is not very good if you plan on dispensing small quantities reliably.

2. it is unclear what is the accuracy you expect. normally one would want feedback that is several times more accurate than what you are aiming to do. if your goal is to measure quantities that are +/- 1L, your flow meter should give maybe 10 pulses per Liter (or 50, or more...). it is also unclear what to tolerance can be.... is it +/- some value within preset OR at least preset value. 

3. program seem to make use of push button that is a start for pump. but i am unsure what you are really doing here or what the process is. i assume you want to present quantity to be dispensed from HMI. every time button is pressed, pump will start and dispense amount that is reasonably close to that quantity. This will be monitored by HSC. 

 

 

This is just what i assumed and not necessarily what you really need. But the point is that clear description is needed before one can start understanding... or offering help.

If above is correct, then setup of Preset value would be simple and independent of what HSC or CTU or push button or output controlling pump do.

Signal to start dispensing should NOT be tied directly to output. pressing pump start button should latch a bit. this bit should be used to run pump until process is complete and then this bit should be reset. start PB should be conditioned to use only rising edge or if someone leans on the button for too long or when button fails, you will be dispensing endlessly. probably not a good idea.

HMI should show dispensed quantity (progress and finished value) by monitoring HSC. There is not need to have both HSC and CTU. 

 

 

Share this post


Link to post
Share on other sites

Thank you very much panic mode for the write up.

my goal is I wish to control flow. For example if I need 100 liters i should input the requirement in my HMI and once 100 liters is dispense The pump should stop, Different amount of litters maybe requested depending on the need. 

Now my flow meter has been set at 1 liters per pulse, pulse width is 100ms and scan cycle is 3-5ms

that is the scope of the project

thanks

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now