Part Number: 66AK2G12
Other Parts Discussed in Thread: TPS51200
Hi all
I'm trying to bring up a custom board with 66AK2G12, TPS51200 and DDR3L memory, but it behaves seemingly random and I need your help with it.
The first issue is that I cannot make it boot to USB-DFU mode. Whatever BOOTCFG I tried, I see no activity on USB0_DM/DP pins. And of-course no new USB devices are detected in USB port by PC. Are there any specifics to make CPU enter USB-DFU apart from BOOTCFG? At the same time UART bootloader works flawless.
The next issue is that I observe high power consumption and TPS51200, DDR3L chips getting hot to touch. I assume that would be due to bootloader de-asserting DDR3_RESETn and issuing NOPs, which raise DDR3_WEn and others to DVDD_DDR, whereas TPS51200 pulls them all to DVDD_DDR/2 through termination resistors. Is it how it is supposed to be?
But anyway with TPS51200 and fly-by termination I cannot run U-Boot. It simply hangs. I've modified sources and could trace it up to get_ram_size function. I have modified it to write patterns into memory and read them back to verify it functions. Turns out it hangs at RAM access attempts. I tried various settings (including the ones calculated by "K2 DDR3 Register Calc v1p60.xlsx"), but the only viable config was ddr3phy_800_512mb/ddr3_800_512mb. This allowed several read/write steps to execute, reading garbage and then eventually halting.
For comparison I desoldered from the second identical PCB TPS51200, replacing it with a passive divider with capacitors on a DDR3_VREFSSTL net, desoldered termination passives. With these changes using ddr3phy_800_512mb/ddr3_800_512mb U-Boot could read/write memory correctly and indefinitely. I did quite a number of tests and sometimes I see DDR3 functioning correctly for indefinite amount of time for the whole duration of the run. Resetting / power cycling the board results in changes in behavior: sometimes it is still fine, sometimes it sees intermittent read/write errors. This behavior holds for the entire duration of the run. Could this be somehow related to read/write-levelling not succeeding sometimes? What configuration options could I try to modify to try to make it levelling more consistently?
Now if RAM functions properly, I allow U-Boot to proceed further and most of the time it stops after the end of copy_loop at relocate.S. At rare trials it could go past that and run U-Boot from RAM, but most of the time it stops just here. After the CPU is hung I observe lower power consumption, so I believe that at that point DDR3-unit of CPU ceases to function and/or RAM stops refreshing, but I may be wrong. What could hang the CPU during operations on DDR3? I mean even if read/write operations function properly something still hangs the CPU while U-Boot is trying to fix addresses at the relocated code, but not when copying the code itself into RAM.
Another issue is that I couldn't make CPU DDR3 controller use all 32 bits. With ddr3phy_800_512mb/ddr3_800_512mb it accesses only 16 bits of attached memory. I used "K2 DDR3 Register Calc v1p60.xlsx" to calculate proper values to no avail. I have DDR3-1600-capable SK Hynix RAM modules, but calculating them to operate at DDR3-800 does not help either. Any calculated configuration results in immediate halting upon first RAM access. I then tried modifying ddr3phy_800_512mb/ddr3_800_512mb to be 32-bit instead, but this also didn't work. I put 1 to .datx8_2_val and .datx8_3_val and changed NM from 2 to 1 in .sdcfg.
My fly-back chain first visits bits 16-31 and only then bits 0-15; do I have to account for it somehow, could it be affecting this somehow?
Length-matching is done on the PCB for DDR3 signals.
Being able to use only UART bootloader, I have to upload U-Boot via UART, which takes almost 2,5 minutes. Could this delay somehow affect the DDR3 initialization, that is attempted later by U-Boot?
Please answer the questions raised above. I would be very grateful if you could advise me on how to proceed further to solving these issues.
Thanks in advance.




