Derivative calculation was wrong all along #40
Loading…
Reference in New Issue
No description provided.
Delete Branch "pid_hotfix"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Derivative should be (error - last_error), but because we're using input to calculate derivative to prevent kick, and the relationship between error and input is (error = target - input), using input for derivative caluculation means it should be calculated as (last_input-input).
The PID controller implementation was taken in verbatim from Ionpak. Maybe it might make sense to backport some fixes.
Yes, ionpak generally needs an overhaul regarding this and a long list of other problems. I'm planning to look into it at some point.