Help - Search - Members - Calendar
Full Version: Can I Stop A Specific 'tty' With Qcop?
OESF Portables Forum > Everything Else > Archived Forums > Zaurus General Forums > General Support and Discussion > Security and Networking
On some Zaurii, even if someone is already online, while Opera is opening up, the network applet stops saying 'Connected' and says 'Network Offline' instead. When done using Opera, users have to disconnect from the internet by using 'cardctl reset 0' or 'cardctl suspend', if they don't just decide to physically unplug either the modem or the jack.

When I was solely using cardctl commands to disconnect, the next two times I attempt to go online, I had to use cardctl again, and usually also kill the pppd process, before my modem would work properly. Otherwise, I could tap on "Connect" and have it get stuck on "Initializing" forever, push 'Abort', and then have it repeat the "Initializing" forever thing about ten times before I finally _might_ get it to work.

If Opera is run more than once during the online session, the GUI may give the user the option to disconnect, but that tapping "disconnect" at that point could result in a crash and require a soft reset.

I have found that I can correct the situation, with none of the above problems developing later on, by entering a combination of cardctl commands and the following:

qcop QPE/Network 'stop()'

However, when a friend who had a simultaneous LAN connection going entered the qcop command, it messed up his network.

Is there any way we can specify, with qcop, which specific process listening on the Network channel we wish to have receive the message?

I could certainly specify the exact process number (PID) of the process I wanted to raise or stop, or which tty or type of Network process I wanted to affect (i.e., LAN, DialUp, IRDA, etc.).

Is there a way to do this using qcop? Has anyone seen anything about Network subchannels that would be helpful?

Maybe some more detail will help.

I guess I do know that I can start a specific network process using qcop as follows:

qcop QPE/Network 'start(QString,QString)' "/home/root/Applications/Network/modules/DialUp30.conf" ""

And I suppose that if all I want to do is stop this known process, the following would probably work:

qcop QPE/Network 'stop(QString,QString)' "/home/root/Applications/Network/modules/DialUp30.conf" ""

But my problem is that there are 'renegade' phantom processes for which I do not know the precise QString. Does anyone have any ideas how I would figure that out?

They do not show up in my "ps ax" listings at all.

In the example I gave, where Opera attempts to start another network connection, there are no QStrings given AFAIK. The netmon applet is repainted, and choices given, and although nothing is chosen, qtopia still acts as if another process was started, messing up the user's ability to get another network process going.

If I open up Opera when I am offline, all that shows up in the network channel (as per qcoptest) is:

06:29:54 - Recv - choicesChanged()
06:30:08 - Recv - repaint()

If I open up Opera when I am online, then my Network channel shows:

06:35:04 - Recv - up()
06:35:06 - Recv - choicesChanged()
06:35:11 - Recv - up()
06:35:11 - Recv - available(QStringList)
QStringList : "/home/root/Applications/Network/modules/DialUp34.conf"
( the list of all network conf files appears here ... )
06:35:12 - Recv - down()
06:35:21 - Recv - repaint()

I want to stop that phantom process, without accidentally stopping other valid network processes.

Also, does anyone know what the second QString would be for, or exactly where there is more precise documentation for it?

Well, my idea about adding arguments to the stop message didn't work out. They did nothing. The following didn't result in an error message, but brought no action either:

qcop QPE/Network 'stop(QString,QString)' "/home/root/Applications/Network/modules/DialUp30.conf" ""__

I had to enter the following to disconnect from the commandline:
qcop QPE/Network 'stop()'

Oh well. There's gotta be a way to be more specific so as to not kill other network processes accidentally. sad.gif
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.
Invision Power Board © 2001-2018 Invision Power Services, Inc.