[En-Nut-Discussion] no source in debugger solved, next step
klaus.kloos at gmx.de
Tue Oct 4 21:45:45 CEST 2011
Many thanks for your help.
'show stopper' is the right name, after the small change it runs and its a really cool show.....
Is it better to work with the version 4.10?
I have tested the ftp-server (4.8.9) with few success.
Im able to create a folder (so mmc access is working) but even a list fails.
On the other side most things Ive tried work like charm. Telnet, RS232, Treads, Mutex, ....
Am 04.10.2011 um 12:54 schrieb Harald Kipp:
> Hi Klaus,
> On 02.10.2011 22:27, Klaus Kloos wrote:
>>  Connected, 1444 bytes free
>>  Low mem
>>  Low mem
> The provided http sample is a bit overdone. Over the years, more and
> more demo code had been added to it. Most real applications will not
> need all the implemented features.
> I just tried a short compile/link test with Nut/OS 4.10 and debugging
> enabled. It turns out, that 12k static RAM is already required before
> the application starts.
> The debug version of the code requires more stack space. For this, the
> Configurator simply defines
> So every thread's stack space reservation is multiplied by 3. Probably
> this could be lowered. And then there is a bug in httpserv.c itself,
> #define HTTPD_SERVICE_STACK ((1024 * NUT_THREAD_STACK_MULT) +
> NutThreadCreate(thname, Service, (void *) (uptr_t) i,
> (HTTPD_SERVICE_STACK * NUT_THREAD_STACK_MULT) + NUT_THREAD_STACK_ADD);
> which actually reserves 9k stack (3 * 3 * 1024) for each of the 4 server
> threads. Together with statically allocated RAM space, we are nearly at
> 50k. The CPU has 64k RAM only.
> This has been fixed in 4.10, but not yet in 4.8. I haven't been aware,
> that this is a show stopper for the SAM7X-EK when running debug code.
> Changing the line to
> NutThreadCreate(thname, Service, (void *) (uintptr_t) i,
> should help in a first step.
> When compiling without debugging info, a lot more RAM is available.
> Furthermore, you can build Nut/OS libs _without_ and your application
> code _with_ debugging info to debug application code only.
Haus Heyden Strasse 111
More information about the En-Nut-Discussion