Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

Ethernet/LAN's NIC interrupt service routine

Status
Not open for further replies.

shakeebh

Member level 2
Member level 2
Joined
Apr 24, 2005
Messages
45
Helped
1
Reputation
2
Reaction score
0
Trophy points
1,286
Location
Pakistan
Activity points
1,852
nic interrupt

Hi all

I want to write an interrupt service routine for my lan card so that I could check every incoming packet regardless of the protocol it carries in my software. Could anyone of you tell me as to what are the interrupt vector numbers I should use? Moreover, I will appreciate if you ppl could refer me to some good articles and tutorials on the subject. Also is this possible with windows APIs ?

Thanks
 

interrupting + service+ lan card

thanks a lot dainis for the very useful link. I m going through the material and its usage.... meanwhile, I will again repeat the request to inform me, if anyone knows, about the interrupt vector numbers of PC's ethernet. I have done such applications in C++ and it would be lot more easier for me to follow that way
 

pc nic interrupt

shakeebh said:
thanks a lot dainis for the very useful link. I m going through the material and its usage.... meanwhile, I will again repeat the request to inform me, if anyone knows, about the interrupt vector numbers of PC's ethernet. I have done such applications in C++ and it would be lot more easier for me to follow that way

What and under which operating system you nead get ?
What is our application ?
Why you ned write NIC interrupt service ????
 

interrupt service routine nic

Windows? Oh that would be a huge learning project! You need a kernel mode device driver and all the heavy operating system baggage that goes along with it. A short-cut procedure would be to get a commercial driver development kit from someplace like Jungo. DOS is comparatively trivial, just hook the vector and use it.

Try WinPcap. Enable promiscuous mode (all modern cards support it) and you'll see all the packets. If you need a good packet sniffer, get Ethereal. It uses WinPcap. Both are free including source code.

The Windows interrupt numbers are listed in Device Manager. Select "view resource by connection" or something like that. Beware that the plug-n-play manager sometimes shuffles the interrupt numbers.
 

nic interrupt

thanks all for ur replies.

Dainis: here is what I intend to do: using get_vector C/C++ routine, save the LAN ISR's address in some pointer and replace the address with that of my own made ISR using set_vector routine. Now whenever a packet would be received, my own ISR will be called in stead of window's. I will check the type field of the packet received and if it comes out to be of my interest, I will go on processing it. Otherwise, using the pointer pointing to the ISR of windows, I will simply call window's ISR to take care of the received packet/frame. This is all intended to be used on win2000 and XP.

echo47: Now you know my scheme, do you or anyone still thinks that it will not be really that simple (I already understand that I will have to have enuff knowlege of related PC registers)? plz comment as i m doing this all just to simplify my task and nothing could be worse if I made it all the more complicated
 

shakeebh said:
thanks all for ur replies.

Dainis: here is what I intend to do: using get_vector C/C++ routine, save the LAN ISR's address in some pointer and replace the address with that of my own made ISR using set_vector routine. Now whenever a packet would be received, my own ISR will be called in stead of window's. I will check the type field of the packet received and if it comes out to be of my interest, I will go on processing it. Otherwise, using the pointer pointing to the ISR of windows, I will simply call window's ISR to take care of the received packet/frame. This is all intended to be used on win2000 and XP.

This is not impossible, but do not wast your time ...
Better kook for these:
http://www.ndis.com/papers/winpktfilter.htm
http://www.pcausa.com/tdisamp/default.htm
**broken link removed**
 

    shakeebh

    Points: 2
    Helpful Answer Positive Rating
Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top