embd: github.com/kidoman/embd/interface/keypad/matrix4x3 Index | Files

package matrix4x3

import "github.com/kidoman/embd/interface/keypad/matrix4x3"

Package matrix4x3 allows interfacing 4x3 keypad with Raspberry pi.

Index

Package Files

matrix4x3.go

type Key Uses

type Key int
const (
    KNone Key = iota
    K0
    K1
    K2
    K3
    K4
    K5
    K6
    K7
    K8
    K9
    KStar
    KHash
)

func (Key) String Uses

func (k Key) String() string

type Matrix4x3 Uses

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

A Matrix4x3 struct represents access to the keypad.

func New Uses

func New(rowPins, colPins []int) (*Matrix4x3, error)

New creates a new interface for matrix4x3.

func (*Matrix4x3) Close Uses

func (d *Matrix4x3) Close()

Close.

func (*Matrix4x3) PressedKey Uses

func (d *Matrix4x3) PressedKey() (key Key, err error)

Pressed key returns the current key pressed on the keypad.

func (*Matrix4x3) Run Uses

func (d *Matrix4x3) Run()

Run starts the continuous key scan loop.

func (*Matrix4x3) SetPollDelay Uses

func (d *Matrix4x3) SetPollDelay(delay int)

SetPollDelay sets the delay between run of key scan acquisition loop.

Package matrix4x3 imports 4 packages (graph). Updated 2016-07-16. Refresh now. Tools for package owners.