Console Integration
Plato Console uses theWIN_DRIVER printer adapter for the PC printer driver.
Printer Record
Console stores printers in an IndexedDB database namedprinter-database.
Printer records include:
- printer type
- status
- last error
- config
- paper width
- categories
- order types
- logo
Driver URL
TheWIN_DRIVER adapter builds its base URL from printer config:
driverPort is empty, the adapter omits the port. This is useful for HTTPS on port 443.
Printer Target
The adapter sends the physical printer target separately from the driver URL.
If the printer IP is missing or equals
192.168.0.0, the adapter sends ip_address: null and port: null, which the current driver rejects with Missing printer address.
Vendor IDs
The adapter maps vendors:Print Preparation
Console print flow:- Render DOM to PNG blob.
- Load blob into canvas.
- Convert canvas pixels to black/white raster rows.
- Split raster rows into 128-row chunks.
- Encode each chunk as ESC/POS raster bytes.
- Base64 encode each byte chunk.
- Send
POST /print.
Browser Queue
Console has a local browser queue before requests reach the PC driver.- Jobs are stored in IndexedDB.
- Jobs move from
pendingtoprinting. - Failed jobs are marked
failed. - A stale
printingjob is recovered after 60 seconds. - Scheduled jobs are checked every 30 seconds.
- Failed jobs are retried every 60 seconds.
Status Mapping
Console callsPOST /status.
- HTTP failure returns
OFFLINE. - Response with
ok: trueandstatusnotofflinereturnsONLINE. - Other driver responses are stored as
lastError.
Cash Drawer
Console callsPOST /cash-drawer for every online printer configured with a cash drawer.