Main Page | Modules | Data Structures | Directories | File List | Data Fields | Globals | Related Pages

uartdma.c File Reference


Detailed Description

Definition in file uartdma.c.

#include "at91sam7s64.h"
#include "global.h"
#include "processor.h"
#include "buffer.h"
#include "uartdma.h"

Go to the source code of this file.

Defines

#define pUSART0   ((AT91S_USART*)AT91C_BASE_US0)
#define pUSART1   ((AT91S_USART*)AT91C_BASE_US1)
#define pUSART2   ((AT91S_USART*)AT91C_BASE_DBGU)
#define pPDC(dev)   ((AT91S_PDC*)((unsigned char*)(dev)+0x100))

Functions

void uart0Init (uint16_t bauddiv, uint32_t mode)
 initializes uart
void uart1Init (uint16_t bauddiv, uint32_t mode)
void uart2Init (uint16_t bauddiv, uint32_t mode)
void uart0InitBuffers (void)
 initializes transmit and receive buffers
void uart1InitBuffers (void)
void uart2InitBuffers (void)
void uartInitDmaTx (int dev)
 setup DMA for circular-buffer transmit
void uartInitDmaRx (int dev)
 setup DMA for circular-buffer receive
cBuffer * uartGetRxBuffer (int dev)
 get receive buffer structure
int uartSendByte (int dev, int data)
 sends a single byte over the uart
int uartGetByte (int dev)
 gets a single byte from the uart receive buffer
int uartSendBlock (int dev, unsigned char *data, unsigned int len)
 sends a block of data over the uart
int uartGetBlock (int dev, unsigned char *data, unsigned int len)
 gets a block of data from over the uart
void uart0Service (void)
 interrupt service handlers
void uart1Service (void)
void uart2Service (void)

Variables

cBuffer UartRxBuffer [3]
 uart receive buffers
cBuffer UartTxBuffer [3]
 uart transmit buffers
AT91S_USART *const pUSART [3] = { AT91C_BASE_US0, AT91C_BASE_US0, AT91C_BASE_DBGU }


Generated on Mon Nov 6 23:37:00 2006 for Procyon ARMlib by  doxygen 1.4.2