×
INTELLIGENT WORK FORUMS
FOR COMPUTER PROFESSIONALS

Log In

Come Join Us!

Are you a
Computer / IT professional?
Join Tek-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!

*Tek-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Students Click Here

printing barcodes in linux

printing barcodes in linux

printing barcodes in linux

(OP)
My company needs a solution to print barcodes on our orders for the warehouse to scan.  We were considering buying a barcode DIMM for our HP printers but were hoping for a software solution.  I'm not sure if this is possible but it would basically need to print a plain text file and have certain characters turned into a bar code.   Is this possible?  

thanks
Ryan

RE: printing barcodes in linux

You can certainly download a soft font to the printer, and print the barcode.

Depending on the barcode symbology you use, you may have to calculate a checksum that becomes included in the barcode data.

What application will generate the data?

Jim Asman
jlasman@telus.net

RE: printing barcodes in linux

(OP)
The application is called Southware (it is our accounting/inventory software that runs the company).  Basically it uses a text file as a template.  This text file has all kinda of tags/code to layout the file.  So I would need to be able to put a tag of some sort in this file to make it print the bar code.  I'm really not exactly sure how this works at all.  I thought maybe there was a program (hopefully free) which would let us do this without buying the DIMMs (as we'd like to be able to print to any printer in the building).  

thanks for the quick reply.

RE: printing barcodes in linux

Well the DIMMs really don't do any more for you than a soft font. In fact the soft font is better as it can be downloaded to any laser printer, whereas, the DIMM is obviously dedicated to a single printer.

What I usually do is to download the barcode font and designate it as the secondary font. Then when it is time to pint a barcode, issue the 1 byte command to switch to the secondary, print the data, and then another one byte command to jump back to the primary font.

It is really an issue of the ability your application to inject the necessary codes in a timely manner that is central. If you can work with a 3of9 barcode, then you won't have to worry about the checksum.

Jim Asman
jlasman@telus.net

RE: printing barcodes in linux

(OP)
Hmm I don't know if it can do that.  I'm a Linux novice so I don't really have any idea how to go about this.  Is it possible to just print a text file (say from VI) and insert codes that would make the barcode print?  

thanks
Ryan

RE: printing barcodes in linux

Of course you can. Assuming the barcode font was resident in the printer and set up as the secondary...

To encode 123456 as a 3of9, you would type...

^N*123456*^O

The first and last are control characters. The '*' are required for 3of9 formatting.

To enter ^N which is the single character chr(14) ...

enter CTRL-V followed by CTRL-N

and similarly..

enter CTRL-V followed by CTRL-O

for the final character.

Jim Asman
jlasman@telus.net

RE: printing barcodes in linux

(OP)
So how would I go about sending the font to the printer and making it the secondary font?  Is that something that is done on a per print basis?

thanks for all your help!

RE: printing barcodes in linux

Well, as long as the font arrives at the printer before it is used, you are fine. So if the font is set as permanent, you could simply 'lp' it before the operation began. The downloaded font will have a unique ID #, let's say 39.

Then in the application you make it the secondary with the code...      ^[)39X  where ^[ is  CTRL-V ESC

Once the font has been downloaded to the printer, it will remain available until the printer is powered off or it has been specifically replaced or deleted.

Jim Asman
jlasman@telus.net

RE: printing barcodes in linux

Hi...

a software only solution would be a filter for the spool system.

This kind of solution generates bar code drawing commands on the fly, while the print job file is processed by the print spool system.

You could try this software (free download):
http://www.tec-it.com/linux

It can create bar code images for Postscript and PCL based printers. With filter control sequences added to the document, you adjust bar code type, size, check digit and the bar code data.

Hope this info helps...

Harald

RE: printing barcodes in linux

(OP)
I installed the TCBLinux software and was able to print a test file they provide.  It appears that it will only work with PostScript files, can anybody confirm this?  I need to be able to print bar codes from a text file.   If anybody has any idea please let me know.

thanks
Ryan

Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

Red Flag Submitted

Thank you for helping keep Tek-Tips Forums free from inappropriate posts.
The Tek-Tips staff will check this out and take appropriate action.

Reply To This Thread

Posting in the Tek-Tips forums is a member-only feature.

Click Here to join Tek-Tips and talk with other members! Already a Member? Login


Close Box

Join Tek-Tips® Today!

Join your peers on the Internet's largest technical computer professional community.
It's easy to join and it's free.

Here's Why Members Love Tek-Tips Forums:

Register now while it's still free!

Already a member? Close this window and log in.

Join Us             Close