PID library

Post your requests and ideas on the future development of mikroPascal for dsPIC30/33 and PIC24.
Post Reply
Author
Message
OT
Posts: 581
Joined: 19 May 2005 05:08
Location: Fairbanks, Alaska

PID library

#1 Post by OT » 12 Nov 2005 08:43

Referring to the discussion in the basic wishlist forum,
http://www.mikroe.com/forum/viewtopic.php?t=175
I am definitely interested in a PID library for use with dsPIC. While it is/has been important to have the base functions of the language and most essential libraries working first, the PID library wish should not be put away. I see several applications relating to temperature and pump/pressure/flow control where it would be useful.

piort
Posts: 1379
Joined: 28 Dec 2005 16:42
Location: Laval,Québec,Canada,Earth... :-)
Contact:

#2 Post by piort » 25 Apr 2006 23:23

Hi OT,

i know its a old post but the prob with PID control depand to analogic input AND analogic output so they depand of wich D/A converter you use ... event the brand new DSpic33F dont have analogic output... Worst of all , most of industrial control work on 4 to 20ma... so with 0-5 volt input and output you have to use resistor to be able to use the ouput. When you use resistor you lost some precision... I have make some test and with 5% resistor on 10 bit D/A converter i lost .625 celsius degree at 20 degree and 2.5 at 250 ... and that is without the imprecision of the temp reader... If you want to control the temp of your aquarium or pool, that isnt a matter but if you want make some good beer, that imprecision can scrap your batch :lol:

LGR
Posts: 3204
Joined: 23 Sep 2004 20:07

#3 Post by LGR » 25 Apr 2006 23:40

piort wrote:. event the brand new DSpic33F dont have analogic output...
But they all have PWM, which can be easily used for analog out. And if you need 4-20 ma, Burr-Brown makes some 4-20 ma driver chips.

The bigger problem as I see it with a PID library, is that it has to be interrupt-driven, because timing is critical. I don't know if anyone has figured out a good way to integrate library functions and interrupts. If you can solve that problem, it should be easy.
If you know what you're doing, you're not learning anything.

Post Reply

Return to “mikroPascal for dsPIC30/33 and PIC24 Wish List”