pn532uart

package
v2.6.2 Latest Latest
Warning

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

Go to latest
Published: Sep 17, 2025 License: GPL-3.0 Imports: 18 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrAckTimeout   = errors.New("timeout waiting for ACK")
	ErrNoFrameFound = errors.New("no frame found")
)

Functions

func InDataExchange

func InDataExchange(port serial.Port, data []byte) ([]byte, error)

func SamConfiguration

func SamConfiguration(port serial.Port) error

Types

type FirmwareVersion

type FirmwareVersion struct {
	Version          string
	SupportIso14443a bool
	SupportIso14443b bool
	SupportIso18092  bool
}

func GetFirmwareVersion

func GetFirmwareVersion(port serial.Port) (FirmwareVersion, error)

type GeneralStatus

type GeneralStatus struct {
	LastError    byte
	FieldPresent bool
}

func GetGeneralStatus

func GetGeneralStatus(port serial.Port) (GeneralStatus, error)

type PN532UARTReader

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

func NewReader

func NewReader(cfg *config.Instance) *PN532UARTReader

func (*PN532UARTReader) CancelWrite

func (*PN532UARTReader) CancelWrite()

func (*PN532UARTReader) Capabilities

func (*PN532UARTReader) Capabilities() []readers.Capability

func (*PN532UARTReader) Close

func (r *PN532UARTReader) Close() error

func (*PN532UARTReader) Connected

func (r *PN532UARTReader) Connected() bool

func (*PN532UARTReader) Detect

func (*PN532UARTReader) Detect(connected []string) string

func (*PN532UARTReader) Device

func (r *PN532UARTReader) Device() string

func (*PN532UARTReader) IDs

func (*PN532UARTReader) IDs() []string

func (*PN532UARTReader) Info

func (r *PN532UARTReader) Info() string

func (*PN532UARTReader) Metadata

func (*PN532UARTReader) OnMediaChange

func (*PN532UARTReader) OnMediaChange(*models.ActiveMedia) error

func (*PN532UARTReader) Open

func (r *PN532UARTReader) Open(device config.ReadersConnect, iq chan<- readers.Scan) error

func (*PN532UARTReader) Write

func (*PN532UARTReader) Write(_ string) (*tokens.Token, error)

type Target

type Target struct {
	Type     string
	UID      string
	UIDBytes []byte
}

func InListPassiveTarget

func InListPassiveTarget(port serial.Port) (*Target, error)

Jump to

Keyboard shortcuts

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