Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrRegisterNotFound = errors.New("register not found")
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config interface {
Chip() string
InputDebounce() time.Duration
// InputOptions are used to configure the pin.
// Valid options: WithBiasDisabled, WithPullDown, WithPullUp
InputOptions() []string
// OutputOptions are used to configure the pin.
// Valid options: AsOpenDrain, AsOpenSource, AsPushPull
OutputOptions() []string
Inputs() []Pin
Outputs() []Pin
}
type DeviceStruct ¶
func NewDevice ¶
func NewDevice( deviceConfig device.Config, gpioConfig Config, stateStorage *dataflow.ValueStorage, commandStorage *dataflow.ValueStorage, ) (*DeviceStruct, error)
func (*DeviceStruct) Model ¶
func (d *DeviceStruct) Model() string
type GpioRegister ¶
type GpioRegister struct {
dataflow.RegisterStruct
// contains filtered or unexported fields
}
func (GpioRegister) String ¶
func (r GpioRegister) String() string
Click to show internal directories.
Click to hide internal directories.