watchdogtimer

package module
v0.0.0-...-5dba4c1 Latest Latest
Warning

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

Go to latest
Published: Jul 16, 2019 License: MIT Imports: 7 Imported by: 0

README

go-watchdogtimer

Use the platform specific hardware watchdog timer from your go application.

Documentation

Index

Constants

View Source
const (
	// Default watchdog path
	DefaultWatchdogPath = "/dev/watchdog"

	// Set timeout (in seconds)
	WDIOF_SETTIMEOUT = 0x0080

	// Supports magic close char
	WDIOF_MAGICCLOSE = 0x0100

	// Keep alive ping reply
	WDIOF_KEEPALIVEPING = 0x8000
)

Variables

View Source
var (
	// ErrUnsupported is returned if the given operation is not supported.
	ErrUnsupported = errors.New("operation not supported")
)

Functions

This section is empty.

Types

type Timer

type Timer interface {
	io.Closer

	Pat() error

	Disable() error

	SetTimeout(seconds time.Duration) error

	GetTimeout() (seconds time.Duration, err error)

	GetTimeLeft() (seconds time.Duration, err error)
}

func Open

func Open(name string) (Timer, error)

Open the named platform specific Watchdog timer.

Jump to

Keyboard shortcuts

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