package
0.0.0-20221215221243-b79a0d8da330
Repository: https://github.com/purecloudlabs/gprovision.git
Documentation: pkg.go.dev

# README

CFA - interfaces with CrystalFontz USB LCDs

Known to work with CFA631 and CFA635 LCDs; likely to work with others since the command sets have a lot in common. Your kernel will need the appropriate driver(s) - CDC ACM for newer LCDs, usb-serial for older.

Known issues

Some tests are occasionally flaky, and the test code is rather ugly. I wasn't sure how to fix the ugliness short of removing tests, which doesn't strike me as the best of options.

# Packages

Demo app to exercise a compatible Crystalfontz LCD.
Package serial configures a serial port for use with Crystalfontz LCDs.

# Functions

No description provided by the author
Connect to an lcd given its port name, such as '/dev/ttyACM0'.Stores mutable state so it can be written back later.
Convert done (chan struct{}) to a Time channel.
Preferred method of getting an Lcd{}.
look for usb serial devices that use the cdc or ftdi driver and appear to be Crystalfontz LCDs.
like Find() but tries multiple times.
No description provided by the author
Stuffs incoming data from the serial port into packets.
No description provided by the author
Chooses scrolling type best suited for text size and allowed dims, returnsblurb implementing this.
No description provided by the author
No description provided by the author
NewMockTicker creates a ticker that will provide the given number of ticksand minimum interval between them.
No description provided by the author
like NewTickDistrib, but for testing.
create a TickDistrib with n output channels.
NewTicker creates a Ticker with behavior identical to time.Ticker.
NewTickerFromChan creates a Ticker whose C is the given channel.
No description provided by the author
set up port, init channels, start bg process.
Convert string arg(s) into array of LcdTxt.
Called as factory restore and mfg exit.

# Constants

no choice made - timeout.
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
0 (00).
3 (11).
2 (10).
1 (01).
-2.
No description provided by the author
0x17.
0x06.
0x01.
0x20.
0x00.
0x18.
0x1e.
0x03.
0x05.
0x0e.
0x0b.
0x0c.
0x1f.
Masks the packet type bytes.
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
gradual - sine wave.
abrupt - square wave.
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
12.
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
20.
No description provided by the author
No description provided by the author
No description provided by the author
13.
No description provided by the author
1.
No description provided by the author
No description provided by the author
No description provided by the author
indexes into data returned for Cmd_ReadKeysPolled.
indexes into data returned for Cmd_ReadKeysPolled.
indexes into data returned for Cmd_ReadKeysPolled.
CFA 631: 4 buttons.
CFA 635: 6 buttons.
CFA 635: 6 buttons.
check mark.
CF docs call this KP_CANCEL.
CFA 635: 6 buttons.
CFA 631: 4 buttons.
CFA 631: 4 buttons.
CFA 635: 6 buttons.
CFA 635: 6 buttons.
CFA 631: 4 buttons.
CFA 635: 6 buttons.
CFA 631: 4 buttons.
CFA 635: 6 buttons.
top: blank, check; bottom: down, X.
top: blank, check; bottom: right, X.
top: left, check; bottom: blank, X.
top: left, check; bottom: right, X.
legend is disabled.
No description provided by the author
No description provided by the author
No description provided by the author
AKA Cancel or 'X'.
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
top: up, check; bottom: blank, X.
top: up, check; bottom: down, X.
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
number of re-transmissions before giving up.
pdf says 250mS + OS overhead.
Reports from the LCD.
caret, aka circumflex.
upside-down circumflex.
double down arrow.
double up arrow.
triangular down arrow.
enter key arrow symbol.
all pixels on.
double greater-than (quotation mark in some langs).
symbols for display on LCD.
triangular left arrow.
diagonal arrow lower left.
diagonal arrow lower right.
double less-than (quotation mark in some languages).
triangular right arrow.
all pixels off.
diagonal arrow upper left.
triangular up arrow.
diagonal arrow upper right.

# Variables

packages can use this rather than calling Find() and maintaining a local *Lcd.
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author

# Structs

No description provided by the author
for keymaskToActivity.
No description provided by the author
Only for CFA631.
incoming packets do include the crc.
No description provided by the author
SerialDev translates Crystalfontz-compatible packets into serial byte streams and vice versa.
Spinner is a message + ASCII progress spinner.
A TickDistrib copies each tick on 'in' to all output channels.Used to signal to multiple ui elements that they can update.
can encompass a time.Ticker, or be a mock suitable for testing.

# Interfaces

type passed to Read() and badPacket(); subset of SerialPort.
No description provided by the author
satisfied by github.com/purecloudlabs/gprovision/pkg/log/testlog.

# Type aliases

No description provided by the author
User selection from menu.
A command in a transmitted packet or a response code in a received packet.
No description provided by the author
No description provided by the author
No description provided by the author
Characters to be displayed on the screen.
Type of legend (only has an effect on cfa631).
Codes for legend symbols for overlay.
No description provided by the author
No description provided by the author