Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronic Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

Register Log in

Digital PID Controller

Status
Not open for further replies.

7rots51

Advanced Member level 4
Joined
May 17, 2002
Messages
1,184
Helped
25
Reputation
50
Reaction score
12
Trophy points
1,318
Activity points
9,651
digital pid controller

Hi

I need help on digital PID controller design .

any help welcome.

sch,c source code,theory,ebook,test methods,...

best regards
 

nebisman

Full Member level 4
Joined
Apr 13, 2002
Messages
226
Helped
10
Reputation
22
Reaction score
9
Trophy points
1,298
Activity points
1,849
fuzzy pid controller 8051

lpease send more specifications about the use of PID, (ex temperature control, system posistion ). I can help you, with several codes for pics microcontrollers

lots of information about general PID here:

http://www.onesmartclick.com/engineering/chemical-process-control.html

In the subject of digital control you need know practical algorithms nad the antiwindup methods.
 

svicent

Full Member level 6
Joined
Jul 11, 2001
Messages
322
Helped
32
Reputation
62
Reaction score
7
Trophy points
1,298
Activity points
2,293
digital pid controller code

Hi,

I hope this file can help you.

svicent.
 

7rots51

Advanced Member level 4
Joined
May 17, 2002
Messages
1,184
Helped
25
Reputation
50
Reaction score
12
Trophy points
1,318
Activity points
9,651
source code pid digital

hi
I want to design a single loop digital PID controller.
input: universal analog input(mV/V/mA/RTD/THC)
output: 0-20mA,4-20mA,0-5V,1-5V,0-10V,2-10V
comm: rs485 modbus protocol
alarm: two relay
display: LED ,and bar
keypad: membrane
......
I do not the problems and tips of PID design,I do not need auto tuning?!!

I do not know how to solve Integral windup!
please guide me.

bye
 

goodboy_pl

Full Member level 5
Joined
Mar 12, 2002
Messages
253
Helped
16
Reputation
32
Reaction score
15
Trophy points
1,298
Activity points
3,119
digital pid

designing digital pid...
well,are u familaiar with Digital Signal Processing?
if no,u can learn it very fast specially i recommend u to read the well known book writen by Alan V.oppenheim:Discrete-Time Signal Processing
designing a digital copy of an analog system like filters and controllers with feed back is described in this book chapter seven.
for start i can say followings:
1.use a sampling frequency of at least 10 times of loop B.W.,this eases the anti aliasing filter design and removes instability problem,also removes the need of inverse-sinc filter at output.
2.it is possible to use low cost 8bit UC such as 8051 and 8bit ADC and DAC but it is strictly recommende to write your program in 16bit(it is not necessary to write floating point software)to limit quantization error and instability problem.

with above guide lines it is possible to design a digital pid controller with 1khz BW and over 20khz sampling rate by a 8051 run by 12mhz xtal(~1mips)[it is assumed that code was written efficiently!]

about integrator wind up:it is abig problem in open loop integrators but when the loop is closed, it has a self limiting property and there is no overfolw danger,if it is not clear scetch theblock diagram of your pid and write tranfer function of input noise of controller to output then find steady state of output for step input to pid as a noise.

best!
 

wolf69

Advanced Member level 4
Joined
Sep 20, 2002
Messages
105
Helped
2
Reputation
4
Reaction score
0
Trophy points
1,296
Activity points
789
digital pid code

you can still use fuzzy logic that is more intuitive to tune...

Bye!
 

svicent

Full Member level 6
Joined
Jul 11, 2001
Messages
322
Helped
32
Reputation
62
Reaction score
7
Trophy points
1,298
Activity points
2,293
digital pid controller design

This file talks about TuningOfFuzzyPIDControllers.
 

hynix

Member level 5
Joined
Dec 17, 2002
Messages
84
Helped
2
Reputation
4
Reaction score
2
Trophy points
1,288
Location
Inda
Activity points
613
digital pid regulator

Hi all,
thanks for all the information provided here.Actually I am intrested in implimentation of fuzzy-PID using good microc. that can support this, also is it possible to implement neuro-fuzzy PID using microc. ? . any body out there can help me for this ....any ebook,good links or any good suggestion is appreciated
thanks. :)
 

wolf69

Advanced Member level 4
Joined
Sep 20, 2002
Messages
105
Helped
2
Reputation
4
Reaction score
0
Trophy points
1,296
Activity points
789
universal fuzzy+pid controller

Hi,
with f*u*z*z*y*T*e*c*h (can download the demo) you can design a fuzzy control system, simulate it, and generate the code (C code and still asm specific). It can still generate rules by samples data (this is what they call neuro fuzzy). Implementing a realtime neurofuzzy maybe is an harder game. I think there are other tools, I'm looking for them too. Anyway should be not too difficult to implement a fuzzy engine.
I have "fuz*zy lo*ic and neur*ofuzzy" by V*on Alt*rock and this is not a good stuff... very basic and without detailed examples.
 

hareshcooleng

Member level 1
Joined
Aug 6, 2010
Messages
36
Helped
1
Reputation
2
Reaction score
1
Trophy points
1,288
Location
ahmedabad
Activity points
1,480
Re: digital pid controller

hi
i have the code of digital, if u want that pls reply quick.
 

pnielsen

Member level 2
Joined
Mar 18, 2002
Messages
50
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,286
Activity points
319
Re: digital pid controller

Hello,

I read your post. I am using a Cypress Psoc 5 MCU with SOC. I am trying to set upa three mode controller. A long long time ago I designed athree mode controller based on analog logic. But I am having a mental block for digital. Do you have the code for a Digital PID controler. I am trying to control air flow.
 

nigelwright7557

Junior Member level 3
Joined
Aug 12, 2009
Messages
26
Helped
4
Reputation
8
Reaction score
4
Trophy points
1,283
Location
England
Activity points
1,393
Re: digital pid controller

A simple attack on PID can be used with this formula.
49*E1 + 70*E2 - 25*E3
You will need to tweak the gain to suit the application.

I have used this numerous times from motor speed control to temperature control and it works a treat.
 

pnielsen

Member level 2
Joined
Mar 18, 2002
Messages
50
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,286
Activity points
319
Thank you for sending the equation. Can you explaine how the the voltage inputs are used. I use a PID with a differential amp as the input. Then I perform my integration and differentiation.

Regards

Philip
 

nigelwright7557

Junior Member level 3
Joined
Aug 12, 2009
Messages
26
Helped
4
Reputation
8
Reaction score
4
Trophy points
1,283
Location
England
Activity points
1,393
Thank you for sending the equation. Can you explaine how the the voltage inputs are used. I use a PID with a differential amp as the input. Then I perform my integration and differentiation.

Regards

Philip
Just calculate the errors from the input voltage and the required voltage.
Shift the errors down each loop of your software.
 
  • Like
Reactions: m.tork

    m.tork

    points: 2
    Helpful Answer Positive Rating

pnielsen

Member level 2
Joined
Mar 18, 2002
Messages
50
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,286
Activity points
319
Thank you very much. In my analog circuit I took a differential amp. Set a setpoit. Took the feedback signal from the device under control. Fed this signal to the other side of the differential. When both signals were equal. Then the PID was at optimal. I used an integrater to remove the error. I forgot:-D:-D what my third amp was used for? Thanks for the feedback.

Thank You,

Philip
 

Status
Not open for further replies.
Toggle Sidebar

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Top