Subversion Repositories Projects

Rev

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

Rev 783 Rev 800
Line 19... Line 19...
19
 ****************************************************************************/
19
 ****************************************************************************/
20
 
20
 
21
#ifndef _MAIN_H
21
#ifndef _MAIN_H
22
#define _MAIN_H
22
#define _MAIN_H
23
 
23
 
-
 
24
#ifndef MCU
-
 
25
#define MCU atmega162
-
 
26
#endif
-
 
27
 
-
 
28
#ifndef __AVR_ATmega162__
-
 
29
#define __AVR_ATmega162__
-
 
30
#endif
-
 
31
 
-
 
32
 
24
#include <avr/pgmspace.h>
33
#include <avr/pgmspace.h>
25
#include "mk-data-structs.h"
34
#include "mk-data-structs.h"
26
 
35
 
27
/* ##########################################################################
36
/* ##########################################################################
28
 * Debugging and general purpose definitions
37
 * Debugging and general purpose definitions
Line 43... Line 52...
43
 
52
 
44
#ifndef FCONLY
53
#ifndef FCONLY
45
#define FCONLY 0                // set to 1 if you do NOT have a NaviCtrl and the OSD is
54
#define FCONLY 0                // set to 1 if you do NOT have a NaviCtrl and the OSD is
46
#endif                          // connected to the FC directly
55
#endif                          // connected to the FC directly
47
 
56
 
48
#define HUD 1               // set to 0 to disable HUD by default
57
#define HUD 1                   // set to 0 to disable HUD by default
49
#define ARTHORIZON 0            // set to 1 to enable roll&nick artificial horizon by default
58
#define ARTHORIZON 0            // set to 1 to enable roll&nick artificial horizon by default
50
#define BIGVARIO 0                      // set to 1 to enable the big vario bar on right side
59
#define BIGVARIO 0              // set to 1 to enable the big vario bar on right side
51
#define STATS 1                         // set to 1 to enable statistics during motor off by default
60
#define STATS 1                 // set to 1 to enable statistics during motor off by default
52
#define WARNINGS 1                      // set to 1 to display battery+rc warning even if HUD is disabled
61
#define WARNINGS 1              // set to 1 to display battery+rc warning even if HUD is disabled
53
 
62
 
54
//#define UBAT_WRN  94          // voltage for blinking warning, like FC settings (deprecated)
63
//#define UBAT_WRN  94          // voltage for blinking warning, like FC settings (deprecated)
55
//#define UBAT_MAX 114          // maximal battery voltage for battery-sign (deprecated)
64
//#define UBAT_MAX 114          // maximal battery voltage for battery-sign (deprecated)
56
#define CELL_VOLT_MAX 37        // max voltage per battery cell (37 for LiPo)
65
#define CELL_VOLT_MAX 37        // max voltage per battery cell (37 for LiPo)
57
#define CELL_VOLT_MIN 32        // min voltage per battery cell (maybe 32 for LiPo?)
66
#define CELL_VOLT_MIN 32        // min voltage per battery cell (maybe 32 for LiPo?)
58
#define CELL_NUM -1                     // -1 for auto, 3 for 3s1p and 4 for 4s1p
67
#define CELL_NUM -1             // -1 for auto, 3 for 3s1p and 4 for 4s1p
59
#define RCLVL_WRN 100           // make the RC level blink if below this number
68
#define RCLVL_WRN 100           // make the RC level blink if below this number
60
 
69
 
61
// ### read datasheet before changing stuff below this line :)
70
// ### read datasheet before changing stuff below this line :)
62
#define BLINK   0b01001111      // attribute byte for blinking characters
71
#define BLINK   0b01001111      // attribute byte for blinking characters
63
#define INVERT  0b00101111      // attribute byte for inverted characters
72
#define INVERT  0b00101111      // attribute byte for inverted characters
Line 71... Line 80...
71
 
80
 
72
/* ##########################################################################
81
/* ##########################################################################
73
 * FLAGS usable during runtime that get saved
82
 * FLAGS usable during runtime that get saved
74
 * ##########################################################################*/
83
 * ##########################################################################*/
75
#define COSD_FLAG_HUD                     1
84
#define COSD_FLAG_HUD                     1
76
#define COSD_FLAG_ARTHORIZON      2
85
#define COSD_FLAG_ARTHORIZON              2
77
#define COSD_FLAG_BIGVARIO                4
86
#define COSD_FLAG_BIGVARIO                4
78
#define COSD_FLAG_STATS                   8
87
#define COSD_FLAG_STATS                   8
79
#define COSD_FLAG_WARNINGS               16
88
#define COSD_FLAG_WARNINGS               16
80
#define COSD_FLAG_STROMVOLT              32
89
#define COSD_FLAG_STROMVOLT              32
81
#define COSD_FLAG_FCCURRENT              64
90
#define COSD_FLAG_FCCURRENT              64
82
#define COSD_FLAG_AGGRHORIZON   128
91
#define COSD_FLAG_AGGRHORIZON           128
83
 
92
 
84
 
93
 
85
#define COSD_FLAG_NTSC                    1
94
#define COSD_FLAG_NTSC                    1
86
#define COSD_FLAG_GPSHEIGHT               2
95
#define COSD_FLAG_GPSHEIGHT               2
87
#define COSD_FLAG_FCMODE                  4
96
#define COSD_FLAG_FCMODE                  4