Subversion Repositories FlightCtrl

Rev

Rev 509 | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 509 Rev 521
Line 32... Line 32...
32
//#define TIMER_RELOAD_VALUE  -78 					// bei 20MHz
32
//#define TIMER_RELOAD_VALUE  -78 					// bei 20MHz
33
#endif
33
#endif
Line 34... Line 34...
34
 
34
 
35
********************************************************************************
35
********************************************************************************
-
 
36
in "uart.h" hinzufügen: (bei den anderen #defines)
-
 
37
 
-
 
38
#define BAUD_RATE1 57600		//Baud Rate für UART2
36
in "uart.h" hinzufügen: (bei den anderen #defines)
39
 
37
#if defined (__AVR_ATmega644P__)
40
#if defined (__AVR_ATmega644P__)
38
#	define USR  UCSR0A
41
#	define USR  UCSR0A
39
#	define UCR  UCSR0B
42
#	define UCR  UCSR0B
40
#	define UDR  UDR0
43
#	define UDR  UDR0
Line 49... Line 52...
49
#   define UDRE UDRE0
52
#   define UDRE UDRE0
50
#   define INT_VEC_RX  SIG_USART_RECV
53
#   define INT_VEC_RX  SIG_USART_RECV
51
#   define INT_VEC_TX  SIG_USART_TRANS
54
#   define INT_VEC_TX  SIG_USART_TRANS
52
#endif
55
#endif
Line 53... Line 56...
53
 
56
 
-
 
57
extern void UART1_Init (void);
Line 54... Line 58...
54
#define BAUD_RATE1 57600		//Baud Rate für UART2
58
 
55
 
59
 
Line 84... Line 88...
84
 
88
 
85
 
89
 
86
//+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
90
//+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
87
//++ Sende-Part der Datenübertragung an zweiten UART
91
//++ Sende-Part der Datenübertragung an zweiten UART
88
//+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
92
//+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Line 89... Line 93...
89
SIGNAL(SIG_USART1_RECV)
93
SIGNAL(SIG_USART1_TRANS)
Line 90... Line 94...
90
{
94
{
91
 
95
 
92
 
96
 
93
 
97
 
94
}
98
}
Line 95... Line 99...
95
 
99
 
Line 132... Line 136...
132
TXCIE		>	TXCIE1
136
TXCIE	>	TXCIE1
133
U2X		>	U2X1
137
U2X		>	U2X1
134
UCSRB		>	UCSR1B
138
UCSRB	>	UCSR1B
135
UDRE 		>	UDRE1
139
UDRE 	>	UDRE1
Line 136... Line 140...
136
 
140
 
137
UCSR0A	>	UCSR0A				
141
UCSR0A	>	UCSR1A				
138
UCSR0B	>	UCSR0B				
142
UCSR0B	>	UCSR1B				
139
UDR0  	>	UDR0  				
143
UDR0  	>	UDR1  				
140
UBRR0L	>	UBRR0L				
144
UBRR0L	>	UBRR1L				
141
EICR0B	>	EICR0B				
145
EICR0B	>	EICR1B				
142
TXEN0 	>	TXEN0 				
146
TXEN0 	>	TXEN1 				
143
RXEN0 	>	RXEN0 				
147
RXEN0 	>	RXEN1 				
144
RXCIE0	>	RXCIE0				
148
RXCIE0	>	RXCIE1				
145
TXCIE0	>	TXCIE0				
149
TXCIE0	>	TXCIE1				
146
U2X0  	>	U2X0  				
150
U2X0  	>	U2X1  				
147
UCSR0B	>	UCSR0B				
151
UCSR0B	>	UCSR1B