Closed loop speed controller


Results 1 to 9 of 9

Threaded View

  1. #7
    Join Date
    Oct 2005
    Location
    Sweden
    Posts
    3,612


    Did you find this post helpful? Yes | No

    Default

    Hi,
    About the sampling rate. The motor and whatever is attached to it has a certain mechanical time constant. If you apply a voltage to it it it takes a certain amount of time for it to "respond". If you sample a lot slower than this time constant you won't be able to get good control.

    I'll take a shot at an example:
    If we are controlling the temperature in our swimming pool (which probably have a very large time constant) perhaps we should read the actual temperature and calculate a new "drive-value" for the heater once every hour or even slower than that. But if we're controlling the position of the mirror in a laser-scanner we may need to read the actual position and calculate a new "drive-value" tens of thousands of times per second.

    Whatever the rate is (once a day or once every uS) it needs to be constant because the final output is based on the error itself (P) the magnitude and amount of time the error has been present (I) and the rate of change of the error (D).

    It all depends on how "stiff" you want the control-loop to be. You may get away with a sampling rate of 1s if you can live with very a slow response. If you need to "instantly" respond to the change in load you need to sample much much faster than that.

    There was a really good article available on the web called PID without a PhD explaining this a lot better than I can but I can't seem to find it. If you look around a bit you may be able to find it.

    EDIT: Here it is.

    HTH
    /Henrik Olsson
    Last edited by HenrikOlsson; - 26th January 2008 at 09:24. Reason: Found the article.

Similar Threads

  1. Controlsystem for compact sporting (clay shooting)
    By Fredrick in forum mel PIC BASIC Pro
    Replies: 11
    Last Post: - 30th July 2009, 16:48
  2. Serin to Serin2 ??
    By Gixxer in forum mel PIC BASIC Pro
    Replies: 3
    Last Post: - 25th January 2008, 03:56
  3. Replies: 14
    Last Post: - 26th September 2007, 05:41
  4. Serial Relays
    By tazntex in forum General
    Replies: 3
    Last Post: - 17th May 2007, 17:42
  5. calculating speed of a loop
    By EDWARD in forum mel PIC BASIC Pro
    Replies: 1
    Last Post: - 5th June 2005, 20:34

Members who have read this thread : 0

You do not have permission to view the list of names.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts