Skip to content

brother-ql


brother-ql / node/src / BrotherQLDiscovery

Class: BrotherQLDiscovery ​

PrinterDiscovery implementation for Brother QL printers.

listPrinters() is the USB enumeration plus one SNMP broadcast on the local subnets. Network printers open by host: the model comes from SNMP (hrDeviceDescr) because port 9100 carries no model or status signal, and deviceKey overrides that. A printer in Editor Lite (mass-storage) mode exposes a PID outside the registry, so it is simply absent from the USB list.

Implements ​

Constructors ​

Constructor ​

new BrotherQLDiscovery(options?): BrotherQLDiscovery

Parameters ​

options? ​

BrotherQLDiscoveryOptions = {}

Returns ​

BrotherQLDiscovery

Properties ​

family ​

readonly family: "brother-ql" = 'brother-ql'

Driver family identifier — matches DeviceEntry.family.

Implementation of ​

PrinterDiscovery.family

Methods ​

listMedia() ​

listMedia(): readonly MediaDescriptor[]

The driver's media registry, for callers that must let a user pick media by id or name instead of relying on getStatus().detectedMedia (a CLI --media flag; network printers whose media cannot be detected). Optional: drivers without a media catalog omit it, and callers report driver <family> does not expose a media catalog. (Code span on purpose: typedoc emits the text raw and VitePress reads a bare <family> as an unclosed element.)

Returns ​

readonly MediaDescriptor[]

Implementation of ​

PrinterDiscovery.listMedia


listPrinters() ​

listPrinters(): Promise<DiscoveredPrinter[]>

List connected printers on this driver's supported transports.

Returns ​

Promise<DiscoveredPrinter[]>

Implementation of ​

PrinterDiscovery.listPrinters


openPrinter() ​

openPrinter(options?): Promise<BrotherQLPrinter>

Open a printer matching the given options.

If no options are provided, opens the first available printer.

Parameters ​

options? ​

BrotherQLOpenOptions = {}

Returns ​

Promise<BrotherQLPrinter>

Implementation of ​

PrinterDiscovery.openPrinter