Zebra 105SL (Plus) 2-way communications - communication

I have written a printing application that works well. I can write files, update settings and do most all functionality from one console. But one aspect of the program has eluded me for quite a while: the ability to read the Zebra register/configuration values.
It would be good to periodically be able to read the values on the Zebra and compare them to default known good standards and to be able to reset them if necessary.
Currently, in order to see these values, I need to either use the built-in web page (networked printers only), print a report, or scroll through the printer interface. What I really need to is a method to be able to read these registers values and create a known good setup file.
Has anyone been able to find any SDK or trick to read these values using .NET (C# or vb.Net)?
The application is a windows desktop utility used on my shop floor and I communicate with the printers using either LPT and ethernet interfaces (as applicable).

I would recommend checking out the Zebra Link-OS SDK which has a lot of functionality when it comes to what you can do with Zebra printers. Specifically they have a section titled "Getting all printer settings and their configuration". However the code example they provide will not work unless your printer is a Link-OS enabled printer. If that happens to be the case then great! If not you can use the SGD class within the Zebra.SDK.Printer namespace to use Set-Get-Do commands to retrieve and change information. More information on SGD can be found in this ZPL manual under the SGD Printer Commands section.

Related

How iOS detects network printer automatically

POS systems mostly can detect thermal printers automatically, as far as I know there are only two ways for an installed application on ios to do that, either by faking it as an Airprint or going with IPP protocol. Since it mostly matters for those application that your printer should be on the same network and subnet configuration and Airprint doesn't support thermal printers, I believe that could be choice that they are using. But my question is that if there is another way that they are all doing it? if not how an application on ipad(iOS) can detect those printers without any need for specific driver installation? If anyone can help me with this would be great!
To print to printers from iOS you can either use the AirPrint API with AirPrint enabled printers or you can implement the printer's protocol and PDL within your own application.
Some solutions include a third middleware like component to fill the gap between the mobile app and the actual device. This is not an elegant way but seems to work for some usecases.
The full process consists indeed of two steps: discovery (like setup) and actual printing (like sending a document). With AirPrint you can check the documentation to learn how Bonjour aka ZeroConf works.

best way for design and print barcode label from handheld (ce5/compact framework) to zebra mobile printer

What i want is
Design a label layout(barcode on it).
Scan the information by handheld and print the label directly from mobile printer linked with bluetooth.
want to know:
best way to implement this? see my preferences list below
1) free of charge
2) the API should have 2D barcode support
3) label layout can be designed by Drag-and-drop. The best is a visual studio control. so we do not need too much coding.
Hope someone has experience can share some to me, what cotrol? what liberary? Must use zebra specific printing language?
Kindly show a technique chain of the best(easy, free). Thank you all.
You should try and go with the Zebra SDK (for windows ce too). I assume there is no drag and drop GUI designer tool. But you may examine the code generated by a label designer application printing to a zebra printer using file: as output port.
Zebra provides good SDKs, samples and support. For example to print a QR code:
^XA^FO100,100^BQN,2,10^FDYourTextHere^FS^XZ
You see, it is more or less readable where to replace text to get another QR barcode.
see also https://km.zebra.com/kb/index?page=content&channel=SAMPLE_CODE
You may need to study the ZPL programmers guide and then you can start to print your own mind-designed labels. Printing meeans to send ZPL code lines directly to the printer.

Creating a virtual printer as an interface for a document management system

I would like to know if the following idea is possible/makes sense?
Create a virtual printer (like "PDF Printer" that any application with printing capabilities can see in the printers list) that doesn't print to paper or file, but simply inserts the document "being printed" in the document management system (DMS) I developed. Imagine from MSWord i choose "MyPrinter" and on "print" my custom forms appear and let the user choose where to save the doc file inside my DMS, letting the user set some parameters (related to my DMS).
So after these "forms" I have all the data needed to insert the file in the DMS.
I am aware this is somehow "in the tricks domain" but it is the only choice to integrate my app with some legacy software (with printing capability) that cannot be repalced.
I'd like to have a comment on this.
Creating a virtual printer is a very technical task. You will have to write a device driver, which is not directly possible with Delphi (even if there are some code in the Net).
There are several components able to do this: they consist in an already developed printer driver, with some general API to be called from other languages, including Delphi.
I found out that EMFPrinterPilot from ColorPilot could be a good start. Your Delphi application may be able to retrieve the Text (for indexing), PDF (for archiving) and even EMF (for display / reprint).

What does a printer driver do? How to intercept/get the data/command it sends to the printer?

What does a printer driver do? For example, when I open a word document, and use File->Print to print the document: what does the printer driver do? Will it convert the .doc document to PostScript, append some printer commands, and then send to the printer?
Another question is how to intercept the data/command the printer driver send to the printer with software, under windows or *nix.
Simply put, a Windows printer driver is a library which implements a Windows-defined interface of device-independent imaging commands, and another interface of communication to devices like printers. Upon receiving calls from the imaging commands interface, it generates a device-specific print file, and sends it to the communications interface.
In the case of the PostScript printer driver, the driver consists of a shared device-independent part which does most of the conversion of imaging commands to PostScript language code, and a device-dependent part which has the data about the paper sizes and capabilities of a particular printer model. This division, and the fact that the shared part is shared, isn't particularly visible to the user.
These printing related interfaces are not simple. Two places to start learning about them are Introduction to Printing, by the Microsoft Dev Center, and the article Windows Driver Model, at Wikipedia
It is possible to intercept the data and send it elsewhere, either at the imaging commands interface or the communications interface. However, it's not a simple task. It requires learning the printing system and its APIs, as in the references above.

How to print (barcode) labels from a Ruby on Rails Application?

My first application I have developed in RoR is for some Kiosk Touchscreen PCs used in our stock. When the stock worker picked up some material he enters the quantity in a Form.
Now I want to print a label containing: customer name, material description, quantity, and a barcode on our Zebra printer.
How would I do that from a Ruby on Rails Application ?
Sending directly the control chars needed for ZPL (Zebra Printer Language) from the controller ? ( not very comfortable )
Create a view in HTML send it to the client, and the client has to print it. ( not very confortable and error prone, as the stock worker has to do additional steps, may choose the wrong printer or maybe don't print the label at all )
Create a pdf document from the controller and send it to the printer from the server ( oh, no the printer does not understand pdf, so I have to control a pdf reader to do the printing ?? That wouldn't be very fast as it will send the label as a graphic image to the printer
Create a gem which will hide all the logic needed for printing ? ( Are there any gems which already do this ? )
I would appreciate every comment.
Thanks
Klaus
I would send the raw ZPL to the printer. You can use a tool like Bartender (I would suggest installing Bartender Only from that link. You can basically design your label in this tool. After you've designed your label you would download the bartender printer drivers for your zebra printer and set up a dummy printer with these drivers and print this label you designed to a file. This will give you the raw zpl. From this you can basically substitute all the dynamic data into the zpl file you printed in the previous step and send this directly to the printer via serial, tcp/ip or usb.
Edit: I found a much better solution as I continued to dig on this. This is pretty significantly edited down to focus on the Java applet solution I ended up using.
Basically, you will generate the label as raw ZPL text. You then need to get that plain text to the printer, which will generate the label.
If your server can access the printer's IP address, you can copy the ZPL to the printer directly from the server process. If it's a remote web app, you need to get the client to send the ZPL for you. Browser sandboxing makes this hard to pull off - drivers want to helpfully get in the way. There are a few options; the most common is to use a small Java or Flash applet to do the actual copying. If you can get the specific web browser your users are using to print to a plain text printer without adding anything, you could use local printing, but generally the most robust approach is to use a helper Java applet.
The Java applet I use for this is jZebra: http://code.google.com/p/jzebra/
It's a very clean & straightforward approach, look at the sample HTML in the download package and a few lines of code print the label. I just edited down the sample and am planning to use it as my production code popup.. it's really that straightforward.
Two caveats with this approach:
Your users must have the JRE installed
jZebra finds the Zebra printer by printer name. There are very specific guides (they have detailed instructions for Mac, Windows, and Linux setup) for what you need to do - but it's well documented and you just have to have your users follow the instructions. Once it's set up correctly it works great.
More simple solution, and I believe better as well, Usually most of browser and machines has PDF viewer installed. So just create labels as PDF documents and sent it to browser.
We have implemented label printing using Zebra printer in ROR following way.
Create exact format label pages in html.
Convert the html to pdf using wickedPDF.
Usually labels contains barcodes as well.
So overall solution would be,
Create barcodes using barbie gem.
Create html using barcodes and your actuall data that needs to go on label.
Convert html view to PDF.
Sounds like a job for a ruby C extension. Perhaps one that also wraps something like gnu barcode http://www.gnu.org/software/barcode/ library and some other open standard for the zebra printer, if one exists? I once did a rails app that made coupons and made heavy use of gnu barcode, but I did simple shell command to interface to it.

Resources