From 4d60c0110d60261878ac6198776549ef898b3cbb Mon Sep 17 00:00:00 2001 From: Joe Taylor Date: Mon, 23 Jul 2007 01:44:00 +0000 Subject: [PATCH] Changed from multicast to unicast for input of data from Linrad. git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/map65@511 ab8295b8-cf94-4d9e-aec4-7959e3be5d79 --- map65.py | 2 +- plrr_subs_win.c | 17 +++++++++++------ 2 files changed, 12 insertions(+), 7 deletions(-) diff --git a/map65.py b/map65.py index 974e29544..a160f1a0e 100644 --- a/map65.py +++ b/map65.py @@ -1,4 +1,4 @@ -#-------------------------------------------------------------------- MAP65 +#--------------------------------------------------------------------- MAP65 # $Date$ $Revision$ # from Tkinter import * diff --git a/plrr_subs_win.c b/plrr_subs_win.c index 19fcab9e0..45623fa35 100644 --- a/plrr_subs_win.c +++ b/plrr_subs_win.c @@ -58,25 +58,28 @@ void setup_rsocket_(void) j=WSAGetLastError(); printf("Error: %d %d\n",err,j); } - /* allow multiple sockets to use the same PORT number */ + + /* + // allow multiple sockets to use the same PORT number if (setsockopt(fd,SOL_SOCKET,SO_REUSEADDR,&yes,sizeof(yes)) < 0) { perror("Reusing ADDR failed"); exit(1); } + */ /* set up destination address */ memset(&addr,0,sizeof(addr)); addr.sin_family=AF_INET; - addr.sin_addr.s_addr=htonl(INADDR_ANY); /* N.B.: differs from sender */ + addr.sin_addr.s_addr=htonl(INADDR_ANY); addr.sin_port=htons(HELLO_PORT); - - /* bind to receive address */ + /* Bind socket to a local source port */ if (bind(fd,(struct sockaddr *) &addr,sizeof(addr)) < 0) { perror("bind"); exit(1); } - - /* use setsockopt() to request that the kernel join a multicast group */ + + /* + // use setsockopt() to request that the kernel join a multicast group mreq.imr_multiaddr.s_addr=inet_addr(HELLO_GROUP); mreq.imr_interface.s_addr=htonl(INADDR_ANY); // NG: mreq.imr_interface.s_addr=htonl("192.168.10.13"); @@ -84,6 +87,8 @@ void setup_rsocket_(void) perror("setsockopt"); exit(1); } + */ + } //void __stdcall RECV_PKT(char buf[])