Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
F
Firmware
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Alberto Ruiz Garcia
Firmware
Commits
e4d4192f
Commit
e4d4192f
authored
6 years ago
by
Beat Küng
Browse files
Options
Downloads
Patches
Plain Diff
module_schema.yaml: add parameter definitions
parent
babe3009
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
test/module_schema.yaml
+119
-1
119 additions, 1 deletion
test/module_schema.yaml
with
119 additions
and
1 deletion
test/module_schema.yaml
+
119
−
1
View file @
e4d4192f
...
...
@@ -67,7 +67,125 @@ serial_config:
type
:
integer
min
:
1
parameters
:
# Parameter definitions.
# This is a list of parameter groups, where each group has one or more
# parameter definitions.
type
:
list
# TODO
minlength
:
1
schema
:
type
:
dict
schema
:
group
:
# Parameter group (should be short)
# This applies to all parameters in the definitions dictionary
type
:
string
required
:
true
definitions
:
type
:
dict
keyschema
:
type
:
string
regex
:
'
[0-9A-Z_]+(\$\{i\}[0-9A-Z_]*)?'
valueschema
:
type
:
dict
schema
:
description
:
type
:
dict
required
:
true
schema
:
short
:
# Short description (one line)
type
:
string
required
:
true
long
:
# Long description (can be multiple lines)
type
:
string
required
:
true
type
:
# Define the parameter type
required
:
true
type
:
string
allowed
:
[
'
int32'
,
'
float'
,
'
boolean'
,
'
enum'
,
'
bitmask'
]
min
:
# Optional minimum value (only for int32 or float)
type
:
number
max
:
# Optional maximum value (only for int32 or float)
type
:
number
unit
:
# Optional parameter unit (only for int32 or float)
# (Extend this list as needed)
type
:
string
allowed
:
[
'
%'
,
'
Hz'
,
'
mAh'
,
'
rad'
,
'
%/rad'
,
'
rad/s'
,
'
bit/s'
,
'
B/s'
,
'
deg'
,
'
deg*1e7'
,
'
deg/s'
,
'
celcius'
,
'
gauss'
,
'
gauss/s'
,
'
mgauss'
,
'
mgauss^2'
,
'
hPa'
,
'
kg'
,
'
kg/m^2'
,
'
mm'
,
'
m'
,
'
m/s'
,
'
m/s^2'
,
'
m/s^3'
,
'
m/s^2/sqrt(Hz)'
,
'
m/s/rad'
,
'
Ohm'
,
'
us'
,
'
ms'
,
'
s'
]
bit
:
# description of all bits for type bitmask.
# The first bit is 0.
type
:
dict
keyschema
:
type
:
integer
valueschema
:
type
:
string
values
:
# enumeration of possible values for type enum
type
:
dict
keyschema
:
type
:
integer
valueschema
:
type
:
string
default
:
# Default value(s). This is an integer or a float,
# or a list of values for multiple instances.
required
:
true
anyof
:
-
type
:
boolean
-
type
:
number
-
type
:
list
minlength
:
1
schema
:
anyof
:
-
type
:
boolean
-
type
:
number
-
type
:
list
category
:
# Optional parameter category
type
:
string
allowed
:
[
'
Developer'
,
'
System'
]
volatile
:
# Optional volatile flag. Set to true if the
# parameter can be changed by the system
# automatially
type
:
boolean
reboot_required
:
# set to true, if changing of the parameter requires
# a reboot to take effect
type
:
boolean
num_instances
:
# Optional number of instances.
# For multiple instances, '${i}' can be used to
# refer to an instance, for example in the parameter
# name or description.
# Default: 1
type
:
integer
min
:
1
instance_start
:
# The value of the first instance for multiple
# instances, used in '${i}'. If 0, ${i} expands to
# [0, N-1]
# Default: 0
type
:
integer
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment