I wrote up this guide because I had serious problems with the WGM160 Getting Started guide linked below.
Written by: David McCurley
Company: Microframe Corporation
Publish date: 2020.10.02
These directions are assembled from the following links. This document is not maintained. Links may change.
https://docs.silabs.com/wifi/wf200/content-source/getting-started/silabs/wgm160/getting-started
https://docs.silabs.com/wifi/wf200/content-source/getting-started/silabs/gg11/getting-started#import-the-project
https://github.com/SiliconLabs/wfx-fullMAC-tools
https://github.com/SiliconLabs/wfx-fullMAC-tools/tree/master/Examples/SiliconLabs/shared/wgm160p/bootloader
https://www.silabs.com/community/mcu/32-bit/knowledge-base.entry.html/2018/10/02/recovering_an_efm32g-S64B (alternate source for bootloader hex, but use the one included in the FullMAC source under "\wfx-fullMAC-tools\Examples\SiliconLabs\shared\wgm160p\bootloader\bl-usart-geckoG1-v2.07.hex".
Overview
--------
GeckoOS used to be the preferred method for developing on the WGM160P. There is also an open source option available if you want further control of the processor. Now that GeckoOS is deprecated, new designs should use the open source version.
The open source project is based on MicriumOS, which appears to be a high-quality OS. Micrium is owned by Silicon Labs. It appears that 7 months ago SI open sourced MicriumOS.
About the WGM160P. This module contains:
2.4 GHz 802.11 b/g/n Wi-Fi radio, specifically the (SI) WF200 WiFi transceiver.
72 MHz Cortex M4 MCU, specifically an (SI) EFM32GG11 microcontroller
At <$10, this module is smaller and less expensive than anything we could manufacture ourselves. Also FCC certified. An excellent choice.
Tools needed
------------
WGM160P Wi-Fi Module Wireless Starter Kit, part # SLWSTK6121A.
Simplicity IDE
FullMAC source
Serial terminal program such as TeraTerm or Putty
The starter kit includes:
BRD4001A Rev A01/PCB4001 Rev A03: SI program/debug base board
BRD4321A/PCB4321A Rev A04: WGM160P module on daughterboard w/ USB, PS, ID chip
BRD8026A rev A00: RMII Ethernet EXP board
It is also helpful to purchase a debug target adapter if you'd like an alternate debug/program header on your final circuit board. That is BRD8010A Rev A02 / PCB8010 Rev A02 STK/WSTK Debug Adapter. Hint: the connectors on this board are offset and only fit properly in one direction.
Getting Started
---------------
If you don't have the starter kit, order that first.
Download Software
-----------------
Download Simplicity IDE 4 or 5. I strongly recommend SS4. This will take a while so get that started and keep reading. v5 seems cleaner and faster, but I have managed to lock it up several times. Hint: don't close a window when there's a cancel option!
Get the FullMAC source. Go to https://github.com/SiliconLabs/wfx-fullMAC-tools. Don't use the "Download ZIP" option. Instead, use a GIT client to clone the repository. Apparently the GIT client downloads some binary files the ZIP file misses.
I used "GIT GUI" version 0.21.GITGUI by Sean Pearce. Set source to "https://github.com/SiliconLabs/wfx-fullMAC-tools.git" and target to your download location. Make sure to check "Recursively clone submodules too".
If you are using the GIT CLI, you can use: "git clone --recurse-submodules https://github.com/SiliconLabs/wfx-fullMAC-tools.git <Optional Target Directory>"
Serial terminal: if you don't have one installed, now is a good time to download it. I'm using Teraterm 4.101.
Hardware setup
--------------
You will want to plug in your hardware before installing Simplicity Studio, as it detects which modules to install based on your hardware.
Orient your base board (BRD4001A) with the Ethernet/USB/Battery connectors on the left and LCD in the middle. Plug in your WiFi module into the top right connector. The antenna connectors will be away from you on the edge of the board. The microUSB plug will face towards you and be over the "S" on the baseboard. Set the power selector to the AEM position. This should be the default.
Plug in a USB micro cable on the left side of the board. Attach the other end to your computer. This provides power and communication. The LCD on the baseboard will bring up some firmware revisions and you will see a green power light blinking to the left.
Install Software
----------------
Install your serial terminal program
Install Simplicity DE. The directions say to register your EFM32 starter kit. As best I can tell the WGM160P doesn't have a registration code, which means certain features of MicriumOS are unavailable. The installer doesn't prompt for a code. During the install, select the option "Install by Device". SS4 will detect the connected processor, but you will need to double click the model to move it to the right side. I believe SS5 automatically selects it for you. Click next. You will need to login with your Silicon Labs account. The installer will install lots of packages. This takes about 30 minutes. It prompts a couple times to install drivers. Note SS5 locked up on me halfway through the install. I reopened it and it restarted the install. No issues the second time.
Set Up Your Workspace
---------------------
Now that SS4 is installed, let's setup your workspace.
[EDIT 10/05/2020]
Your workspace is located under your user profile, something like this: C:\Users\David\SimplicityStudio\v4_workspace. When importing you can link to the original folder or copy to your workspace. If you link then you are editing your copy of the FullMAC repository. If you copy the projects into your workspace, you will get lots of broken links, because the projects contain relative path references to other folders inside the FullMAC repository. The easiest thing to do here is to copy the whole FullMAC repository to your workspace folder [390 MB], then import (link, because it's already inside the workspace) the two projects in the new location.
[/EDIT 10/05/2020]
Go to Window->Perspective->Simplicity IDE. This will allow you to see the Project Explorer.
You will need to import two projects: The EFM32GG11, and the WGM160P.
SS4: Go to File->Import. More Import Options. General->Existing Projects Into Workspace. Select the EFM32GG11 project located in the FullMAC driver folder: \wfx-fullMAC-tools\Examples\SiliconLabs\commissioning\micrium_os\SLSTK3701A
SS5: The "More Import Options" worked previously, but now the window blinks and comes back. It won't show the more import options. Lesson: Stick with SS4.
Repeat the process for the second project:
\wfx-fullMAC-tools\Examples\SiliconLabs\commissioning\micrium_os\WGM160P
You should now see the two projects listed in your Project Explorer window.
Format your WGM160P
-------------------
If you have done any development with GeckoOS, your module will have a GeckoOS bootloader installed, which must be removed for your new code to work. I also ran across a page that says GeckoOS bootloader is installed on every WGM160P.
Directions here: https://github.com/SiliconLabs/wfx-fullMAC-tools/blob/master/Examples/SiliconLabs/shared/wgm160p/bootloader/README.md
and here: D:\Installed_Software\SiliconLabs\wfx-fullMAC-tools\Examples\SiliconLabs\shared\wgm160p\bootloader\README.md
The referenced HEX file is here: D:\Installed_Software\SiliconLabs\wfx-fullMAC-tools\Examples\SiliconLabs\shared\wgm160p\bootloader\bl-usart-geckoG1-v2.07.hex
You can also get a copy of the file here: https://www.silabs.com/community/mcu/32-bit/knowledge-base.entry.html/2018/10/02/recovering_an_efm32g-S64B
Run Your Project
----------------
Open your serial terminal. Select your USB port and set the baud rate to 115000bps, 8 bits, 1 stop, no parity.
Right click on your WGM160P project->Debug As->Silicon Labs Arm. SS will take a while to compile it, then upload it to WGM160p target hardware. Upon launch the IDE will automatically halt at int main(void). Press F8 to run.
You should see the following printed to the screen:
///
WF200 Micrium OS LwIP Example
FMAC Driver version 3.0.3
WF200 Firmware version 3.7.0
WF200 initialization successful
Press <Enter> within 5 seconds to configure the demo...
AP started
Join the AP with SSID: silabs_softap
///
If you missed it, press the "Reset" button on right edge of the baseboard.
Errata
------
Attempting to Modify or Uninstall SS5 from Win10->Apps and Features results in an error message, something like "No application found to execute this function". Uninstall using the older "Programs and Features" control panel.
Fixes??
-------
To fix this warning:
Implicit declaration of function 'sl_sleeptimer_get_time'; did you mean 'sl_sleeptimer_stop_timer'? [-Wimplicit-function-declaration] clk.c /SLSTK3701A_commissioning_micriumos/micrium_os/common/source/clk line 3186
Credit to: https://www.silabs.com/community/wireless/wi-fi/forum.topic.html/wgm160p_micrium_oslwipcompilationproblems-VfaR
Change "#define SL_SLEEPTIMER_WALLCLOCK_CONFIG" from 0 to 1 in line 52 of SLSTK3701A.../service/sleeptimer/config/sl_sleeptimer_config.h.
You will need to click "Edit in SDK" or the change won't apply to this project.
***Caution this may break other things.***
Fix for HTTPS cert error/crash
https://www.silabs.com/community/wireless/wi-fi/forum.topic.html/fmac_example_wgm160pcommissioningmicriumosgoes-hJV7
WGM160P: Getting Started with MicriumOS and FullMAC Driver [Solution]
I wrote up this guide because I had serious problems with the WGM160 Getting Started guide linked below.
Written by: David McCurley
Company: Microframe Corporation
Publish date: 2020.10.02
These directions are assembled from the following links. This document is not maintained. Links may change.
https://docs.silabs.com/wifi/wf200/content-source/getting-started/silabs/wgm160/getting-started
https://docs.silabs.com/wifi/wf200/content-source/getting-started/silabs/gg11/getting-started#import-the-project
https://github.com/SiliconLabs/wfx-fullMAC-tools
https://github.com/SiliconLabs/wfx-fullMAC-tools/tree/master/Examples/SiliconLabs/shared/wgm160p/bootloader
https://www.silabs.com/community/mcu/32-bit/knowledge-base.entry.html/2018/10/02/recovering_an_efm32g-S64B (alternate source for bootloader hex, but use the one included in the FullMAC source under "\wfx-fullMAC-tools\Examples\SiliconLabs\shared\wgm160p\bootloader\bl-usart-geckoG1-v2.07.hex".
Overview
--------
GeckoOS used to be the preferred method for developing on the WGM160P. There is also an open source option available if you want further control of the processor. Now that GeckoOS is deprecated, new designs should use the open source version.
The open source project is based on MicriumOS, which appears to be a high-quality OS. Micrium is owned by Silicon Labs. It appears that 7 months ago SI open sourced MicriumOS.
About the WGM160P. This module contains:
2.4 GHz 802.11 b/g/n Wi-Fi radio, specifically the (SI) WF200 WiFi transceiver.
72 MHz Cortex M4 MCU, specifically an (SI) EFM32GG11 microcontroller
At <$10, this module is smaller and less expensive than anything we could manufacture ourselves. Also FCC certified. An excellent choice.
Tools needed
------------
WGM160P Wi-Fi Module Wireless Starter Kit, part # SLWSTK6121A.
Simplicity IDE
FullMAC source
Serial terminal program such as TeraTerm or Putty
The starter kit includes:
BRD4001A Rev A01/PCB4001 Rev A03: SI program/debug base board
BRD4321A/PCB4321A Rev A04: WGM160P module on daughterboard w/ USB, PS, ID chip
BRD8026A rev A00: RMII Ethernet EXP board
It is also helpful to purchase a debug target adapter if you'd like an alternate debug/program header on your final circuit board. That is BRD8010A Rev A02 / PCB8010 Rev A02 STK/WSTK Debug Adapter. Hint: the connectors on this board are offset and only fit properly in one direction.
Getting Started
---------------
If you don't have the starter kit, order that first.
Download Software
-----------------
Download Simplicity IDE 4 or 5. I strongly recommend SS4. This will take a while so get that started and keep reading. v5 seems cleaner and faster, but I have managed to lock it up several times. Hint: don't close a window when there's a cancel option!
Get the FullMAC source. Go to https://github.com/SiliconLabs/wfx-fullMAC-tools. Don't use the "Download ZIP" option. Instead, use a GIT client to clone the repository. Apparently the GIT client downloads some binary files the ZIP file misses.
I used "GIT GUI" version 0.21.GITGUI by Sean Pearce. Set source to "https://github.com/SiliconLabs/wfx-fullMAC-tools.git" and target to your download location. Make sure to check "Recursively clone submodules too".
If you are using the GIT CLI, you can use: "git clone --recurse-submodules https://github.com/SiliconLabs/wfx-fullMAC-tools.git <Optional Target Directory>"
Serial terminal: if you don't have one installed, now is a good time to download it. I'm using Teraterm 4.101.
Hardware setup
--------------
You will want to plug in your hardware before installing Simplicity Studio, as it detects which modules to install based on your hardware.
Orient your base board (BRD4001A) with the Ethernet/USB/Battery connectors on the left and LCD in the middle. Plug in your WiFi module into the top right connector. The antenna connectors will be away from you on the edge of the board. The microUSB plug will face towards you and be over the "S" on the baseboard. Set the power selector to the AEM position. This should be the default.
Plug in a USB micro cable on the left side of the board. Attach the other end to your computer. This provides power and communication. The LCD on the baseboard will bring up some firmware revisions and you will see a green power light blinking to the left.
Install Software
----------------
Install your serial terminal program
Install Simplicity DE. The directions say to register your EFM32 starter kit. As best I can tell the WGM160P doesn't have a registration code, which means certain features of MicriumOS are unavailable. The installer doesn't prompt for a code. During the install, select the option "Install by Device". SS4 will detect the connected processor, but you will need to double click the model to move it to the right side. I believe SS5 automatically selects it for you. Click next. You will need to login with your Silicon Labs account. The installer will install lots of packages. This takes about 30 minutes. It prompts a couple times to install drivers. Note SS5 locked up on me halfway through the install. I reopened it and it restarted the install. No issues the second time.
Set Up Your Workspace
---------------------
Now that SS4 is installed, let's setup your workspace.
[EDIT 10/05/2020]
Your workspace is located under your user profile, something like this: C:\Users\David\SimplicityStudio\v4_workspace. When importing you can link to the original folder or copy to your workspace. If you link then you are editing your copy of the FullMAC repository. If you copy the projects into your workspace, you will get lots of broken links, because the projects contain relative path references to other folders inside the FullMAC repository. The easiest thing to do here is to copy the whole FullMAC repository to your workspace folder [390 MB], then import (link, because it's already inside the workspace) the two projects in the new location.
[/EDIT 10/05/2020]
Go to Window->Perspective->Simplicity IDE. This will allow you to see the Project Explorer.
You will need to import two projects: The EFM32GG11, and the WGM160P.
SS4: Go to File->Import. More Import Options. General->Existing Projects Into Workspace. Select the EFM32GG11 project located in the FullMAC driver folder: \wfx-fullMAC-tools\Examples\SiliconLabs\commissioning\micrium_os\SLSTK3701A
SS5: The "More Import Options" worked previously, but now the window blinks and comes back. It won't show the more import options. Lesson: Stick with SS4.
Repeat the process for the second project:
\wfx-fullMAC-tools\Examples\SiliconLabs\commissioning\micrium_os\WGM160P
You should now see the two projects listed in your Project Explorer window.
Format your WGM160P
-------------------
If you have done any development with GeckoOS, your module will have a GeckoOS bootloader installed, which must be removed for your new code to work. I also ran across a page that says GeckoOS bootloader is installed on every WGM160P.
Directions here: https://github.com/SiliconLabs/wfx-fullMAC-tools/blob/master/Examples/SiliconLabs/shared/wgm160p/bootloader/README.md
and here: D:\Installed_Software\SiliconLabs\wfx-fullMAC-tools\Examples\SiliconLabs\shared\wgm160p\bootloader\README.md
The referenced HEX file is here: D:\Installed_Software\SiliconLabs\wfx-fullMAC-tools\Examples\SiliconLabs\shared\wgm160p\bootloader\bl-usart-geckoG1-v2.07.hex
You can also get a copy of the file here: https://www.silabs.com/community/mcu/32-bit/knowledge-base.entry.html/2018/10/02/recovering_an_efm32g-S64B
Run Your Project
----------------
Open your serial terminal. Select your USB port and set the baud rate to 115000bps, 8 bits, 1 stop, no parity.
Right click on your WGM160P project->Debug As->Silicon Labs Arm. SS will take a while to compile it, then upload it to WGM160p target hardware. Upon launch the IDE will automatically halt at int main(void). Press F8 to run.
You should see the following printed to the screen:
///
WF200 Micrium OS LwIP Example
FMAC Driver version 3.0.3
WF200 Firmware version 3.7.0
WF200 initialization successful
Press <Enter> within 5 seconds to configure the demo...
AP started
Join the AP with SSID: silabs_softap
///
If you missed it, press the "Reset" button on right edge of the baseboard.
Errata
------
Attempting to Modify or Uninstall SS5 from Win10->Apps and Features results in an error message, something like "No application found to execute this function". Uninstall using the older "Programs and Features" control panel.
Fixes??
-------
To fix this warning:
Implicit declaration of function 'sl_sleeptimer_get_time'; did you mean 'sl_sleeptimer_stop_timer'? [-Wimplicit-function-declaration] clk.c /SLSTK3701A_commissioning_micriumos/micrium_os/common/source/clk line 3186
Credit to: https://www.silabs.com/community/wireless/wi-fi/forum.topic.html/wgm160p_micrium_oslwipcompilationproblems-VfaR
Change "#define SL_SLEEPTIMER_WALLCLOCK_CONFIG" from 0 to 1 in line 52 of SLSTK3701A.../service/sleeptimer/config/sl_sleeptimer_config.h.
You will need to click "Edit in SDK" or the change won't apply to this project.
***Caution this may break other things.***
Fix for HTTPS cert error/crash
https://www.silabs.com/community/wireless/wi-fi/forum.topic.html/fmac_example_wgm160pcommissioningmicriumosgoes-hJV7
Thank you