Subversion Repositories FlightCtrl

Rev

Rev 1444 | Rev 1486 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 1444 Rev 1479
Line 5... Line 5...
5
// + porting the sources to other systems or using the software on other systems (except hardware from www.mikrokopter.de) is not allowed
5
// + porting the sources to other systems or using the software on other systems (except hardware from www.mikrokopter.de) is not allowed
6
// + see the File "License.txt" for further Informations
6
// + see the File "License.txt" for further Informations
7
// ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
7
// ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
8
#include "main.h"
8
#include "main.h"
Line 9... Line -...
9
 
-
 
10
unsigned int  TestInt = 0;
-
 
11
#define ARRAYGROESSE 10
-
 
12
unsigned char Array[ARRAYGROESSE] = {1,2,3,4,5,6,7,8,9,10};
9
 
13
char DisplayBuff[80] = "Hallo Welt";
10
char DisplayBuff[80] = "Hallo Welt";
Line 14... Line 11...
14
unsigned char DispPtr = 0;
11
unsigned char DispPtr = 0;
15
 
12
 
Line 53... Line 50...
53
           LCD_printfxy(0,1,"HW:V%d.%d SW:%d.%d%c",PlatinenVersion/10,PlatinenVersion%10, VERSION_MAJOR, VERSION_MINOR, VERSION_PATCH +'a');
50
           LCD_printfxy(0,1,"HW:V%d.%d SW:%d.%d%c",PlatinenVersion/10,PlatinenVersion%10, VERSION_MAJOR, VERSION_MINOR, VERSION_PATCH +'a');
54
           LCD_printfxy(0,2,"Setting:%d %s",GetActiveParamSetNumber(),Mixer.Name);
51
           LCD_printfxy(0,2,"Setting:%d %s",GetActiveParamSetNumber(),Mixer.Name);
55
           if(I2CTimeout < 6) LCD_printfxy(0,3,"I2C ERROR!!!")
52
           if(I2CTimeout < 6) LCD_printfxy(0,3,"I2C ERROR!!!")
56
                   else
53
                   else
57
           if(MissingMotor) LCD_printfxy(0,3,"Missing BL-Ctrl:%d!!",MissingMotor)
54
           if(MissingMotor) LCD_printfxy(0,3,"Missing BL-Ctrl:%d!!",MissingMotor)
58
           else LCD_printfxy(0,3,"(c) Holger Buss");
-
 
59
//           if(RemoteTasten & KEY3) TestInt--;
-
 
60
//           if(RemoteTasten & KEY4) TestInt++;
-
 
61
           break;
55
           break;
62
    case 1:
56
    case 1:
63
          if(EE_Parameter.GlobalConfig & CFG_HOEHENREGELUNG)
57
          if(EE_Parameter.GlobalConfig & CFG_HOEHENREGELUNG)
64
           {
58
           {
65
           LCD_printfxy(0,0,"Height:  %5i",(int)(HoehenWert/5));
59
           LCD_printfxy(0,0,"Height:  %5i",(int)(HoehenWert/5));
Line 159... Line 153...
159
           LCD_printfxy(0,2,"Gs:%4i  Gi:%4i ",ExternControl.Gas,ExternControl.Gier);
153
           LCD_printfxy(0,2,"Gs:%4i  Gi:%4i ",ExternControl.Gas,ExternControl.Gier);
160
           LCD_printfxy(0,3,"Hi:%4i  Cf:%4i ",ExternControl.Hight,ExternControl.Config);
154
           LCD_printfxy(0,3,"Hi:%4i  Cf:%4i ",ExternControl.Hight,ExternControl.Config);
161
           break;
155
           break;
162
    case 13:
156
    case 13:
163
           LCD_printfxy(0,0,"BL-Ctrl Errors " );
157
           LCD_printfxy(0,0,"BL-Ctrl Errors " );
164
           LCD_printfxy(0,1,"%3d %3d %3d %3d ",MotorError[0],MotorError[1],MotorError[2],MotorError[3]);
158
                   LCD_printfxy(0,1,"%3d %3d %3d %3d ",Motor[0].State & MOTOR_STATE_ERROR_MASK,Motor[1].State & MOTOR_STATE_ERROR_MASK,Motor[2].State & MOTOR_STATE_ERROR_MASK,Motor[3].State & MOTOR_STATE_ERROR_MASK);
165
           LCD_printfxy(0,2,"%3d %3d %3d %3d ",MotorError[4],MotorError[5],MotorError[6],MotorError[7]);
159
                   LCD_printfxy(0,2,"%3d %3d %3d %3d ",Motor[4].State & MOTOR_STATE_ERROR_MASK,Motor[5].State & MOTOR_STATE_ERROR_MASK,Motor[6].State & MOTOR_STATE_ERROR_MASK,Motor[7].State & MOTOR_STATE_ERROR_MASK);
166
           LCD_printfxy(0,3,"%3d %3d %3d %3d ",MotorError[8],MotorError[9],MotorError[10],MotorError[11]);
160
                   LCD_printfxy(0,3,"%3d %3d %3d %3d ",Motor[8].State & MOTOR_STATE_ERROR_MASK,Motor[9].State & MOTOR_STATE_ERROR_MASK,Motor[10].State & MOTOR_STATE_ERROR_MASK,Motor[11].State & MOTOR_STATE_ERROR_MASK);
167
           break;
161
           break;
168
    case 14:
162
    case 14:
169
           LCD_printfxy(0,0,"BL-Ctrl found " );
163
           LCD_printfxy(0,0,"BL-Ctrl found " );
170
           LCD_printfxy(0,1," %c   %c   %c   %c ",MotorPresent[0] + '-',MotorPresent[1] + '-',MotorPresent[2] + '-',MotorPresent[3] + '-');
164
                   LCD_printfxy(0,1," %c   %c   %c   %c ",'-' + 4 * (Motor[0].State>>7),'-' + 5 * (Motor[1].State>>7),'-' + 6 * (Motor[2].State>>7),'-' + 7 * (Motor[3].State>>7));
171
           LCD_printfxy(0,2," %c   %c   %c   %c ",MotorPresent[4] + '-',MotorPresent[5] + '-',MotorPresent[6] + '-',MotorPresent[7] + '-');
165
                   LCD_printfxy(0,2," %c   %c   %c   %c ",'-' + 8 * (Motor[4].State>>7),'-' + 9 * (Motor[5].State>>7),'-' + 10 * (Motor[6].State>>7),'-' + 11 * (Motor[7].State>>7));
172
           LCD_printfxy(0,3," %c   -   -   -",MotorPresent[8] + '-');
166
                   LCD_printfxy(0,3," %c   -   -   - ",'-' + 12 * (Motor[8].State>>7));
173
                   if(MotorPresent[9]) LCD_printfxy(4,3,"10");
167
                   if(Motor[9].State>>7)  LCD_printfxy(4,3,"10");
174
                   if(MotorPresent[10]) LCD_printfxy(8,3,"11");
168
                   if(Motor[10].State>>7) LCD_printfxy(8,3,"11");
175
                   if(MotorPresent[11]) LCD_printfxy(12,3,"12");
169
                   if(Motor[11].State>>7) LCD_printfxy(12,3,"12");
176
           break;
170
           break;
177
    case 15:
171
    case 15:
178
           LCD_printfxy(0,0,"Flight-Time  " );
172
           LCD_printfxy(0,0,"Flight-Time  " );
179
           LCD_printfxy(0,1,"Total:%5umin",FlugMinutenGesamt);
173
           LCD_printfxy(0,1,"Total:%5umin",FlugMinutenGesamt);
180
           LCD_printfxy(0,2,"Act:  %5umin",FlugMinuten);
174
           LCD_printfxy(0,2,"Act:  %5umin",FlugMinuten);