motor

package
v0.0.0-...-ab4e8a8 Latest Latest
Warning

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

Go to latest
Published: Jan 23, 2023 License: BSD-3-Clause Imports: 1 Imported by: 0

Documentation

Index

Constants

View Source
const (
	Address              = 0x10
	Forward    Direction = 0x00
	Backward   Direction = 0x01
	MotorRight Motor     = 0x02
	MotorLeft  Motor     = 0x00
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Device

type Device struct {
	Address uint8
	// contains filtered or unexported fields
}

func New

func New(i2c drivers.I2C) *Device

func (*Device) Backward

func (d *Device) Backward()

func (*Device) Configure

func (d *Device) Configure()

func (*Device) Forward

func (d *Device) Forward()

func (*Device) Left

func (d *Device) Left()

func (*Device) Right

func (d *Device) Right()

func (*Device) SetSpeed

func (d *Device) SetSpeed(speed uint8)

func (*Device) SpinLeft

func (d *Device) SpinLeft()

func (*Device) SpinRight

func (d *Device) SpinRight()

func (*Device) Stop

func (d *Device) Stop()

type Direction

type Direction uint8

type Motor

type Motor uint8

Jump to

Keyboard shortcuts

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