Host Engineering Forum

General Category => Do-more CPUs and Do-more Designer Software => Do-more Programming Examples => Topic started by: artonpaper on November 26, 2017, 06:50:53 PM

Title: PID program
Post by: artonpaper on November 26, 2017, 06:50:53 PM
I want to program a simple PID loop using the simulator. How do I establish the Setpoint? Seems there is no input for this.


Thanks,

Art
Title: Re: PID program
Post by: Mike Nash on November 26, 2017, 07:48:29 PM
It will be the PID name and .SP so PID_00.SP for example. These are all in the help for PID.
Title: Re: PID program
Post by: BobO on November 26, 2017, 09:50:47 PM
I'll give more detail in the morning, but the sim has a process simulator, and it shows the steps required...it's very simple to set up.
Title: Re: PID program
Post by: BobO on November 27, 2017, 01:01:49 PM
We're going to put together a detailed step by step and post it here. It isn't hard. You can set up the process simulator, create the logic, tune the loop, and test the loop...all in about 5 minutes. It definitely isn't intuitive though, and we realized that we kinda dropped the ball on it. All of the information exists, but it's not in a single place.

So stand by...
Title: Re: PID program
Post by: franji1 on November 27, 2017, 01:17:42 PM
Try looking at the PID1.dmd Example Project (under your Projects folder, look for Examples\Do-more Simulator\PID1.dmd).  The Start Page of that project walks you through SOME of these steps.

It is a program for the Simulator that lets you play around with the "oven" process.  It then lets you use a PID to control the oven, then utilizes a RAMPSOAK to run through a temperature profile.
Title: Re: PID program
Post by: Garyhlucas on November 28, 2017, 08:19:15 PM
Absolutely you MUST try the autotune function on your process! Truly freaking awesome. Blower controlled on pressure took about 5 seconds. Pump controlled on flow about 10 seconds. Pump controlled on tank level about 1 minute. Chemical pump on pH took almost 45 minutes because of slow system response. Nailed it perfectly! I am old enough to remember standing in front of a control panel for days while adjusting trim pots on analog PID controls, so this is just amazing.
Title: Re: PID program
Post by: artonpaper on November 29, 2017, 10:03:39 PM
Thanks for the feedback.

I did find the PID sample oven program and was able to use the simulator to experiment. Still learning....thanks,

Art.
Title: Re: PID program
Post by: BobO on December 01, 2017, 10:38:25 AM
We've written an FAQ on how to get the processor simulator running.

http://www.hosteng.com/FAQFiles/Do-more.htm#FAQ0041
 (http://www.hosteng.com/FAQFiles/Do-more.htm#FAQ0041)