On 17.03.2018 00:08, Keith Rubow wrote:
I am trying to use LwIP for the first time, and am having trouble
figuring out what I need to do to properly initialize it.
I am trying to run LwIP version 1.4.1
Hell, 1.4.1 is more than five years old. If you start something new, use
*at least* 2.0.3! Even better, use git master, the next release is not
too far away and will be based on that.
[..] I wish to use the netconn
api in a multi-threaded system. My operating system is a very simple
cooperative multitasking system with no preemption and no task priorities.
A cooperative OS might *not* be the best for using the netconn API.
Don't expect great performance.
[..]
Now I am trying to get LwIP 1.4.1 initialized. I am doing the following:
tcp_init(NULL,NULL);
netif_add(&wiznetif,&ipaddr,&netmask,&gateway,NULL,ðernetif_init,&tcpip_input);
Where wiznetif is a netif struct, and the IP addresses are initiallized
to my desired static IP, netmask and gateway. When I run my code, I get
as far as calling netif_add, but netif_add never returns.
Are you sure about netif_add() not returning?
It seems to be
hung in sys_arch_mbox_fetch
No. Netif_add() won't call sys_arch_mbox_fetch() in any case. I guess
there's something wrong in your port or your debugger.
Simon
_______________________________________________
lwip-users mailing list
[email protected]
https://lists.nongnu.org/mailman/listinfo/lwip-users