Subversion Repositories FlightCtrl

Rev

Rev 1984 | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
1 ingob 1
#ifndef _MAIN_H
1622 killagreg 2
#define _MAIN_H
1 ingob 3
 
1923 holgerb 4
//#define DEBUG                                                 // use to activate debug output to MK-Tool: use Debug(text);
1438 ingob 5
//#define ACT_S3D_SUMMENSIGNAL
1928 holgerb 6
//#define RECEIVER_SPEKTRUM_DX7EXP
7
//#define RECEIVER_SPEKTRUM_DX8EXP
1438 ingob 8
 
1 ingob 9
// neue Hardware
1662 killagreg 10
#define ROT_OFF   {if((PlatinenVersion == 10)||(PlatinenVersion >= 20)) PORTB &=~0x01; else  PORTB |= 0x01;}
11
#define ROT_ON    {if((PlatinenVersion == 10)||(PlatinenVersion >= 20)) PORTB |= 0x01; else  PORTB &=~0x01;}
1 ingob 12
#define ROT_FLASH PORTB ^= 0x01
1058 killagreg 13
#define GRN_OFF   {if((PlatinenVersion < 12)) PORTB &=~0x02; else PORTB |= 0x02;}
14
#define GRN_ON    {if((PlatinenVersion < 12)) PORTB |= 0x02; else PORTB &=~0x02;}
173 holgerb 15
#define GRN_FLASH PORTB ^= 0x02
1 ingob 16
 
1435 killagreg 17
#define SYSCLK F_CPU
18
 
1 ingob 19
//+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
20
 
1155 hbuss 21
#define J3High    PORTD |= 0x20
22
#define J3Low     PORTD &= ~0x20
23
#define J4High    PORTD |= 0x10
24
#define J4Low     PORTD &= ~0x10
25
#define J5High    PORTD |= 0x08
26
#define J5Low     PORTD &= ~0x08
27
 
1 ingob 28
extern volatile unsigned char SenderOkay;
1236 killagreg 29
extern unsigned char BattLowVoltageWarning;
1 ingob 30
extern unsigned char CosinusNickWinkel, CosinusRollWinkel;
173 holgerb 31
extern unsigned char PlatinenVersion;
723 hbuss 32
extern unsigned char SendVersionToNavi;
1702 holgerb 33
extern unsigned char FoundMotors;
1834 holgerb 34
extern unsigned char JetiBeep;
1268 hbuss 35
void LipoDetection(unsigned char print);
1512 holgerb 36
extern unsigned int FlugMinuten,FlugMinutenGesamt,FlugSekunden;
1 ingob 37
 
1930 holgerb 38
#include <avr/pgmspace.h>
39
 
40
#if (defined(__AVR_ATmega1284__) || defined(__AVR_ATmega1284P__))
41
 
42
#endif
43
 
1 ingob 44
#include <stdlib.h>
45
#include <string.h>
46
#include <avr/io.h>
47
#include <avr/pgmspace.h>
48
#include <avr/interrupt.h>
49
#include <avr/eeprom.h>
50
#include <avr/boot.h>
51
#include <avr/wdt.h>
52
 
53
#include "old_macros.h"
54
 
55
#include "printf_P.h"
56
#include "timer0.h"
57
#include "uart.h"
58
#include "analog.h"
59
#include "twimaster.h"
60
#include "menu.h"
61
#include "rc.h"
62
#include "fc.h"
63
#include "gps.h"
304 ingob 64
#include "spi.h"
921 hbuss 65
#include "led.h"
1424 ingob 66
#include "spektrum.h"
1486 killagreg 67
#include "capacity.h"
1622 killagreg 68
#include "eeprom.h"
1435 killagreg 69
#include "libfc.h"
1917 holgerb 70
#include "hottmenu.h"
1636 ingob 71
#include "debug.h"
1 ingob 72
 
1419 ingob 73
 
1 ingob 74
#endif //_MAIN_H
75
 
76
 
77
 
78
 
79
 
80