How to debug this Problem?
Hello,
I am developing a device driver as part of Data Link Layer/ Physical Layer, which is responsible to communicate with the LAN Card (RealTek RTL8139© card) using DOS OS.
How is this Driver tested?
I had a REMOTE PC (Windows 2000) in which I was running the TCP Server application, which could respond to any client connection. The driver, which I developed on DOS system hereafter called as TEST PC, was one of the client side, which request for the connection with the server.
Polling method is used for reception / transmission of data.
The following steps are performed for the data transfer between the TEST PC and the REMOTE PC.
1) Address has to be resolved between the TEST PC and REMOTE PC before any data transfer takes place.
To do this,
· ARP (Address Resolution Protocol) Request is sent from the TEST PC to the REMOTE PC. TEST PC activates Transmit interrupt flag when the data is successfully sent out to the line.
· On receiving the ARP Request, the REMOTE PC sends the ARP Response to the TEST PC. TEST PC activates Receive Interrupt flag on successfully reception of the data. Address resolution on the REMOTE PC could be checked with the arp –a command from the command prompt.
2) Data is sent/ received between the TEST PC and REMOTE PC.
What is the problem encountered?
TEST PC initially seems to be communicating with the REMOTE PC without any problems.
But, later when I updated the code making few changes, the communication between the TEST PC and REMOTE PC was not happening. The addition of the code does not affect the functionality of the driver.
The following observation was made:
· TEST PC while sending ARP Request activates Transmit interrupt flag.
· Address is not resolved on the REMOTE PC. This is checked with the arp –a command.
· TEST PC do not activates Receive Interrupt flag, which indicates no data from the REMOTE PC is received.
The same setup was also tried with the point-to-point connection between the two systems using cross cable.
Note: It was also observed that the previous working code doesn't seem to be responding when any of the redundant code is removed.
The following configuration is used:
Configuration:
Operating System: DOS
Processor: Intel 0x86 (Pentium III)
Speed: 700 MHz
RAM: 128MB
HDD: 20GB
Ethernet Card: Realtek RTL8139(C)
***I believe there may be possible memory corruption (Stack/Heap). If this is True, then is there any method to trace this.
Please can anyone tell me what could be the solution for the problem.