picommon

package
v0.1.1 Latest Latest
Warning

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

Go to latest
Published: Sep 26, 2022 License: AGPL-3.0 Imports: 6 Imported by: 0

Documentation

Overview

Package picommon contains shared information for supported and non-supported pi boards.

Index

Constants

View Source
const ModelName = "pi"

ModelName is the name used refer to any implementation of a pi based component.

Variables

This section is empty.

Functions

This section is empty.

Types

type ServoConfig

type ServoConfig struct {
	Pin      string   `json:"pin"`
	Min      int      `json:"min,omitempty"`
	Max      int      `json:"max,omitempty"`
	StartPos *float64 `json:"starting_position_degs,omitempty"`
	HoldPos  *bool    `json:"hold_position,omitempty"` // defaults True. False holds for 500 ms then disables servo
}

ServoConfig is the config for a pi servo.

func (*ServoConfig) Validate

func (config *ServoConfig) Validate(path string) error

Validate ensures all parts of the config are valid.

Jump to

Keyboard shortcuts

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