sensor

package
v0.0.0-...-5657e6c Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 7, 2022 License: GPL-3.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Sensor

type Sensor interface {
	ID() string
	Read() (units.Temperature, time.Time)
	Subscribe() <-chan units.Temperature
}

func New

func New(name string, cfg config.SensorConfig) (Sensor, error)

func NewW1Sensor

func NewW1Sensor(name, id string) Sensor

type SettableSensor

type SettableSensor interface {
	Sensor
	Set(units.Temperature, time.Time)
}

func NewPushSensor

func NewPushSensor(name, id string) SettableSensor

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL