Go to Post it should not matter the gender of a person but rather their ability. - vivek16 [more]
Home
Go Back   Chief Delphi > Technical > Programming
CD-Media   CD-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
 
 
Thread Tools Rate Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Spotlight this post!  
Unread 01-03-2010, 13:46
FRC4ME FRC4ME is offline
Registered User
FRC #0339
 
Join Date: Feb 2008
Rookie Year: 2007
Location: Fredericksburg, VA
Posts: 324
FRC4ME has a brilliant futureFRC4ME has a brilliant futureFRC4ME has a brilliant futureFRC4ME has a brilliant futureFRC4ME has a brilliant futureFRC4ME has a brilliant futureFRC4ME has a brilliant futureFRC4ME has a brilliant futureFRC4ME has a brilliant futureFRC4ME has a brilliant futureFRC4ME has a brilliant future
WPI PIDController doesn't account for varying dT?

I was looking through WPI's PIDController code and noticed that they do not incorporate dT into the calculations anywhere. For example, the calculate() method contains the line:

Code:
m_totalError += m_error;
Shouldn't it be like this?

Code:
m_totalError += m_error * m_period;
The way it is now, changing the period of the PID loop would require resetting of the I and D constants. Multiplying the integral by the period and dividing the derivative by the period would remove this inconvenience.
__________________
Go directly to queue. Do not pass pit.
 


Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
RobotDrive + PIDController = possible? oddjob C/C++ 4 14-01-2010 23:33
Can I get my account name changed or my account deleted? bendh18 CD Forum Support 4 14-06-2009 19:21
WPI Lib Source Code from subversion at WPI Sourceforge steinra Programming 6 02-12-2008 16:34
Code for sensor still doesn't work Ianuser Programming 3 14-02-2007 10:17
Varying levels of enforcement... Gui Cavalcanti General Forum 9 28-03-2002 16:29


All times are GMT -5. The time now is 03:27.

The Chief Delphi Forums are sponsored by Innovation First International, Inc.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi