This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

uPP Channel A (TX) to B (RX)

In our design we are using AM1810BZWTA3 processor.Currently we are testing uPP in 8 bit with loopback mode Channel A to B & Channel B to A.

1/ Channel A to B:

Upp Register Configurations :

  a/ uPP_UPCTL Register Value---->0x00000007 (A is Tx and B is Rx)

 b/ uPP_UPICR Register Value---->0x00180020 (Signals are enabling related to A(Tx) and B(Rx))

 c/ uPP_UPTCR Register Value---->0x00030303 (Transmit threshold and Read threshold for DMA Channel Q and I are set to 256 bytes)

 d/ Digital Loop Back A to B is Enabled uPP_UPDLB = 0x00001000

Dma Related Configuration :

Channel-Q is Receive

Channel-I is Transmit

Line_Count = 1;

Byte_Count = 4096;

Line_Offset_Count = 0;

When we run the Upp with the above Configuration settings in Arm1810, In Inturrept routine continiously Underrun or Overflow Inturrept related to Channel-I are getting, But data corruption is not happening(Data size is 4k(4096)).

The following output as shown below:

TxBuff b b b

RxBuff

bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb

bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb

bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb

bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb

bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb

bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb

Underrun or Overflow Inturrept Occured for Channel- I

TxBuff c c c

RxBuff

cccccccccccccccccccccccccccccccc

cccccccccccccccccccccccccccccccc

cccccccccccccccccccccccccccccccc

cccccccccccccccccccccccccccccccc

cccccccccccccccccccccccccccccccc

cccccccccccccccccccccccccccccccc

Underrun or Overflow Inturrept Occured for Channel -I

2/ Channel B to A:

The same configuration parameters used & working fine.

Kindly let us known your feedback/ suggestions for Channel A to B issue for Underrun or Overflow Inturrept Occuring.

  • Moving this to the proper forum.
  • Vijay Varma,

    Please check the below configurations for UPP

    UPCTL.value=0;
    UPCTL.bits.IWB = 1;  //16 bit interface
    UPCTL.bits.DPWB = 2; //10 bit data

    UPCTL.bits.DPFA = 0;
    UPCTL.bits.DPWA = 2;
    UPCTL.bits.IWA = 1;

    UPCTL.bits.CHN = 1;  //dual channel mode
    UPCTL.bits.MODE = 2; //0 all recv, 1 all xmit, 2 a recv b xmit, 3 a xmit b recv
           //Channel A ADC, Channel B DAC

    UPICR.value=0;

    UPIVR.value=0;
    UPIVR.bits.VALB = 0x1000;
    UPIVR.bits.VALA = 0x0000;

    UPTCR.value=0;  //all values 0 for 64byte DMA bursts read / write
    UPDLB.value=1;  //loopback    
    UPIES.value=0;  //dont enable any interrupts
    UPPCR.value = 0;  
    UPPCR.bits.EN = 1;    //enable uPP
    UPPCR.bits.RTEMU = 1; //allow emulator use
    UPPCR.bits.SOFT = 1;  //allow emulation

    If interrupt enabled, Watch for interrupt events. Reprogram the DMA as necessary (checking that the PEND bit in the uPP DMA channel status register (UPxS2) is 0).

    System Priority:
    When the uPP operates in parallel with EDMA, assigning higher priority to the uPP may help the uPP avoid underflow or overflow conditions.

    You can find the reference code for uPP in a digital loopback mode at the wiki article,
    http://processors.wiki.ti.com/index.php/Using_the_uPP_EVM_example_applications_from_the_BIOS_PSP

  • Pubesh,

    We have tried with above suggested configurations,but data corruption is happening.

    We tried with 16 bit configuration A to B Upp Loop Back Mode, with below configurations issues are observed.

    TX-->Channel-A and RX--->Channel-B (A-to-B)
    Upp Configurations and settings
    Clk-75Mhz
    uPP_UPCTL----->0x02020007
    uPP_UPICR----->0x00180020
    uPP_UPIVR----->0x0000FFFF
    uPP_UPTCR----->0x00030303
    uPP_UPDLB----->0x00001000

    -----------Dma Related Configurations-----
    Every Packet size is 4k (unsigned short 4096 size)
    allocation of memory kmalloc(MAX_SIZE, GFP_DMA).
    and mapping the memory using dma_map_single API
    Line_count = 1
    Dma Transaction Size is = (4096) bytes
    Line_offset = 0
    -------------------------------------------
    Observed issue :
    At the receiving end always 12 to 15 bits are corruption is happening out of (0 t0 15 bits)

  • Vijay Varma,

    Take this as a reference code for UPP, and modify or configure the UPP to according your target / device.

    5224.ARM EVM UPP Test.zip

  • Hi All,

    I am working on the SBC8018 board for upp driver. I am able to build and install the upp driver code given on the below link,

    I am trying to run loop back using linux upp driver code.

     I have allocated statically tx/rx buffer. While reading rx buffer I am always getting value as 0.

    Could you please let me know, is static buffer allocation affect this DMA operation.

    Here is my upp configuration,


     UPPID = 44231100
     UPPCR =       8a
     UPDLB =     1000
    RSVD0 =        0
    UPCTL =        7
     UPICR =        0
     UPIVR =        0
     UPTCR =        0
     UPISR =     1010
     UPIER =        0
     UPIES =        0
     UPIEC =        0
     UPEOI =        0
                =        0
                =        0
                =        0
     UPID0 = c6df0068
     UPID1 =    10040
     UPID2 =        0
                =        0
     UPIS0 = c6df0068
     UPIS1 =    20000
     UPIS2 =       80
                =        0

    UPQD0 = c6df2210

    UPQD1 =    10040
     UPQD2 =        0
                  =        0
     UPQS0 = c6df2210
     UPQS1 =    20000
     UPQS2 =       80
                 =        0
    With this configuration I am always getting rx buffer value as zero.

    Please let me know any modification do I need to make on kernel side to make it work.

    Thanks

    Mrudula