[maemo-developers] Starting a 3G traffic monitoring application for N900: some questions
From: Naresh Mehta nareshtechs at gmail.comDate: Fri Dec 3 11:41:46 EET 2010
- Previous message: Starting a 3G traffic monitoring application for N900: some questions
- Next message: Starting a 3G traffic monitoring application for N900: some questions
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Check out the source for my conference manager at https://garage.maemo.org/projects/confmgr/. It is written in QT. I also have a class which abstracts the dbus implementation and allows for methods to send and receive as well subscribe and unsubscribe to dbus events. BR; Naresh On Thu, Dec 2, 2010 at 4:43 PM, a.grandi at gmail.com <a.grandi at gmail.com> wrote: > Hi, > > On 29 November 2010 15:14, Mohammad Abu-Garbeyyeh > <mohammad7410 at gmail.com> wrote: >> You can use DBus to monitor 3G connection states, run dbus-monitor --system >> in a shell to see the paths send, then you can just use QtDbus to connect a >> signal to a function in your app. > > I've tried your idea and I've saved a text file with dbus log. I think > this is the best way to monitor both connection, disconnection and > traffic. > > I won't report the whole log, just a brief extract, but anyway I think > that the interesting part should be this one: > > 1) How to detect connection: this message appears once, when you have > estabilished a connection. > > signal sender=:1.18 -> dest=(null destination) serial=15255 > path=/com/nokia/csd/gprs/0; interface=com.nokia.csd.GPRS.Context; > member=Connected > string "tre.it" > string "IP" > string "gprs0" > string "1.87.169.88" > string "62.13.173.92" > string "62.13.173.93" > > 2) How to monitor traffic: this message appears every time there is a > traffic. The two uint64 are sent and received bytes. > > signal sender=:1.18 -> dest=(null destination) serial=15266 > path=/com/nokia/csd/gprs; interface=com.nokia.csd.GPRS; member=Status > array [ > dict entry( > object path "/com/nokia/csd/gprs/0" > struct { > string "tre.it" > string "IP" > string "gprs0" > string "1.87.169.88" > boolean true > uint64 10528 > uint64 38281 > } > ) > ] > > 3) How to detect disconnection: > > signal sender=:1.18 -> dest=(null destination) serial=15319 > path=/com/nokia/csd/gprs; interface=com.nokia.csd.GPRS; > member=Suspended > uint32 3 > string "Detached" > > > I've two more question now. Since I've never worked with dbus before, > is there any good example about a dbus "client" in Qt/C++? > Is there a way to "simulate" those messages, so I will be able to test > my application directly on my desktop, without having to build the > executable for N900 and test it on the device? > > p.s: very last question... let me guess..... QtDbus is not available > on Qt for Symbian, right :) ? > > -- > Andrea Grandi - Nokia Qt Ambassador > Maemo Community Council member > website: http://www.andreagrandi.it > _______________________________________________ > maemo-developers mailing list > maemo-developers at maemo.org > https://lists.maemo.org/mailman/listinfo/maemo-developers > -- BR; Naresh visit me at: http://www.naresh.se/
- Previous message: Starting a 3G traffic monitoring application for N900: some questions
- Next message: Starting a 3G traffic monitoring application for N900: some questions
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]