Documentation ¶
Index ¶
- type Commander
- func (o *Commander) DisableLights() error
- func (o *Commander) DisableTemperatureLogging() error
- func (o *Commander) EnableTemperatureLogging() error
- func (o *Commander) GetGrillLights(params *lights.GetGrillLightsParams) (*models.LightStrip, error)
- func (o *Commander) GetName() string
- func (o *Commander) GetStrip() hardware.WS2801
- func (o *Commander) IsRunning() bool
- func (o *Commander) ShutdownSystem(params *system.ShutdownParams) (*models.Shutdown, error)
- func (o *Commander) StartBackground() error
- func (o *Commander) StopBackground() error
- func (o *Commander) UpdateGrillLights(params *lights.UpdateGrillLightsParams) (bool, error)
- type LightShow
- type RunnableIFC
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Commander ¶
type Commander struct { Options *framework.CmdOptions // contains filtered or unexported fields }
Commander is the main controller of all background goroutines
func NewCommander ¶
func NewCommander() *Commander
NewCommander creates a Commander instance which can be used to query and control all background processes. e.g: Temperature logger, temperature monitor
func (*Commander) DisableLights ¶
func (*Commander) DisableTemperatureLogging ¶
func (*Commander) EnableTemperatureLogging ¶
func (*Commander) GetGrillLights ¶
func (o *Commander) GetGrillLights(params *lights.GetGrillLightsParams) (*models.LightStrip, error)
func (*Commander) IsRunning ¶
func (o *Commander) IsRunning() bool
IsRunning returns the internal state representing if the main loop is running or not.
func (*Commander) ShutdownSystem ¶
func (*Commander) StartBackground ¶
func (o *Commander) StartBackground() error
startBackground starts the main loop of the runner resulting the the given tickableIFC being executed on the default Ticker schedule
func (*Commander) StopBackground ¶
func (o *Commander) StopBackground() error
StopBackground causes the background goroutine to exit
func (*Commander) UpdateGrillLights ¶
func (o *Commander) UpdateGrillLights(params *lights.UpdateGrillLightsParams) (bool, error)
type RunnableIFC ¶
type RunnableIFC interface { // StartBackground starts the runnable in a goroutine StartBackground() error // StopBackground stops the background goroutine StopBackground() error // IsRunning determines if the main loop is executing IsRunning() bool }
RunnableIFC objects are executed in the background by a runner
Click to show internal directories.
Click to hide internal directories.