Re: TCP/IP comms problems between WinXP and DOS
- From: Howard Smith <HowardSmith@xxxxxxxxxxxxxxxxxxxxxxxxx>
- Date: Thu, 19 Apr 2007 08:06:04 -0700
"r norman" wrote:
On Tue, 17 Apr 2007 00:28:01 -0700, Howard SmithThe effect I see is that in my VC++ program OnReceive() doesn't get called
<HowardSmith@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote:
I am using VC++ 6.0 (with SP5 installed). When using WinXP this is with SP2
installed.
I am developing an instrumentation system comprising a set of networked PCs
connected using TCP/IP TCP links. Communications on the Windows PCs use a
class derived from CAsyncSocket(). I have written client and server versions
of my software for use on the appropriate PCs.
I am also using communicating with a legacy DOS based system, with the
software written in Microsoft C V7, with 3rd party TCP/IP drivers.
In the instance where I have a problem the DOS system is running as client,
and the Windows system as server.
When I run my server side s/ware on Windows XP the connection from the DOS
system is accepted OK, but the server fails to receive any messages. It can
successfully send messages to the DOS client system. The DOS client error
detection correctly determines that the message has not been able to be
successfuly sent to the server.
By simple changing of i/p addresses / network names I have run the client
and server software on various combinations of operating system without
modifying the code behind the 'exe' files. I have also done tests with a
Windows client from another application performing a very similar
implementation of the communications of the DOS client.
If I run my client side on DOS and the server side on Windows NT, this works
perfectly.
If I run a compatible client side s/ware on Windows NT or XP and the server
side on Windows NT or XP this works perfectly.
If I run my client side on DOS and the server side on Windows XP this fails
as described as above.
Hence:
Without altering anything on the DOS client side (which communicated OK with
a WindowsNT server side) it fails to communicate with the XP server side
(which communicated OK with a WindowsXP/NT client side). The only changes
made for the test were to the ip addresses and names of the NT 'server' test
app and the XP 'client' test apps.
Does anyone know what the problem may be in trying to communicate between
systems on DOS and WindowsXP?
It should be noted that my DOS app communicates successfully using tcp/ip
with other non PC based equipment.
Working through your problems with a packet sniffer will let you see
just what message exchanges are going on between your systems. You
also don't give much information about what it means for the system to
"fail". Just what function fails and exactly what error codes are
returned? Exactly at what point in the entire communication system
does it fail? Saying merely that "the message failed to be delivered"
doesn't provide much information.
Maybe I can't help too much, but I can sympathize with you enormously.
I, too, have long hours of bitter experience trying to get various
systems to intercommunicate. Often the only solution I have found is,
as suggested above, to put some kind of monitor on the communication
line to see every bit and byte of data that gets sent by whom and,
often, at exactly what time.
even though a Send() is executed by the DOS program. As a result my VC++
program doesn't set the flag that causes my program to then do a Recive() to
get the message. In case it was OnReceive() not working properly I tried
using a key press to set the flag when I knew the DOS program had done a
send. In this case Receive() returned no data, effectively confirming that
indeed nothing had apparently been received.
At the DOS end an asynchronous Send is triggered. A second call to Send then
returns an error indicating that the previous send has not yet completed.
This agrees with the message not getting received by my VC++ program. Of
course it doesn't explain why and which end is at fault.
I can send messages successfully the other way (from VC++ to the DOS app),
so the socket must have been established OK.
The logic etc. in both my programs is presumably basically correct as they
work when the 'other end' is on an O/S combination that works OK. e.g.
DOS->NT or XP->NT. I
I'll try to find the sniffer I came across a few years ago, though my
understanding of very low level TCP/IP is limited so I'm not sure what it
will tell me. I expect the OS to do that for me! I suspect I'll need to find
an ethernet hub rather that an ethernet switch too - which could be more of a
challenge - may need to visit a museum.
.
- Follow-Ups:
- Re: TCP/IP comms problems between WinXP and DOS
- From: r norman
- Re: TCP/IP comms problems between WinXP and DOS
- References:
- Re: TCP/IP comms problems between WinXP and DOS
- From: r norman
- Re: TCP/IP comms problems between WinXP and DOS
- Prev by Date: Re: Exporting C++ classes as ordinals (via a def file)
- Next by Date: Re: TCP/IP comms problems between WinXP and DOS
- Previous by thread: Re: TCP/IP comms problems between WinXP and DOS
- Next by thread: Re: TCP/IP comms problems between WinXP and DOS
- Index(es):
Relevant Pages
|