DDD With Io-net

Is it possible to use DDD to work with io-net.When i try to attach to io-net
I get this dialog box saying “please open a program first”,whereas i am
trying to debug a filter.Any help is appreciated…

Thanks

Sreekanth

Sreekanth wrote:

Is it possible to use DDD to work with io-net.When i try to attach to
io-net
I get this dialog box saying “please open a program first”,whereas i
am
trying to debug a filter.Any help is appreciated…

First, load the program /sbin/io-net, then attach to it and set
breakpoints before continuing (F9).

Optionally, start a second instance of io-net like this:

  • start DDD
  • load /sbin/io-net
  • run (F2) with command these options: -d yourDriver -p tcpip
  • continue (F9)

Remember, your need to be root!

–bl

I have a similar request… I am attempting to debug a network driver. I
have started io-net without my driver and intend to attach to it and then
use the mount command to load my driver. I used pidin to get the PID for
io-net on the target devcie, however when I do attach 9999, it just seems to
hang after printing the message “Attaching to process 9999”…

“Bernard Leclerc” <whittom-leclerc@sympatico.ca> wrote in message
news:abfcq9$i3i$1@inn.qnx.com

Sreekanth wrote:

Is it possible to use DDD to work with io-net.When i try to attach to
io-net
I get this dialog box saying “please open a program first”,whereas i
am
trying to debug a filter.Any help is appreciated…

First, load the program /sbin/io-net, then attach to it and set
breakpoints before continuing (F9).

Optionally, start a second instance of io-net like this:

  • start DDD
  • load /sbin/io-net
  • run (F2) with command these options: -d yourDriver -p tcpip
  • continue (F9)

Remember, your need to be root!

–bl

Actually, the problem is I was attached to the remote machine with tcpip and
when I attached to io-net, it stops io-net and therefore it all hangs. I
understand I need to start another instance of io-net or not use tcpip as
the method of debugging. if i start another io-net, not sure how to control
which one voyager uses…

“Jay Witherspoon” <spoon@scubadiving.com> wrote in message
news:ajqteq$stf$1@inn.qnx.com

I have a similar request… I am attempting to debug a network driver. I
have started io-net without my driver and intend to attach to it and then
use the mount command to load my driver. I used pidin to get the PID for
io-net on the target devcie, however when I do attach 9999, it just seems
to
hang after printing the message “Attaching to process 9999”…

“Bernard Leclerc” <> whittom-leclerc@sympatico.ca> > wrote in message
news:abfcq9$i3i$> 1@inn.qnx.com> …
Sreekanth wrote:

Is it possible to use DDD to work with io-net.When i try to attach to
io-net
I get this dialog box saying “please open a program first”,whereas i
am
trying to debug a filter.Any help is appreciated…

First, load the program /sbin/io-net, then attach to it and set
breakpoints before continuing (F9).

Optionally, start a second instance of io-net like this:

  • start DDD
  • load /sbin/io-net
  • run (F2) with command these options: -d yourDriver -p tcpip
  • continue (F9)

Remember, your need to be root!

–bl
\

Jay Witherspoon <spoon@scubadiving.com> wrote:

Actually, the problem is I was attached to the remote machine with tcpip and
when I attached to io-net, it stops io-net and therefore it all hangs. I
understand I need to start another instance of io-net or not use tcpip as
the method of debugging. if i start another io-net, not sure how to control
which one voyager uses…

Start the one you will debug with first, and then start the second one
for the runtime environment. So if you do the following (more-or-less)…

io-net -d tulip -p tcpip
ifconfig …
route …
pdebug 9000 &
io-net -d speedo -p tcpip
ifconfig …
route …
voyager &

…you will get what you want. The networking tools will always interact with
the last instance of io-net started. MAke sure you don’t try to run on
the same ethernet device though - you will need two of them.

The other option, of course, is to do the debugging over serial.

chris



“Jay Witherspoon” <> spoon@scubadiving.com> > wrote in message
news:ajqteq$stf$> 1@inn.qnx.com> …
I have a similar request… I am attempting to debug a network driver. I
have started io-net without my driver and intend to attach to it and then
use the mount command to load my driver. I used pidin to get the PID for
io-net on the target devcie, however when I do attach 9999, it just seems
to
hang after printing the message “Attaching to process 9999”…

“Bernard Leclerc” <> whittom-leclerc@sympatico.ca> > wrote in message
news:abfcq9$i3i$> 1@inn.qnx.com> …
Sreekanth wrote:

Is it possible to use DDD to work with io-net.When i try to attach to
io-net
I get this dialog box saying “please open a program first”,whereas i
am
trying to debug a filter.Any help is appreciated…

First, load the program /sbin/io-net, then attach to it and set
breakpoints before continuing (F9).

Optionally, start a second instance of io-net like this:

  • start DDD
  • load /sbin/io-net
  • run (F2) with command these options: -d yourDriver -p tcpip
  • continue (F9)

Remember, your need to be root!

–bl



\


Chris McKillop <cdm@qnx.com> “The faster I go, the behinder I get.”
Software Engineer, QSSL – Lewis Carroll –
http://qnx.wox.org/

Chris,

Thank you for the update, do not currently have two interfaces, so that is
probably why I am having some problems. I have also tried to use serial and
cannot believe I am having trouble… Here is what I am doing…

io-net is started at boot
start pdebug using: pdebug /dev/ser1,115200 &

start ddd on the development machine
set target with: target qnx /dev/ser1

and it never connects. I am using two Intel boxes and a null modem cable.
Is there more involved in the setup?

“Chris McKillop” <cdm@qnx.com> wrote in message
news:ajrg1u$rjk$1@nntp.qnx.com

Jay Witherspoon <> spoon@scubadiving.com> > wrote:
Actually, the problem is I was attached to the remote machine with tcpip
and
when I attached to io-net, it stops io-net and therefore it all hangs.
I
understand I need to start another instance of io-net or not use tcpip
as
the method of debugging. if i start another io-net, not sure how to
control
which one voyager uses…


Start the one you will debug with first, and then start the second one
for the runtime environment. So if you do the following (more-or-less)…

io-net -d tulip -p tcpip
ifconfig …
route …
pdebug 9000 &
io-net -d speedo -p tcpip
ifconfig …
route …
voyager &

…you will get what you want. The networking tools will always interact
with
the last instance of io-net started. MAke sure you don’t try to run on
the same ethernet device though - you will need two of them.

The other option, of course, is to do the debugging over serial.

chris



“Jay Witherspoon” <> spoon@scubadiving.com> > wrote in message
news:ajqteq$stf$> 1@inn.qnx.com> …
I have a similar request… I am attempting to debug a network driver.
I
have started io-net without my driver and intend to attach to it and
then
use the mount command to load my driver. I used pidin to get the PID
for
io-net on the target devcie, however when I do attach 9999, it just see
ms
to
hang after printing the message “Attaching to process 9999”…

“Bernard Leclerc” <> whittom-leclerc@sympatico.ca> > wrote in message
news:abfcq9$i3i$> 1@inn.qnx.com> …
Sreekanth wrote:

Is it possible to use DDD to work with io-net.When i try to attach
to
io-net
I get this dialog box saying “please open a program first”,whereas
i
am
trying to debug a filter.Any help is appreciated…

First, load the program /sbin/io-net, then attach to it and set
breakpoints before continuing (F9).

Optionally, start a second instance of io-net like this:

  • start DDD
  • load /sbin/io-net
  • run (F2) with command these options: -d yourDriver -p tcpip
  • continue (F9)

Remember, your need to be root!

–bl






\

Chris McKillop <> cdm@qnx.com> > “The faster I go, the behinder I get.”
Software Engineer, QSSL – Lewis Carroll –
http://qnx.wox.org/

Chris,

We found another pcmcia card for our laptop and tried to use the two io-net
methods, but it appears from your example we need two different ethernet
card types? your example shows two different -d parameters, is that
required or you just showing two types? If not, how can we control which
one is being used by each io-net… we have two of the same type. Also,
how can we tell which driver is being used? As you can see, we are trying
both methods (serial and two io-nets).

“Chris McKillop” <cdm@qnx.com> wrote in message
news:ajrg1u$rjk$1@nntp.qnx.com

Jay Witherspoon <> spoon@scubadiving.com> > wrote:
Actually, the problem is I was attached to the remote machine with tcpip
and
when I attached to io-net, it stops io-net and therefore it all hangs.
I
understand I need to start another instance of io-net or not use tcpip
as
the method of debugging. if i start another io-net, not sure how to
control
which one voyager uses…


Start the one you will debug with first, and then start the second one
for the runtime environment. So if you do the following (more-or-less)…

io-net -d tulip -p tcpip
ifconfig …
route …
pdebug 9000 &
io-net -d speedo -p tcpip
ifconfig …
route …
voyager &

…you will get what you want. The networking tools will always interact
with
the last instance of io-net started. MAke sure you don’t try to run on
the same ethernet device though - you will need two of them.

The other option, of course, is to do the debugging over serial.

chris



“Jay Witherspoon” <> spoon@scubadiving.com> > wrote in message
news:ajqteq$stf$> 1@inn.qnx.com> …
I have a similar request… I am attempting to debug a network driver.
I
have started io-net without my driver and intend to attach to it and
then
use the mount command to load my driver. I used pidin to get the PID
for
io-net on the target devcie, however when I do attach 9999, it just
seems
to
hang after printing the message “Attaching to process 9999”…

“Bernard Leclerc” <> whittom-leclerc@sympatico.ca> > wrote in message
news:abfcq9$i3i$> 1@inn.qnx.com> …
Sreekanth wrote:

Is it possible to use DDD to work with io-net.When i try to attach
to
io-net
I get this dialog box saying “please open a program first”,whereas
i
am
trying to debug a filter.Any help is appreciated…

First, load the program /sbin/io-net, then attach to it and set
breakpoints before continuing (F9).

Optionally, start a second instance of io-net like this:

  • start DDD
  • load /sbin/io-net
  • run (F2) with command these options: -d yourDriver -p tcpip
  • continue (F9)

Remember, your need to be root!

–bl






\

Chris McKillop <> cdm@qnx.com> > “The faster I go, the behinder I get.”
Software Engineer, QSSL – Lewis Carroll –
http://qnx.wox.org/

io-net is started at boot
start pdebug using: pdebug /dev/ser1,115200 &

start ddd on the development machine
set target with: target qnx /dev/ser1

and it never connects. I am using two Intel boxes and a null modem cable.
Is there more involved in the setup?

Make sure that both ports are in raw mode (although pdebug should set them
that way by default). Also lower the baud rate to 19200.

You can setup the ports in “raw” mode on the command line to any devc
device or using stty. ie: “stty +raw < /dev/ser1”. You also should ensure
that both sides are using the same flowcontrol settings.

chris


Chris McKillop <cdm@qnx.com> “The faster I go, the behinder I get.”
Software Engineer, QSSL – Lewis Carroll –
http://qnx.wox.org/

Jay Witherspoon <spoon@scubadiving.com> wrote:

Chris,

We found another pcmcia card for our laptop and tried to use the two io-net
methods, but it appears from your example we need two different ethernet
card types? your example shows two different -d parameters, is that
required or you just showing two types? If not, how can we control which
one is being used by each io-net… we have two of the same type. Also,
how can we tell which driver is being used? As you can see, we are trying
both methods (serial and two io-nets).

If it is a pci (cardbus) device then you can start two io-nets for different
devices using the “pci=X” option to the driver to specify the pci index.
If it is truly pcmcia you have to give the ioport and irq on the command line
and that will id a specific card.

ie:

io-net -d tulip pci=0 -p tcpip

io-net -d tulip pci=1 -p tcpip

OR

io-net -d ne2000 ioport=0x300,irq=11 -p tcpip

io-net -d ne2000 ioport=0x330,irq=9 -p tcpip


chris

\

Chris McKillop <cdm@qnx.com> “The faster I go, the behinder I get.”
Software Engineer, QSSL – Lewis Carroll –
http://qnx.wox.org/

Chris,

Thanks again for your help. I am amazed this is not working… I was not
using +raw and now it is timing out with “Timeout in mid-packet”. I have
reduced the baud rate to 19,200 and 9600 without luck. Here is the command
I use to setup the serial port on both machines:

stty +raw baud=9600 bits=8 stopb=1 -ihflow -ohflow < /dev/ser1

I start pdebug using: pdebug /dev/ser1,9600 &

Any help would be greatly appreciated…

“Chris McKillop” <cdm@qnx.com> wrote in message
news:ajskum$9mq$1@nntp.qnx.com

io-net is started at boot
start pdebug using: pdebug /dev/ser1,115200 &

start ddd on the development machine
set target with: target qnx /dev/ser1

and it never connects. I am using two Intel boxes and a null modem
cable.
Is there more involved in the setup?


Make sure that both ports are in raw mode (although pdebug should set them
that way by default). Also lower the baud rate to 19200.

You can setup the ports in “raw” mode on the command line to any devc
device or using stty. ie: “stty +raw < /dev/ser1”. You also should ensure
that both sides are using the same flowcontrol settings.

chris


Chris McKillop <> cdm@qnx.com> > “The faster I go, the behinder I get.”
Software Engineer, QSSL – Lewis Carroll –
http://qnx.wox.org/

seems that DDD was causing the problem, went to gdb and it is working…
all setting are the same…

“Jay Witherspoon” <spoon@scubadiving.com> wrote in message
news:ajtem4$nlm$1@inn.qnx.com

Chris,

Thanks again for your help. I am amazed this is not working… I was not
using +raw and now it is timing out with “Timeout in mid-packet”. I have
reduced the baud rate to 19,200 and 9600 without luck. Here is the
command
I use to setup the serial port on both machines:

stty +raw baud=9600 bits=8 stopb=1 -ihflow -ohflow < /dev/ser1

I start pdebug using: pdebug /dev/ser1,9600 &

Any help would be greatly appreciated…

“Chris McKillop” <> cdm@qnx.com> > wrote in message
news:ajskum$9mq$> 1@nntp.qnx.com> …

io-net is started at boot
start pdebug using: pdebug /dev/ser1,115200 &

start ddd on the development machine
set target with: target qnx /dev/ser1

and it never connects. I am using two Intel boxes and a null modem
cable.
Is there more involved in the setup?


Make sure that both ports are in raw mode (although pdebug should set
them
that way by default). Also lower the baud rate to 19200.

You can setup the ports in “raw” mode on the command line to any devc
device or using stty. ie: “stty +raw < /dev/ser1”. You also should
ensure
that both sides are using the same flowcontrol settings.

chris


Chris McKillop <> cdm@qnx.com> > “The faster I go, the behinder I
get.”
Software Engineer, QSSL – Lewis Carroll –
http://qnx.wox.org/
\