View topic - Handling Ethernet packets

Handling Ethernet packets

Read-only archive of qnx.ddk (Writing device drivers for scanners, video card, optical mouse, etc) at inn.qnx.com

Handling Ethernet packets

Postby rk » Sun Mar 21, 2004 3:34 pm

A naive question -- what docs should I read in order to be able to
receive and transmit type XXXX ethernet packets? I've glanced through
the io-net docs, and am a little leary about doing a "full" io-net
interface; I was kind of hoping that I could, as a separate process,
just "attach" to en0 and request type XXXX ethernet packets to be
sent to me via something simple like read() and be able to write()
those same packets out the ethernet port. Too naive? :-)

Thanks,
-RK

--
[If replying via email, you'll need to click on the URL that's emailed to you
afterwards to forward the email to me -- spam filters and all that]
Robert Krten, PDP minicomputer collector http://www.parse.com/~pdp8/
rk
Senior Member
 
Posts: 172
Joined: Mon Sep 15, 2003 3:58 pm

Re: Handling Ethernet packets

Postby ed1k » Mon Mar 22, 2004 2:24 am

In article <c3kcle$o6l$1@inn.qnx.com>, rk@parse.com says...

I heard there is a port of Berkeley Packet Filter for QNX though I never
used it. Looks like you want to find/install the BPF and, in this case,
you should read docs for this software and programming of BPF provided
interface (fortunately there is lot of it on internet).

Cheers,
Eduard.

A naive question -- what docs should I read in order to be able to
receive and transmit type XXXX ethernet packets? I've glanced through
the io-net docs, and am a little leary about doing a "full" io-net
interface; I was kind of hoping that I could, as a separate process,
just "attach" to en0 and request type XXXX ethernet packets to be
sent to me via something simple like read() and be able to write()
those same packets out the ethernet port. Too naive? :-)

Thanks,
-RK

ed1k
 

Re: Handling Ethernet packets

Postby Xiaodan Tang » Mon Mar 22, 2004 3:56 am

I don't think the BPF port support write though. :-(

The closest to what RK need, is nfm-nraw.so, which provides "nraw" support.
But it is not a released software, last I know, it only exist in "Network
Edition" :-(

-xtang

ed1k <ed1k@fake.address> wrote in message
news:MPG.1ac818433ea0ccd1989682@inn.qnx.com...
In article <c3kcle$o6l$1@inn.qnx.com>, rk@parse.com says...

I heard there is a port of Berkeley Packet Filter for QNX though I never
used it. Looks like you want to find/install the BPF and, in this case,
you should read docs for this software and programming of BPF provided
interface (fortunately there is lot of it on internet).

Cheers,
Eduard.

A naive question -- what docs should I read in order to be able to
receive and transmit type XXXX ethernet packets? I've glanced through
the io-net docs, and am a little leary about doing a "full" io-net
interface; I was kind of hoping that I could, as a separate process,
just "attach" to en0 and request type XXXX ethernet packets to be
sent to me via something simple like read() and be able to write()
those same packets out the ethernet port. Too naive? :-)

Thanks,
-RK

Xiaodan Tang
 

Re: Handling Ethernet packets

Postby ed1k » Mon Mar 22, 2004 4:00 am

In article <MPG.1ac818433ea0ccd1989682@inn.qnx.com>, ed1k@fake.address
says...
In article <c3kcle$o6l$1@inn.qnx.com>, rk@parse.com says...


/lib/dll/nfm-bpf.so
It's on 3rd party s/w CD in tcpdump package.

I heard there is a port of Berkeley Packet Filter for QNX though I never
used it. Looks like you want to find/install the BPF and, in this case,
you should read docs for this software and programming of BPF provided
interface (fortunately there is lot of it on internet).

Cheers,
Eduard.

A naive question -- what docs should I read in order to be able to
receive and transmit type XXXX ethernet packets? I've glanced through
the io-net docs, and am a little leary about doing a "full" io-net
interface; I was kind of hoping that I could, as a separate process,
just "attach" to en0 and request type XXXX ethernet packets to be
sent to me via something simple like read() and be able to write()
those same packets out the ethernet port. Too naive? :-)

Thanks,
-RK


ed1k
 

Re: Handling Ethernet packets

Postby rk » Mon Mar 22, 2004 2:17 pm

Xiaodan Tang <xtang@qnx.com> wrote:
I don't think the BPF port support write though. :-(

The closest to what RK need, is nfm-nraw.so, which provides "nraw" support.
But it is not a released software, last I know, it only exist in "Network
Edition" :-(

I do not have that version. Are you saying that:

a) Yes, it's possible to write what you want, just a little more complicated
than what you are suggesting, or
b) It is not possible to write what you want unless you have the NE version.

?

If (A), then I'd certainly be happy to take a stab at it; I'm assuming I'll have
to get "right in" to io-net though...

Cheers,
-RK

-xtang

ed1k <ed1k@fake.address> wrote in message
news:MPG.1ac818433ea0ccd1989682@inn.qnx.com...
In article <c3kcle$o6l$1@inn.qnx.com>, rk@parse.com says...

I heard there is a port of Berkeley Packet Filter for QNX though I never
used it. Looks like you want to find/install the BPF and, in this case,
you should read docs for this software and programming of BPF provided
interface (fortunately there is lot of it on internet).

Cheers,
Eduard.

A naive question -- what docs should I read in order to be able to
receive and transmit type XXXX ethernet packets? I've glanced through
the io-net docs, and am a little leary about doing a "full" io-net
interface; I was kind of hoping that I could, as a separate process,
just "attach" to en0 and request type XXXX ethernet packets to be
sent to me via something simple like read() and be able to write()
those same packets out the ethernet port. Too naive? :-)

Thanks,
-RK





--
[If replying via email, you'll need to click on the URL that's emailed to you
afterwards to forward the email to me -- spam filters and all that]
Robert Krten, PDP minicomputer collector http://www.parse.com/~pdp8/
rk
Senior Member
 
Posts: 172
Joined: Mon Sep 15, 2003 3:58 pm

Re: Handling Ethernet packets

Postby rk » Wed Mar 24, 2004 6:34 pm

Xiaodan Tang <xtang@qnx.com> wrote:

Robert Krten <rk@parse.com> wrote in message
news:c3mshj$r7f$1@inn.qnx.com...
Xiaodan Tang <xtang@qnx.com> wrote:
I don't think the BPF port support write though. :-(

The closest to what RK need, is nfm-nraw.so, which provides "nraw"
support.
But it is not a released software, last I know, it only exist in
"Network
Edition" :-(

I do not have that version. Are you saying that:

a) Yes, it's possible to write what you want, just a little more
complicated
than what you are suggesting, or
b) It is not possible to write what you want unless you have the NE
version.

?

If (A), then I'd certainly be happy to take a stab at it; I'm assuming
I'll have
to get "right in" to io-net though...

It's a). You need to have a "nfm-" (Network filtering module, as oppose to
npm/devn) module, have it attach to a resmgr name, so then your application
could read/write this new name to get control.


Ok, thanks. I've requested nfm-raw from QSSL.

Cheers,
-RK


--
[If replying via email, you'll need to click on the URL that's emailed to you
afterwards to forward the email to me -- spam filters and all that]
Robert Krten, PDP minicomputer collector http://www.parse.com/~pdp8/
rk
Senior Member
 
Posts: 172
Joined: Mon Sep 15, 2003 3:58 pm

Re: Handling Ethernet packets

Postby Xiaodan Tang » Wed Mar 24, 2004 6:55 pm

Robert Krten <rk@parse.com> wrote in message
news:c3mshj$r7f$1@inn.qnx.com...
Xiaodan Tang <xtang@qnx.com> wrote:
I don't think the BPF port support write though. :-(

The closest to what RK need, is nfm-nraw.so, which provides "nraw"
support.
But it is not a released software, last I know, it only exist in
"Network
Edition" :-(

I do not have that version. Are you saying that:

a) Yes, it's possible to write what you want, just a little more
complicated
than what you are suggesting, or
b) It is not possible to write what you want unless you have the NE
version.

?

If (A), then I'd certainly be happy to take a stab at it; I'm assuming
I'll have
to get "right in" to io-net though...

It's a). You need to have a "nfm-" (Network filtering module, as oppose to
npm/devn) module, have it attach to a resmgr name, so then your application
could read/write this new name to get control.

-xtang
Xiaodan Tang
 


Return to qnx.ddk

Who is online

Users browsing this forum: No registered users and 1 guest