1 /* |
|
2 * Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). |
|
3 * All rights reserved. |
|
4 * This component and the accompanying materials are made available |
|
5 * under the terms of "Eclipse Public License v1.0" |
|
6 * which accompanies this distribution, and is available |
|
7 * at the URL "http://www.eclipse.org/legal/epl-v10.html". |
|
8 * |
|
9 * Initial Contributors: |
|
10 * Nokia Corporation - initial contribution. |
|
11 * |
|
12 * Contributors: |
|
13 * |
|
14 * Description: |
|
15 * |
|
16 */ |
|
17 |
|
18 #ifndef WLANQTUTILSCOMMON_H |
|
19 #define WLANQTUTILSCOMMON_H |
|
20 |
|
21 #ifdef BUILD_WLANQTUTILITIES_DLL |
|
22 #define WLANQTUTILITIESDLL_EXPORT Q_DECL_EXPORT |
|
23 #else |
|
24 #define WLANQTUTILITIESDLL_EXPORT Q_DECL_IMPORT |
|
25 #endif |
|
26 |
|
27 // Maximum length of WLAN SSID (limit also for number of characters for user input) |
|
28 static const int KMaxSsidLen = 32; |
|
29 // Maximum length of WEP key |
|
30 static const int KMaxWEPKeyLen = 64; |
|
31 // Maximum length of WPA key |
|
32 static const int KMaxWPAKeyLen = 256; |
|
33 |
|
34 /** |
|
35 * Bearer type. |
|
36 */ |
|
37 enum WlanQtUtilsBearerType { |
|
38 WlanQtUtilsBearerTypeNone = 0, ///< None of the bearer types. |
|
39 WlanQtUtilsBearerTypeCellular , ///< Cellular (2G, 3G, 3.5G) bearer type. |
|
40 WlanQtUtilsBearerTypeWlan ///< WLAN bearer type. |
|
41 }; |
|
42 |
|
43 /** |
|
44 * Connection status. |
|
45 */ |
|
46 enum WlanQtUtilsConnectionStatus { |
|
47 WlanQtUtilsConnectionStatusNone = 0, ///< None of the connection statuses. |
|
48 WlanQtUtilsConnectionStatusConnecting, ///< Connecting. |
|
49 WlanQtUtilsConnectionStatusConnected, ///< Connected. |
|
50 WlanQtUtilsConnectionStatusDisconnected ///< Disconnected. |
|
51 }; |
|
52 |
|
53 /** |
|
54 * Signal strength category boundaries in dB (absolute value). |
|
55 * Smaller value means better signal. |
|
56 */ |
|
57 // TODO: WLAN signal level values valid are copied from 08wk41 Sniffer. OK? |
|
58 // (WINS emulator gives just 0 which is equal to "Absolute max"...) |
|
59 enum |
|
60 { |
|
61 WlanQtUtilsWlanSignalStrengthAbsoluteMax = 0, ///< Absolute maximum signal strength. |
|
62 WlanQtUtilsWlanSignalStrengthMax = 60, ///< Maximum signal strength. |
|
63 WlanQtUtilsWlanSignalStrengthGood = 74, ///< Good signal strength. |
|
64 WlanQtUtilsWlanSignalStrengthLow = 87, ///< signal strength. |
|
65 WlanQtUtilsWlanSignalStrengthMin = 100, ///< Minimum signal strength. |
|
66 WlanQtUtilsWlanSignalUnavailable = 9999, ///< Signal is unavailable. |
|
67 }; |
|
68 |
|
69 /** WLAN signal is unknown. */ |
|
70 const int WlanQtUtilsWlanSignalUnknown = 1000000; |
|
71 |
|
72 /** WLAN transmit power is unknown. */ |
|
73 const unsigned WlanQtUtilsWlanTransmitPowerUnknown = 0xFFFFFFFF; |
|
74 |
|
75 /** |
|
76 * WLAN security modes. |
|
77 * Mapping functions exist for reading and writing these values |
|
78 * from / to ConnMon and CMM. |
|
79 */ |
|
80 enum WlanQtUtilsWlanSecMode |
|
81 { |
|
82 WlanQtUtilsWlanSecModeNone = 100, ///< None of the security modes. |
|
83 WlanQtUtilsWlanSecModeOpen = 101, ///< Open security mode. |
|
84 WlanQtUtilsWlanSecModeWep = 102, ///< WEP security mode. |
|
85 WlanQtUtilsWlanSecMode802_1x = 103, ///< 802.1x security mode. |
|
86 WlanQtUtilsWlanSecModeWpa = 104, ///< WPA security mode. |
|
87 WlanQtUtilsWlanSecModeWpa2 = 105 ///< WPA@ security mode. |
|
88 }; |
|
89 |
|
90 /** |
|
91 * WLAN connection modes. |
|
92 */ |
|
93 enum WlanQtUtilsWlanConnMode |
|
94 { |
|
95 WlanQtUtilsWlanConnModeNone = 200, ///< None of the connection modes. |
|
96 WlanQtUtilsWlanConnModeInfraStructure = 201, ///< Infrastructure connection mode. |
|
97 WlanQtUtilsWlanConnModeAdHoc = 202, ///< Adhoc connection mode. |
|
98 WlanQtUtilsWlanConnModeSecureInfra = 203, ///< Secure infrastructure connection mode.´ |
|
99 }; |
|
100 |
|
101 #endif // WLANQTUTILSCOMMON_H |
|