[En-Nut-Discussion] EIR and running code in XRAM
C. Bonnemayer
cbonnemayer at voo.be
Sat Sep 19 19:38:09 CEST 2015
Dear Harald,
I succeeded in running code from SDRAM using OpenOCD as suggested. Initially
the code runs fine, but after a few seconds the board just hangs. It doesn't
matter if I keep the Telnet session alive or if I shut it down. The same
behavior also happens with other example programs I've tried. I'm wondering
what's happening here.
Besides this, I think there's a small mistake in the final board
configuration file for the Elektor Internet Radio in Part 8 of the OpenOCD
for AT91SAM7SE tutorial. In proc eir_init{} the line eir_init_membus is
missing. Also in eir_init_clock the line mww 0xfffffc20 0x00000701 is
changed into 0x00000601. However, I don't think this is the cause of the
behavoir described above.
Best regards,
Charlie
-----Original Message-----
From: en-nut-discussion-bounces at egnite.de
[mailto:en-nut-discussion-bounces at egnite.de] On Behalf Of Harald Kipp
Sent: Friday, September 18, 2015 12:51
To: en-nut-discussion at egnite.de
Subject: Re: [En-Nut-Discussion] EIR and running code in XRAM
Hi Charlie,
On 16.09.2015 18:18, C. Bonnemayer wrote:
> As a test program I use the uart example which is provided whith
> ethernut. I use SAM-BA 2.15 to upload the code to the board. When I
> save the code to sdram (after enabling the sdram) it does save and
> compare the code correctly, but a go 0x20000000 (that's 7 times 0) just
does nothing.
Not sure about the compare. SDRAMs are tricky and may contain the right
code...until after a few milliseconds later...
When code is uploaded directly to SDRAM, one has to make sure, that the
programmer correctly initialized the SDRAM. Unfortunately I didn't try
SAM-BA for a long time, but typically use OpenOCD with the EIR.
http://www.ethernut.de/en/hardware/eir/openocd_sdram.html
> When I try a for sdram precompiled example from Atmels at91sam7se-ek
> software package it just runs fine. Therefore I think there's
> something wrong with the at91sam7se512_xram.ld linker script or the
> crtat91sam7se512_xram.s startup file, but I have just too little
> knowledge about this.
Just a few weeks ago I updated an older application on the EIR (debugging in
SDRAM, final in Flash) without any problems. I used a rather new toolchain,
but a modified Nut/OS 5.1. If you still can't solve it with the information
above, I can grab out the board and try again with the official version.
Regards,
Harald
_______________________________________________
http://lists.egnite.de/mailman/listinfo/en-nut-discussion
More information about the En-Nut-Discussion
mailing list