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.

TM4C1290NCPDT: EPI Throughput

Part Number: TM4C1290NCPDT

Hi,

I'm using the EPI to write to 16 bit data bus peripheral (only one Chipselect CS0 at this bus, no ALE or multiplexing of Adress/Data). Basically I write to 2 addresses, one for config and a second one for data. Normally I have to burst data to this (constant) address very often subsequently. Basically this works with a pointer assignment and a while loop as:

while ( len-- ) *pData = uData;

The TM4C is running at 80 MHz.

My config is

EPIModeSet(EPI0_BASE,EPI_MODE_HB16);
    EPIDividerSet(EPI0_BASE,1);
    EPIConfigHB16Set(EPI0_BASE,EPI_HB16_MODE_ADDEMUX| EPI_HB16_CSCFG_CS|EPI_HB16_RDWAIT_0|EPI_HB16_WRWAIT_0, 0);
    EPIConfigHB16TimingSet(EPI0_BASE, 0, (EPI_HB16_WRWAIT_MINUS_DISABLE | EPI_HB16_RDWAIT_MINUS_DISABLE));
    EPIAddressMapSet(EPI0_BASE,EPI_ADDR_RAM_SIZE_64KB | EPI_ADDR_RAM_BASE_8 )

The throughput is only 200ns each write. Do I miss something? I'd thought the EPI is running at 40 MHz and therefore I expected a write access to appear every 50 ns or somthing like this.

Can I accelerate this somehow ?

Thanks & Regards

Micky

  • Hello Michael,

    So you are feeding data from the application to the EPI? Not using DMA?

    If so, I would think that the system clock cycles to transfer the data to EPI is introducing that latency.

    Have you checked the EPI clock to see if it is running at 40MHz as you expect? Do you see any delay in the data coming out (i.e. wasted clock cycles)?

  • Ralph Jacobi said:
    So you are feeding data from the application to the EPI? Not using DMA?

    Yes, I just repeated to write a constant value to a constant address.

    If so, I would think that the system clock cycles to transfer the data to EPI is introducing that latency.

    Have you checked the EPI clock to see if it is running at 40MHz as you expect? Do you see any delay in the data coming out (i.e. wasted clock cycles)?

    I didnot check exactly, bit I see the wirte impuls is low for 25 ns:

    Here is the timing for subsequent writing (with the mentioned while()). What do you mean with "wasted clock cycles"?

    The program is just for testing and does really nothing except the writing to the EPI, so I thought this is a best case scenario. But this throughput is rather poor. Is there any chance to improve?

    Regards

    Michael

  • Hello Michael,

    I had been looking for similar requests about EPI Throughput improvements and saw something along those lines come up. Doesn't seem that is applicable here. I haven't tried to max out the EPI and don't have a setup to do so right quickly so I've been trying to find related issues.

    I did dig up this following thread which seems very close to what you are doing, the solution included turning on optimizations.

    Amit also shared code that he saw high performance on as well in the lines of what you are looking for: https://e2e.ti.com/support/microcontrollers/other/f/908/p/449440/1622205#1622205

    To get further speed beyond that, the uDMA interface should be able to help as well by allowing the data transfers to happen behind the scenes rather than as part of your program.

    If you are finding that the above isn't enough to see simple EPI performance you want, I can try next week and test on my end further. By the way for that thread it was 60MHz to get around 50ns.

  • Hi Ralph,

    things can be so easy. That hint did the job, I didnot compile with optimization. Now I have about 75ns...

    Thanks & Regards

    Micky