Wi-Fi R-Mesh WHC mode
R-Mesh currently supports WHC mode on the Linux platform and can be used in both WPAoH and WPAoD architectures.
Device driver configuration
Please enable R-Mesh and Socket according to the instructions in SDK Configuration , and then setting the WPAoH or WPAoD device driver according to WHC Device Configuration , finally compile and flash the firmware.
Note
RNAT is not supported at WHC mode currently
R-MESH WHC mode requires the use of CMD PATH. Please ensure tha CMD PATH is enabled when executing
./menuconfig.py(Top) -> CONFIG WHC INTF -> WHC config ----Configuration---- (X) Support WHC CMD PATH ( ) Support WHC WIFI API PATH ( ) Support WHC SUPPLICANT OFFLOAD ( ) Support WHC DEV TCPIP KEEPALIVE
By default, the root node in SDK supports only 2 connections. To enable more connections, you can contact us to obtain the corresponding wlan lib:
Obtain the R-Mesh WLAN library(contact us)
Replace
lib_wifi_whc_dev.aat{sdk}/component/soc/amebadplus/project/project_km4/lib/application
btain the R-Mesh WLAN library(contact us)
Replace
lib_wifi_whc_dev.aat{sdk}/component/soc/amebagreen2/project/project_km4tz/lib/application
Host driver configuration
- Please setting the WPAoH host driver according to
WPAoH Configuration
when choosing WPAoH architecture, or setting the WPAoD host driver according to
WPAoD configuraton
, note that when executing
./whc_setup.sh, you need to add thermeshparameter. ./whc_setup.sh sdio rmesh
./whc_setup.sh spi rmesh
./whc_setup.sh usb rmesh
Demo
Based on the original SDK demo program {SDK}/component/wifi/whc/whc_host_linux/app , R-MESH incorporates the feature of periodically transmitting topology information, enabling
Gravitation
to funtion properly.
Note
This modified demo program is designed to work with the Gravitation tool. If you do not need the Gravitation tool in your actual use case, for WPAoH,running this demo is not necessary; for WPAoD, users only need to run the demo according to the instructions in WPAoD configuration
after successful modprobe loading, launch WPA SUPPLICANT to start wifi connection,and then IP address can be obtained through dhcpcd
enable RMESH in
{SDK}/component/wifi/whc/whc_host_linux/app/whc_host_app.c
#define CONFIG_RMESH
compile and run the demo
cd ${SDK}/component/whc/whc_host_linux/app
make
sudo ./whc_cust_path_demo
after demo is excuted, input “init” cmd for initialization
> init
now you can see the corresponding rmesh node in Gravitation tool
after successful modprobe loading, enable RMESH in
{SDK}/component/wifi/whc/whc_host_linux/app/whc_host_app.c
#define CONFIG_RMESH
compile and run the demo
cd ${SDK}/component/wifi/whc/whc_host_linux/app
make
sudo ./whc_cust_demo
Once the demo is running, execute the following command to initialize
> init
> wifion
> getmac 0
00:E0:4C:XX:XX:XX
> setmac 0 00:E0:4C:XX:XX:XX
execute the following command for wifi connection
> netifon
> connect ap_ssid 12345678
Note
ap_ssid is the ssid of the target AP,12345678 is the password of target, omit password parameter for open networks
obtain IP address after wifi connection is succeeded
now you can see the corresponding rmesh node in Gravitation tool