Commit Graph

30 Commits

Author SHA1 Message Date
zrrong
d17c9509f6 wireless/wapi: fix wapi wpa_wconfig_s alg data type error
Signed-off-by: zrrong <zrrong@bouffalolab.com>
2022-04-14 18:24:33 +03:00
zhanghongyu
e0e41c5d7f feature: wapi add encode parse when scan
Signed-off-by: zhanghongyu <zhanghongyu@xiaomi.com>
2022-03-15 18:01:04 +08:00
Xiang Xiao
66dbaa4539 Replace self defined macros with NET_SOCK_[FAMILY|TYPE|PROTOCOL]
NET_SOCK_* is defined by nuttx/net/netconfig.h and then can be shared

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-12-20 16:04:29 -03:00
chenwen
39c5fa812d wireless/wapi: Fix issue of getting the operating frequency 2021-04-12 03:56:11 -05:00
chao.an
623a668baa wapi: Extend "WAPI_ESSID_DELAY_ON" flag to support customized connection behavior
The current essid setting(SIOCSIWESSID) are not satisfactory in case
of specified bssid connection, if there are multiple essids with same name,
we need additional bssid information to connect to the specified softap.
The extended flag "WAPI_ESSID_DELAY_ON" instructs the driver to delay the
connection behavior of essid, so that which can accept more accurate
information before generating a connection.

About flow of wapi command, drivers that support WAPI_ESSID_DELAY_ON semantics
will have the following behavior changes:

1. Station mode without bssid set:

$ ifup wlan0
$ wapi mode wlan0 2
$ wapi psk wlan0 12345678 3
$ wapi essid wlan0 archer 1
$ renew wlan0

2. Station mode with bssid set:

$ ifup wlan0
$ wapi mode wlan0 2
$ wapi psk wlan0 12345678 3
$ wapi essid wlan0 archer 2       <----- WAPI_ESSID_DELAY_ON will indicate the driver delay
$                                        the connection event late to bssid set (SIOCSIWAP).
$ wapi ap wlan0 ec:41:18:e0:76:7e
$ renew wlan0

Signed-off-by: chao.an <anchao@xiaomi.com>
2021-01-30 20:19:10 -08:00
chao.an
bd9174a3b6 wireless/wapi: add set country code support
Signed-off-by: chao.an <anchao@xiaomi.com>
2021-01-05 08:00:29 +01:00
chao.an
937b67bfa0 wapi/wireless: add get sensitivity support
Change-Id: I9906810466edaad59edf3d63b534959541609aab
Signed-off-by: chao.an <anchao@xiaomi.com>
2020-11-10 19:37:29 -08:00
chao.an
3959f7535e wireless/wapi: add channel frequency set during associate
Therefore, the associate can support the connection of specified
channel if the scan results contain the multiple AP with same essids.

Change-Id: I4e657c52e638693e7ae19aea2a4fe8a431885547
Signed-off-by: chao.an <anchao@xiaomi.com>
2020-11-10 19:36:17 -08:00
Xiang Xiao
8a63e58936 Change all 'Nuttx' to 'NuttX'
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-10-18 22:27:57 -07:00
chao.an
3061dbf2f8 wireless/wapi: add option to associate with bssid
Change-Id: I68ef42edfc50ef5baf0f02a570d0e7f79669659f
Signed-off-by: chao.an <anchao@xiaomi.com>
2020-09-19 04:20:43 -07:00
chao.an
a0f6b14c0d wireless/wapi: add scan partial channel support
Change-Id: I2279406a9ca0cc3a9535ce79fbf651dbaf14ad4c
Signed-off-by: chao.an <anchao@xiaomi.com>
2020-09-19 01:14:45 -07:00
chao.an
df1d0e73f8 wireless/wapi: add save_config/reconnect support
Signed-off-by: chao.an <anchao@xiaomi.com>
2020-04-03 13:29:19 +01:00
chao.an
6bafe90db4 wireless/wapi: independent scan and scan_results
add scan <ssid> support

Signed-off-by: chao.an <anchao@xiaomi.com>
2020-04-03 13:29:19 +01:00
chao.an
52ad01f0bf netutils: save wapi config to file system
save and reload the wapi config from file system
2020-02-26 16:11:46 +00:00
chao.an
ee615f0568 net/wapi: remove unnecessary cast 2020-02-26 16:11:39 +00:00
Xiang Xiao
41d88f06e7 Run codespell -w with the latest dictonary again 2020-02-23 07:10:14 -06:00
Xiang Xiao
d660492289 Run codespell -w against all files
and fix the wrong correction
2020-02-22 14:41:36 -06:00
chao.an
7612221df6 apps/wireless/wapi/scan: Add frequency/rssi printf
Scan print layout:

nsh> wapi scan wlan0
bssid / frequency / signal level / ssid
**:**:**:**:**:**       2437    -38     <ssid>
**:**:**:**:**:**       2427    -36     <ssid>
...
2020-01-22 07:53:02 -06:00
Xiang Xiao
6d22dd0013 Author: Gregory Nutt <gnutt@nuttx.org>
Run all .c and .h files in last PR through nxstyle and fix all complaints.

Author: Xiang Xiao <xiaoxiang@xiaomi.com>

    Wapi improvement (#16)

    * wireless: add passphrase control
    * wireless: add disconnect control
2020-01-16 12:21:45 -06:00
Gregory Nutt
64bc8f5b7f Run all .c and .h files modified in last PR through nxstyle. 2019-12-31 10:57:34 -06:00
Xiang Xiao
49c997501a Wapi simplify (#1)
apps/wireless/wapi:  Simplify usage of command line.  Remove duplicate extensions
2019-12-31 10:39:53 -06:00
Gregory Nutt
a0915850b9 wireless/wapi: wpa_driver_wext_associate() now accepts a configuration parameter that can be used to specify the wireless properties. nshlib: NSH now has configuration options to select the wireless properties. It builds the configuration structure and passes this to wpa_driver_wext_associate() so that it will setwork the network as configured. 2017-05-06 11:28:11 -06:00
Gregory Nutt
f12d857f0a Move wireless/wext into wireless/wapi/src. Update some naming for better follow the NuttX coding style. 2017-05-06 09:40:09 -06:00
Simon Piriou
33027bd66e wireless/wext: Add drivers_wext from the WPA supplicant; Integrate into NSH 2017-05-02 09:43:48 -06:00
Gregory Nutt
568e932e80 apps/wireless/wapi: Some changes from initial debug. 2017-04-11 12:42:15 -06:00
Gregory Nutt
1a470c6480 wireless/wapi: Re-write of wapi tool UI. 2017-04-11 10:22:47 -06:00
Gregory Nutt
322ffe193b wireless/wapi: Remove functionality that depends on the Linux procfs: This includes only 1) listing of available interfaces and 2) listing of all routes. 2017-04-10 16:02:17 -06:00
Gregory Nutt
aeb37c12b2 apps/wireless/wapi: Fix problems in build support. Fix some initial compile isses (still does not compile). 2017-04-10 14:57:33 -06:00
Gregory Nutt
806d2c731a wireless/wapi: Remove logic that depnds on Linux netlink. Add (untested) build support. 2017-04-10 14:00:21 -06:00
Gregory Nutt
eeb143415a wireless/wapi: Quick port of Wapi wireless services. No build support yet. This also depends on features not supported by NuttX. This is a work in progress. 2017-04-10 13:28:32 -06:00