[ECOS] cyg_user_start fails to start
Andrew Lunn
andrew@lunn.ch
Thu Jan 27 14:09:00 GMT 2005
On Wed, Jan 26, 2005 at 05:42:15PM -0800, Harshit Suri wrote:
> The board is based on at91eb40a and has 1MegaByte of external SRAM.
> Code works perfectly in RAMROM startup mode also ONLY IF
> readBuffer is given a small enough size eg.
> char readBuffer[1600]={'c'};
This makes it very easy to track down the problem....
Take a look at /packages/hal/arm/at91/eb40a/current/include/hal_platform_setup.h
Around line 115 is:
#if defined(CYG_HAL_STARTUP_ROMRAM)
ldr r0,=0x01000000 // Relocate FLASH/ROM to on-chip RAM
ldr r1,=0x02000000 // RAM base & length
ldr r2,=0x02010000
20: ldr r3,[r0],#4
str r3,[r1],#4
cmp r1,r2
bne 20b
ldr r0,=30f
mov pc,r0
30:
#endif
This bit of code copies the image from ROM to RAM. As you can see if
copies a fixed amount.....
Andrew
--
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss
More information about the Ecos-discuss
mailing list