Project Structure#

In Bluetooth Mesh SDK v1.x, a project contains the following folders:

/                   Application-specific files
/hardware           Development board configuration files and drivers for external peripherals
/platform           Device configuration files and drivers for the MCU peripherals
/protocol           Bluetooth stack files

When a new project is generated, a subset of the SDK files (source files, headers, configuration headers) is copied from the SDK folder into the project folders based on hardware type and on the needs of the sample application. Additionally, some files (for example init_mcu.c, hal-config.h, and so on) are generated from templates into the root folder of the project. Again, the output is based on the hardware type and on the needs of the sample application.

In Bluetooth Mesh SDK v2.x auto-generated files and configuration headers are clearly separated from the static SDK files and gathered into separate folders:

/autogen            Automatically-generated files based on the installed software components
/config             Editable configuration files for the software components
/gecko_sdk_3.x.x
  /app              Application-specific files
  /hardware         Development board configuration files and drivers for external peripherals
  /platform         Device configuration files and drivers for the MCU peripherals
  /protocol         Bluetooth stack files
  /util             Utilities

Developers can now easily see which files can be modified by the generator script and it is easy to access all configuration files. This is especially important because in Bluetooth Mesh SDK v2.x many more files are generated by the addition of software components.

Due to the new project structure – and due to the new auto-generated files required by the Bluetooth stack – migrating a v1.x project into Bluetooth Mesh SDK v2.x must begin by creating a new project in the new SDK. All Bluetooth Mesh v1.x SDK examples are also in the Bluetooth Mesh v2.x SDK. It is recommended to start from the equivalent or from the Bluetooth Mesh SoC Empty project. Application logic should be pulled into this new project. After you select a compatible part on SSv5’s Welcome page, the project can be created from the Part-specific Launcher perspective. The Technology filter makes it easy to find applicable projects.

The Technology filterThe Technology filter

In the project configuration dialog, you can rename the project, change the project location, and define how to handle project files.

Note: In Bluetooth Mesh SDK v1.x all SDK files are copied into the project by default. In Bluetooth Mesh SDK v2.0 SDK files, considered to be static, are linked by default. If you want to version-control your full project, it is recommended to change this setting to “Copy contents” in the Project Configuration wizard, when you create the new project to have all content needed by the project in one folder.

Copy contentsCopy contents

Bluetooth Mesh projects automatically open in the Simplicity IDE’s Project Configurator. Three tabs are presented: the GATT Configurator (gatt_configuration.btconf), .the slcp or Project Configurator (<projectname>.slcp), and the Mesh Configurator (dcd_config.btmeshconf). If the example has documentation, the project opens on a readme tab.

GATT configuration is the same for both Bluetooth and Bluetooth mesh projects. UG438: GATT Configurator User’s Guide for Bluetooth SDK v3.x describes how to configure the GATT database.

GATT configurationGATT configuration

The Project Configurator and its associated Component Editor provide access to components. All the Bluetooth Mesh functionality is provided as components. You can customize projects by installing or uninstalling the components based on the use cases and requirements, and then configuring installed components using the Component Editor. The Bluetooth Mesh Component group shows the components specific to Bluetooth Mesh projects. Components are discussed in more detail in the next section.

The Project ConfiguratorThe Project Configurator

The Bluetooth Mesh Configurator provides access to information about a Bluetooth mesh node, the elements it includes, and the supported models. DCD exposes the node information to a configuration client so that it knows the potential functionalities the node supports and based on that can configure the node.

The Bluetooth Mesh ConfiguratorThe Bluetooth Mesh Configurator

For more details on node configuration using the Project Configurator and Bluetooth Mesh Configurator, see UG472: Bluetooth® Mesh Node Configurator User's Guide for SDK v2.x.