[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [lwip-users] sys_mbox_post gets wron parameter
From: |
Jonathan Larmour |
Subject: |
Re: [lwip-users] sys_mbox_post gets wron parameter |
Date: |
Wed, 30 May 2007 16:23:56 +0100 |
User-agent: |
Thunderbird 1.5.0.10 (X11/20070301) |
Matthias Weisser wrote:
Hi
today I started to test around with the socket interface of lwip and
wanted to implement a simple echo server and failed :-)
I saw that socket() never returned and debugged it to sys_mbox_post
never returned from posting the message to the mailbox. This is because
the mbox parameter (which is a typedefed int) is wrong. The only mailbox
which is created returns 2119 (id from the os) to the lwip stack but
then the sys_mbox_post is called with 0 as mbox parameter. Thanks for
any help.
This sounds like a problem in your port. In your sources you should find
tcpip.c inside which is a function tcpip_apimsg() which is posting to
"mbox", which is a static defined as:
static sys_mbox_t mbox;
I bet this is the reason for the 0 parameter.
But as you will also see in that file, there is a function tcpip_init,
which initialises that mbox. I suspect your port is not calling this
function. Or, you are accessing the lwIP functions before the port
initialisation has occurred.
Jifl
--
eCosCentric Limited http://www.eCosCentric.com/ The eCos experts
Barnwell House, Barnwell Drive, Cambridge, UK. Tel: +44 1223 245571
Registered in England and Wales: Reg No 4422071.
------["The best things in life aren't things."]------ Opinions==mine