Editing And Building Applications Using Wiced Studio; Application Makefiles And Source Files; Building An Application - Laird LSR STERLING-LWB STM Quick Start Manual

Table of Contents

Advertisement

3.4 Editing and Building Applications using WICED Studio

3.4.1 Application Makefiles and Source Files

Applications can be edited by adding/editing files from the "Project Explorer" view on the left side of
WICED Studio. For example, to view the "snip.scan" source files, expand the "apps" folder, then "snip"
and finally "scan" to see the scan.c and scan.mk files. All projects have an .mk file associated with them
to specify the source files and other options to the WICED Studio builder. This file MUST be named with
the same name as the folder containing it (e.g. the folder for the application is named 'scan', therefore
the build environment looks for a file named 'scan.mk' within that when building the scan application).
The .mk file provides at least the NAME of the application and a list of source files required to build it i.e.
$(NAME)_SOURCES. See the 'scan.mk' file for a simple example.
There are many other options that can be set in the project .mk file, but describing these is outside the
scope of this document. To learn more about this, take a look at the comments in the top-level
43xxx_Wi-Fi/Makefile or check out the numerous project.mk files provided with the SDK in 43xxx_Wi-
Fi/apps/snip/* and 43xxx_Wi-Fi/apps/demo/*.

3.4.2 Building an Application

To build an application, a make target must be created containing a build string that specifies the
application name, target platform, operations and other flags if necessary. To create a new make target,
right-click "43xxx_Wi-Fi" in the "Make Target" tab and select "New...".
For "Target name:", enter the name of the application starting with the subfolder of "apps" and using
dot (.) as the path separator (e.g. 'snip.scan'), followed by a dash (-), followed by target name (e.g.
LSRSTERLING_00950), followed optionally by the RTOS (e.g. ThreadX), networking stack (e.g. NetX) and
interface (e.g. SDIO) all separated by dashes. This should be followed by a space, then one or more
commands to execute such as 'download', 'download_apps' and/or 'run'. For a detailed listing of the
possible options for build strings, see the USAGE_TEXT defined in '43xxx_Wi-Fi/Makefile' near the top of
the file.
To build the snip.scan application:
1.) Double-click the "clean" make target to clean any previously built target files
2.) create a make target with the following build string:
3.) Double-click the make target created in step 2. The "Console" tab near the bottom of the WICED
Studio window will display the status of the build. Once the build is complete, the output files
will be located in the 43xxx_Wi-Fi/build folder.
The information in this document is subject to change without notice.
330-0234-R1.2
snip.scan-LSRSTERLING_00950-ThreadX-NetX-SDIO
Copyright ©2016-2017 LSR
Sterling-LWB STM Expansion Board
USER GUIDE
Page 13 of 25

Advertisement

Table of Contents
loading

Table of Contents