feat(firmware): add 'user data' section to model yaml for Lua scripts (#7562)

Co-authored-by: Peter Feerick <peter.feerick@gmail.com>
Co-authored-by: Claude Sonnet 5 <noreply@anthropic.com>
This commit is contained in:
philmoz
2026-09-18 09:04:48 +10:00
committed by GitHub
co-authored by Peter Feerick Claude Sonnet 5
parent abeed9f23b
commit ed71a38726
45 changed files with 1105 additions and 16 deletions
@@ -942,6 +942,13 @@ static const struct YamlNode struct_USBJoystickChData[] = {
YAML_UNSIGNED( "switch_npos", 3 ),
YAML_END
};
static const struct YamlNode struct_UserData[] = {
YAML_IDX,
YAML_CUSTOM("key",r_userdata_key,w_userdata_key),
YAML_CUSTOM("type",r_userdata_type,w_userdata_type),
YAML_CUSTOM("value",r_userdata_value,w_userdata_value),
YAML_END
};
static const struct YamlNode struct_ModelData[] = {
YAML_CUSTOM("semver",nullptr,w_semver),
YAML_STRUCT("header", 1048, struct_ModelHeader, NULL),
@@ -1023,6 +1030,7 @@ static const struct YamlNode struct_ModelData[] = {
YAML_ENUM("modelSFDisabled", 2, enum_ModelOverridableEnable, NULL),
YAML_ENUM("modelCustomScriptsDisabled", 2, enum_ModelOverridableEnable, NULL),
YAML_ENUM("modelTelemetryDisabled", 2, enum_ModelOverridableEnable, NULL),
YAML_ARRAY("userData", 0, 50, struct_UserData, userdata_is_active),
YAML_END
};
static const struct YamlNode struct_PartialModel[] = {