summaryrefslogtreecommitdiffstats
path: root/ctrl/flight-control.vala
diff options
context:
space:
mode:
authorSebastian Reichel <sre@ring0.de>2012-11-02 19:24:33 +0100
committerSebastian Reichel <sre@ring0.de>2012-11-02 19:24:33 +0100
commitadfe7c37b333c245256885aa3d8ac1077e24ff18 (patch)
tree215e00e7e64a042fabbbd8b6ffc412137c223992 /ctrl/flight-control.vala
parenta0bd460f7f901d48d111511d9e7c2d92aaac0fa2 (diff)
downloadmicrocopterd-master.tar.bz2
make PID timing more precise, setup P, I and DHEADmaster
Diffstat (limited to 'ctrl/flight-control.vala')
-rw-r--r--ctrl/flight-control.vala5
1 files changed, 4 insertions, 1 deletions
diff --git a/ctrl/flight-control.vala b/ctrl/flight-control.vala
index f0e1345..964c449 100644
--- a/ctrl/flight-control.vala
+++ b/ctrl/flight-control.vala
@@ -27,8 +27,11 @@ public class FlightControl {
public FlightControl() throws Error {
pid = new PID[PIDEntry.length];
- for(int i=0; i<PIDEntry.length; i++)
+ for(int i=0; i<PIDEntry.length; i++) {
pid[i] = new PID();
+ pid[i].calibrate(100.0, 0, -300.0);
+ pid[i].clear();
+ }
}
/**