8 Replies Latest reply on Nov 27, 2013 6:01 AM by user_1377889

    Simultaneous SPI DMA not working.

    user_62720120

       I have a PSoC3666 project containing 4 identical SPI Master components. Each is fed by it's own TX and RX DMAs.

         

      I can get one of these units working on its own by enabling its DMA channels. But when I try to enable the DMA channels of the other three SPI components, the first one breaks.

         

       

         

          CyDmaChSetInitialTd_FAST(SPI_TxChannel[0], SPI_TxTD[0]);

         

          CyDmaChSetInitialTd_FAST(SPI_RxChannel[0], SPI_RxTD[0]);

         

          CyDmaChEnable_FAST(SPI_RxChannel[0]);

         

          CyDmaChEnable_FAST(SPI_TxChannel[0]);               // This works on its own.

         

          

         

          CyDmaChSetInitialTd_FAST(SPI_TxChannel[1], SPI_TxTD[1]);

         

          CyDmaChSetInitialTd_FAST(SPI_RxChannel[1], SPI_RxTD[1]);

         

       

         

          CyDmaChEnable_FAST(SPI_RxChannel[1]);

         

          CyDmaChEnable_FAST(SPI_TxChannel[1]);               // But when I add this, it all stops working.

         
              
         
          Is there some reason enabling a second DMA would affect the first one?   
         
              
         
          Hugo