Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.arch.embedded > #29696

Re: PID controller: dummy questions

From pozz <pozzugno@gmail.com>
Newsgroups comp.arch.embedded
Subject Re: PID controller: dummy questions
Date 2020-06-26 10:59 +0200
Organization A noiseless patient Spider
Message-ID <rd4dct$9dc$1@dont-email.me> (permalink)
References <rd2odq$oiv$1@dont-email.me>

Show all headers | View raw


Il 25/06/2020 19:55, pozz ha scritto:
> I'm trying to implement a PID controller in C for an embbeded system. 
> This is the first time. I think I haven't fully understand the theory.

I read all your answers, but I didn't get the point.

I'm thinking of a system where a process variable (PV, such as a liquid 
flow) must match a desired set point (SP, such as 1 lt/min). The 
controller can change a control variable (CV, such as a voltage applied 
to an electronic valve).

If we need 1 lt/min we start opening the valve increasing the voltage 
control. When we see 1 lt/min on a flowmeter, we stop increasing the 
voltage that stay indefinitely at, for example, 1.0V.
At the steady state, when the error is zero, the control voltage *is 
not* zero, but 1.0V.

The proportional term (P) of a PID controller can't mimic this "manual 
control", because when the error is zero (we found the right voltage on 
the valve), the P term drops to zero and the valve would close.

When I use my brain, I will do:

- the error is high, rotate the knob fast
- the error is low (we are approaching the desidered value), rotate the 
knob slowly
- the error is zero, ok stop rotating the knob

The P term of a PID controller works in a different way:

- the error is high, high voltage control, open the valve high
- the error decreases, low voltage control, the valve starts closing
- the error is zero, close the valve completely (P=0)


Maybe my brain works as an integrative-only controller?

Back to comp.arch.embedded | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

PID controller: dummy questions pozz <pozzugno@gmail.com> - 2020-06-25 19:55 +0200
  Re: PID controller: dummy questions Hans-Bernhard Bröker <HBBroeker@t-online.de> - 2020-06-25 21:14 +0200
  Re: PID controller: dummy questions DJ Delorie <dj@delorie.com> - 2020-06-25 15:29 -0400
    Re: PID controller: dummy questions David Brown <david.brown@hesbynett.no> - 2020-06-26 08:43 +0200
  Re: PID controller: dummy questions Richard Damon <Richard@Damon-Family.org> - 2020-06-25 22:21 -0400
  Re: PID controller: dummy questions pozz <pozzugno@gmail.com> - 2020-06-26 10:59 +0200
    Re: PID controller: dummy questions David Brown <david.brown@hesbynett.no> - 2020-06-26 11:07 +0200
    Re: PID controller: dummy questions Rick C <gnuarm.deletethisbit@gmail.com> - 2020-06-26 09:10 -0700
    Re: PID controller: dummy questions Richard Damon <Richard@Damon-Family.org> - 2020-06-26 12:29 -0400
      Re: PID controller: dummy questions Rick C <gnuarm.deletethisbit@gmail.com> - 2020-06-26 12:00 -0700
        Re: PID controller: dummy questions Richard Damon <Richard@Damon-Family.org> - 2020-06-26 22:24 -0400
          Re: PID controller: dummy questions Paul Rubin <no.email@nospam.invalid> - 2020-06-26 21:41 -0700
            Re: PID controller: dummy questions DJ Delorie <dj@delorie.com> - 2020-06-27 01:15 -0400
              Re: PID controller: dummy questions Paul Rubin <no.email@nospam.invalid> - 2020-06-26 23:12 -0700
                Re: PID controller: dummy questions Rick C <gnuarm.deletethisbit@gmail.com> - 2020-06-27 00:07 -0700
                Re: PID controller: dummy questions pozz <pozzugno@gmail.com> - 2020-06-27 16:53 +0200
                Re: PID controller: dummy questions David Brown <david.brown@hesbynett.no> - 2020-06-27 17:31 +0200
                Re: PID controller: dummy questions Rick C <gnuarm.deletethisbit@gmail.com> - 2020-06-27 10:09 -0700
                Re: PID controller: dummy questions Rick C <gnuarm.deletethisbit@gmail.com> - 2020-06-27 15:44 -0700
                Re: PID controller: dummy questions Richard Damon <Richard@Damon-Family.org> - 2020-06-27 12:34 -0400
                Re: PID controller: dummy questions DJ Delorie <dj@delorie.com> - 2020-06-27 11:51 -0400
            Re: PID controller: dummy questions Rick C <gnuarm.deletethisbit@gmail.com> - 2020-06-26 23:06 -0700
              Re: PID controller: dummy questions Paul Rubin <no.email@nospam.invalid> - 2020-06-26 23:18 -0700
                Re: PID controller: dummy questions Rick C <gnuarm.deletethisbit@gmail.com> - 2020-06-27 00:23 -0700
            Re: PID controller: dummy questions Tauno Voipio <tauno.voipio@notused.fi.invalid> - 2020-06-27 10:28 +0300
            Re: PID controller: dummy questions Richard Damon <Richard@Damon-Family.org> - 2020-06-27 18:13 -0400
    Re: PID controller: dummy questions Hans-Bernhard Bröker <HBBroeker@t-online.de> - 2020-06-26 22:30 +0200
      Re: PID controller: dummy questions Phil Martel <pomartel@comcast.net> - 2020-06-28 13:10 -0400

csiph-web