Skip to content

CMSIS Configuration Wizard Annotations

SLC component configuration uses a subset of the CMSIS Configuration Wizard Annotation standard. Only the options listed on this page are allowed to be used in SLC-compatible configuration header files.

There are two ways of linking an annotation to code using CMSIS Configuration Wizard Annotations:

  • Implicit reference to the nth integer after the annotation
  • Explicit reference to a specific symbol/identifier

SLC only supports the second way, using an explicit reference to the symbol. This helps structure the list of annotations, makes it clear which annotation operates on which symbol, and ensures consistency regardless of whether the annotation is meant to reference an integer or another type of symbol.

Operators

<h>

Creates a header element in the GUI.

1
2
3
// <h> Header Title
// ...
// </h>

<o> with identifier

Sets the value of the following #define with the given identifier.

Typically rendered as an input box with constraints given by attributes, or a drop-down list if one or more option attributes is given.

1
2
// <o PRIORITY_LEVEL> Priority Level
#define PRIORITY_LEVEL 4

<q> with identifier

Sets the boolean value of the following #define with the given identifier.

Typically rendered as a checkbox or toggle.

1
2
// <q PERIPHERAL_ENABLED> Enable Peripheral
#define PERIPHERAL_ENABLED 0

<e> with identifier

Sets the boolean value of the following #define with the given identifier.

Typically rendered as a heading with an associated checkbox or toggle.

1
2
3
4
// <e PERIPHERAL_ENABLED> Enable Peripheral
#define PERIPHERAL_ENABLED 0
// ...
// </e>

<s> with length and identifier

Sets the string value of the following #define with the given identifier, enforcing a maximum length.

Typically rendered as a text input box.

1
2
// <s.128 APPLICATION_NAME> Application Name
#define APPLICATION_NAME "My App"

<a> with length and identifier

Sets the value of the following #define to the given array.

1
2
// <a.4 CONFIG_LIST> Configuration
#define CONFIG_LIST {0, 0, 0, 0}

Attributes

<i> - Information

Detailed description for the active operator.

1
// <i> Description

<d> - Default value

Default value for the active operator. For backwards compatibility, <i> Default: is also supported.

1
2
3
// <o FOO> Option
// <d> 3
#define FOO 2

<value=> - Option

Option for the active <o> operator. Constrains valid values to the ones given by option attributes.

1
2
3
4
// <o FOO> Option
// <one=> One
// <two=> Two
#define FOO two

<x..y:z> - Range

Constrains range of <o> operator to x to y inclusive, in steps of z.

1
// <0..100:10>

<f> - Format

Format specifier for the active operator. One of

  • d - decimal
  • h - hexadecimal
  • o - octal
  • b - binary
1
2
// <o HEX_OPTION> Hex Option <f.h>
#define HEX_OPTION  52      // displayed as 0x34 in GUI
Back to top