mcp4921

package
v0.0.0-...-b9caf1c Latest Latest
Warning

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

Go to latest
Published: Jun 18, 2020 License: MIT Imports: 3 Imported by: 1

Documentation

Index

Constants

View Source
const (
	//EnumBufferedTrue Buffer the output registers
	EnumBufferedTrue EnumBuffered = 1
	//EnumBufferedFalse Do not buffer the output register
	EnumBufferedFalse EnumBuffered = 0

	//EnumOutputGain1x Set output to (1 * VREF) * input
	EnumOutputGain1x EnumOutputGain = 1
	//EnumOutputGain2x Set output to (2 * VREF) * input
	EnumOutputGain2x EnumOutputGain = 0

	//EnumShutdownModeActive Enable Vout when shut down
	EnumShutdownModeActive EnumShutdownMode = 1
	//EnumShutdownModeHighImpedence Set Vout to high impedence when shut down (500k typical)
	EnumShutdownModeHighImpedence EnumShutdownMode = 0
)

Variables

This section is empty.

Functions

This section is empty.

Types

type EnumBuffered

type EnumBuffered int

EnumBuffered ..

type EnumOutputGain

type EnumOutputGain int

EnumOutputGain ..

type EnumShutdownMode

type EnumShutdownMode int

EnumShutdownMode ..

type Mcp4921

type Mcp4921 struct {
	// contains filtered or unexported fields
}

Mcp4921 ..

func NewMcp4921

func NewMcp4921(spi spi.Conn, label string, buffered EnumBuffered, outputGain EnumOutputGain, shutdownMode EnumShutdownMode) (*Mcp4921, error)

NewMcp4921 ..

func (*Mcp4921) Label

func (e *Mcp4921) Label() string

Label ..

func (*Mcp4921) Write

func (e *Mcp4921) Write(value uint16) error

Write ..

Jump to

Keyboard shortcuts

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