uln28byj

package
v0.26.0 Latest Latest
Warning

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

Go to latest
Published: Apr 29, 2024 License: AGPL-3.0 Imports: 11 Imported by: 0

Documentation

Overview

Package uln28byj implements a GPIO based stepper motor (model: 28byj-48) with uln2003 controler.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	Pins             PinConfig `json:"pins"`
	BoardName        string    `json:"board"`
	TicksPerRotation int       `json:"ticks_per_rotation"`
}

Config describes the configuration of a motor.

func (*Config) Validate

func (conf *Config) Validate(path string) ([]string, error)

Validate ensures all parts of the config are valid.

type PinConfig

type PinConfig struct {
	In1 string `json:"in1"`
	In2 string `json:"in2"`
	In3 string `json:"in3"`
	In4 string `json:"in4"`
}

PinConfig defines the mapping of where motor are wired.

Jump to

Keyboard shortcuts

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