protocol development

I need to communicate two computers over Ethernet. I don’t need all the
overhead of tcp or ip protocols. So, I have to write my own protocol
layer, right? But I have looked for about this subject on documentations
and I haven’t found anything about protocol development (just about driver
development). I think I need to use raw sockets… So, could anyone give
me a help on where to start?

Thanks a lot! All help is welcome!
Cesar

“Cesar Ossamu Ida” <root@qnx.com> wrote in message
news:Pine.NTO.4.21.0206181737240.831536-100000@minardi.inf.ufrgs.br

I need to communicate two computers over Ethernet. I don’t need all the
overhead of tcp or ip protocols. So, I have to write my own protocol
layer, right? But I have looked for about this subject on documentations
and I haven’t found anything about protocol development (just about driver
development). I think I need to use raw sockets… So, could anyone give
me a help on where to start?

Raw sockets still involve IP - That said, IP isn’t that much overhead and
using it means that other products could potentially interact with it, or at
least route it. There are only very few circumstances where IP would be
more of a hinderance than a help in the development cycle.


Cheers,
Adam

QNX Software Systems Ltd.
[ amallory@qnx.com ]

With a PC, I always felt limited by the software available.
On Unix, I am limited only by my knowledge.
–Peter J. Schoenster <pschon@baste.magibox.net>

You should look at developing a filter above the ethernet layer.You will be
able to generate packets which will go on ethernet frames.But then you have
to develop your protocol to do the ARP for your protocol.

Sreekanth

“Adam Mallory” <amallory@qnx.com> wrote in message
news:aeq5pc$dh0$1@nntp.qnx.com

“Cesar Ossamu Ida” <> root@qnx.com> > wrote in message
news:> Pine.NTO.4.21.0206181737240.831536-100000@minardi.inf.ufrgs.br> …
I need to communicate two computers over Ethernet. I don’t need all the
overhead of tcp or ip protocols. So, I have to write my own protocol
layer, right? But I have looked for about this subject on documentations
and I haven’t found anything about protocol development (just about
driver
development). I think I need to use raw sockets… So, could anyone give
me a help on where to start?

Raw sockets still involve IP - That said, IP isn’t that much overhead and
using it means that other products could potentially interact with it, or
at
least route it. There are only very few circumstances where IP would be
more of a hinderance than a help in the development cycle.


Cheers,
Adam

QNX Software Systems Ltd.
[ > amallory@qnx.com > ]

With a PC, I always felt limited by the software available.
On Unix, I am limited only by my knowledge.
–Peter J. Schoenster <> pschon@baste.magibox.net
\

Sorry, I got a little confused…
Did you mean I have to develop a filter instead of a converter?
Well, here is what I had thought: I need to develop a program that talks
directly to the Ethernet layer, but as I think this is not possible, I
have to develop a protocol (or a converter) that lays between the program
and the Ethernet layer. Am I wrong? Do you have any idea on how can I do
that?

Thanks a lot!
Cesar


On Wed, 19 Jun 2002, Sreekanth wrote:

You should look at developing a filter above the ethernet layer.You will be
able to generate packets which will go on ethernet frames.But then you have
to develop your protocol to do the ARP for your protocol.

Sreekanth

“Adam Mallory” <> amallory@qnx.com> > wrote in message
news:aeq5pc$dh0$> 1@nntp.qnx.com> …
“Cesar Ossamu Ida” <> root@qnx.com> > wrote in message
news:> Pine.NTO.4.21.0206181737240.831536-100000@minardi.inf.ufrgs.br> …
I need to communicate two computers over Ethernet. I don’t need all the
overhead of tcp or ip protocols. So, I have to write my own protocol
layer, right? But I have looked for about this subject on documentations
and I haven’t found anything about protocol development (just about
driver
development). I think I need to use raw sockets… So, could anyone give
me a help on where to start?

Raw sockets still involve IP - That said, IP isn’t that much overhead and
using it means that other products could potentially interact with it, or
at
least route it. There are only very few circumstances where IP would be
more of a hinderance than a help in the development cycle.


Cheers,
Adam

QNX Software Systems Ltd.
[ > amallory@qnx.com > ]

With a PC, I always felt limited by the software available.
On Unix, I am limited only by my knowledge.
–Peter J. Schoenster <> pschon@baste.magibox.net



\

Ok. If I use raw sockets, I am actually implementing the IP layer and I
will make use of the IP-EN converter (right?). But I still do not have any
idea on how to implement it on qnx, as the documentation only mention the
Driver development (registering, advertising, …)

Thanks for the help!
Cesar

On Wed, 19 Jun 2002, Adam Mallory wrote:

“Cesar Ossamu Ida” <> root@qnx.com> > wrote in message
news:> Pine.NTO.4.21.0206181737240.831536-100000@minardi.inf.ufrgs.br> …
I need to communicate two computers over Ethernet. I don’t need all the
overhead of tcp or ip protocols. So, I have to write my own protocol
layer, right? But I have looked for about this subject on documentations
and I haven’t found anything about protocol development (just about driver
development). I think I need to use raw sockets… So, could anyone give
me a help on where to start?

Raw sockets still involve IP - That said, IP isn’t that much overhead and
using it means that other products could potentially interact with it, or at
least route it. There are only very few circumstances where IP would be
more of a hinderance than a help in the development cycle.


Cheers,
Adam

QNX Software Systems Ltd.
[ > amallory@qnx.com > ]

With a PC, I always felt limited by the software available.
On Unix, I am limited only by my knowledge.
–Peter J. Schoenster <> pschon@baste.magibox.net

\

I’m doing the same thing (a protocol on top of Ethernet). I also have the
added requirement of needing to filter downward packets (based on bandwidth
usage) from above layers, so I made an up filter (en_en0). An up filter sits
above the Ethernet driver (en0), and below protocol converters (ip_en for
example). From this position I’m able to see all the packets received on the
ethernet device, I’m able to transmit packets to the ethernet device, and I
can filter packets from higher layers. You’re probably only interested in
the first two abilities, but an up filter might do what you need. The
alternative is to write a converter (yourprotocol_en).

Cheers,
Shaun

Cesar Ossamu Ida <root@qnx.com> wrote:

Sorry, I got a little confused…
Did you mean I have to develop a filter instead of a converter?
Well, here is what I had thought: I need to develop a program that talks
directly to the Ethernet layer, but as I think this is not possible, I
have to develop a protocol (or a converter) that lays between the program
and the Ethernet layer. Am I wrong? Do you have any idea on how can I do
that?

If you want, you can create your own “protocol X”, and a “X-EN”
converter, to use it with exist driver.

If you just want to pump data into driver, you can create “en-en filter”,
which can sends packet down to driver, and could receive packet
from driver.

A “filter module” is almost the same as a driver (_REG_PRODUCER_UP),
except while register, you regist as a “_REG_FILTER_ABOVE”, with
top/bot_type as “en”.

-xtang


On Wed, 19 Jun 2002, Sreekanth wrote:

You should look at developing a filter above the ethernet layer.You will be
able to generate packets which will go on ethernet frames.But then you have
to develop your protocol to do the ARP for your protocol.

Sreekanth

“Adam Mallory” <> amallory@qnx.com> > wrote in message
news:aeq5pc$dh0$> 1@nntp.qnx.com> …
“Cesar Ossamu Ida” <> root@qnx.com> > wrote in message
news:> Pine.NTO.4.21.0206181737240.831536-100000@minardi.inf.ufrgs.br> …
I need to communicate two computers over Ethernet. I don’t need all the
overhead of tcp or ip protocols. So, I have to write my own protocol
layer, right? But I have looked for about this subject on documentations
and I haven’t found anything about protocol development (just about
driver
development). I think I need to use raw sockets… So, could anyone give
me a help on where to start?

Raw sockets still involve IP - That said, IP isn’t that much overhead and
using it means that other products could potentially interact with it, or
at
least route it. There are only very few circumstances where IP would be
more of a hinderance than a help in the development cycle.


Cheers,
Adam

QNX Software Systems Ltd.
[ > amallory@qnx.com > ]

With a PC, I always felt limited by the software available.
On Unix, I am limited only by my knowledge.
–Peter J. Schoenster <> pschon@baste.magibox.net



\

Although it will be called a filter,It can be used to generate
packets.Depending on whether you want to use IP or not you can place your
filter between IP and arp or between Arp and ethernet.You have to write a
resource manager to be able to send the packets to your module by another
application.This can be thought of as a socket interface.I am currently
working on similar thing.
Hope that helps

Sreekanth

“Cesar Ossamu Ida” <root@qnx.com> wrote in message
news:Pine.NTO.4.21.0206191620110.790565-100000@minardi.inf.ufrgs.br

Sorry, I got a little confused…
Did you mean I have to develop a filter instead of a converter?
Well, here is what I had thought: I need to develop a program that talks
directly to the Ethernet layer, but as I think this is not possible, I
have to develop a protocol (or a converter) that lays between the program
and the Ethernet layer. Am I wrong? Do you have any idea on how can I do
that?

Thanks a lot!
Cesar


On Wed, 19 Jun 2002, Sreekanth wrote:

You should look at developing a filter above the ethernet layer.You will
be
able to generate packets which will go on ethernet frames.But then you
have
to develop your protocol to do the ARP for your protocol.

Sreekanth

“Adam Mallory” <> amallory@qnx.com> > wrote in message
news:aeq5pc$dh0$> 1@nntp.qnx.com> …
“Cesar Ossamu Ida” <> root@qnx.com> > wrote in message
news:> Pine.NTO.4.21.0206181737240.831536-100000@minardi.inf.ufrgs.br> …
I need to communicate two computers over Ethernet. I don’t need all
the
overhead of tcp or ip protocols. So, I have to write my own protocol
layer, right? But I have looked for about this subject on
documentations
and I haven’t found anything about protocol development (just about
driver
development). I think I need to use raw sockets… So, could anyone
give
me a help on where to start?

Raw sockets still involve IP - That said, IP isn’t that much overhead
and
using it means that other products could potentially interact with it,
or
at
least route it. There are only very few circumstances where IP would
be
more of a hinderance than a help in the development cycle.


Cheers,
Adam

QNX Software Systems Ltd.
[ > amallory@qnx.com > ]

With a PC, I always felt limited by the software available.
On Unix, I am limited only by my knowledge.
–Peter J. Schoenster <> pschon@baste.magibox.net




\

Thanks guys! All these valuable tips are sure helping me!!! I’m going
through filters already!

Cheers!
Cesar

On 20 Jun 2002, Xiaodan Tang wrote:

Cesar Ossamu Ida <> root@qnx.com> > wrote:
Sorry, I got a little confused…
Did you mean I have to develop a filter instead of a converter?
Well, here is what I had thought: I need to develop a program that talks
directly to the Ethernet layer, but as I think this is not possible, I
have to develop a protocol (or a converter) that lays between the program
and the Ethernet layer. Am I wrong? Do you have any idea on how can I do
that?

If you want, you can create your own “protocol X”, and a “X-EN”
converter, to use it with exist driver.

If you just want to pump data into driver, you can create “en-en filter”,
which can sends packet down to driver, and could receive packet
from driver.

A “filter module” is almost the same as a driver (_REG_PRODUCER_UP),
except while register, you regist as a “_REG_FILTER_ABOVE”, with
top/bot_type as “en”.

-xtang


On Wed, 19 Jun 2002, Sreekanth wrote:

You should look at developing a filter above the ethernet layer.You will be
able to generate packets which will go on ethernet frames.But then you have
to develop your protocol to do the ARP for your protocol.

Sreekanth

“Adam Mallory” <> amallory@qnx.com> > wrote in message
news:aeq5pc$dh0$> 1@nntp.qnx.com> …
“Cesar Ossamu Ida” <> root@qnx.com> > wrote in message
news:> Pine.NTO.4.21.0206181737240.831536-100000@minardi.inf.ufrgs.br> …
I need to communicate two computers over Ethernet. I don’t need all the
overhead of tcp or ip protocols. So, I have to write my own protocol
layer, right? But I have looked for about this subject on documentations
and I haven’t found anything about protocol development (just about
driver
development). I think I need to use raw sockets… So, could anyone give
me a help on where to start?

Raw sockets still involve IP - That said, IP isn’t that much overhead and
using it means that other products could potentially interact with it, or
at
least route it. There are only very few circumstances where IP would be
more of a hinderance than a help in the development cycle.


Cheers,
Adam

QNX Software Systems Ltd.
[ > amallory@qnx.com > ]

With a PC, I always felt limited by the software available.
On Unix, I am limited only by my knowledge.
–Peter J. Schoenster <> pschon@baste.magibox.net





\

Hellooooo,

You can find a good example of a down producer if you type
_REG_PRODUCER_DOWN on groups.google.com

Have a look at Chris Goeble’s example :
io-net bug on slow machine? (if you want, type just that in google :wink: )

Follow the instructions and then, you just have to write a raw_en filter.
Again, search google for examples :slight_smile:

If you want to receive the Ethernet packets you sent with the down_producer,
transform Chris Goeble’s example into a “filter below”.

I hope it’s what your looking for…
Sorry for my English ,

Bye bye,

Starn