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.

TMS320C6657: UPP DMA stalls

Part Number: TMS320C6657

I am using the TMDXEVM6657 Evaluation Board and experimenting with the Universal Parallel Port (uPP). I created initialization function and ISR based on  the UPP User Guide SPRUHG9. I have configured the uPP for two receive channels (but I'm only driving the B channel for now). It works initially and can capture a sine wave signal from an ADC I connected to the I/O expansion header.

Problem: When I disable the uPP to print the data from the capture buffer and then enable the uPP, the uPP DMA no longer updates the data buffer (stale data remains in the buffer). It looks like the DMA is stalled out. The ISR continues to trigger on the End of Window signal, at which point I reload the DMA Channel Descriptor registers, but DMA does not transfer new data from parallel port to memory. I tried replacing the UPP disable/enable operation with simply redirecting the DMA destination to a dummy buffer while I read the 'good' data using a flag in the ISR (i.e. I kept the UPP enabled continuously) and it still fails in the same fashion. Only a power cycle fixed the problem. I added a function call to re-initialize the uPP when re-enabling the uPP in my serial port access command and it still did not work. That seems to point to a hardware issue.

Please help.

  • Additional Observations:

    It appears that the simple act of reading the buffer data (and sending it out the serial port for observation) after the UPP has been disabled causes the DMA stallout. I started the experiment with no analog input signal, performed a UPP stop/start action, applied a sine-wave analog input signal, stopped the UPP and the buffer data was correct. A subsequent start/stop operation produced the 'stale' data described above. Does this point to a problem with the DRAM Controller? My DRAM can't be written by the DMA after I manually access (read) it.

    Please help.

  • Even More Observations:

    I gained more insight into the issue using the Memory Browser. I read only the first 8 Uint16 values (16 bytes) and it appears that 64 bytes were somehow 'write protected' from UPP DMA writes. I am able to manually write and read using serial port commands, but DMA writes are being blocked. I wrote 40 decimal to the entire 1K buffer and enabled the UPP.. The top 64 bytes are frozen and the the remaining bytes are being refreshed (presumably) by the UPP DMA. Reading the entire 1K buffer causes the entire buffer to be rendered 'UPP DMA write protected'.

    What's going on here?