Hi,
I am trying to write a fairly straight forward eCos app and I am trouble
understanding how the TCP/IP stack should behave with application threads
(or vice versa).
I am using the FreeBSD TCP/IP stack and I have written a small C++
application. My app has a cyg_user_start function which currently creates
and resumes a single thread. In my thread I successfully initialise the
network interface with init_all_network_interfaces(); and then go into a
loop which is (at the moment at least) a simple CLI (reading commands from
the serial port and replies to it).
Now, what I have observed is that when I am in my thread's loop I can't ping
to the eCos machine (even though the link is up). If I exit from my thread,
I can ping it no problem.
So, what am I doing wrong here? Do I need to have an application thread that
handles the "background" TCP/IP stuff link answering ping? I was assuming
this stuff would just work but now I suspect I've misunderstood something
fundamental.