-
Notifications
You must be signed in to change notification settings - Fork 208
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
a5a8741
commit 892de17
Showing
1 changed file
with
22 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,24 @@ | ||
# simple-pid | ||
|
||
A simple and easy to use PID controller. | ||
A simple and easy to use PID controller in Python. If you want a PID controller without external dependencies that just works, this is for you! The PID was designed to be robust with help from [Brett Beauregards guide](http://brettbeauregard.com/blog/2011/04/improving-the-beginners-pid-introduction/). | ||
|
||
Usage is very simple: | ||
|
||
```python | ||
from simple_pid import PID | ||
pid = PID(1, 0.1, 0.05, setpoint=1) | ||
|
||
# assume we have a system we want to control in controlled_system | ||
v = controlled_system.update(0) | ||
|
||
while True: | ||
# compute new ouput from the PID according to the systems current value | ||
control = pid(v) | ||
|
||
# feed the PID output to the system and get its current value | ||
v = controlled_system.update(control) | ||
``` | ||
|
||
Complete API documentation can be found [here](). | ||
|
||
## Installation |