PyramidTechnologies / ThermalTalk

Reliance Thermal Printer API
MIT License
10 stars 2 forks source link

Printing 2Dbarcode on Phoenix printer #2

Closed stevan-borus closed 4 years ago

stevan-borus commented 4 years ago

I am not sure why this is happening but when I call the method

public override void Print2DBarcode(string encodeThis)
        {
            var len = encodeThis.Length > 154 ? 154 : encodeThis.Length;
            var setup = new byte[] { 0x1D, 0x28, 0x6B, (byte)len, 0x00, 0x31, 0x50 };
            var printit = new byte[] { 0x1D, 0x28, 0x6B, 0x03, 0x00, 0x31, 0x51, 0x31 };

            var fullCmd = Extensions.Concat(setup, Encoding.ASCII.GetBytes(encodeThis), printit);
            internalSend(fullCmd);
        }

the printer doesn't print the barcode. Instead, it prints the string that is passed as parameter with P at the beggining and Q1 at the end (something like P1234Q1 if "1234" is passed as a parameter)

corytodd commented 4 years ago

What firmware and model Phoenix are you using? The model can be found on the sticker on the bottom of the printer. The firmware revision can be found using Phoenix Tools. https://pyramidacceptors.com/app

stevan-borus commented 4 years ago

I have downloaded PHXv119.PTI file and updated the printer with Phoenix Tools using that file. The model of the printer is PHX-POG (12 volts dc if that is of any relevance)

corytodd commented 4 years ago

Ah, ok. POG means pot-of-gold which is a serial protocol that does not include esc/pos. QR codes will not work on this model. Please contact support@pyramidacceptors.com for information on esc/pos printers.