Overview
Examples
Screenshots
Comparisons
Applications
Download
Documentation
Tutorials
Bazaar
Status & Roadmap
FAQ
Authors & License
Forums
Funding Ultimate++
Search on this site
Search in forums












SourceForge.net Logo
Home » Extra libraries, Code snippets, applications etc. » OS Problems etc., Win32, POSIX, MacOS, FreeBSD, X11 etc » UDP - XP does not receive frames in recvfrom
UDP - XP does not receive frames in recvfrom [message #33739] Fri, 09 September 2011 14:28 Go to next message
arkady_c is currently offline  arkady_c
Messages: 14
Registered: December 2010
Location: Polska
Promising Member
Howk,

I use to communicate <Web/Web.h>
win7 and Linux is the communication works.
g = socket(PF_INET, SOCK_DGRAM, IPPROTO_UDP);
int optval = 1;
setsockopt(g, SOL_SOCKET, SO_BROADCAST, (const char*)&optval, sizeof optval);
adr.sin_family = PF_INET;
adr.sin_port = htons(UDP_PORT);
adr.sin_addr.s_addr = htonl(INADDR_ANY);
retx = bind(g, (sockaddr *) &adr, sizeof(adr));
ret = recvfrom(g, frame, sizeof(frame), 0, (sockaddr *) &nad, &ret1);

the compilation of XPsp3 sends a frame the controller sends back but now that recvfrom is not receiving.
or met someone with a problem on the part of XP in receiving the UDP?
Ethereal checked the frame from the driver goes a good frame but unable to recvfrom

I greet all!!



2a7aff6be3f76940495be32258777636
Re: UDP - XP does not receive frames in recvfrom [message #33742 is a reply to message #33739] Fri, 09 September 2011 17:03 Go to previous messageGo to next message
arkady_c is currently offline  arkady_c
Messages: 14
Registered: December 2010
Location: Polska
Promising Member
I checked on xp prof and everything works Shocked
aha laptop XP this home

on the laptop I have a fresh system, so something's missing. Can anyone knows what is needed for UDP. I will add that cmd-> netstat-aon shows willingness to listen to my port.


2a7aff6be3f76940495be32258777636

[Updated on: Fri, 09 September 2011 17:04]

Report message to a moderator

Re: UDP - XP does not receive frames in recvfrom [message #33802 is a reply to message #33742] Wed, 14 September 2011 17:57 Go to previous message
arkady_c is currently offline  arkady_c
Messages: 14
Registered: December 2010
Location: Polska
Promising Member
int timeout=100;
time_out.tv_sec = timeout / 1000;
time_out.tv_usec = timeout % 1000 * 1000;

if(/*IsNull(timeout) || */ select(gniazdo + 1, &file_set, NULL, NULL, &time_out) > 0)

it seems that this is due to network card (10/100) - (10/100/1000).
probably will use the upp:: Socket. Smile
I do not know how to control the various systems. Socket can give advice. Cool
/*IsNull(timeout) || */ it helped.
Howk All!!


2a7aff6be3f76940495be32258777636
Previous Topic: BUG: FreeBSD debugging
Next Topic: WordPress requires a pre-running website or blog?
Goto Forum:
  


Current Time: Fri Mar 29 09:09:45 CET 2024

Total time taken to generate the page: 0.01778 seconds