scanner

package
v1.0.2 Latest Latest
Warning

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

Go to latest
Published: Sep 21, 2023 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Scanner

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

Scanner describes the symbol scanner device

func New

func New(deviceInfo hid.DeviceInfo) (*Scanner, error)

New takes a HID device info and returns a Scanner with the opened device

func (*Scanner) Device

func (s *Scanner) Device() *hid.Device

Device returns the real device

func (*Scanner) ReadCodes

func (s *Scanner) ReadCodes(ctx context.Context) <-chan *code.Code

ReadCodes starts a code read loop and returns a channel that recieves new codes

Jump to

Keyboard shortcuts

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