Hi Andrea, 2010/11/29 a.gra...@gmail.com <a.gra...@gmail.com>: > It's not easy to keep track of transfered data, so I'd like to write a > desktop applet that monitor traffic and keep the amount updated. > I'm going to write this in Qt/C++. > > I've some question before starting: > > 1) How can I detect, from a Qt/C++ application, if a 3G connection is > estabilished and when it disconnects?
libconic can do that: http://maemo.org/api_refs/5.0/5.0-final/libconic/ > 2) Is it ok if I monitor the trasmitted/received data using ifconfig? > If yes, how can I execute ifconfig from an application running as > user? (Usually you can only execute ifconfig if you "sudo gainroot" > before). There already exists a Personal Dataplan Monitor applet that might already fulfill your use case :) And even if not, its source might be a good starting point for your app (or simply add changes that you need and submit a patch to Andrew): http://maemo.org/downloads/product/Maemo5/personal-gprs-mon/ HTH. Thomas _______________________________________________ maemo-developers mailing list maemo-developers@maemo.org https://lists.maemo.org/mailman/listinfo/maemo-developers