ESC-POS-.NET icon indicating copy to clipboard operation
ESC-POS-.NET copied to clipboard

USB not working

Open danielegithub opened this issue 2 years ago • 1 comments

Hi everyone. Has anyone encountered the same error?

public SerialPrinter Printer { get; set; }

    public PosCommand()
    {
        this.Printer = new SerialPrinter(portName: "USB0001", baudRate: 115200);
    }

and have exception "The given port name (USB001) does not resolve to a valid serial port. (Parameter Portname).

My ports is configured as "Port: USB001" and Description "Virtual printer port for USB".

Thank

danielegithub avatar Feb 03 '23 11:02 danielegithub

This library uses System.Io.Ports. That exception is probably being thrown by the MS library. Normally the virtual COM ports are mapped to the normal serial port names (like COM6 or something). Does your virtual port driver support that?

lukevp avatar Feb 25 '23 19:02 lukevp