Wi-Fi Commissioning Micrium OS Example on EFM32GG11 (STK3701A)
This document describes how to connect the WF(M)200 Wi-Fi Expansion Board to a STK3701A Starter Kit and run the Wi-Fi Commissioning example. The example is based on the combo capacity of the WF(M)200, meaning its ability to behave simultaneously as an Access Point and as a Station in order to demonstrate a typical use case of field deployment. Where an operator installs the device and configures it to connect to a specific Access Point using a Webpage.
Getting Started
This demonstration runs the Wi-Fi Full MAC driver meant to communicate with the WF(M)200 Silicon Labs Wi-Fi transceivers.
Naming convention
- SoftAP : WF(M)200 configured in Wi-Fi Software-enabled Access Point mode
- Station : WF(M)200 configured in Wi-Fi Station mode
- AP : Any 'home network' or 'office network' Wi-Fi Access Point
- Device : The PC or phone used to access the demo
Requirements
Hardware Prerequisites
The WF(M)200 Wi-Fi Expansion Board contains a Wi-Fi module. To use the board, a MCU Starter Kit is required, where the MCU will be the host that communicates and controls the Wi-Fi module.
- One of the two Wi-Fi® expansion kits listed below:
WF200 Wi-Fi® Expansion Kit SLEXP8022A | WFM200 Wi-Fi® Expansion Kit SLEXP8023A |
- The Host Microcontroller:
EFM32 Giant Gecko GG11 Starter Kit – SLSTK3701A |
Software Prerequisites
-
The required software includes Simplicity Studio 4 and the Gecko SDK Suite (32-bit MCU SDK v5.9, Gecko Platform SDK v2.7 and Micrium OS Kernel SDK v5.8)
-
The example project and the Wi-Fi Full MAC driver available in the SDK or from https://github.com/SiliconLabs/wfx-fullMAC-tools
-
A Serial terminal to communicate with the SLSTK3701A board. For example, Tera Term or Putty
The main software components used by this example are:
- Micrium OS Kernel, which a Real-Time Operating System (RTOS) designed to run on Silicon Labs devices only. It is provided free of charge.
- Lightweight IP (LwIP), which is an open-source TCP/IP stack licensed under the BSD license.
Set up your Kit
-
Connect the WF(M)200 Wi-Fi Expansion Kit to the STK3701A Starter Kit.
-
Ensure that the power selector switch on the STK3701A is in the [AEM] position.
-
Ensure that the power selector switch on the WF(M)200 Wi-Fi Expansion Board is in the [EXP VMCU] position.
-
Set the communication interface switch to the [SPI] position.
-
Provide power by connecting the [DBG] USB connector on the STK3701A to the PC using the provided USB cable.
setup stk3701a wfm200
Install Simplicity Studio and the SDK
Simplicity Studio 4 is a free software suite needed to start developing your application.
-
Download the latest version of Simplicity Studio 4 from the following link: http://www.silabs.com/simplicity-studio .
-
Create a Silicon Labs account.
-
Register your STK3701A Starter Kit by entering the Serial Number found in the packaging.
-
In the Installation Manager, select the option [Install by Device] .
-
Connect the STK3701A, select it from the panel [Connected Devices] and move it to the panel [Selected Devices] .
-
Sign in with your Silicon Labs account credentials and install the Gecko SDK Suite (espcecially 32-bit MCU SDK v5.9, Gecko Platform SDK v2.7 and Micrium OS Kernel SDK v5.8).
Get the Example
Get the example from the SDK (version 2.7) or from the Github Repository. Follow the instructions from the section that fits your use case.
From the SDK
An SDK with the version 2.7 for this section. If this does not match your case, either update Simplicity Studio packages or see Get the Example from the Github Repository section.
-
Connect the STK3701A Starter Kit and open Simplicity Studio 4.
-
Select the [Launcher] perspective.
-
From the [Debug Adapters] panel on the left top corner, select your STK3701A under the J-Link Silicon Labs tree.
-
Select the example [SLSTK3701A_micriumos_lwip_wfx] from the Software Examples list as illustrated in the image below:
At the end of this procedure, Simplicity Studio 4 has created the project in your workspace and will display the project in the [Project Explorer] as shown below:
From the Github Repository
Clone the GitHub Repository
This example, along with other examples, is also available in our GitHub repository: https://github.com/SiliconLabs/wfx-fullMAC-tools . The main difference between both examples is that the example available on GitHub provides new features waiting to be included in the SDK example.
Please refer to the Get started section of the repository to use the GitHub example. Or if you wish to download the zip file from github rather than clone the repository using Git, make sure to download the wfx_fmac_driver and copy it to wfx-fullMAC-tools/wfx-fullMAC-driver .
Import the Project
This procedure is important and has to be followed carefully. The default import method must not be used, an alternate import method is used instead to ease the source code management, especially the GitHub repository updates and sharing sources between the examples. The main difference with this alternate method is that the source code is not copied into your workspace. The sources used are directly the ones you retrieved when cloning the repository. One advantage for you is to benefit of the "git" commands to see if you applied changes to the repository, revert them if necessary, or update easily the repository.
-
Open Simplicity Studio 4 and press [File -> Import…] .
-
Click the link [More Import Options...] .
-
Select the option [General -> Existing Projects into Workspace] and click the button [Next] .
-
Select the root directory by browsing to the location where you cloned the repository.
wfx-fullMAC-tools\Examples\SiliconLabs\commissioning\micrium_os\SLSTK3701A\
-
Click the button [Finish] .
At the end of this procedure, Simplicity Studio 4 has created the project in your workspace and will display the project in the [Project Explorer] as shown below:
Start the Example
-
Right-Click over the project name to open the context menu and select [Debug As] and then the option [Silicon Labs ARM Program] to Build the Project and Launch a Debug Session.
-
While the toolchain builds the project and launches the debug session, open the Device Manager in Windows OS to see the COM Port Number assigned to the USB device [J-Link CDC UART Port] .
-
Open a Serial Terminal application, such as PuTTY, configure it to the COM Port Number you found in the previous step, and set the UART settings to 115200 bps, 8 data bits, 1 stop bit and no parity.
-
After the Debug session is launched, the IDE will switch to the [Debug] perspective and will halt the CPU at the main entry point. Press the key [F8] to Resume execution.
-
Watch the application’s progress on the Serial Terminal. Wait 5 seconds if you want to use the default settings. The application will go through the following stages before it is ready:
WF200 Micrium OS LwIP Example
FMAC Driver version 3.2.2
WF200 Firmware version 3.11.1
WF200 initialization successful
Press <Enter> within 5 seconds to configure the demo...
AP started
Join the AP with SSID: silabs_softap
You are ready to move to the Wi-Fi commissioning demonstration page.