SPI with DMA: INTDMA0 triggered but no TX

Hallo everyone,

I'm trying to implement SPI TX with DMA using RH850/F1KM-S4 and try to implement following flow

chip select pin Low --> write first data to CSIG2TX0H --> INTDMA0 triggerd, set flag A --> IF A & !(CSIG2STR0&(1<<7) --> chip select pin high.

On the oscilloscope i can confirm that chip select pin was toggled high -> low -> high. But only the first data was transmitted (i.e. DMA transfer is not happening).

How can INTDMA0 is still triggered?

Parents
  • I think i solved the problem.

    I changed DMAC0DM00CM = _DMAC_PE1_SETTING | _DMAC_SPID0_SETTING | _DMAC_SUPERVISON_MODE;

    which is translated to 0x0010 to DMAC0DM00CM = 0x0000 and use _DMAC_SINGLE_TRANSFER since ICCSIG2IC was triggered after TX is completed.

    So my question will be, how one determine the value of SPID[1:0] und PEID[2:0]?

Reply
  • I think i solved the problem.

    I changed DMAC0DM00CM = _DMAC_PE1_SETTING | _DMAC_SPID0_SETTING | _DMAC_SUPERVISON_MODE;

    which is translated to 0x0010 to DMAC0DM00CM = 0x0000 and use _DMAC_SINGLE_TRANSFER since ICCSIG2IC was triggered after TX is completed.

    So my question will be, how one determine the value of SPID[1:0] und PEID[2:0]?

Children