ioman

package
v0.0.0-...-f35197a Latest Latest
Warning

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

Go to latest
Published: Jun 18, 2020 License: MIT Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ADC

type ADC struct {
	Vals      []uint16
	Timestamp time.Time
	Err       error
}

ADC ..

type Calculated

type Calculated struct {
	FlowIntegrated          float64
	FlowIntegratedTimestamp time.Time
}

Calculated ..

type DataPacket

type DataPacket struct {
	Valid      bool
	Timestamp  time.Time
	Sensors    Sensors
	Calculated Calculated
	State      EnumState
	Stats      Stats
}

DataPacket ..

type EnumState

type EnumState int

EnumState ..

const (
	//StateError ..
	StateError EnumState = iota
	//StateBreathingIn ..
	StateBreathingIn
	//StateRest ..
	StateRest
)

func (EnumState) String

func (e EnumState) String() string

type Flow

type Flow struct {
	Val       float64
	CRC       uint8
	Err       error
	Timestamp time.Time
}

Flow ..

type IOMan

type IOMan struct {
	// contains filtered or unexported fields
}

IOMan ..

func NewIOMan

func NewIOMan() (*IOMan, error)

NewIOMan ..

func (*IOMan) Destroy

func (*IOMan) Destroy()

Destroy ..

func (*IOMan) GetDataPacket

func (io *IOMan) GetDataPacket() DataPacket

GetDataPacket ..

func (*IOMan) Start

func (io *IOMan) Start(cherr chan<- error)

Start ..

type Sensors

type Sensors struct {
	Flow Flow
	ADC  ADC
}

Sensors ..

type Stats

type Stats struct {
	OkReads     uint64
	FailedReads uint64
}

Stats ..

Jump to

Keyboard shortcuts

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