public inbox for ecos-discuss@sourceware.org
 help / color / mirror / Atom feed
* [ECOS] UDP Issues with SH-4 custom platform.
@ 2007-06-21 15:18 Jason Thomas
  0 siblings, 0 replies; only message in thread
From: Jason Thomas @ 2007-06-21 15:18 UTC (permalink / raw)
  To: ecos-discuss

  I am currently trying to implement a simple UDP
client/server on a custom SH-4 target, using the
FreeBSD TCP/IP stack. I've managed to get TCP/IP
working to some extent, and have tested several
functions through it. UDP however, seems to behaving
somewhat strangely. The symptom at the moment is, I
have a server blocking on recvfrom, with a socket that
will accept a connection from any client on port 1602.
I then have a client system, also eCos, which creates
a UDP socket, referring to the host system, and sends
a request for data. The host then responds with a
packet containing data, or the first three bytes as -1
to denote data isn't currently available.

  The first packet negotiation goes as expected, ARP
packets are sent, the host sends a response packet.
The second send/recv, however, seems to be drawing the
same packet over and over again. The send routine
doesn't call the 'send' function in my device driver,
and the recv function seems to pull the same exact
packet at the first sent packet from the ethernet
stack. I've made certain that there doesn't seem to be
any interaction by the TCP/IP stack with my ethernet
driver.


  To test that my socket logic is okay, I created an
example application that mimics the exact functions I
use in my eCos application, with the exception that
the server IP is hard coded.

Client:
http://pastecode.net/?action=viewpost&tag=1864

Server:
http://pastecode.net/?action=viewpost&tag=1865

   Everything goes flawlessly--- with the printed
array numbers incrementing every packet request (This
would normally be filled with ADC data from my
device).

Perhaps there are some optimizations issues? Perhaps
some flags that need to be set? Any help would be
greatly appreciated!

-Jason Thomas.



       
____________________________________________________________________________________
Sick sense of humor? Visit Yahoo! TV's 
Comedy with an Edge to see what's on, when. 
http://tv.yahoo.com/collections/222

-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2007-06-21  3:48 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-06-21 15:18 [ECOS] UDP Issues with SH-4 custom platform Jason Thomas

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).