From mboxrd@z Thu Jan 1 00:00:00 1970 From: Jonathan Larmour To: Christoph Obermair Cc: ecos-discuss@sources.redhat.com, grante@visi.com Subject: Re: [ECOS] ecos and ks32c50100 Date: Tue, 31 Jul 2001 07:21:00 -0000 Message-id: <3B66BEE8.8A67B269@redhat.com> References: X-SW-Source: 2001-07/msg00947.html Christoph Obermair wrote: > > hi everybody, > > i am working with a ks32c50100-custom-board at the moment. my aim is to > run a tcp/ip-stack and one or two other small applications on it. the > board has 128k ram and 512k flash-rom. > i think ecos could be a good solution for my little project. > > so, i've already read some mails in the archive of this list concerning > ecos on a ks32c50100-board, but none of them was really helpful. is there > already an existing port? The evaluator 7t port uses this part. > i read something about a port for the snds100. if this port exists, can i > use it for my custom-board without any further changes? We have just started integrating the SNDS port, but it won't be complete for a little while. Perhaps we (or Grant) can make Grant's original work available to you directly in the interim, just by e-mailing it? > i saw that there are two tcp/ip-implementaions: the one from ecos and > another one from tristan gingold. why are there two different stacks? Tristan's one predates the eCos one. Frankly, it probably doesn't work any more, but I haven't the guts to remove it. > besides, do i have enough memory at all to run a tcp/ip-stack an my > board??? Probably not. Here's what was written before: -=-=-=-=-=-=-=-=- >From some simple measurements, the difference between including and not including the stack appears to be about 121944 bytes code, 3944 bytes initialized data, and 296940 bytes BSS, 256K of which is networking buffers. The buffer size cannot be shrunk down to near 0 though. Hugo would know better what the minimal requirements for this are. I've quoted below some things he wrote before that indicate that 128K is almost certainly the absolute minimum, otherwise you may never receive 64K packets. So you can subtract 128K off that 296940 bytes BSS to give the minimum. And as he says, there will potentially be more overruns/lost data even with that minimum. This is for an app that includes read, write and select. Values may differ more with extra functions as large sections of the stack may be brought in due to selective linking. But probably not. Hugo wrote: > The default value is fairly generous. You should be quite safe > resizing this down by half. The layout of how that chunk of memory > gets used is automatic: > 1/4 - general space, used for bookkeeping data > 1/4 - small network buffers > 1/2 - large network buffers > > ... time passes > > I have just verified that the stack will work with less (128K) memory. > I did uncover some problems, which are now fixed, where the system > simply shut down in some cases where it ran out of memory. In any > case, with less memory you will have to face the possibility of lost > data and/or memory overruns/exhaustion. But the system will continue > to work :-) -=-=-=-=-=-=-=-=- I don't know if (assuming you got it working) Tristan's one would be smaller. Jifl -- Red Hat, Rustat House, Clifton Road, Cambridge, UK. Tel: +44 (1223) 271062 Maybe this world is another planet's Hell -Aldous Huxley || Opinions==mine