[En-Nut-Discussion] ARM MMC Boot Problem

Harald Kipp harald.kipp at egnite.de
Mon Jun 29 15:47:00 CEST 2009


Hello list,

During the last days I've spend some hours to track down a problem with
Ethernut 3. No success so far.

I may later create a full sample to show the problem. My intention right
now is simply to ask, whether someone else had a similar problem and
possibly an idea about what causes this.

We have two Nut/OS applications, mmcloader and httpserv.

mmcloader is linked with at91_rom for running in flash. We modified the
linker script to let the RAM start at 0x3C000. RAM 0-0x3BFFF is free
(except the vector table).

httpserv is actually the httpd sample, linked with at91_ram.

bootmon is replaced by mmcloader, which loads the binary of httpserv
from MMC and stores it in the lower RAM area. This had been verified and
works fine. There are a few things to take care of, like writing the
lowest RAM sector last and disabling interrupts before doing this.

mmloader loads the image, jumps to address 0x0 and httpserv starts
running. Everything works until there is some network traffic. In most
cases the first HTTP request is completely processed and the browser
shows the correct result. The second or third request freezes the system.

Running the same RAM image of httpserv with bootmon works without
problems. Thus, we can assume, that the httpserv image itself is OK.

mmcloader seems to work fine too. Otherwise httpserv won't come that
far, being able to respond to the first one or two HTTP requests, right?

I'm almost sure, that the problem is caused by the state/mode of the
CPU, when jumping from the Nut/OS application running in flash to
address zero into another Nut/OS app.

The bootloader does the same, but is not a full Nut/OS application by
itself. For example, no interrupts are used.

Btw. I tried SVN trunk and release 4.8.3. No difference.

Harald




More information about the En-Nut-Discussion mailing list