EmbeddedRelated.com
Forums
The 2024 Embedded Online Conference

AT91SAM9RL64

Started by sananan82 February 10, 2009
I am pretty new to this.. I am building an getting started example
from AT91SAM9RL64-EK kit. I was able to build with eclipse and run
with samba. Trying to debug with jlink gdb server and SAMICE. It
takes long time to run on sram and with sdram i copied the
init_sdram.gdb file from http://www.at91.com/samphpbb/viewtopic.php?
f=9&t944. the gdb server output is Connected to 127.0.0.1
SAM-ICE found !
Reading all registers
Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
Resetting target (halt with breakpoint @ address 0)
Writing 0x00000401 @ address 0xFFFFFD08
Writing 0x00000004 @ address 0xFFFFFD00
Writing 0x00000000 @ address 0xFFFFEF00
Resetting target (soft reset)
Writing 0xFFFFFFFF @ address 0xFFFFF124
Writing 0xFFFFFFFF @ address 0xFFFFF128
Resetting target
JTAG speed set to 30 kHz
Select adaptive clocking instead of fixed JTAG speed
Writing 0x30008000 @ address 0xFFFFFD44
Downloading 4 bytes @ address 0xFFFFFC20 - Verified OK
Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
Read 4 bytes @ address 0xFFFFFC68 (Data = 0x00000009)
Downloading 4 bytes @ address 0xFFFFFC30 - Verified OK
Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
Downloading 4 bytes @ address 0xFFFFFC28 - Verified OK
Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
Read 4 bytes @ address 0xFFFFFC68 (Data = 0x0000000B)
Read 4 bytes @ address 0xFFFFFC68 (Data = 0x0000000B)
Downloading 4 bytes @ address 0xFFFFFC30 - Verified OK
Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
Read 4 bytes @ address 0xFFFFFC68 (Data = 0x0000000B)
Downloading 4 bytes @ address 0xFFFFFC30 - Verified OK
Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
Read 4 bytes @ address 0xFFFFFC68 (Data = 0x0000000B)
Downloading 4 bytes @ address 0xFFFFEF1C - Verify failed
Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
Downloading 4 bytes @ address 0xFFFFEA08 - Verified OK
Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
Downloading 4 bytes @ address 0xFFFFEA00 - Verified OK
Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
Downloading 4 bytes @ address 0x20000000 - Verify failed
Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
Downloading 4 bytes @ address 0xFFFFEA00 - Verified OK
Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
Downloading 4 bytes @ address 0x20000000 - Verify failed
Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
Downloading 4 bytes @ address 0xFFFFEA00 - Verified OK
Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
Downloading 4 bytes @ address 0x20000000 - Verify failed
Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
Downloading 4 bytes @ address 0xFFFFEA00 - Verified OK
Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
Downloading 4 bytes @ address 0x20000000 - Verify failed
Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
Downloading 4 bytes @ address 0xFFFFEA00 - Verified OK
Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
Downloading 4 bytes @ address 0x20000000 - Verify failed
Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
Downloading 4 bytes @ address 0xFFFFEA00 - Verified OK
Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
Downloading 4 bytes @ address 0x20000000 - Verify failed
Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
Downloading 4 bytes @ address 0xFFFFEA00 - Verified OK
Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
Downloading 4 bytes @ address 0x20000000 - Verify failed
Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
Downloading 4 bytes @ address 0xFFFFEA00 - Verified OK
Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
Downloading 4 bytes @ address 0x20000000 - Verify failed
Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
Downloading 4 bytes @ address 0xFFFFEA00 - Verified OK
Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
Downloading 4 bytes @ address 0x20000000 - Verify failed
Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
Downloading 4 bytes @ address 0xFFFFEA00 - Verified OK
Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
Downloading 4 bytes @ address 0x20000000 - Verify failed
Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
Downloading 4 bytes @ address 0xFFFFEA00 - Verified OK
Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
Downloading 4 bytes @ address 0x20000000 - Verify failed
Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
Downloading 4 bytes @ address 0xFFFFEA00 - Verified OK
Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
Downloading 4 bytes @ address 0x20000000 - Verify failed
Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
Downloading 4 bytes @ address 0xFFFFEA04 - Verified OK
Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
Downloading 4080 bytes @ address 0x20000000 - Verify failed
Downloading 4080 bytes @ address 0x20000FF0 - Verify failed
Downloading 2804 bytes @ address 0x20001FE0 - Verify failed
Downloading 112 bytes @ address 0x20002AD4 - Verify failed
Writing register (PC = 0x20000000)
Setting breakpoint @ address 0x200006A4, Size = 4, BPHandle = 0x0001
Starting target CPU...

Its sits there for ever.

Any ideas on how to increase the speed and also how to make it work
on sdram.

I found out the problem with init_sdram.gdb. instead of
# Enable EBI chip select for the SDRAM
set *0xFFFFEF1C = 0x2

it should be

# Enable EBI chip select for the SDRAM
set *0xFFFFEF20 = 0x2

After modifying this I was able to debug. But i see verify failed in
Jlink gdb server window at
set *0xFFFFEA00 = 0x0
set *0x20000000 = 0

After going back to normal mode the write access verify failed. I
don't know why
--- In A..., "sananan82" wrote:
>
> I am pretty new to this.. I am building an getting started example
> from AT91SAM9RL64-EK kit. I was able to build with eclipse and run
> with samba. Trying to debug with jlink gdb server and SAMICE. It
> takes long time to run on sram and with sdram i copied the
> init_sdram.gdb file from http://www.at91.com/samphpbb/viewtopic.php?
> f=9&t944. the gdb server output is Connected to 127.0.0.1
> SAM-ICE found !
> Reading all registers
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Resetting target (halt with breakpoint @ address 0)
> Writing 0x00000401 @ address 0xFFFFFD08
> Writing 0x00000004 @ address 0xFFFFFD00
> Writing 0x00000000 @ address 0xFFFFEF00
> Resetting target (soft reset)
> Writing 0xFFFFFFFF @ address 0xFFFFF124
> Writing 0xFFFFFFFF @ address 0xFFFFF128
> Resetting target
> JTAG speed set to 30 kHz
> Select adaptive clocking instead of fixed JTAG speed
> Writing 0x30008000 @ address 0xFFFFFD44
> Downloading 4 bytes @ address 0xFFFFFC20 - Verified OK
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Read 4 bytes @ address 0xFFFFFC68 (Data = 0x00000009)
> Downloading 4 bytes @ address 0xFFFFFC30 - Verified OK
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Downloading 4 bytes @ address 0xFFFFFC28 - Verified OK
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Read 4 bytes @ address 0xFFFFFC68 (Data = 0x0000000B)
> Read 4 bytes @ address 0xFFFFFC68 (Data = 0x0000000B)
> Downloading 4 bytes @ address 0xFFFFFC30 - Verified OK
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Read 4 bytes @ address 0xFFFFFC68 (Data = 0x0000000B)
> Downloading 4 bytes @ address 0xFFFFFC30 - Verified OK
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Read 4 bytes @ address 0xFFFFFC68 (Data = 0x0000000B)
> Downloading 4 bytes @ address 0xFFFFEF1C - Verify failed
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Downloading 4 bytes @ address 0xFFFFEA08 - Verified OK
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Downloading 4 bytes @ address 0xFFFFEA00 - Verified OK
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Downloading 4 bytes @ address 0x20000000 - Verify failed
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Downloading 4 bytes @ address 0xFFFFEA00 - Verified OK
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Downloading 4 bytes @ address 0x20000000 - Verify failed
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Downloading 4 bytes @ address 0xFFFFEA00 - Verified OK
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Downloading 4 bytes @ address 0x20000000 - Verify failed
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Downloading 4 bytes @ address 0xFFFFEA00 - Verified OK
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Downloading 4 bytes @ address 0x20000000 - Verify failed
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Downloading 4 bytes @ address 0xFFFFEA00 - Verified OK
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Downloading 4 bytes @ address 0x20000000 - Verify failed
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Downloading 4 bytes @ address 0xFFFFEA00 - Verified OK
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Downloading 4 bytes @ address 0x20000000 - Verify failed
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Downloading 4 bytes @ address 0xFFFFEA00 - Verified OK
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Downloading 4 bytes @ address 0x20000000 - Verify failed
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Downloading 4 bytes @ address 0xFFFFEA00 - Verified OK
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Downloading 4 bytes @ address 0x20000000 - Verify failed
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Downloading 4 bytes @ address 0xFFFFEA00 - Verified OK
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Downloading 4 bytes @ address 0x20000000 - Verify failed
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Downloading 4 bytes @ address 0xFFFFEA00 - Verified OK
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Downloading 4 bytes @ address 0x20000000 - Verify failed
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Downloading 4 bytes @ address 0xFFFFEA00 - Verified OK
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Downloading 4 bytes @ address 0x20000000 - Verify failed
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Downloading 4 bytes @ address 0xFFFFEA00 - Verified OK
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Downloading 4 bytes @ address 0x20000000 - Verify failed
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Downloading 4 bytes @ address 0xFFFFEA04 - Verified OK
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Downloading 4080 bytes @ address 0x20000000 - Verify failed
> Downloading 4080 bytes @ address 0x20000FF0 - Verify failed
> Downloading 2804 bytes @ address 0x20001FE0 - Verify failed
> Downloading 112 bytes @ address 0x20002AD4 - Verify failed
> Writing register (PC = 0x20000000)
> Setting breakpoint @ address 0x200006A4, Size = 4, BPHandle = 0x0001
> Starting target CPU...
>
> Its sits there for ever.
>
> Any ideas on how to increase the speed and also how to make it work
> on sdram.
>

I found out the problem with init_sdram.gdb. instead of
# Enable EBI chip select for the SDRAM
set *0xFFFFEF1C = 0x2

it should be

# Enable EBI chip select for the SDRAM
set *0xFFFFEF20 = 0x2

After modifying this I was able to debug. But i see verify failed in
Jlink gdb server window at
set *0xFFFFEA00 = 0x0
set *0x20000000 = 0

After going back to normal mode the write access verify failed. I
don't know why

and also with sram debug takes long time. I am not using any init
file just the following commands in eclipse debug configurations
target remote localhost: 2331
monitor reset 1
load

If I put a breakpoint in the code for sram configuration. jlink
gdbserver traget status reports ARM9, Halted but in eclipse I don't
see the halt or I can't resume it. Are there any other steps to debug
in sram configuration?

--- In A..., "sananan82" wrote:
>
> I am pretty new to this.. I am building an getting started example
> from AT91SAM9RL64-EK kit. I was able to build with eclipse and run
> with samba. Trying to debug with jlink gdb server and SAMICE. It
> takes long time to run on sram and with sdram i copied the
> init_sdram.gdb file from http://www.at91.com/samphpbb/viewtopic.php?
> f=9&t944. the gdb server output is Connected to 127.0.0.1
> SAM-ICE found !
> Reading all registers
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Resetting target (halt with breakpoint @ address 0)
> Writing 0x00000401 @ address 0xFFFFFD08
> Writing 0x00000004 @ address 0xFFFFFD00
> Writing 0x00000000 @ address 0xFFFFEF00
> Resetting target (soft reset)
> Writing 0xFFFFFFFF @ address 0xFFFFF124
> Writing 0xFFFFFFFF @ address 0xFFFFF128
> Resetting target
> JTAG speed set to 30 kHz
> Select adaptive clocking instead of fixed JTAG speed
> Writing 0x30008000 @ address 0xFFFFFD44
> Downloading 4 bytes @ address 0xFFFFFC20 - Verified OK
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Read 4 bytes @ address 0xFFFFFC68 (Data = 0x00000009)
> Downloading 4 bytes @ address 0xFFFFFC30 - Verified OK
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Downloading 4 bytes @ address 0xFFFFFC28 - Verified OK
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Read 4 bytes @ address 0xFFFFFC68 (Data = 0x0000000B)
> Read 4 bytes @ address 0xFFFFFC68 (Data = 0x0000000B)
> Downloading 4 bytes @ address 0xFFFFFC30 - Verified OK
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Read 4 bytes @ address 0xFFFFFC68 (Data = 0x0000000B)
> Downloading 4 bytes @ address 0xFFFFFC30 - Verified OK
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Read 4 bytes @ address 0xFFFFFC68 (Data = 0x0000000B)
> Downloading 4 bytes @ address 0xFFFFEF1C - Verify failed
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Downloading 4 bytes @ address 0xFFFFEA08 - Verified OK
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Downloading 4 bytes @ address 0xFFFFEA00 - Verified OK
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Downloading 4 bytes @ address 0x20000000 - Verify failed
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Downloading 4 bytes @ address 0xFFFFEA00 - Verified OK
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Downloading 4 bytes @ address 0x20000000 - Verify failed
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Downloading 4 bytes @ address 0xFFFFEA00 - Verified OK
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Downloading 4 bytes @ address 0x20000000 - Verify failed
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Downloading 4 bytes @ address 0xFFFFEA00 - Verified OK
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Downloading 4 bytes @ address 0x20000000 - Verify failed
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Downloading 4 bytes @ address 0xFFFFEA00 - Verified OK
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Downloading 4 bytes @ address 0x20000000 - Verify failed
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Downloading 4 bytes @ address 0xFFFFEA00 - Verified OK
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Downloading 4 bytes @ address 0x20000000 - Verify failed
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Downloading 4 bytes @ address 0xFFFFEA00 - Verified OK
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Downloading 4 bytes @ address 0x20000000 - Verify failed
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Downloading 4 bytes @ address 0xFFFFEA00 - Verified OK
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Downloading 4 bytes @ address 0x20000000 - Verify failed
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Downloading 4 bytes @ address 0xFFFFEA00 - Verified OK
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Downloading 4 bytes @ address 0x20000000 - Verify failed
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Downloading 4 bytes @ address 0xFFFFEA00 - Verified OK
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Downloading 4 bytes @ address 0x20000000 - Verify failed
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Downloading 4 bytes @ address 0xFFFFEA00 - Verified OK
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Downloading 4 bytes @ address 0x20000000 - Verify failed
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Downloading 4 bytes @ address 0xFFFFEA00 - Verified OK
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Downloading 4 bytes @ address 0x20000000 - Verify failed
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Downloading 4 bytes @ address 0xFFFFEA04 - Verified OK
> Read 4 bytes @ address 0x00000000 (Data = 0xEA000006)
> Downloading 4080 bytes @ address 0x20000000 - Verify failed
> Downloading 4080 bytes @ address 0x20000FF0 - Verify failed
> Downloading 2804 bytes @ address 0x20001FE0 - Verify failed
> Downloading 112 bytes @ address 0x20002AD4 - Verify failed
> Writing register (PC = 0x20000000)
> Setting breakpoint @ address 0x200006A4, Size = 4, BPHandle = 0x0001
> Starting target CPU...
>
> Its sits there for ever.
>
> Any ideas on how to increase the speed and also how to make it work
> on sdram.
>


The 2024 Embedded Online Conference