?lang_form? ?lang_select? ?lang_submit? ?lang_endform?
{HEADER END}
{BLAME START}

library

?curdirlinks? -

Blame information for rev 6

Line No. Rev Author Line
1 6 kaklik /*! \file uartsw2conf.h \brief Interrupt-driven Software UART Driver Configuration. */
2 //*****************************************************************************
3 //
4 // File Name : 'uartsw2conf.h'
5 // Title : Interrupt-driven Software UART Driver Configuration
6 // Author : Pascal Stang - Copyright (C) 2002-2003
7 // Created : 7/20/2002
8 // Revised : 4/27/2004
9 // Version : 0.6
10 // Target MCU : Atmel AVR Series (intended for the ATmega16 and ATmega32)
11 // Editor Tabs : 4
12 //
13 // Description :
14 // This uart library emulates the operation of a UART (serial port) using
15 // the AVR's hardware timers, I/O pins, and some software.
16 //
17 // Specifically, this code uses:
18 // -Timer 2 Output Capture for transmit timing
19 // -Timer 0 Output Capture for receive timing
20 // -External Interrupt 2 for receive triggering
21 //
22 // The above resources cannot be used for other purposes while this software
23 // UART is enabled. The overflow interrupts from Timer0 and Timer2 can still
24 // be used for other timing, but the prescalers for these timers must not be
25 // changed.
26 //
27 // Serial output from this UART can be routed to any I/O pin. Serial input
28 // for this UART must come from the External Interrupt 2 (INT2) I/O pin.
29 // These options should be configured by editing your local copy of
30 // "uartsw2conf.h".
31 //
32 // This code is distributed under the GNU Public License
33 // which can be found at http://www.gnu.org/licenses/gpl.txt
34 //
35 //*****************************************************************************
36  
37 #ifndef UARTSW2CONF_H
38 #define UARTSW2CONF_H
39  
40 // constants/macros/typdefs
41  
42 #define UARTSW_RX_BUFFER_SIZE 0x20 ///< UART receive buffer size in bytes
43  
44 // UART transmit pin defines
45 #define UARTSW_TX_PORT PORTB ///< UART Transmit Port
46 #define UARTSW_TX_DDR DDRB ///< UART Transmit DDR
47 #define UARTSW_TX_PIN PB7 ///< UART Transmit Pin
48  
49 // UART receive pin defines
50 // This pin must correspond to the
51 // External Interrupt 2 (INT2) pin for your processor
52 #define UARTSW_RX_PORT PORTD ///< UART Receive Port
53 #define UARTSW_RX_DDR DDRD ///< UART Receive DDR
54 #define UARTSW_RX_PORTIN PIND ///< UART Receive Port Input
55 #define UARTSW_RX_PIN PD4 ///< UART Receive Pin
56  
57 #endif
{BLAME END}
{FOOTER START}

Powered by WebSVN v2.8.3