summaryrefslogtreecommitdiff
authormickeyl <mickeyl>2004-02-23 15:59:05 (UTC)
committer mickeyl <mickeyl>2004-02-23 15:59:05 (UTC)
commit20b0e62e6c23cdaed9a30d6fad73431edc60be53 (patch) (unidiff)
treea179f858449e56b04883267c61141f163b4dfbac
parent68c8d3eb878f9ba913c42368fbb253d7320c62be (diff)
downloadopie-20b0e62e6c23cdaed9a30d6fad73431edc60be53.zip
opie-20b0e62e6c23cdaed9a30d6fad73431edc60be53.tar.gz
opie-20b0e62e6c23cdaed9a30d6fad73431edc60be53.tar.bz2
addition to API: OWirelessNetworkInterface::signalStrength() [wip]
Diffstat (more/less context) (show whitespace changes)
-rw-r--r--libopie2/opienet/onetwork.cpp8
-rw-r--r--libopie2/opienet/onetwork.h18
2 files changed, 20 insertions, 6 deletions
diff --git a/libopie2/opienet/onetwork.cpp b/libopie2/opienet/onetwork.cpp
index d918193..16fa8ae 100644
--- a/libopie2/opienet/onetwork.cpp
+++ b/libopie2/opienet/onetwork.cpp
@@ -964,6 +964,14 @@ OStationList* OWirelessNetworkInterface::scanNetwork()
964} 964}
965 965
966 966
967int OWirelessNetworkInterface::signalStrength() const
968{
969 int max = _range.max_qual.level;
970 odebug << "signalStrength(): max quality seems to be " << max << "dBM" << oendl;
971 return 50;
972}
973
974
967bool OWirelessNetworkInterface::wioctl( int call, struct iwreq& iwreq ) const 975bool OWirelessNetworkInterface::wioctl( int call, struct iwreq& iwreq ) const
968{ 976{
969 #ifndef NODEBUG 977 #ifndef NODEBUG
diff --git a/libopie2/opienet/onetwork.h b/libopie2/opienet/onetwork.h
index bc9e299..9b8a0d4 100644
--- a/libopie2/opienet/onetwork.h
+++ b/libopie2/opienet/onetwork.h
@@ -1,7 +1,7 @@
1/* 1/*
2                 This file is part of the Opie Project 2                 This file is part of the Opie Project
3              Copyright (C) 2003 by Michael 'Mickey' Lauer <mickey@Vanille.de> 3              Copyright (C) 2003-2004 by Michael 'Mickey' Lauer
4 =. 4 =. <mickey@Vanille.de>
5 .=l. 5 .=l.
6           .>+-= 6           .>+-=
7 _;:,     .>    :=|. This program is free software; you can 7 _;:,     .>    :=|. This program is free software; you can
@@ -60,7 +60,7 @@ class OMonitoringInterface;
60 * 60 *
61 * This class provides access to all available network interfaces of your computer. 61 * This class provides access to all available network interfaces of your computer.
62 * 62 *
63 * @author Michael 'Mickey' Lauer <mickey@tm.informatik.uni-frankfurt.de> 63 * @author Michael 'Mickey' Lauer <mickey@vanille.de>
64 */ 64 */
65class ONetwork : public QObject 65class ONetwork : public QObject
66{ 66{
@@ -124,7 +124,7 @@ class ONetwork : public QObject
124 * @warning Most of the setting methods contained in this class require the appropriate 124 * @warning Most of the setting methods contained in this class require the appropriate
125 * process permissions to work. 125 * process permissions to work.
126 * 126 *
127 * @author Michael 'Mickey' Lauer <mickey@tm.informatik.uni-frankfurt.de> 127 * @author Michael 'Mickey' Lauer <mickey@vanille.de>
128 */ 128 */
129class ONetworkInterface : public QObject 129class ONetworkInterface : public QObject
130{ 130{
@@ -234,7 +234,7 @@ class ONetworkInterface : public QObject
234 * This is necessary when in monitoring mode and scanning for other devices, because 234 * This is necessary when in monitoring mode and scanning for other devices, because
235 * the radio frequency hardware can only detect packets sent on the same frequency. 235 * the radio frequency hardware can only detect packets sent on the same frequency.
236 * 236 *
237 * @author Michael 'Mickey' Lauer <mickey@tm.informatik.uni-frankfurt.de> 237 * @author Michael 'Mickey' Lauer <mickey@vanille.de>
238 */ 238 */
239class OChannelHopper : public QObject 239class OChannelHopper : public QObject
240{ 240{
@@ -294,7 +294,7 @@ class OChannelHopper : public QObject
294 * 294 *
295 * This class provides a high-level encapsulation of the Linux wireless extension API. 295 * This class provides a high-level encapsulation of the Linux wireless extension API.
296 * 296 *
297 * @author Michael 'Mickey' Lauer <mickey@tm.informatik.uni-frankfurt.de> 297 * @author Michael 'Mickey' Lauer <mickey@vanille.de>
298 */ 298 */
299class OWirelessNetworkInterface : public ONetworkInterface 299class OWirelessNetworkInterface : public ONetworkInterface
300{ 300{
@@ -414,6 +414,12 @@ class OWirelessNetworkInterface : public ONetworkInterface
414 * @note: UNSTABLE API - UNDER CONSTRUCTION - DON'T USE! 414 * @note: UNSTABLE API - UNDER CONSTRUCTION - DON'T USE!
415 */ 415 */
416 virtual OStationList* scanNetwork(); 416 virtual OStationList* scanNetwork();
417 /**
418 * @return signal strength to associated neighbour (in percent).
419 * In infrastructure mode, this is the signal strength of the Access Point.
420 * In other modes the result is driver dependent.
421 */
422 virtual int signalStrength() const;
417 /** @internal commit pending changes to the driver 423 /** @internal commit pending changes to the driver
418 * 424 *
419 */ 425 */