feat: add support for seesaw encoders

Adds the necessary function addresses for reading and writing encoders on a seesaw.
Also provides two helper functions to make this easier.
This commit is contained in:
JP Hastings-Spital
2025-06-30 15:30:11 +01:00
committed by deadprogram
parent a31ba26a6c
commit 857ab80ae6
4 changed files with 94 additions and 0 deletions
+10
View File
@@ -98,3 +98,13 @@ const (
FunctionKeypadCount FunctionAddress = 0x04
FunctionKeypadFifo FunctionAddress = 0x10
)
// encoder module function address registers
// these are the defaults for encoder 0, change the lower nibble to address other encoders
// see the Device.GetEncoderPosition and SetEncoderPosition methods for examples.
const (
FunctionEncoderIntenset FunctionAddress = 0x10
FunctionEncoderIntenclr FunctionAddress = 0x20
FunctionEncoderPosition FunctionAddress = 0x30
FunctionEncoderDelta FunctionAddress = 0x40
)