Page 1
RS9116 n-Link Linux and Android Technical Reference Manual Version 2.0 July 2020 Redpine Signals, Inc. 2107 North First Street, Suite #540, San Jose, California 95131, United States of America. Phone: +1-408-748-3385, Fax: +1-408-705-2019 Email: sales@redpinesignals.com Website: www.redpinesignals.com --------------------------------------------------------------------------------------------------------------------------------------------------------...
RS9116 n-Link Linux and Android Technical Reference Manual Version 2.0 July 2020 Table of Contents Introduction to RS9116......................7 Getting Started with RS9116 ..................... 8 2.1 Hardware Requirements ......................8 2.2 Software Requirements......................8 2.3 Software Package Contents ...................... 8 Compiling the Driver ........................
Page 4
RS9116 n-Link Linux and Android Technical Reference Manual Version 2.0 July 2020 20.1 Configuration ......................... 110 21 Steps to connect 802.11R client to AP .................. 111 22 Steps to configure 802.11W ....................112 22.1 Configuring and Compiling Driver for PMF in client mode: ..........112 22.2 Configuring and Compiling Driver for PMF in AP mode: ............
Page 5
RS9116 n-Link Linux and Android Technical Reference Manual Version 2.0 July 2020 31.1 Bgscan and Roaming ......................140 32 Appendix G: Considerations need to be made during hostapd usage........ 142 32.1 Parameters updated from hostapd.conf file................ 142 33 Appendix H: Antennae ......................143 33.1 Taoglas Antenna ........................
Page 6
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 About this Document This document is a preliminary version of RS9116 n-Link Technical Reference Manual for Linux and Android, provided to customers...
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 1 Introduction to RS9116 The OneBox-Mobile(refers to single software providing combo of all the features supported) software supports the following modes. They are outlined below: • Wi-Fi (Access Point, Client, Wi-Fi-Direct (P2P), Sniffer and Monitor modes) •...
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 2 Getting Started with RS9116 This section lists the hardware and software requirements for the installation of the software and also describes the steps to be followed to initialize and run the software.
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 3 Compiling the Driver This section describes the steps to be followed in order to compile the OneBox-Mobile Linux software for different platforms. The steps are outlined below: 1.
Page 10
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 Figure 2: Selecting Operating System By default, the driver package includes "BSD" support. In case the user needs "Nl80211" support for Access point and Station modes, select the menuconfig accordingly. For Nl80211, the "Hostapd" application is used as a configuration utility.
Page 11
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 If NL80211 support is enabled in the driver, make sure that the following modules are loaded in the kernel before running the driver in order to avoid module dependencies. This can be verified by using the commands.
Page 12
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 Figure 5: Save the changes before exiting 4. Now to compile the driver, enter the following command: make The code is compiled and the binaries are generated in the source/host/release folder. For embedded platforms, modify the path assigned to the "DEF_KERNEL_DIR"...
Page 13
July 2020 Before installing the Onebox RS9116 Driver modules, make sure that the RSI opensource modules are uninstalled. This has been taken care in the onebox_insert.sh script. In order to un-install the RSI opensource driver, use the following commands:...
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 4 Installing the Driver 4.1 Installation of Modules After completion of compilation, the driver generates the following modules in the release folder. They are outlined below: • onebox_common_gpl.ko •...
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 4.2 Enabling a Protocol Execute following command to enable required protocol(s): # ./onebox_util rpine0 enable_protocol $protocol_value Below are the possible values of protocol. • 1 – Enables Wi-Fi only •...
Page 16
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 2. Ensure DRIVER_MODE and COEX_MODE are set as below: • DRIVER_MODE = 1 • COEX_MODE = 1 (For Station Mode only/WIFI-Direct) • COEX_MODE = 2 (For Access Point Mode) •...
Page 17
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 network={ ssid="<SSID of Access Point>" key_mgmt=NONE wep_key0=XXXXXXXXXX wep_tx_keyidx=X The key can be input either in ASCII or Hexadecimal formats: ASCII Format: wep_key0="12345" Hexadecimal Format: wep_key0=1234567890 The key index can vary between 0 and 3.
Page 18
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 network={ ssid="<SSID of Access Point>" scan_ssid=1 key_mgmt=NONE Next, run the "start_sta.sh" script in the "release" folder to load the driver modules and the supplicant and also connect to the Access Point specified in the "sta_settings.conf" file.
Page 19
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 $ dhclient wifi0 $ dhclient wifi0 The sample output of dhclient command is given below Listening on LPF/wifi0/88:da:1a:1e:b2:58 Sending on LPF/wifi0/88:da:1a:1e:b2:58 Sending on Socket/fallback DHCPDISCOVER on wifi0 to 255.255.255.255 port 67 interval 4 (xid=0x133cec16) DHCPREQUEST on wifi0 to 255.255.255.255 port 67 (xid=0x133cec16)
Page 20
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 • Channel 1 of 2.4GHz Band (2412 MHz) • Security Mode: WPA-PSK (TKIP) • Passphrase: "12345678" For Access Point in WPA2-PSK (CCMP) Mode, wpa_supplicant_ccmp.conf configuration file is used, and this starts an Access Point with the following parameters: •...
Page 21
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 ifconfig <interface> <IP> Example : ifconfig wifi1 192.168.2.1 4.4.3 Installation in Wi-Fi Client Mode (with NL80211 support) The steps for installing Wi-Fi Only mode in Client are as follows: 1.
Page 22
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 In case of multiple phy's to identify the appropriate phy on which to run the command, enter the following command. iw dev The sample output of this command is...
Page 23
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 4.4.4 Installation in Wi-Fi AP mode (with NL80211 support) The steps for installing Wi-Fi Only mode in AP are as follows: 1. Open the common_insert.sh file present in the "release" folder.
Page 24
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 Configure the SSID Settings of the AP in the hostapd_open.conf file (say if you are starting AP in open mode). In order to start AP in a particular band and channels, configure variables hw_mode, channel and country in hostapd_open.conf (present in release folder) file as follows :...
Page 25
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 # ./wpa_cli –i wifi0 p2p_group_add freq=<channel_freq> The "channel_freq" input mentioned in the above command is the center frequency of the Wi-Fi channel in which the GO needs to be started The OneBox-Mobile software supports DFS slave mode. However, DFS Channels need to be avoided till the module is certified for DFS..
Page 26
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 wpa_supplicant version used should be latest one (2.6 or higher). Please check the start_p2pgo.sh script for better understanding and update it accordingly. The given below command is used to start the device in Autonomous GO mode: # ./wpa_cli –i wifi0 p2p_group_add freq=<channel_freq>...
Page 27
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 Note: wpa_supplicant version used should be latest one (2.6 or higher) and need to compile with CONFIG_P2P and CONFIG_WPS flag enble. Use below command to start the device in Autonomous GO mode: #./wpa_cli -i wifi0 p2p_group_add freq=<channel_freq>...
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 Note: wpa_supplicant version used should be latest one (2.6 or higher) and need to compile with CONFIG_P2P and CONFIG_WPS flag enable. After starting the supplicant, the p2p_commands mentioned below should be executed.
Page 29
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 Note: For SDIO mode, ensure that the SDIO stack related modules are already inserted in the kernel refer Appendix A: Configuration of Kernels from 3.13 and above section to install sdio stack modules .
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 # hcitool –i <hciX> lecc <remote_MAC_Addr> The "remote_MAC_Addr" parameter mentioned above is the MAC address of the remote device, e.g., 00:23:AC: 01:02:03. • Slave Mode Connected State Ensure that our device is in Advertise mode and then issue the command given below: # hcitool –i <hciX>...
It may be used in lieu of the Wi-Fi supplicant provided as a part of the OneBox-Mobile software. However, care has to be taken to follow the correct sequence of commands while using "iwconfig". The Redpine Signals recommends usage of the supplicant provided in the software package.
Page 32
Note: For Access Point mode, this command has to be issued after the Set Mode command only if the VAP has started using “iwconfig” commands and not using the supplicant provided by Redpine Signals. For Client mode, the Set Mode command is not mandatory...
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 Default Value 2346 Input Parameters VAP Name (string like wifi0, wifi1, etc.) Integer between 256 and 2346 Output Parameter None Reset Required Usage # iwconfig <vap_name> rts <payload_size>...
Page 34
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 Set Short GI Description This command is used to set the Short GI mode of the n-Link® Module. Default Value 0 (Short GI disabled for both 20 MHz and 40 Mhz Bandwidth) Input Parameters VAP Name (string like wifi0, wifi1, etc.)
Page 35
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 Output Parameter The integer value mapping has been shown below: 0 – Disable Short GI 32 – Enable Short GI for 20MHz Bandwidth 64 – Enable Short GI for 40MHz Bandwidth 96 –...
Page 36
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 Output Parameter None Reset Required Usage # iwpriv <vap_name> wmm <value> Example The command below sets the WMM mode for the module: # iwpriv wifi0 wmm 1 Note: ...
Page 37
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 Input Parameters VAP Name (string like wifi0, wifi1, etc.) The integer value mapping has been shown below: 1- Enable only 20MHz 2- Enable only 40MHz 3 – Enable both 20 and 40MHz...
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 Input Parameters Zone value. The integer value mapping has been shown below: 0 – Disable zone. 0x4000 – Error Zone. Output Parameter None Reset Required Usage # iwpriv <vap name> set_dbg_zone <zone_value>...
Page 39
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 Example The commands given below is used to reset the VAP and set the DTIM period: #sh remove_all.sh #sh wlan_enable.sh (or) wlan_bt_insert.sh (or) wlan_zigb_insert.sh (or) onebox_insert.sh script present in the "release" folder as per the instructions in Section 4.1...
Page 40
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 Output Parameter Integer value Reset Required Usage # iwpriv <vap_name> get_bintval Example The command given below is used to get the Beacon interval programmed in the module:...
Page 41
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 Input Parameters VAP Name (string like wifi0, wifi1, etc.) 48-bit MAC Address in hexadecimal format with colon separation. e.g., 00:23:A7:01:02:03 Output Parameter None Reset Required Usage # iwpriv <vap_name> addmac <mac_addr>...
Page 42
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 Output Parameter None Reset Required Yes. In order to move from/to Hidden SSID mode, the virtual interface has to be reset. Usage # iwpriv <vap_name> hide_ssid <value>...
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 Input Parameters value*2 Output Parameter None Reset Required Usage # iwpriv <vap name> mgmt_rate <value*2> Example The Following command sets the mgmt rate to 5.5Mbps #iwpriv wifi0 mgmt_rate 11...
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 Default Value NULL Data Input Parameters VAP Name (string like wifi0, wifi1, etc.) Integer value - 0 or 1 0 – Inform Access Point that the module is going to be in power save mode.
Page 45
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 Create a VAP The OneBox- Mobile software allows creation of 4 VAPs Description This command is used to create a virtual interface (VAP) in the operating mode specified.
Page 46
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 Input Parameters Base Interface (string like rpine0) VAP Name (string like wifi0, wifi1, etc.) Output Parameter None Reset Required Usage # ./onebox_util <base_interface> delete_vap <vap_name> Example The command given below deletes a virtual interface named wifi0.
Page 47
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 Default Value Input Parameters VAP Name (string like wifi0, wifi1, etc.) 48-bit MAC Address in hexadecimal format with colon separation. e.g., 00:23:A7:01:02:03 [-v] – Get description of the fields in the statistics...
Page 48
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 Input Parameters Base Interface (string like rpine0) The integer value mapping has been shown below: 2 – Select RF_OUT_2/Integrated Antenna 3 – Select RF_OUT_1/U.FL Connector Output Parameter...
Page 49
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 Usage # ./onebox_util <base_interface> set_bgscan_params <bgscan_threshold> <rssi_tolerance_threshold> <periodicity> <active_scan_duration> <passive_scan_duration> <two_probe_enable> <num_of_bgscan_channels> <channels_to_scan> Example The command given below enables Background Scan with a scan threshold of 10, RSSI tolerance threshold of 10, periodicity...
Page 50
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 Set SSID for Background Scan (only in Client mode) Description This command is used to set the SSID of the Hidden Access Point (SSID not being broadcast) during Background Scan.
Page 51
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 Input Parameters Base Interface (string like rpine0) Power Save Enable/Disable Sleep Type Transmit Threshold Receive Threshold Transmit Hysteresis Receive Hysteresis Monitor Interval Sleep Duration Listen Interval Duration...
Page 52
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 Input Parameters Base Interface (string like rpine0) UAPSD Wakeup Period in milliseconds – 0 for Transmit Based UAPSD and between 10 and 100 for Periodic UAPSD. UAPSD Service Period Length- This field indicates number of packets delivered by AP to station after receiving one trigger frame.
Page 53
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 Example /onebox_util rpine0 reset_adapter Set Beacon Interval (only in Access Point mode) Description This command is used to set the Beacon Interval in milliseconds. It is recommended that this command is given before the VAP is created.
Page 54
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 Set WMM Parameters (only in Access Point mode) Description This command is used to set the WMM parameters for specific queues. Note: This ioctl is redundant, refer to the Section 16 for further details.
Page 55
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 Input Parameters VAP Name (string like wifi0, wifi1, etc.) WMM Parameter Name (string like aifs, cwmin, cwmax, txop, acm) Integer value. The allowed values are as follows: AIFSN –...
Page 56
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 Input Parameters Integer (country code) mapped as below: REGION COUNTRY_CODE COUNTRY_NAME UNITED STATES CANADA MEXICO ETSI FRANCE BELGIUM GERMANY ITALY JAPAN JAPAN WORLD AUSTRALIA INDIA IRAN MALAYSIA...
Page 57
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 Example The commands below reset the VAP and set the country to Singapore in Station mode. # sh remove_all.sh # sh wlan_enable.sh or wlan_bt_insert.sh or wlan_zigb_insert.sh or onebox_insert.sh script present in the “release”...
Page 58
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 Example The commands below set the Antenna gain values for 2.4 GHz to 3 dBm RESERVED field should be programmed as 1 # sh remove_all.sh # sh wlan_enable.sh or wlan_bt_insert.sh or onebox_insert.sh script present in the “release”...
Page 59
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 Reset Required Usage ./onebox_util rpine0 ant_type ant_path ant_type Example # ./onebox_util rpine0 ant_type 1 2 Set Wake-On-Wireless LAN Parameters (only in Client Mode) Description This command is used to set the Wake-On-Wireless LAN (WoWLAN) parameters in the device.
Page 60
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 Output Parameters None Reset Required Usage # ./onebox_util <base_interface> set_rf_tx_rx_pwr_mode tx_value rx_value Example ./onebox_util rpine0 set_rf_tx_rx_pwr_mode 0 1 Set scan type Description This command is used to select the band in which the user wants to perform the scan.
Page 61
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 Get Tx-Power Description This command is used to get current value of transmit power from firmware and updates it in iwconfig command. Default Value Input Parameters Output Parameter...
Page 62
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 ctrl_interface=/var/run/wpa_supplicant update_config=1 uuid=12345678-9abc-def0-1234-56789abcdef0 device_name=RSI_P2P_DEVICE manufacturer=Redpine Signals, Inc. model_name=M2MCombo model_number=9113 serial_number=03 device_type=1-0050F204-1 os_version=01020300 config_methods=display push_button keypad The sections below list down the steps for configuring WPS and setting up a connection in Access Point and Client modes using the methods listed above.
Page 63
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 #. /wpa_cli –i <vap_name> wps_pin <sta_mac_addr> This will generate a 4/8-digit numeric WPS PIN. 7. Enter the PIN on the STA. 8. Wait for the STA to parse all the WPS Access Points.
Page 64
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 #. /wpa_cli –i <vap_name> wps_pin <bssid> • This will generate an 8-digit numeric WPS PIN. • Enter the PIN on the Access Point • Wait for the STA to parse all the WPS Access Points.
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 6 Configuration Using CFG80211 This section explains about the usage of various IOCTL commands, which can be issued to the Onebox-Mobile™ driver operating in CFG80211 mode from the user space.
Page 66
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 Usage The following command initiates a scan and displays the list of AP's scanned. $ iw dev $interface_name scan Example $ iw dev wifi0 scan Connect Description This command is used to connect devices to the Access points in open or WEP security mode.
Page 67
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 Link Status Description This command is used to get the connection status of our device. Default Value Input Parameters Interface name. Output Connection status. Parameter Reset Required...
Page 68
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 Set Power save mode Description This command is used to set power save mode on/off in station mode. Default Value Input Parameters Interface name. Output Parameter Reset Required Usage iw dev $interface_name set power_save <on | off>...
Page 69
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 Note: If there are multiple phys, i.e there are several instances of cfg80211 being used by different modules, then to determine the correct phy, run the following commands: $ ...
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 7 Enterprise security using CFG80211 7.1 Installation and configuration of FREERADIUS Server The following packages are required to install the freeradius server 3.09: • libtalloc-devel • openssl-devel The steps for downloading as well as installing the freeradius tar ball are as follows: $ tar zxvf freeradius-server-3.0.9.tar.gz...
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 tls-config tls-common #private_key_password = whatever private_key_password = Wi-Fi #private_key_file = ${certdir}/server.pem private_key_file = /etc/certs/wifiuser.pem #certificate_file = ${certdir}/server.pem certificate_file = /etc/certs/wifiuser.pem ...
Page 72
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 • openssl-devel 7.2.1 Configuration of the AP Go to driver source folder and compile it with the following options enabled: [*] NL80211 support [*] HOSTAPD support...
Page 73
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 $. /hostapd hostapd_eap.conf -ddddt >log & $ sh dhcp_server.sh wifi1 , where wifi1 is the interface name 7.2.2 Configuring hostapd as RADIUS server The steps for configuring hostapd as RADIUS server are as follows: Copy the certs folder in /etc location, which will contain the certificates, hostapd.radius_clients, hostapd.eap_user...
Page 74
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 CONFIG_DRIVER_NL80211=y CONFIG_IEEE8021X_EAPOL=y CONFIG_EAP_MSCHAPV2=y CONFIG_EAP_TLS=y CONFIG_EAP_PEAP=y CONFIG_EAP_TTLS=y CONFIG_EAP_FAST=y CONFIG_EAP_LEAP=y CONFIG_PKCS12=y CONFIG_TLS=internal Ensure that in menuconfig, NL80211 support is enabled. Compile the driver. $ make Go to the release folder and start the device in station mode.
Page 75
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 To connect using EAP-TTLS method, sta_settings.conf should be described as below: network={ ssid="Redpine_Signals" key_mgmt=WPA-EAP eap=TTLS anonymous_identity="ttlsuser" identity="test" password="password" To connect using EAP-TLS method, sta_settings.conf should be described as below: network={ ssid="Redpine_Signals"...
Page 76
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 network={ ssid="Redpine_Signals" key_mgmt=WPA-EAP eap=LEAP identity="user1" password="test123" To connect using EAP-LEAP for CCX, sta_settings.conf should be described as below: network={ ssid="Redpine_Signals" key_mgmt=WPA-CCKM eap=LEAP identity="user1" password="test123" pairwise=TKIP group=TKIP proto= WPA2 WPA...
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 8 HOSTAPD and Wi-Fi Protected Setup (WPS) This section describes how the WPS implementation in hostapd can be configured and how an external component on an AP is used to enable enrollment of client devices.
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 Check if the hostapd.wpa_psk file present in /etc/, if not, then create a new empty file naming hostapd.wpa_psk in location (/etc/ ). # Enable control interface for PBC/PIN entry ...
Page 79
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 $ iw phy ; it will give phyXX number $ iw phy phyXX interface add wifi1 type __ap $ /hostapd hostapd_wps.conf -ddddddt>log & $ sh dhcp_server.sh wifi1 ...
Page 80
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 $ hostapd_cli wps_ap_pin disable The command disables AP PIN (i.e., it does not allow external Registrars to use it inorder to learn the current AP settings or to reconfigure the AP).
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 9 ACS with Hostapd Following steps should be followed for Auto Channel Selection using Hostapd: 1. Compilation Steps: a. Enable CONFIG_ACS in Driver Makefile b. Enable Hostapd and NL80211 in ‘make menuconfig’...
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 10 Antenna Diversity 10.1 Introduction Antenna diversity is a feature which enables the automatic selection of the antennas which is needed to be use. The antenna on which the packets with better RSSI values are received is selected. The RSSI monitoring happens continuously.
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 11 Sniffer Mode The Steps for operating the device in Sniffer Mode are outlined below. Ensure that the common_insert.sh present in the release folder has valid driver mode and coexistence mode.
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 12 Monitor Mode The Monitor Mode is one of the operating modes that can be set while creating a VAP. It enables capturing of packets which is transferred over a single or multiple VAPs and are operating in either Access Point or Client or P2P modes.
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 13 Concurrent Mode Concurrent mode is the mechanism in which Onebox-Mobile can be operated in AP and Client modes simultaneously.User can create a virtual interface as client mode on one interface and as AP mode on other interface.
Page 86
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 13.1.2 Creating VAP in AP mode Create VAP in AP mode using command: $. /onebox_util rpine0 create_vap <vap_name> Ex:./onebox_util rpine0 create_vap wifi1 ap After issuing the above command virtual interface with name “wifi1” will be created. User can view the list of interfaces using the following command.
Page 87
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 In the case The following command scans all the 2G channels, 1-14 with periodicity of 5 seconds and active scan duration of 30ms. 1. ./onebox_util rpine0 host_scan_2g 5 30 The following command stops the host based scan.
Page 88
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 disconnects from the AP, by default it will move to the INIT state. The user is expected to give the host_scan command to initiate scanning. 2. SCAN: In This state the device performs scan and sends the scan results to the supplicant. In the STA alone mode, the scan request from the supplicant is sufficient for the STA to move to this state.
Page 89
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 • AP will always operate in channel in which the client [corresponding to other VAP] connects. For eg: In case if client connects in ch6 then AP mode will get created in ch6 irrespective of the channel configured.Similarly if AP mode is started first in the user configured channel and client mode is started later, then AP switches to the channel in which client is finally connected.
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 14 Background Scan Parameters This section describes the various parameters for the Background scan commands that can be sent to the n-Link Client using the onebox_util program.
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 15 Power save Modes, Profiles and Parameters The Power save modes and parameters are valid only for the Client mode. By default, the module's power save is disabled.
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 • Max PSP: In this mode, the module wakes up at the end of sleep period (Listen or DTIM interval) and retrieves pending Rx packets from the Access Point by sending a PS-POLL packet. It also transmits any packets received from the Host processor and then goes back to sleep.
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 values. The value is in Mbps and minimum value is 0 Mbps. This parameter should be assigned a value which is less than the value assigned to the <rx_threshold> parameter.
Page 94
It means Redpine module is detected as 2-1 device. Please make a note of this. Read the manufacturer of 2-1 device using following command. #cat /sys/bus/usb/devices/2-1/manufacturer The output of this command should be Redpine Signals, Inc. Issue the following command to enable device power saves for RSI module in USB mode. # echo >...
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 16 Compliance and Certification M7DB module is FCC/IC/CE certified. This section outlines the regulatory information for the M7DB module. This allows integrating the module in an end product without the need to obtain subsequent and separate approvals from these regulatory agencies.
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 Cet équipement est conforme aux limites d’exposition aux rayonnements IC établies pour un environnement non contrôlé. Cet équipement doit être installé et utilisé avec un minimum de 20 cm de distance entre la source de rayonnement et votre corps.
Page 97
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 Provision for Chip Antenna or other Antennae Label and compliance information Already in the manual Information on test modes and additional testing requirements a) The modular transmitter has been fully tested by the module grantee on the required number of channels, modulation types, and modes, it should not be necessary for the host installer to re-test all the available transmitter modes or settings.
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 17 Wi-Fi Performance Test ioctl usage The One Box-Mobile software provides applications to test Transmit and receive performances of the module. The Band of operation of the module needs to be configured before performing any tests.
Page 99
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 Band (GHz) Bandwidth (MHz) Channel Number Center Frequency (MHz) 2412 2417 2422 2427 2432 2437 2442 2447 2452 2457 2462 2467 2472 2422 2427 2432 2437 2442...
Page 100
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 Description Short GI 0 – Disable Short GI 1 – Enable Short GI Greenfield transmission 0 – Disable Greenfield transmission 1 – Enable Greenfield transmission [4:2] Operating bandwidth of the channel (3 bits) ]]></ac:plain-text-body></ac:structured-macro>...
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 #. /transmit rpine0 2 5.5 750 1 11 0 1 0 0 0 0 The above command starts continuous transmission with the following configuration: Transmit gain – 2dbm Data rate –...
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 Value Channel Width 20Mhz mode for 11J channel Table 10: Channel Width Values Examples: ./receive rpine0 stats 6 0 0 The above command starts the receive utility and logs statistics with the following parameters.
Page 103
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 #. /transmit rpine0 2 5.5 750 1 11 0 1 0 0 0 0 #. /transmit rpine0 #. /onebox_util rpine0 cw_mode 6 0 2 The above command starts continuous wave transmission with the following configuration.
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 18 Wake-On-Wireless LAN 18.1 WoWLAN through onebox_util The parameters listed below for the Wake-On-Wireless LAN are valid only in Client mode. The <hw_bmiss> parameter needs to be given as an input during VAP creation inorder to use the WoWLAN feature – refer to the section 5.5 Configuring Using onebox_util for details on VAP creation.
Page 105
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 18.2.2 Configure WoWLAN To configure WoWLAN, standard network tool ‘iw’ can be used. Issue below command in the terminal to configure WoWLAN. # iw phy <phyX> wowlan enable <trigger_type>...
Page 106
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 #systemctl suspend This step will suspend the system and system goes to power save mode. 18.2.5 Trigger wakeup To initiate trigger packet, connect a PC or laptop to AP through LAN/WLAN. Get IP and check ping to AP is working or not.
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 19 PUF [ Physical Unclonable Functions ] 19.1 Introduction PUF, is a technology which provides a secure method for storing a key, withstanding today’s attack and even protecting against future potential attack.
Page 108
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 ./onebox_util rpine0 puf_req puf_keycode_0.txt 19.3.6 PUF Load Key This operation is used for loading key to AES engine or key holder for the given key code input.
Page 109
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 ./onebox_util rpine0 puf_req 19.3.12 PUF Block Get Key This operation is used for blocking further Get Key operations. ./onebox_util rpine0 puf_req Refer the page Features for all IOCTL commands in detail...
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 20 GTK Offload GTK Offload is a firmware feature that updates the Group Temporal Key (GTK) by processing EAPOL message within firmware instead of sending EAPOL messages to host driver.
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 21 Steps to connect 802.11R client to AP 1. Use the following configuration in sta_settings.conf file to connect to 802.11R AP. network={ ssid="<SSID of Access Point>" key_mgmt=FT-PSK psk=<passphrase specified in the Access Point>...
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 22 Steps to configure 802.11W 22.1 Configuring and Compiling Driver for PMF in client mode: 1. Enable CONFIG_11W in Driver Makefile 2. Enable CONFIG_IEEE80211W=y in wpa_supplicant .config ...
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 23 Update WLAN region based maximum powers from driver Following are the steps need to be followed to program region based maximum powers to the WLAN device.
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 24 Bluetooth hcitool and hciconfig Usage The hcitool and hciconfig commands are used to control and configure parameters for the Bluetooth interface. The HCI commands explained here are the most frequently used commands. For other HCI commands please refer to the Bluetooth specification, Volume 2 Part E, Chapter7 from www.bluetooth.org.
Page 115
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 Reset Required Usage hcitool -i <hciX> cmd 0x04 0x02 Get Local BD Address Description This command is used to get the local BD Address Default Value Input Parameters...
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 24.1 Bluetooth Power Save Commands The vendor-specific HCI Commands are used to configure the device in the power save mode. The module supports Low Power (LP) and Ultra-Low Power (ULP) modes. These are explained in more detail in the Power Save Modes section of WLAN ioctl Usage Guide.
Page 117
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 • packet length • ble rate • Receive channel index • Transmit_channel index • Scrambler seed • no.of packets • payload type • le channel type • tx power •...
Page 118
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 inter_pkt_gap : Number of slots to be skipped between two packets - Each slot will be 1250usec pll_mode : PLL_MODE0 – 0 PLL_MODE1 – 1 PLL_MODE2 – 2 rf_type : External RF ...
Page 119
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 Band(GHz) Bandwidth (MHz) Channel Centre Freq (MHz) 2460 2462 2464 2466 2468 2470 2472 2474 2476 2478 2480 Examples: <Access_Addr> <pkt_length> <ble_rate> <rx_channel_index> <tx_channel_index> <scrambler_seed>...
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 ./ble_transmit 71764129 250 1 38 38 0 0 0 1 10 0 0 3 0 0 1 3 For transmitting a BLE-1Mbps Advertising packet with Access Address of 0x71764129 and packet length of 250bytes...
Page 121
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 24.4.2 IOCTL The following command can be given to start the reception ./ble_receive <access_addr> <data_legth_indication> <scrambler_seed> <ble_rate> <rx_channel_index> <tx_channel_index> <le_channel_type> <hopping_type> <ant_sel> <loop_back_mode> <pwrsave_options> <pll_mode> <rf_type> <rf_chain>...
Page 123
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 channel_bit_map –70000000000000000000 (here only upper 4 bits of bit map are set. So, transmission happens in 76,77 & 78 channels randomly)
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 25 Android support for RS9116 Redpine Signlas also supports Android Operating System. Currently supported variants in Android • MarshMallow (6.0.1) • Nougat (7.1) Please contact sales@redpinesignals.com for further details.
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 26 Appendix A: Configuration of Kernels from 3.13 and above To ensure that the OneBox-Mobile software works on kernel versions from 3.13 and above, some configuration changes might be needed. These are explained in this section. Super user permissions are needed to make these changes.
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 5. In the new menu, press 'M' to modularize the following options: • MMC block device driver • Secure Digital Host Controller Interface support • SDHCI support on PCI bus 6.
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 CONFIG_WIRELESS_EXT CONFIG_WEXT_PRIV CONFIG_WEXT_SPY 26.3 Bluetooth Stack Options If Bluetooth is required, it has to be ensured that the Bluetooth modules are compiled in the kernel. If the Bluetooth modules are not present, follow the steps below to enable Bluetooth support in the kernel.
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 5. In the new menu, press 'M' to modularize the following options: • RFCOMM Protocol support (enable the "RFCOMM TTY support" feature under this). • BNEP Protocol support (enable the "Multicast filter support" and "Broadcast filter support" features under this).
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 27.2.4 Cross Compile and Copy OneBox-Mobile Software If the OneBox-Mobile software's source is available, follow the steps mentioned in the Compiling the Driver section in order to cross compile the OneBox-Mobile software for i.MX6.
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 4. Preparing the MMC Card: An SD/MMC memory card is required to transfer the bootloader and kernel images for initializing the partition table and copy the root file system. This is included in the i.MX53 Evaluation Kit.
Page 132
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 • Stop bits: 1 • Parity: None • Flow Control: 1. Connect the RJ45 cable between the PC and the board. 2. Follow the instructions given at http://www.at91.com/linux4sam/bin/view/Linux4SAM/GettingStarted...
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 28 Appendix C: Using the Bluetooth Manager The steps given below explain about the usage of the Bluetooth Manager in Fedora Core 18 on an x86 platform for pairing Bluetooth devices and transferring files.
Page 134
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 Select the particular device, like your smartphone, right click and select Pair tab to pair with that device. After successfully pairing with the device, right-click on the device and select "Send a file" button in order to send...
Page 135
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020...
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 29 Appendix D: Common Configuration Parameters The common_insert.sh script is used to configure parameters at boot time. The parameters with their usage and input values are described below.
Page 137
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 If antenna diversity selection feature is also enabled, initial operation will start on the antenna selected. Antenna diversity operation will continue as expected. 29.3.1 COEX Mode selection This variable is used to select the Coex mode in which the module has to operate.
Page 138
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 BLR_DUTY_CYCLING BIT(1) BLE_PWR_SAVE_4X_MODE BIT(2) ...
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 30 Appendix E: Installation of Missing Generic Netlink Libraries libnl CFlags should be enabled with CONFIG_LIBNL32=y in supplicant and hostpad .config file \[The above configuration settings should be set to "y" in case NL80211 is used\]. Make sure that the NL80211 support and Hostapd support are enabled in the menuconfig during compilation.
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 31 Appendix F: Procedure to use latest supplicant with NL80211 interface Follow the below steps to use latest supplicant with the NL80211 interface Download the supplicant from https://w1.fi/wpa_supplicant/...
Page 141
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 ctrl_interface=/var/run/wpa_supplicant update_config=1 network={ ssid="REDPINE_AP_CCMP" pairwise=CCMP TKIP group=CCMP TKIP key_mgmt=WPA-PSK psk="12345678" proto=WPA2 WPA bgscan="simple:10:-45:100" priority=1 31.1.2 Configure Connection quality monitoring (cqm ) rssi and hysteresis using iw command To know more about iw tool, refer to the section Configuration Using CFG80211.
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 32 Appendix G: Considerations need to be made during hostapd usage 32.1 Parameters updated from hostapd.conf file The following are the parameters that will be updated from hostapd conf file instead of using onebox util ioctls.
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 33 Appendix H: Antennae 33.1 Taoglas Antenna Part No : GW.71.5153 33.2 SMARTEQ Antenna Part No : 4211613980 33.3 InsideWLAN Antenna Part No : PRO-IS-299 33.4 PCB Antenna...
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 34 RS9116 n-Link Software TRM Revision History Revision Version No. Date Changes v1.0 October 2017 Preliminary version v1.1 January 2018 Formatted the document as per Redpine document standard v1.2...
Page 145
RS9116 n-Link Linux and Android Technical Reference Manual Version : 2.0 July 2020 Revision Version No. Date Changes v1.9 March 2019 1. Added the NOTES and updated the INFO for some Wi- Fi ioctl Usage Guide commands. 2. Added Programming WLAN region based maximum powers from driver section.
Page 146
July 2020 Disclaimer The information in this document pertains to information related to Redpine Signals, Inc. products. This information is provided as a service to our customers, and may be used for information purposes only. Redpine assumes no liabilities or responsibilities for errors or omissions in this document. This document may be changed at any time at Redpine’s sole discretion without any prior notice to anyone. Redpine is not...
Need help?
Do you have a question about the RS9116 and is the answer not in the manual?
Questions and answers