From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 24198 invoked by alias); 21 Jun 2007 03:48:02 -0000 Received: (qmail 24171 invoked by uid 22791); 21 Jun 2007 03:48:01 -0000 X-Spam-Check-By: sourceware.org Received: from web54011.mail.re2.yahoo.com (HELO web54011.mail.re2.yahoo.com) (206.190.37.185) by sourceware.org (qpsmtpd/0.31) with SMTP; Thu, 21 Jun 2007 03:47:59 +0000 Received: (qmail 80798 invoked by uid 60001); 21 Jun 2007 03:47:57 -0000 X-YMail-OSG: 5OoIPWkVM1mDbBAnl6AK3f.jZXPsUwoBoKe4W35CA.i924NpWIgtraHwZRpL3SGTxGA3EcooJZasUeFYbnprLemfCJrC.k2MMXpo.prV2XMqRDltGOrIIeMucIGWf5ECxnVC5MRhZvyqdTyX.qRd48Ezeg-- Received: from [166.70.140.70] by web54011.mail.re2.yahoo.com via HTTP; Wed, 20 Jun 2007 20:47:57 PDT Date: Thu, 21 Jun 2007 15:18:00 -0000 From: Jason Thomas To: ecos-discuss@ecos.sourceware.org MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit Message-ID: <316993.80692.qm@web54011.mail.re2.yahoo.com> X-IsSubscribed: yes Mailing-List: contact ecos-discuss-help@ecos.sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: ecos-discuss-owner@ecos.sourceware.org Subject: [ECOS] UDP Issues with SH-4 custom platform. X-SW-Source: 2007-06/txt/msg00224.txt.bz2 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