Add (semi-experimental) support for multiple deadzones and deadzones that emit a fixed value.
This commit is contained in:
parent
8a903e0703
commit
2e8c2c5404
8 changed files with 246 additions and 178 deletions
33
internal/configparser/ruletarget.go
Normal file
33
internal/configparser/ruletarget.go
Normal file
|
|
@ -0,0 +1,33 @@
|
|||
package configparser
|
||||
|
||||
type RuleTargetConfigButton struct {
|
||||
Device string
|
||||
Button string
|
||||
Inverted bool
|
||||
}
|
||||
|
||||
type RuleTargetConfigAxis struct {
|
||||
Device string
|
||||
Axis string
|
||||
Inverted bool
|
||||
Deadzones []DeadzoneConfig
|
||||
}
|
||||
|
||||
type DeadzoneConfig struct {
|
||||
Center int32 `yaml:"center,omitempty"`
|
||||
Size int32 `yaml:"size,omitempty"`
|
||||
SizePercent int32 `yaml:"size_percent,omitempty"`
|
||||
Start int32 `yaml:"start,omitempty"`
|
||||
End int32 `yaml:"end,omitempty"`
|
||||
Emit bool `yaml:"emit,omitempty"`
|
||||
Value int32 `yaml:"emit_value,omitempty"`
|
||||
}
|
||||
|
||||
type RuleTargetConfigRelaxis struct {
|
||||
Device string
|
||||
Axis string
|
||||
}
|
||||
|
||||
type RuleTargetConfigModeSelect struct {
|
||||
Modes []string
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue