Subversion Repositories FlightCtrl

Compare Revisions

Ignore whitespace Rev 570 → Rev 571

/branches/salvo_gps/Basis_v0067g/trunk/README_Gps_Deutsch.txt
1,6 → 1,6
*********************************************************************
GPS Implementierung von Peter Muehlenbrock ("Salvo") für Mikrokopter/FlightCrtl
Stand 22.12.2007
Stand 23.12.2007
Verwendung der SW ohne Gewaehr. Siehe auch die Lizenzbedingungen in File Licensce_LPGL.txt und Licensce_GPL.txt
Die Version basiert auf Holgers V00.67g.
*********************************************************************
12,7 → 12,9
 
Software-Voraussetzungen:
In timer0.h muss die Ausrichtung des Kompasses bezogen auf die Nordachse des Kopters
eingetragen sein. KOMPASS_OFFSET (im hexfile =135 Grad) legt diesen Wert fest.
eingetragen sein. Wenn KOMPASS_OFFSET > 0 wird dieser Wert genommen
Wenn KOMPASS_OFFSET = 0 ist wird der UserParameter4 verwendet (=hexfile). Da die userparameter nur ein Byte lang sind werden Offsets von 0...358 Grad
durch einen Wert von 0...179 dargestellt.
 
Betriebs-Voraussetzungen:
Damit der Kompass sauber funktioniert, muss die waagrechte Lage (Gashebel Vollanschlag und Gier rechts)
22,7 → 24,7
Der GPS Hold Regler ist ein PID Regler, der ueber die UserParameter1(P), 2(I) und D(3) gesteuert wird.
UserParameter1 beschreibt den P-Anteil, UserParameter2 den I-Anteil und UserParameter3 den D-Anteil.
Hier kann und muss gespielt werden.Alle Parameter koennen direkt im Mikrokoptertool in den Settings eingestellt werden.
Standardwert ist 90 für den P-Anteil, 16 für den I-Anteil und 130 für den D-Anteil.
Standardwert ist 90 für den P-Anteil,24 für den I-Anteil und 130 für den D-Anteil.
Je größer die Werte desto "ruckeliger" reagiert die Regelung aber desto schneller und stärker greift sie auch.
Wenn alle 0 sind, ist der Regler deaktiviert.
 
/branches/salvo_gps/Basis_v0067g/trunk/README_Gps_English.txt
1,46 → 1,53
*********************************************************************
GPS Implementation by Peter Muehlenbrock ("Salvo") for Mikrokopter/FlightCrtl
As of 23.12.2007
Please note Licensce_LPGL.txt and Licensce_GPL.txt
As of 24.12.2007
Please note the files Licensce_LPGL.txt and Licensce_GPL.txt
This SW is based on Holgers V00.67g.
*********************************************************************
Hardware-requirements:
Calibrated compass of type CMPS03, horizontally adjusted
GPS module of type ublox, The messages "NAV_STATUS", "NAV_POSUTM" and "NAV_VELNED"
GPS module of type ublox, The messages "NAV_STATUS", "NAV_POSUTM" and "NAV_VELNED"
must be activated with 4 HZ update rate. All messages of type NMEA should be disabled.
The TX port of the GPS module must be connected to the RX input of the Flight Crtl. Baudrate is 57600 (like Kopter Tool).
 
UserParameter 4 tells the software the orientation for the compass. The difference between the "north" direction of the kopter
and the north direction of the compass is represented as follows 0...360 Grad Offset corresponds to a value of 0...180.
(A userparameter ist only 1 byte long and therefore can not directly represent 0..360 degree). Please check the correct values via the Koptertool
The "Kompass" debug value has to show the correct orientation: kopter front oriented to north => value approx 0 Degree)
UserParameter 4 tells the software the orientation for the compass. The difference between the "north" direction
( = Motor "vorne" or 1 as described in Holgers Flight Crtl manual) of the kopter
and the north direction of the compass is represented as follows: 0...360 degree offset corresponds to a value of 0...180.
(A userparameter ist only 1 byte long and therefore can not directly represent 0..360 degree). Please check the
correct value via the Koptertool. The "Kompass" debug value has to show the correct orientation:
kopter Motor vorne orientated to north => value approx 0 Degree)
 
Other requirements:
Please calibrate the ACC Sensor values (pitch full, yaw full right) in horizontal orientation of the kopter.
Please calibrate the ACC Sensor values (pitch full, yaw full right) in horizontal orientation of the kopter
as exactly as possible.
 
Parameters:
The GPS Hold regulator is of type PID: UserParameter1 =P(proportional), UserParameter2 = I(ntegral), UserParameter3 = D(ifferential).
Standardvalues for P,I and D are 90,24,130.
The GPS Hold regulator is of type PID: UserParameter1 =P(proportional), UserParameter2 = I(ntegral),
UserParameter3 = D(ifferential). Standardvalues for P,I and D are 90,24,130.
The i-Part may be set to 0 if a small deviation from hold position is acceptable. The D-Part is important to avoid
oscillating.
Please find out the best values yourself.
It might be useful to put the P and D Part on potis and test the behaviour in flight.
 
 
Requirements for GPS_Hold:
The gps module has do provide a 3D-fix. If succesfull, you can hear a longer beep when performing a gyro calibration.
The red led on the FlightCrtl flashes with a 4 Hz rate.
Without a succesfull position fix at calibration the GPS functionality ist completely disabled.
The red led on the FlightCrtl flashes with a 4 Hz rate if the gps module delivers a position fix.
 
 
Enabling GPS_Hold in fligh:
GPS Hold is automatically activated if the sticks for roll and nick are in neutral position for about 400ms.
Moving the stick disables immediately the Hold mode.
Moving the stick immediately disables the Hold mode. The GPS Hold function doesn not change height, pitch or yaw.
 
 
GPS Coming Home function
-- coming later :-)
GPS Coming-Home function
The coming-home function is activated by the same switch as for the height regulator, if the switch is set to maximum.
The height regulator itself is activated at approx. Maximum/2.
 
 
Other changes:
-automatically pitch reduction if the battery voltage falls more than 0.2V below the warning limit.
-Output PC6 can be used to switch TX data between a Bluetooth and the GPS Module (further hardware required) to the RX input of the FlightCrtl
-automatically Yaw gyro compensation if compass is available.
- automatic pitch reduction if the battery voltage falls more than 0.2V below the warning limit.
- Output PC6 can be used to switch TX data between a Bluetooth and the GPS Module (further hardware required) to the RX input of the FlightCrtl
- automatic Yaw gyro compensation if compass is available.
 
 
 
/branches/salvo_gps/Basis_v0067g/trunk/flightctrl.aws
1,0 → 0,0
<AVRWorkspace><IOSettings><CurrentRegisters/></IOSettings><part name="ATMEGA644"/><Files><File00000 Name="G:\Mikrokopter\Flight_Crtl\v0067g\timer0.c" Position="266 101 1248 593" LineCol="109 0" State="Maximized"/><File00001 Name="G:\Mikrokopter\Flight_Crtl\v0067g\analog.h" Position="288 130 1262 592" LineCol="0 0" State="Maximized"/><File00002 Name="G:\Mikrokopter\Flight_Crtl\v0067g\makefile" Position="310 159 1284 621" LineCol="411 0" State="Maximized"/><File00003 Name="G:\Mikrokopter\Flight_Crtl\v0067g\main.c" Position="262 71 1402 774" LineCol="125 0" State="Maximized"/></Files></AVRWorkspace>
<AVRWorkspace><IOSettings><CurrentRegisters/></IOSettings><part name="ATMEGA644"/><Files><File00000 Name="G:\Mikrokopter\Flight_Crtl\v0067g\timer0.c" Position="266 101 1248 593" LineCol="109 0" State="Maximized"/><File00001 Name="G:\Mikrokopter\Flight_Crtl\v0067g\analog.h" Position="288 130 1262 592" LineCol="0 0" State="Maximized"/><File00002 Name="G:\Mikrokopter\Flight_Crtl\v0067g\makefile" Position="310 159 1284 621" LineCol="411 0" State="Maximized"/><File00003 Name="G:\Mikrokopter\Flight_Crtl\v0067g\main.c" Position="332 188 1306 650" LineCol="125 0" State="Maximized"/><File00004 Name="G:\Mikrokopter\Flight_Crtl\v0067g\gps.h" Position="354 217 1328 679" LineCol="0 0" State="Maximized"/><File00005 Name="G:\Mikrokopter\Flight_Crtl\v0067g\timer0.h" Position="262 71 1402 774" LineCol="9 22" State="Maximized"/></Files></AVRWorkspace>
/branches/salvo_gps/Basis_v0067g/trunk/timer0.h
2,8 → 2,9
#define TIMER_TEILER CK8
#define TIMER_RELOAD_VALUE 250
 
// Salvo Kompassoffset 31.8.2007 ***********
#define KOMPASS_OFFSET 0 // Winkel zwischen Nordachse Kopter und Nordachse Kompass
// Salvo Kompassoffset 23.12.2007 ***********
//#define KOMPASS_OFFSET 135// Winkel zwischen Nordachse Kopter und Nordachse Kompass
#define KOMPASS_OFFSET 0// Winkel zwischen Nordachse Kopter und Nordachse Kompass
// Wenn 0 wird der UserParameter4 fuer den Offset verwendet (0..360 Grad entspricht 0 ..180)
// Salvo End