Custom manufacturing tokens are similar to custom stack token, but the purpose is to write once (in manufacturing case) and read multiple times (as opposed to custom stack tokens where the purpose is to modify the value several times at runtime).
While for stack tokens there is a Token Manager component where one can specify the name and the location of the header file that contains the custom stack tokens, this is not the case for custom manufacturing tokens.
For custom stack tokens the default location is the project's config directory and the default name is sl_custom_token_header.h. Don't place the custom manufacturing token defines in this file.
Instead, create a file with the content required for custom manufacturing token(s), name it freely (ex.: sl_custom_mfg_token_header.h - preferably don't use sl_custom_token_header.h to avoid conflicts) place it in the project's config directory (not necessarily, but seems a good choice, beside sl_custom_token_header.h).
Then add -D APPLICATION_MFG_TOKEN_HEADER="sl_custom_mfg_token_header.h" to the compile options. The easiest way to apply this is opening Project Properties -> C/C++ Build -> Settings -> Preprocessor -> Defined symbols -> + (Add..) and add APPLICATION_MFG_TOKEN_HEADER="sl_custom_mfg_token_header.h":
Sample manufacturing token example from SimplicityStudio_v5/developer/sdks/gecko_sdk_suite/v3.0/platform/service/token_manager/inc/sl_token_manufacturing_series_1.h:
Proprietary Knowledge Base
Creating custom manufacturing tokens in Connect based apps
Custom manufacturing tokens are similar to custom stack token, but the purpose is to write once (in manufacturing case) and read multiple times (as opposed to custom stack tokens where the purpose is to modify the value several times at runtime).
While for stack tokens there is a Token Manager component where one can specify the name and the location of the header file that contains the custom stack tokens, this is not the case for custom manufacturing tokens.
For custom stack tokens the default location is the project's config directory and the default name is sl_custom_token_header.h. Don't place the custom manufacturing token defines in this file.
Instead, create a file with the content required for custom manufacturing token(s), name it freely (ex.: sl_custom_mfg_token_header.h - preferably don't use sl_custom_token_header.h to avoid conflicts) place it in the project's config directory (not necessarily, but seems a good choice, beside sl_custom_token_header.h).
Then add -D APPLICATION_MFG_TOKEN_HEADER="sl_custom_mfg_token_header.h" to the compile options. The easiest way to apply this is opening Project Properties -> C/C++ Build -> Settings -> Preprocessor -> Defined symbols -> + (Add..) and add APPLICATION_MFG_TOKEN_HEADER="sl_custom_mfg_token_header.h":
Sample manufacturing token example from SimplicityStudio_v5/developer/sdks/gecko_sdk_suite/v3.0/platform/service/token_manager/inc/sl_token_manufacturing_series_1.h:
The header file should contain only the token definitions, avoid using header guards.