Weighing Control - continued

I collected a little more data on the weighing system I've been trying to improve.

I did a sort of Cm machine capability calculations, 20 weighing's, took max - min * 1.67 and figured out what % of the set point it was running. One bin was dosing at a rate for 7 seconds and was running at 0.9%, another bin was dosing at a rate of 3 seconds and was running over 11%. My conclusion is that the operator should not be allowed to set the speed!

The "InFly" amount, final weight minus weight when feeding stops, varies from about 1/2 the flow rate as slow flow to around 2X flow rate at higher flows. Plotting some data I came up with a calculation of Estimate_InFly = Flow^1.24/0.656 or something like that for a flow range of 0.04 to 3.3 lbs/second.

So at slow speed is seems relatively accurate and at high speed it's hard to hit the mark. Imagine locking up the brakes to stop at a stop sign, you'll be more accurate from 5 mph than from 60 mph.

I'm wanting to use a motion control profile calculations using acceleration, speed, and deceleration to try to stop at the final weight "position". I'm not sure what I should base my calculations on, 0-100% speed, 0-max flow, or weight. The maximum flow is unknown, I can ramp up to a desired flow or

100% but how do I decide when to start decelerating? The weight lags, response to changes lag.... I can taper from flow rate to 0 at so many % per second or change flow rate ramped down, or predict the actual weight using my approximate flow formula. I don't need high accuracy on the way as long as I can stop close to the final weight, if I slow too soon, it takes longer feeding at a slow rate, if I overshoot, the operator has to stop and scoop out chemical.

I need to do a controlled stop relatively fast and accurate, using the car braking analogy, I need anti-lock brakes to remain in control as I stop fast. Any ideas to control flow to go from, for example, 2lbs/second to

0.1lbs/sec at 0.1lbs before the final weight? Or flow from 2lbs/second to 0 at a set point?

RogerN

Reply to
RogerN
Loading thread data ...

You haven't mentioned how quickly you can stop the flow.

In an ideal world you'd just open the thing all the way up, add your measured weight plus the "in flight" estimate, and as soon as the sum equals your target, then BANG! close the door. You'd be perfect every time.

That's the ideal world...

I'd make an estimator for the "in bin" plus "in flight", then have a simple proportional controller from that estimate to your flow target. I assume that the flow is measured, and that you have to control it, so I'd wrap a PI or a PID controller around that flow value.

If you do it all correctly then for most of the time your flow target will be maxed out. When you get close to the right amount, things will rapidly shut down, then you'll get a few dribs and drabs out to bring the weight right up to the dot.

If your flow control isn't super-quick, either because you can't achieve much bandwidth with the thing operating in a linear mode, or because you're demanding more speed out of the valve (or whatever actuator there is) than is available, then you'll need to ramp back the proportional gain from estimated total to flow target.

I bet you'll end up filling the bin quickly and accurately, though.

--

Tim Wescott 
Wescott Design Services 
http://www.wescottdesign.com
Reply to
Tim Wescott

It's either an analog output card controlling a vibratory feeder controller or Profi-Bus communication to a VFD for auger motors. Shut off is however long it takes the vibratory to settle or ramp down time for the motors. The augers have doors but we have to wait for the motor to stop or else if feeds product and binds the door.

We have some loss of weight systems that work pretty much that way.

Today I tried ramping down, when it gets to the estimated ramp down point, I record the weight from the load cell and then decrement it each pass by

1/(DecelTime * 50) that's for 50 passes per second. I have a PID trying to hold it to this ramping down set point. For some reason it isn't working as well as I like, they only ran the line I'm testing on for a couple of hours today, so I didn't locate or solve the problem. It would help if I had trend graphs like the Rockwell software has, I could tune the control better.

RogerN

Reply to
RogerN

Trying to tune things without bringing the line down must be a royal pain in the behind -- fortunately the loops I close are all in products, so I get to have something to play with all by my oneself in a lab.

--
Tim Wescott 
Control system and signal processing consulting 
www.wescottdesign.com
Reply to
Tim Wescott

Now I'm thinking about trying to us a flow rate as a set point for the PID and base it on the weight set point - current weight.

Since the "inFly" varies from around 2 X flow for fast flow to flow/2, I may try to set maybe flow_SP := Lbs_Err * 0.2 for high flow rates to something like flwo_SP := Lbs_Err * 1 for low flow rates.

This week the line programmer from Germany is supposed to be there to upgrade our software so I may not get much testing done. He used to support us good but since he's went from independent to employee, he hardly responds when we need help. That's why I'm trying to dig into the problems and learning to fix the line without depending on others.

I'd kind of like to find out if I can get Siemens data into a visual basic program and plot or graph the data. I use that a lot with Rockwell in trying to see what's going on in a machine.

It's fun to take a machine that runs bad, operators hate, and make it run better than the others.

RogerN

Reply to
RogerN

I'd try to model it somehow so you can test different approaches more quickly. I'm battling a difficult control problem myself for a backburner project where I need to control the rate of liquid going into an evaporator by using the temperature reading from a thermocouple. I already ordered a book which should be more hands-on than the theoretical books I have from my EE study.

AFAIK it is possible to dump data from a Siemens S7 PLC into a CSV file which you can load into Excel. A guy I work with every now and then is a real wizzard when it comes to Siemens industrial automation gear. I could get you in touch with him. He has projects all over the world.

--
Failure does not prove something is impossible, failure simply 
indicates you are not using the right tools... 
nico@nctdevpuntnl (punt=.) 
--------------------------------------------------------------
Reply to
Nico Coesel

The braking analogy is good, but the disk drive seek servo analogy is bette r. Closed loop HDD servo's have for decades used two PID loops to achieve min seek times and zero position error. This is the same as your requirement fo r max flow rate and zero weight error at target. The main limitation is th e rate of change of velocity or acceleration in your system controlled by s ome current.

The reason this is done is to make two second order feedback loops and avoi d the effects of a 3rd order system instability created by the 2nd derivati ve of position or weight count in your case.

Create a setpoint profile for Velocity and use PID control for velocity fee dback with a transition from Velocity control (or rate of weight transfer) to Position Control ( or accumulated weight control) within the de-accelera tion or braking limits of your system.

You are still counting weight transfer (Position) but control starts with a velocity error loop then switches to position error loop when your positi on error or weight remaining is < X. Then your PID weight loop takes over from the PID velocity loop for weight/second. This is how the better close d loop servos work for max speed and zero error. For zero overshoot, the PI D loop on position error must be critically damped.

Disturbances and target error, such as mechanical stiction of mass flow con trol must be considered.

**Adding random noise feedback and averaging helps reduce hysteresis, if th at exists in the control system.
Reply to
Anthony Stewart

ElectronDepot website is not affiliated with any of the manufacturers or service providers discussed here. All logos and trade names are the property of their respective owners.