Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Command ¶
type Command = uint8
Command is a command that can be sent to the printer
const ( // CommandInit is the command to initialize the printer CommandInit Command = 0x01 // CommandStart is the command to start printing CommandStart Command = 0x02 // CommandData is the command to send data to the printer CommandData Command = 0x04 // CommandStatus is the command to get the status of the printer CommandStatus Command = 0xF )
type CommandPosition ¶
type CommandPosition uint8
CommandPosition is the position of the command in the command sequence
const ( // CommandPositionMagic1 is the first magic byte CommandPositionMagic1 CommandPosition = 0x00 // CommandPositionMagic2 is the second magic byte CommandPositionMagic2 CommandPosition = 0x01 // CommandPositionID is the ID of the command CommandPositionID CommandPosition = 0x02 // CommandPositionCompression is the compression flag CommandPositionCompression CommandPosition = 0x03 // CommandPositionLengthLow is the low byte of the length CommandPositionLengthLow CommandPosition = 0x04 // CommandPositionLengthHigh is the high byte of the length CommandPositionLengthHigh CommandPosition = 0x05 // CommandPositionData is the data of the command CommandPositionData CommandPosition = 0x06 // CommandPositionChecksumLow is the low byte of the checksum CommandPositionChecksumLow CommandPosition = 0x07 // CommandPositionChecksumHigh is the high byte of the checksum CommandPositionChecksumHigh CommandPosition = 0x08 // CommandPositionKeepAlive is the keep alive flag CommandPositionKeepAlive CommandPosition = 0x09 // CommandPositionStatus is the status byte CommandPositionStatus CommandPosition = 0x0A )
func (CommandPosition) String ¶
func (c CommandPosition) String() string
type Printer ¶
type Printer struct {
// contains filtered or unexported fields
}
func NewPrinter ¶
func NewPrinter() *Printer
func (*Printer) GetPrintJob ¶
func (*Printer) HasPrintJob ¶
func (*Printer) PrintStashed ¶
func (p *Printer) PrintStashed()
Click to show internal directories.
Click to hide internal directories.