android - Command not being understood by Zebra iMZ320 -


i'm trying print label android app zebra printer (imz 320) seems not understanding command line.

when try sample code, printer prints commands paper send them printer:

zebraprinterconnection.write("^xa^fo50,50^adn,36,20^fdhello^fs^xz".getbytes()); 

i've read zpl programming tutorial zebra's official website, can't figure out how make printer work right zpl commands.

the zebra imz may ship in line print mode. means not parse , interpret zpl commands have provided, rather, print them. you'll need configure printer zpl mode instead of line print mode. following command should it:

! u1 setvar "device.languages" "zpl"

note: in cases may have set language "hybrid_xml_zpl" instead of "zpl"

notice need include newline character (or carriage return) @ end of command. can use zebra setup utilities send commands directly printer through 'communication' perspective, available hitting 'communication' button on main screen.

zebra setup utilities: http://www.zebra.com/us/en/products-services/software/manage-software/zebra-setup-utility.html

zpl manual page 705 (details command such 1 listed above): https://support.zebra.com/cpws/docs/zpl/zpl_manual.pdf


Comments

Popular posts from this blog

Why does Ruby on Rails generate add a blank line to the end of a file? -

keyboard - Smiles and long press feature in Android -

node.js - Bad Request - node js ajax post -