APM:Libraries
Config.h
Go to the documentation of this file.
1 #pragma once
2 
3 #define IS_PLANE 1 // plane functions
4 #define IS_COPTER 1 // copter functions
5 // sets.model_type plane=0 copter=1
6 
7 
8 // EEPROM Version number, incrementing this will erase/upload factory settings. Only devs should increment this
9 #define VER 79
10 
11 
12 #define VERSION "2.4"
13 
14 //#define DEBUG
15 
16 #define SLAVE_BUILD // not separate device
17 #define HARDWARE_TYPE 2
18 
19 #define STARTUP_SCREEN 0
20 //#define AUTOBAUD // no port
21 //#define USE_SENSORS // no sensors
22 
23 #define FONT_UPLOAD 0 // no way
24 #define USE_SETUP 1
25 #define MAVLINK_CONFIG 1
26 #define MAVLINK_READ_EEPROM 1
27 #define MAVLINK_FONT_UPLOAD 1
28 #define MAVLINK_PARAMS 1
29 
30 #define USE_MAVLINK 1
31 #define MAV_REQUEST 1
32 #define PROTOCOL "MAVLink"
33 
34 
35 #define TELEMETRY_SPEED 57600 // initial speed of Serial port for CT
36 
37 // enter to loop() at ~1700ms
38 #define BOOTTIME 3700 // Time in milliseconds that we show boot loading bar and wait user input
39 
40 
41 // no LED
42  #define LED_BLINK {}
43  #define LED_ON {}
44  #define LED_OFF {}
45 
47 
48 #define OSD_MODEL "builtin"
49 
50 
51 #define on 1
52 #define off 0
53 
54 
55 #define RC_NEUTRAL 1500 // PWM pulse width for center stick
56 
57 #include "eeprom.h"
58 #include "version.h"
59 
60 
61 #ifdef DEBUG
62  #define DBG_PRINTLN(x) { console.print_P(PSTR(x)); Serial.println(); Serial.wait(); }
63  #define DBG_PRINTVARLN(x) { console.print_P(PSTR(#x)); Serial.print_P(PSTR(": ")); Serial.println(x); Serial.wait(); }
64  #define DBG_PRINTVAR(x) { console.print_P(PSTR(#x)); Serial.print_P(PSTR(": ")); Serial.print(x); Serial.print(" "); Serial.wait(); }
65  #define DBG_PRINTF(x,...) { console.printf_P(PSTR(x),## __VA_ARGS__); Serial.wait(); }
66 #else
67  #define DBG_PRINTLN(x) {}
68  #define DBG_PRINTVAR(x) {}
69  #define DBG_PRINTVARLN(x) {}
70  #define DBG_PRINTF(x,...) {}
71 #endif
72 
73 extern void osd_queue(uint8_t c);
74 
75 static const uint8_t chan=0;
76 
77 #define MAVLINK_USE_CONVENIENCE_FUNCTIONS
78 
79 #include "../osd_namespace.h"
80 using namespace OSDns;
81 
void osd_queue(uint8_t c)
static const uint8_t chan
Definition: Config.h:75