Skip to content

Commit c3f64fa

Browse files
committed
Update
Adds the SetOutputSum(sum); function
1 parent 9655589 commit c3f64fa

File tree

5 files changed

+12
-3
lines changed

5 files changed

+12
-3
lines changed

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -106,6 +106,7 @@ void SetSampleTimeUs(uint32_t NewSampleTimeUs); // Set PID compute sample time,
106106
void SetProportionalMode(pMode pMode); // Set pTerm based on error (default), measurement, or both
107107
void SetDerivativeMode(dMode dMode); // Set the dTerm, based error or measurement (default).
108108
void SetAntiWindupMode(iAwMode iAwMode); // Set iTerm anti-windup to iAwCondition, iAwClamp or iAwOff
109+
void SetOutputSum(float sum); // sets the output summation value
109110
```
110111
111112
### Autotuner

library.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "QuickPID",
3-
"version": "3.1.8",
3+
"version": "3.1.9",
44
"description": "A fast PID controller with multiple options. Various Integral anti-windup, Proportional, Derivative and timer control modes.",
55
"keywords": "PID, controller, signal, autotune, tuner, stune",
66
"repository":

library.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
name=QuickPID
2-
version=3.1.8
2+
version=3.1.9
33
author=David Lloyd
44
maintainer=David Lloyd <[email protected]>
55
sentence=A fast PID controller with multiple options. Various Integral anti-windup, Proportional and Derivative control modes.

src/QuickPID.cpp

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/**********************************************************************************
2-
QuickPID Library for Arduino - Version 3.1.8
2+
QuickPID Library for Arduino - Version 3.1.9
33
by dlloydev https://github.com/Dlloydev/QuickPID
44
Based on the Arduino PID_v1 Library. Licensed under the MIT License.
55
**********************************************************************************/
@@ -262,6 +262,11 @@ void QuickPID::Reset() {
262262
dTerm = 0;
263263
}
264264

265+
// sets the output summation value
266+
void QuickPID::SetOutputSum(float sum) {
267+
outputSum = sum;
268+
}
269+
265270
/* Status Functions************************************************************
266271
These functions query the internal state of the PID.
267272
******************************************************************************/

src/QuickPID.h

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -73,6 +73,9 @@ class QuickPID {
7373
void SetAntiWindupMode(iAwMode iAwMode);
7474
void SetAntiWindupMode(uint8_t IawMode);
7575

76+
// sets the output summation value
77+
void SetOutputSum(float sum);
78+
7679
void Initialize(); // Ensure a bumpless transfer from manual to automatic mode
7780
void Reset(); // Clears pTerm, iTerm, dTerm and outputSum values
7881

0 commit comments

Comments
 (0)