This repository has been archived on 2025-08-11. You can view files and clone it, but cannot push or open issues or pull requests.
Files
PKGBUILD/pkg/sensor/interfaces.go

16 lines
419 B
Go

package sensor
import (
"context"
"sync"
"github.com/go-flucky/flucky/pkg/types"
)
type Sensor interface {
GetSensorModel() types.SensorModel
Read() ([]types.MeasuredValue, error)
ReadChannel(measuredValuesChannel chan<- []types.MeasuredValue, errorChannel chan<- error, wg *sync.WaitGroup)
ReadContinously(ctx context.Context, measuredValuesChannel chan<- []types.MeasuredValue, errorChannel chan<- error)
}