[IAEP] bar code

Sean DALY sdaly.be at gmail.com
Fri Mar 27 05:42:24 EDT 2009

David was saying he started with American UPC, but the publishing
industry has standardized on EAN-13 with the "country" field being a
value (978 or in future 979) indicating "book" and called...
"Bookland" (!), the next 9 digits being the "classic" ISBN-10 number
then a final checksum digit.

There is also the 5-digit price add-on UPC-5 code for which the value
90000 is often used for international titles, indicating "no suggested
list price".

Generating a postscript file for the manual's single barcode shouldn't
take more than a few minutes:

$ barcode -h
barcode: Options:
   -i <arg>     input file (strings to encode), default is stdin
   -o <arg>     output file, default is stdout
   -b <arg>     string to encode (use input file if missing)
   -e <arg>     encoding type (default is best fit for first string)
   -u <arg>     unit ("mm", "in", ...) used to decode -g, -t, -p
   -g <arg>     geometry on the page: [<wid>x<hei>][+<margin>+<margin>]
   -t <arg>     table geometry: <cols>x<lines>[+<margin>+<margin>]
   -m <arg>     internal margin for each item in a table: <xm>[,<ym>]
   -n           "numeric": avoid printing text along with the bars
   -c           no Checksum character, if the chosen encoding allows it
   -E           print one code as eps file (default: multi-page ps)
   -P           create PCL output instead of postscript
   -p <arg>     page size (refer to the man page)

Known encodings are (synonyms appear on the same line):
        "ean", "ean13", "ean-13", "ean8", "ean-8"
        "upc", "upc-a", "upc-e"
        "39", "code39"
        "128c", "code128c"
        "128b", "code128b"
        "128", "code128"
        "i25", "interleaved 2 of 5"
        "cbr", "codabar"
        "pls", "plessey"
        "code93", "93"

$ barcode -e ean-13 -b 9782746031197 -u mm -t 3x8+5+2-5-20 -m 10,9 -p
216x279mm  -o SugarManual084barcode.ps

$ ps2pdf SugarManual084barcode.ps SugarManual084barcode.pdf

(I have substituted a barcode from a handy bash cheatcard, of course
our own number would need to go in)

Actually, the truly rushed can just go to:
http://www.tux.org/~milgram/bookland and run the Python script :-)


On Fri, Mar 27, 2009 at 9:54 AM, Jonas Smedegaard <dr at jones.dk> wrote:
> Hash: SHA1
> On Thu, Mar 26, 2009 at 06:13:17PM -0500, David Farning wrote:
>>I believe you are right.  Being American, EAN passed over my head
>>without notice.  https://commerce.bowker.com/BarCode/faqs.asp
>>Some places are offering to sell bar codes at around $5US apiece:( It
>>does look like some we can easily generate our selves at no cost.
> EAN13 is a common barcode format, but there are more than one.
> I was recently involved in packaging of organic sheep meat. EAN 13 was
> used, and we could produce it ourselves - the important part is to
> register somewhere centrally to get a unique ID for your "company", then
> you can choose yourself how you organize the rest of the digits in the
> serial number contained in the barcode.
> Instead of generating it with a shell script, I would recommend to use
> Inkscape, it has a nice plugin to handle several different barcode
> formats, including EAN13.  Just make sure to read the documentation for
> the barcode format used, and double-check that the result size fits the
> definitions (i.e. it is not stretch or scaled wrongly).
>  - Jonas
> - --
> * Jonas Smedegaard - idealist og Internet-arkitekt
> * Tlf.: +45 40843136  Website: http://dr.jones.dk/
>  [x] quote me freely  [ ] ask before reusing  [ ] keep private
> Version: GnuPG v1.4.9 (GNU/Linux)
> noMAn0Cj8SvTzz40QzyZvsvEmwoYsEI3
> =0VfR
> _______________________________________________
> IAEP -- It's An Education Project (not a laptop project!)
> IAEP at lists.sugarlabs.org
> http://lists.sugarlabs.org/listinfo/iaep
-------------- next part --------------
A non-text attachment was scrubbed...
Name: SugarManual084barcode.ps
Type: application/postscript
Size: 2067 bytes
Desc: not available
Url : http://lists.sugarlabs.org/archive/iaep/attachments/20090327/b9ab4e6c/attachment-0001.ps 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: SugarManual084barcode.pdf
Type: application/pdf
Size: 1339 bytes
Desc: not available
Url : http://lists.sugarlabs.org/archive/iaep/attachments/20090327/b9ab4e6c/attachment-0001.pdf 

More information about the IAEP mailing list