We're a community of 1077K IT Pros here for help, advice, solutions, professional growth and fun. Join us!
1,076,386 Members — Technology Publication meets Social Media
Username:
Password:
Lost login information?
Start New Discussion Reply to this Discussion

windows sockets best practice, advice needed

I'm trying to connect to devices on a network through TCP , one is a wireless device with limited capabilities (a 802.11g transceiver with an incorporated SoC ) or the client and the other is a normal pc , the server . As the client is meant to be in sleep mode as long as possible when not used i need a way for the pc to discover the client when he is active . My idea was : broadcast/multicast (but as i know from my own router multicasting isn't allowed to often, or is it?) through UDP the address and port of the server , and listen there for TCP connection requests. I figured the TCP listener out but while reading on UDP broadcast i came across some stuff i don't quite get :
1 can i use blocking sockets in the same application to broadcast on one port and send/receive on another?is there a need for a select() implementation ? here is a link to the source of my dilemma.
2 this seems much to complex for what i need , is there a better way a "best practice" approach?

1
Contributor
1
Reply
7 Hours
Discussion Span
2 Years Ago
Last Updated
2
Views
emperor43
Newbie Poster
2 posts since Jun 2010
Reputation Points: 10
Solved Threads: 0
Skill Endorsements: 0

found what i needed :D just 3 hours of searching and 4 hours of reading , pretty fast .. for any other endeavourer http://www.winsocketdotnetworkprogramming.com/winsock2programming/

emperor43
Newbie Poster
2 posts since Jun 2010
Reputation Points: 10
Solved Threads: 0
Skill Endorsements: 0

This article has been dead for over three months: Start a new discussion instead

Post: Markdown Syntax: Formatting Help
 
You
View similar articles that have also been tagged:
 
© 2013 DaniWeb® LLC
Page rendered in 0.0780 seconds using 2.69MB