Subversion Repositories NaviCtrl

Compare Revisions

Ignore whitespace Rev 501 → Rev 502

/trunk/main.c
594,15 → 594,21
// ++++++++++++++++++++++++++++++++++++++++++++++
if(FromFC_LoadWP_List)
{
//if(FromFC_LoadWP_List & 0x80) -> load relative
WPL_Store.Index = FromFC_LoadWP_List;
if(PointList_ReadFromFile(&WPL_Store) == WPL_OK)
{
if(FC.StatusFlags & FC_STATUS_FLY) PointList_WPActive(TRUE);
GPS_pWaypoint = PointList_WPBegin(); // updates POI index
BeepTime = 150;
}
FromFC_LoadWP_List = 0;
WPL_Store.Index = FromFC_LoadWP_List;
if(PointList_ReadFromFile(&WPL_Store) == WPL_OK)
{
if(FromFC_LoadWP_List & 0x80)// -> load relative
{
if(!PointList_Move(1, &(GPSData.Position))) // try to move wp-list so that 1st entry matches the current position
{
PointList_Clear();
}
}
if(FC.StatusFlags & FC_STATUS_FLY) PointList_WPActive(TRUE);
GPS_pWaypoint = PointList_WPBegin(); // updates POI index
BeepTime = 150;
}
FromFC_LoadWP_List = 0;
}
// ++++++++++++++++++++++++++++++++++++++++++++++
 
/trunk/menu.c
360,7 → 360,6
else LCD_printfxy(0,3,"not calibrated");
break;
case 15:
// LCD_printfxy(0,0,"Ubat: %2i.%1i V", FC.BAT_Voltage/10, FC.BAT_Voltage%10);
LCD_printfxy(0,0,"Compass: %3i", FromFlightCtrl.GyroHeading / 10);
LCD_printfxy(0,1,"Man.-Offset:%3i", FC.FromFC_CompassOffset / 10);
if(FC.FromFC_DisableDeclination)
463,8 → 462,8
LCD_printfxy(11,3,"(in 0.1A)" );
for(i1 = 0; i1 < 3; i1++)
{
LCD_printfxy(0,i1+1,"%3d %3d %3d %3d ",BL3_Current(i1*4),BL3_Current(i1*4+1),BL3_Current(i1*4+2),BL3_Current(i1*4+3));
if(Motor[4 + i1 * 4].State == 0) break;
LCD_printfxy(0,i1+1,"%3d %3d %3d %3d ",BL3_Current(i1*4),BL3_Current(i1*4+1),BL3_Current(i1*4+2),BL3_Current(i1*4+3));
if(Motor[4 + i1 * 4].State == 0) break;
}
break;
 
499,9 → 498,9
WPL_Store.Index = index;
if(PointList_ReadFromFile(&WPL_Store) == WPL_OK)
{
if(FC.StatusFlags & FC_STATUS_FLY) PointList_WPActive(TRUE);
GPS_pWaypoint = PointList_WPBegin(); // updates POI index
BeepTime = 150;
if(FC.StatusFlags & FC_STATUS_FLY) PointList_WPActive(TRUE);
GPS_pWaypoint = PointList_WPBegin(); // updates POI index
BeepTime = 150;
}
}
LCD_printfxy(0,0,"Load WPL" );