Subversion Repositories NaviCtrl

Compare Revisions

Ignore whitespace Rev 932 → Rev 933

/trunk/main.h
20,7 → 20,7
 
#define VERSION_MAJOR 2
#define VERSION_MINOR 21
#define VERSION_PATCH 8
#define VERSION_PATCH 9
// 0 = A
// 1 = B
// 2 = C
/trunk/menu.c
462,7 → 462,7
else sign = '+';
LCD_printfxy(0,2,"Mag.Declinat.:%c%i.%1i", sign, abs(GeoMagDec)/10,abs(GeoMagDec)%10);
}
LCD_printfxy(0,3,"True Compass: %3i", GyroCompassCorrected/10);
LCD_printfxy(0,3,"True Compass: %3i", OrientationGyroCompassCorrected/10);
break;
case 18: // User Parameter
LCD_printfxy(0,0,"UP1:%3i UP2:%3i",Parameter.User1,Parameter.User2);
/trunk/spi_slave.c
142,7 → 142,8
SPI_Version_t FC_Version;
s16 POI_KameraNick = 0;
u8 NC_Wait_for_LED = 0;
s16 GyroCompassCorrected = 0; // corrected with the magnetic declination
s16 GyroCompassCorrected = 0; //in 0,1° corrected with the magnetic declination
s16 OrientationGyroCompassCorrected = 0; //in 0,1° corrected with the FC-Orientation
s16 CompassSetpointCorrected = 0; // The compass setpoint that the FC tries to keep - corrected with the magnetic declination
s16 CompassSetpoint = 0; // in 0,1°
s16 SimulatedDirection = 0; // only for flight simulation
395,6 → 396,7
ToFlightCtrl.CompassHeading = Compass_Heading;
DebugOut.Analog[10] = ToFlightCtrl.CompassHeading;
GyroCompassCorrected = (3600 + FromFlightCtrl.GyroHeading + FC.FromFC_CompassOffset + GeoMagDec) % 3600;
OrientationGyroCompassCorrected = ((3600 + GyroCompassCorrected + Parameter.OrientationAngle * 150) % 3600);
if(ToFlightCtrl.CompassHeading >= 0) ToFlightCtrl.CompassHeading = (360 + ToFlightCtrl.CompassHeading + FromFlightCtrl.GyroYaw / 12) % 360;
// ToFlightCtrl.MagVecX = MagVector.X;
// ToFlightCtrl.MagVecY = MagVector.Y;
625,7 → 627,7
ToFlightCtrl.Param.Byte[0] = 3+3; // index +3, weil bei HoTT V4 3 Bytes eingeschoben wurden
ToFlightCtrl.Param.Byte[1] = 9-1; // how many
//-----------------------------
ToFlightCtrl.Param.Byte[2] = GyroCompassCorrected / 20;//NaviData.HomePositionDeviation.Bearing / 2;
ToFlightCtrl.Param.Byte[2] = OrientationGyroCompassCorrected / 20;//NaviData.HomePositionDeviation.Bearing / 2;
i1 = GPSData.Speed_Ground; // in cm/sec
i1 *= 36;
i1 /= 1000;
/trunk/spi_slave.h
120,6 → 120,7
extern s16 FromFC_LaserAltCorrect_dm;
extern u8 FromFC_Parameter_LaserAltitude;
extern s32 BaroAltimeter_dm;
extern s16 OrientationGyroCompassCorrected; // The compass setpoint that the FC tries to keep - corrected with the magnetic declination
 
typedef struct
{
/trunk/triggerlog.c
106,7 → 106,7
TrigLogging.ServoControlNick = FromFC_ServoNickControl;
TrigLogging.ServoControlPoi = POI_KameraNick;
if(SimulationFlags) TrigLogging.Yaw = CompassSetpointCorrected;
else TrigLogging.Yaw = GyroCompassCorrected;
else TrigLogging.Yaw = OrientationGyroCompassCorrected;
TrigLogging.NewData++;
 
if(NMEA_cnt)