zplCore.comzplCore.com

ParallelPrinterConnection

public sealed class ParallelPrinterConnection : IPrinterConnection, IAsyncDisposable

Parallel (Centronics/IEEE 1284) port. Writes to the port device: "LPT1".."LPT9" on Windows (or a spooler printer shared on that port), /dev/lp0 / /dev/usb/lp0 on Linux; "LPTn" is mapped to /dev/lp{n-1} on Linux. Write-only.

Constructors

SignatureDescription
# ParallelPrinterConnection(string port = "LPT1")

Properties

PropertyTypeDescription
DevicePath { get; }stringThe device path written to.
Port { get; }string

Methods

Method SignatureReturnsDescription
# DisposeAsync()ValueTask
# QueryAsync(string command, TimeSpan timeout, CancellationToken ct = default)Task<string>
static # ResolveDevicePath(string port, bool windows)stringMaps "LPTn" to the OS device path.
# SendAsync(byte[] data, CancellationToken ct = default)Task