4 Replies Latest reply on Feb 26, 2013 2:43 PM by max.ramirez

    FlagA and watermark FlagB problem w/multiDMAChannel

    max.ramirez

      I have just started implementing a multiDMAChannel with 2 producers(Pport0, Pport1) and 1 consumer (Socket3).

         

      FPGA transfers data at 100MHz over a 32bit bus to the FX3. I am able to transfer at 309MB/s for a few seconds before the throughput starts decreasing until it eventually starts getting failures. The oscilloscopes shows flagA going low  for a period of ~10ns and flagB goes low for ~50ns (flagB has a watermark value of 4) after changing addresses. As throughput drops flags A &  B stay LOW for a longer time up to 180us! What could be causing this issue?  

         

      FX3 is set up as follows: DMA Buffers = 3, DMA Buffer Size = 32KB, pkt size = 1024, Burst Length = 16 

         

       

         

          dmaCfg.size  = CY_FX_IMG_STREAM_BUF_SIZE;

         

          dmaCfg.count = CY_FX_SLFIFO_DMA_BUF_COUNT;

         

          dmaCfg.dmaMode = CY_U3P_DMA_MODE_BYTE;

         

          dmaCfg.prodHeader = 0;

         

          dmaCfg.prodFooter = 0;

         

          dmaCfg.consHeader = 0;

         

          dmaCfg.prodAvailCount = 0;

         

          //dmaCfg.prodSckId = CY_FX_PRODUCER_PPORT_SOCKET;

         

          dmaCfg.validSckCount = 2;

         

          dmaCfg.prodSckId [0] = CY_FX_PRODUCER_PPORT_SOCKET_0;

         

          dmaCfg.prodSckId [1] = CY_FX_PRODUCER_PPORT_SOCKET_1;

         

          dmaCfg.consSckId [0] = CY_FX_CONSUMER_USB_SOCKET;

         

          apiRetStatus = CyU3PDmaMultiChannelCreate (&glChHandleSlFifoPtoU, CY_U3P_DMA_TYPE_AUTO_MANY_TO_ONE , &dmaCfg);

         

          if (apiRetStatus != CY_U3P_SUCCESS)

         

          {

         

              CyU3PDebugPrint (4, "CyU3PDmaChannelCreate failed, Error code = %d\r\n", apiRetStatus);

         

              CyFxAppErrorHandler(apiRetStatus);

         

          }