AnsweredAssumed Answered

UART on BF525

Question asked by anjana on Jun 28, 2010
Latest reply on Jun 28, 2010 by Andreas

Hi,

 

I am using bf525 processor(our own board). I want to send some data to bill serial and receive the data  back.  we are sing UART1. we are using Pf14/pf15 to transmit and recive operations. We are using DMA mode for this(DMA10/DMA11).  but i am not able to recive/transmit data.  Is there any neeed of pull-up resisitors across the pf pins?.

 

 

since i am using pf pins for peripherals i have configure the FER and MUX registers like this..

*pPORTF_FER  =0xc000; //PF14/pf15
*pPORTF_MUX=0x0800;//UART1 TX/RX

 

I have initialized my uart like this.

*pUART1_GCTL = 0x01;
    *pUART1_LCR = 0x80;

 

    *pUART1_DLL = 0x48;   //for 115200 baudrate
    *pUART1_DLH = 0x00;
        *pUART1_LCR = 0x0003;
        *pUART1_THR = 0x0000;
        *pUART1_LSR = 0x0061;
        *pUART1_IIR = 0x0003;    // UART Interrupt Identification Register
        *pUART1_IER = 0x0007

 

 

and the DMA initializations for Rx and TX are

 

void Init_DMA_UART_RX(void)                              //dma channel 10 for receiving
{
   
  
    *pDMA10_START_ADDR     = buf_rx;                    //start address
    *pDMA10_CURR_ADDR      =*pDMA10_START_ADDR;
    *pDMA10_X_COUNT        = rx_buf_len ;          //size of the buffer
    *pDMA10_X_MODIFY       = 0x0001;                  //in steps of what it has to increment
    *pDMA10_PERIPHERAL_MAP = 0xA000;               //configuring dma as a reciever
    *pDMA10_CONFIG         = 0x1083;                  //enabling the dma for single dimension array
    ssync();
    ssync();
   
   
    //return 0;
}//end Init_DMA_UART_RX   

 

int Init_DMA_UART_TX(void)                                       //dma channel 11 for transmitting
{
    *pDMA11_START_ADDR     = buf_tx;                //start address
     *pDMA7_X_COUNT        = 25;
    *pDMA11_X_MODIFY       = 0x0001;                 //in steps of what it has to increment
    *pDMA11_PERIPHERAL_MAP = 0xB000;               //configuring dma as a tx
    *pDMA11_CONFIG         = 0x00A1;             //enabling the dma for single dimension array
    
    ssync();
   ssync();
  
   return 0;
  
}//end Init_DMA_UART_TX

 

Please help me

 

Thanks in Advance

 

Regards

Anjana

Outcomes