TI中文支持网
TI专业的中文技术问题搜集分享网站

AM3505 gdb debug in SDRAM

HI,ALL

芯片是am3505,ddr2是NT5TU6416GG-3C,现在想在ddr里面调试我的程序,但是gdb初始化出现了问题,sdram无法正常工作,gdbserver打印输出如下:

这里是在sdram里面调试,gdb连接cpu的打印:
Connected to 127.0.0.1
Reading all registers
Read 4 bytes @ address 0x00014000 (Data = 0xEA000232)
WARNING: Failed to read memory @ address 0x00013FFC
Read 4 bytes @ address 0x00013FFC (Data = 0xAAAAAAAA)
Read 4 bytes @ address 0x00014000 (Data = 0xEA000232)
WARNING: Failed to read memory @ address 0x00013FFC
Read 4 bytes @ address 0x00013FFC (Data = 0xAAAAAAAA)
Read 4 bytes @ address 0x00014000 (Data = 0xEA000232)
Read 4 bytes @ address 0x00014000 (Data = 0xEA000232)
Read 4 bytes @ address 0x00014000 (Data = 0xEA000232)
Target interface speed set to 30 kHz
Target endianess set to "little endian"
Resetting target
Writing 0x00000020 @ address 0x48004C10
Writing 0x00000020 @ address 0x48004C00
Sleep 10ms
。。。。。
很显然,gdb读的那些个地址,好像在抽风。。。。没有正常显示应该读取的寄存器,困惑ing,gdb初始化cpu寄存器的后面一截的打印信息:
Downloading 6776 bytes @ address 0x80E80000
Downloading 157 bytes @ address 0x80E81A78
Downloading 20 bytes @ address 0x80E81B18
Writing register (PC = 0x80e80000)
Read 4 bytes @ address 0x80E80000 (Data = 0xFFFFFFFF)
Read 4 bytes @ address 0x80E7FFFC (Data = 0xFFFFFFFF)
Read 4 bytes @ address 0x80E80000 (Data = 0xFFFFFFFF)
Read 4 bytes @ address 0x80E7FFFC (Data = 0xFFFFFFFF)
Read 4 bytes @ address 0x80E80000 (Data = 0xFFFFFFFF)
Read 4 bytes @ address 0x80E80000 (Data = 0xFFFFFFFF)
Read 4 bytes @ address 0x80E80000 (Data = 0xFFFFFFFF)
Read 4 bytes @ address 0x80E810EC (Data = 0xFFFFFFFF)
Read 4 bytes @ address 0x80E80098 (Data = 0xFFFFFFFF)
Read 4 bytes @ address 0x80E8013C (Data = 0xFFFFFFFF)
Read 4 bytes @ address 0x80E800F4 (Data = 0xFFFFFFFF)
Read 4 bytes @ address 0x80E802BC (Data = 0xFFFFFFFF)
Read 4 bytes @ address 0x80E81084 (Data = 0xFFFFFFFF)
Read 4 bytes @ address 0x80E81008 (Data = 0xFFFFFFFF)
Read 4 bytes @ address 0x80E80050 (Data = 0xFFFFFFFF)
Read 4 bytes @ address 0x80E80050 (Data = 0xFFFFFFFF)
Read 4 bytes @ address 0x80E80000 (Data = 0xFFFFFFFF)
Setting breakpoint @ address 0x80E80050, Size = 4, BPHandle = 0x0001
Setting breakpoint @ address 0x80E80000, Size = 4, BPHandle = 0x0002
Starting target CPU…
…Breakpoint reached @ address 0x80E80000
Reading all registers
Removing breakpoint @ address 0x80E80050, Size = 4
Removing breakpoint @ address 0x80E80000, Size = 4
Read 4 bytes @ address 0x80E80000 (Data = 0xFFFFFFFF)
Read 4 bytes @ address 0x80E7FFFC (Data = 0xFFFFFFFF)
Read 4 bytes @ address 0x80E80000 (Data = 0xFFFFFFFF)
Read 4 bytes @ address 0x80E7FFFC (Data = 0xFFFFFFFF)
Read 4 bytes @ address 0x80E80000 (Data = 0xFFFFFFFF)
Read 4 bytes @ address 0x80E80000 (Data = 0xFFFFFFFF)
Read 4 bytes @ address 0x80E80000 (Data = 0xFFFFFFFF)
Read 4 bytes @ address 0x80E80000 (Data = 0xFFFFFFFF)
Setting breakpoint @ address 0x80E80004, Size = 4, BPHandle = 0x0003
Starting target CPU…
sdram里面的数据都是一些错的,sdram配置也有问题。
关于这款ddr有谁有用过的?
感觉cpu在sdram调试下,工作不正常。请问是什么问题。
chars ant:

HI All:

现在我转而在SRAM里面调试SDRAM的读写,不能正常读写,写入0xA5A5A5A5,sdram地址是取的0x8000000.然而读出来是0xA5A5ADB5.写其他的sdram地址也是一样的。请问NT5TU6416GG-3C这款芯片的sdram register寄存器配置有谁有的,我修改了很多遍config register 和timer register,但是还是不行。

Please help me, thanks a lots!

Jian Zhou:

回复 chars ant:

请您先检查原理图,看看DDR2这部分的接线有没有错误。

其次,要检查PCB,制版和焊接。

最后,要检查软件配置部分是不是做了正确的修改。

Yaoming Qin:

回复 chars ant:

请您参考

 

http://processors.wiki.ti.com/index.php/AM3517/05_SDRC_Subsystem

chars ant:

回复 Jian Zhou:

你好,Jian Zhou:

为了排除硬件原因,我倒腾了一块AM3517 logicPD,我根据这块板子的winbon的ddr数据手册,针对Jlink的gdbinit文件进行了修改,也注释了xload里面针对sdram配置的代码。发现,可以在DDR2里面调试,但是,打印是一些乱码,在sram里面调试打印是正常的。这里我有个疑问,代码能运行,但是打印为啥是乱码?

chars ant:

回复 Jian Zhou:

我在gdbinit文件里面使用同样于调试xload的sdram初始化配置,在ddr2中可以调试xload,但是编译uboot进行调试,没反应。是不是代表我的配置是错误的。

这里,我还有个疑问,我的cpu出来的时钟是166Mhz,但是我的器件上表明是667的器件,那我的tck应该填6ns还是3ns?tRP和tRCD上面有个5-5-5.这三个参数我该怎么计算、选择?这个tck和nCK是个什么意思?芯片上有解释,没看太明白。

赞(0)
未经允许不得转载:TI中文支持网 » AM3505 gdb debug in SDRAM
分享到: 更多 (0)