First, be sure to put your ZQ520 printer into ZPL mode.
This can be done programmatically by sending the following command to the printer:
! U1 setvar “device.languages” “zpl” <cr> <lf>
You would then need to convert the PDF into a black and white PNG file.
I’m not sure if you can do this natively in the Windows phone environment, you may need to use a third-party library or SDK.
Then convert your PNG File and convert it to either Hexadecimal or binary data and wrap it in ~DY ZPL command.
More information on the ~DY command can be found in the ZPL Programming Guide:
Hope this helps.
Thank you so much for this info!
I was able to get this work in ZQ520.
Unfortunately the same is not working on zebra RW 420. When I tried to print the png I get a blank label. Please could you help me with this?
Your help is much appreciated!!
You are most welcome.
Your RW420 may need to be calibrated for ZPL printing.
Send the following command to it:
The printer should then feed a few label and then stop at a gap.
Tap the feed button a few times to verify that the printer is feeding one label at a time, stopping at a gap.
Then save your calibration settings by sending the following command:
You should then get some output to show up on the label the next time you send your ZPL data to it.
Thank you for your response!
I tried these steps but couldn't able to print png. I am able to print simple ZPL commands though. I have attached the ZPL that I am trying from my end. Please could you have a look and tell me if I am doing anything wrong. (The same is working fine in ZQ520).
Below ZPL is printing fine. The problem is with png printing only,
Script.txt.zip 3.8 K
So it turns out that the ZPL emulator on the RW420 supports a limited portion of ZPL. The ~DY command is one of those unsupported commands.
When it comes to printing images on the RW420, it is best to use CPCL.
The ZQ520 printer also accepts CPCL so if you are printing to both printer models, you design your label format in CPCL.
The CPCL programming guide can be found here:
Look up the EG command as it will explain how to send image data to the printer.
Hope this helps,
The EG is not working either as the image we are using is too large. Its working if I try with small images.
Is there any other option to print large size images to RW420?
If PCX is an option, Is it possible to send PCX images dynamically through commands? It would be great if you can point me to some samples.
Instead of converting the pdf into a png, convert it into a pcx file.
Then send the pcx data wrapped in the PCX command.