Documentation ¶
Index ¶
Constants ¶
View Source
const FanControl = 18
View Source
const LedClock int = 14
View Source
const LedData int = 15
View Source
const MaxTemp = 80
View Source
const MinTemp = 35
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct { Port int CpuOffThreshold float64 CpuOnThreshold float64 OffThreshold float64 OnThreshold float64 ExtendedColors bool Delay uint64 Brightness float64 Verbose bool }
func LoadConfig ¶
func LoadConfig() *Config
type FakeFanshim ¶
type FakeFanshim struct { }
func (*FakeFanshim) Cleanup ¶
func (f *FakeFanshim) Cleanup()
func (*FakeFanshim) Off ¶
func (f *FakeFanshim) Off()
func (*FakeFanshim) On ¶
func (f *FakeFanshim) On()
func (*FakeFanshim) SetColor ¶
func (f *FakeFanshim) SetColor(color colorful.Color)
type Fanshim ¶
type Fanshim interface { On() Off() SetColor(color colorful.Color) Cleanup() }
func NewFakeFanshim ¶
func NewFakeFanshim() Fanshim
func NewGPIOFanshim ¶
func NewGPIOFanshim() Fanshim
type FanshimController ¶
type FanshimController struct {
// contains filtered or unexported fields
}
func NewController ¶
func NewController(config *Config, fanshim Fanshim) *FanshimController
func (*FanshimController) Cleanup ¶
func (f *FanshimController) Cleanup()
func (*FanshimController) Update ¶
func (f *FanshimController) Update(temperature, cpu float64)
type GPIOFanshim ¶
type GPIOFanshim struct {
// contains filtered or unexported fields
}
func (*GPIOFanshim) Cleanup ¶
func (f *GPIOFanshim) Cleanup()
func (*GPIOFanshim) Off ¶
func (f *GPIOFanshim) Off()
func (*GPIOFanshim) On ¶
func (f *GPIOFanshim) On()
func (*GPIOFanshim) SetColor ¶
func (f *GPIOFanshim) SetColor(color colorful.Color)
Click to show internal directories.
Click to hide internal directories.