lwip-users
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [lwip-users] Implementing 1.4.0 RC1 on Lattice Mico 32 upgrading Eth


From: Kieran Mansley
Subject: Re: [lwip-users] Implementing 1.4.0 RC1 on Lattice Mico 32 upgrading Ethernet MAC Demo from 1.2.0
Date: Thu, 05 Aug 2010 09:58:06 +0100

On Tue, 2010-08-03 at 03:34 +0000, David Lypka wrote:
> My questions
> 1. I'm running on an FPGA chip (embedded) with no operating system, so I 
> assume 
> I MUST have NOSYS == 1, right?

I would agree, but NO_SYS is a little more subtle than just OS or not OS
these days, so I wouldn't say that you must run like that.

> 2. What values should I set for LWIP_SOCKET and LWIP_NETCONN?

Do you use the sockets API?  Then set LWIP_SOCKET to 1.  Similar for the
netconn API.  The sockets API uses the netconn API so if you set
LWIP_SOCKET 1 you also need LWIP_NETCONN 1.


> 3. Where is documentation of LWIP_SOCKET and LWIP_NETCONN? I normally would 
> look 
> in the CHANGELOG, but I don't see much info for those.

src/include/lwip/opt.h is a good place to start.  This goes through all
the options and sets any to default values that you haven't specified in
your port's lwipopts.h file.  

> 4. I had to comment out all the ipv6 files so as to not cause duplicate def 
> errors with ipv4

Yes - you can choose at compile time which to use.  You can't have both.
ipv6 support in lwiP was a bit of an experiment from many years ago that
never got finished and should be avoided.

> 5. Are mailboxes only for NO_SYS not defined or 0?
>    e.g sys_arch_mbox_tryfetch() - so I do not worry about it in my case?

Take a look at src/include/lwip/sys.h.  If you have NO_SYS=1 then all
the stuff beginning with sys_ is defined to NULL operators (i.e. do
nothing).  If you want to use code that relies on things provided by the
SYS module then you have to either run with NO_SYS=0 or provide
alternative implementations of your own.

Hope that helps,

Kieran




reply via email to

[Prev in Thread] Current Thread [Next in Thread]