PDA

View Full Version : A question about QSystemNetworkInfo



Ataul Ghalib
1st December 2010, 00:30
Hi,
I am new to Qt. I am trying to use QSytemNetworkInfo class to find out the available WLAN networks and their mac addresses as well as their RSS. pro file is here

SOURCES += main.cpp\
mainwindow.cpp

TARGET = wlan

HEADERS += mainwindow.h

QT = core gui network svg
QT += network

include(../examples.pri)

CONFIG += mobility
MOBILITY = systeminfo

symbian:TARGET.CAPABILITY = ReadDeviceData

But still after adding mobility systeminfo when I use QSystemNetworkInfo in the header file it gives me the error: QNetworkSystemInfo no such file or directory.

Can anyone help?

My second question is that. Even if I make this working, this does not fulfills my problem. I need to find out a way to display all the available WLAN networks and their MAC addresses and RSS values, while this class will only give me the info about the WLAN network to which my device is connected to?

Hope to hear a good solution soon.

Regards, Ata

ChrisW67
1st December 2010, 23:33
But still after adding mobility systeminfo when I use QSystemNetworkInfo in the header file it gives me the error: QNetworkSystemInfo no such file or directory.

My guess: the include file is not on the standard path and needs to be added to INCLUDEPATH in the PRO file.

I am not sure there are many mobile devices with more than one wifi interface. This class tells you what your wifi interface is connected to (or if it is not connected). It does not, AFAICT, give you any information about what wireless access points are available (i.e. no scanning ability). The networks that the device knows about may be accessible through QNetworkConfigurationManager and QNetworkConfiguration.

Take a look at the Bearer Cloud (http://doc.qt.nokia.com/qtmobility-1.0-tp/bearercloud.html) example.

Ataul Ghalib
4th December 2010, 00:17
Hi, Chris!
Thanks, I am already using QNetworkConfigurationManager class and I have studied Bearere Cloud example in detail. But the problem is that it does not provide me any function to access the mac addresses and Received Signal Strength. It just tells about the status of the network, like, discovered, connected etc.
But what I need is to show MAC addresses and RSS from all the WiFi networks in range.
I have already seen an application like this running in N900 but that is written in Python, but I need to use Qt.

And about the QSystemNetworkInfo, I have even tried including the path in pro file, but didn't work out. Even I QNetworkConfigurationManager is working fine and both QtBearer and QtSystemInfo APIs are placed in the same folder so there is not question of wrong path. When QNetworkConfigurationManager is working then why not QSystemNetworkInfo?