CWBARS printer driver V1.3e October 19, 1992 written by Charlotte Wood and Eric Isaacson The entire package is Copyright 1991, 1992 Charlotte Wood Software All rights reserved. Charlotte Wood Software 5482 South Hyde Park Boulevard Chicago, IL 60615-5802 (312)363-9712 PLEASE read the first part of this manual for legal terms, how to register for the package, and the overview of the program. Then if you don't like reading manuals, just type CWBARS to the DOS prompt. We have formatted this file so that it can be printed at 10cpi with margins. To save space, we don't have a left margin in the file. You'll need to set your printer to a one-inch left margin to have room to punch holes for a ring binder. If you got CWBARS from an XYZ software house, that advertises great software for $5 per disk, and you are now confused as to your rights, you might ask the following QUESTION: "What's going on here? Have I already bought the program, or what?" ANSWER: Well, no, not exactly. You've bought a disk that has great software on it; unless you legally purchased the registered version of CWBARS, you haven't bought the software yet. CWBARS, like most major software offered by the $5-per- disk distribution houses, is free-distribution software (also known as "shareware", or "user-supported software"). That means we retain the rights to CWBARS, but we choose to let people pass the evaluation copy around. We have no business relationship with any distribution houses in the U.S.; we don't get a penny of the $5 (or whatever) you paid them for the disk containing CWBARS. So we need and expect to be paid by you, because we make our income from making and supporting shareware products. Some distribution houses do a pretty poor job of revealing the shareware nature of the software they sell. If you thought you had purchased the software free and clear, you might feel justified in being angry with them for having misled you. And you might look around for houses that do a better job of informing the public. But we hope you'll take the time to consider everybody's role in the shareware marketing scene; if you do, we think you'll conclude that although you may have been misled, you haven't really been cheated out of anything. Page 2 Shareware is great for authors like us, who have spent years in their computer holes, learning to be great programmers, and no time in business school learning marketing and distribution techniques. We simply cast our programs to the winds. They are distributed at practically no cost to us. That's why we can charge a lot less than the cost of "commercial" software. Shareware is also great for customers like you. You can try out the software before paying for it. You'll know that a successful shareware product is good, because only satisfied customers pay for it. The existence of shareware infuses healthy competition into the entire software market, for both price and quality. Finally, let's consider the distribution houses. They provide a legitimate service, for which they charge a reasonable price. The best houses act as librarians, evaluating and cataloguing software. Most pay thousands of dollars for advertising. Their cut is far less than the distributor's cut for "commercial" software (they prosper because their volume is bigger and their support responsibilities are smaller). Most customers for the distribution houses are repeat customers, who are aware of, and happy with, what they are getting. If it weren't for your XYZ House, you might never have heard of CWBARS, or might never have figured out where to obtain it. So we hope you'll be happy with shareware, and actively desire to support it. You'll feel good about promoting a healthy situation for everybody. And you'll encourage the best programmers in the world to keep writing for you, instead of for the big corporations. Now that we've said that, let's move on to the package. The CWBARS evaluation package consists of the program CWBARS.EXE, and this manual CWBARS.DOC. TABLE OF CONTENTS Overview of This Manual 3 Overview of CWBARS 3 Operating Requirements 4 Legal Terms 4 Legal Conditions for Free Distribution 5 How to Contact Us 5 Installing the CWBARS Program on Your Disk 6 Reconfiguring CWBARS 7 Printing Barcodes Manually 8 Installing the CWBARS Driver in Your Computer's Memory 8 Automatic Printing of Barcodes 9 Troubleshooting Automatic Barcodes 9 Escape Sequences for Barcodes 10 Order Form Generation 11 Index 12 Page 3 Overview of This Manual Welcome to CWBARS! We've tried to make the CWBARS program as self-explanatory as possible -- chances are good that you will be able to run CWBARS without needing to read this manual at all. We would, of course, like you to read the legal terms and conditions pertaining to the program. If you're a programmer sending the CWBARS escape sequence to your printer, you'll need to read the "Escape Sequences" section. Otherwise, if you're the kind of person who doesn't like reading manuals, simply type CWBARS and follow the prompts. If you're a beginner at computers, CWBARS will do everything for you: copy itself to your hard disk, store the answers to the configuration questions it asks you, and (with your permission) add its own invocation line to your AUTOEXEC.BAT, so that your laser printer will have barcode capability from now on. Overview of CWBARS CWBARS adds to your HP laser printer the ability to print Postnet barcodes on your outgoing U. S. mail. The barcodes will speed your mail and possibly save you postage. At the time of this writing, the discount is two cents per piece for a mailing of 250 or more nine-digit zipcode pieces. You do not need to presort or to have a bulk mail permit -- see your postal representative for details. You may also wish to use CWBARS only for the following convenience feature: you can tell CWBARS to substitute an escape character whenever it sees the 5-character sequence {Esc} being sent to your printer. You can use this feature if you're having trouble inserting the escape character into your word-processing documents. You can print barcodes in any of three ways: 1. Manually, by typing CWBARS followed by a zip code to the DOS prompt. 2. By arranging for your software to output a special escape sequence to your printer at the location where the barcodes are desired. 3. Totally automatically -- CWBARS can detect when your Laserjet is printing an envelope, and if the last printing characters on the envelope form a zip code, it can put the bar codes at the correct location, with little or no adjustment to your software! Page 4 Operating Requirements CWBARS requires an IBM-PC, IBM-PC AT, or 100% hardware-compatible computer with at least 128K bytes of memory, running MS-DOS V2.0 or later. A hard disk is not required, but you'll need to edit your own AUTOEXEC.BAT if you don't have a hard drive and wish to make CWBARS' installation permanent. CWBARS also requires a laser printer compatible with HP's printer command language (PCL), and capable of accepting "soft fonts". The original HP Laserjet did not have soft fonts, but the Laserjet Plus, II, IID, IIP, III, and IIIP all do. There's a simple way to tell if CWBARS is going to work for you: simply type CWBARS ORDER to fill out an order form. When the program asks if you wish to print an envelope, answer Y. The envelope should have our own barcodes printed along the bottom. If it doesn't, your printer probably isn't sufficiently compatible to run CWBARS. Legal Terms CWBARS is a copyrighted work -- it is not and never has been in the public domain. Each release of the CWBARS program comes in two versions: CWBARS.EXE, the evaluation copy, may be copied and distributed to others, subject to the conditions we're about to describe. The other version CWBARS.COM, the registered user's copy, is subject to the same legal restrictions as traditionally-distributed ("commercial") software. Neither version has any physical copy-protection schemes. WARNING: Before installing this or ANY new software, you should BACK UP any valuable data on your computer system. CWBARS has been extensively tested on numerous different machines, and it is believed to be reliable and non-harmful. However, software is the most complicated kind of product there is. No mortal human can be absolutely and completely certain that a piece of complicated software will work on any given machine. So you are completely responsible for determining the fitness or usability of this package. We will not be liable for damages of any kind, including but not limited to lost sales or profits, arising from any failure of this package to perform as expected. If you have the evaluation copy CWBARS.EXE, we hereby grant you permission to install this version of CWBARS in its memory-resident mode for up to one month. After that, you must either remove CWBARS from your system, or register -- if you type CWBARS ORDER, the program will create an order form for you. If you have the registered copy CWBARS.COM, you may install it only on those computers connected to licensed printers. You may make copies for backup and archival purposes. You may not let the registered copy print to more printers than you have licensed. The license for running the current version of CWBARS is permanent. Page 5 The registered version, with a printed manual and diskette, is $20 per printer. Illinois residents must add sales tax. Overseas users add $3 shipping. We reserve the legal right to change terms and prices for future versions without prior notice. At the present time we have no plans to change prices until inflation has seriously reduced the value of the dollar (by, say, at least a third off its 1992 value). We will never consider you committed to a higher price before being advised of the price-- you'll always have the option to cancel your purchase. Legal Conditions for Free Distribution Here are the conditions for free distribution of the evaluation version of CWBARS: 1. You may copy the disk-file version of this manual and the evaluation version CWBARS.EXE, and give them to anyone who accepts all the legal terms spelled out in this chapter. The copies you distribute must be complete and unmodified. 2. No part of CWBARS may be sold to anyone without our prior written permission. If the package is distributed on a diskette, any fees collected must be specified as materials/handling, and may not exceed $10 for the diskette. Thus, we are allowing shareware distribution houses to distribute the evaluation version of CWBARS, as long as they don't try to deceive their customers into thinking they have bought the full rights to the program. 3. We reserve the right to prohibit specific individuals and/or companies from distributing any or all of our copyrighted works. If we exercise this right, we shall inform such individuals/companies in writing, by certified letter. How to Contact Us You can write to: Charlotte Wood Software 5482 South Hyde Park Boulevard Chicago, IL 60615-5802 or call (312)363-9712. Sorry, we can't guarantee to return everybody's long distance calls. If you'd like to be SURE we'll get back to you, please invite us to call you back collect, or tell us to charge the cost of the call to your credit card. Page 6 Charlotte Wood is a member of the Association of Shareware Professionals (ASP). ASP wants to make sure that the shareware principle works for you. If you are unable to resolve a shareware-related problem with an ASP member by contacting the member directly, ASP may be able to help. The ASP Ombudsman can help you resolve a dispute or a problem with an ASP member, but does not provide technical support for members' products. Please write to the ASP Ombudsman at 545 Grover Road, Muskegon, MI 49442-9427 or send a CompuServe message via CompuServe Mail to ASP Omubdsman 70007,3536. Installing the CWBARS Program on Your Disk If you know how to copy files from a diskette to your hard drive, you may copy CWBARS to the subdirectory of your choice. But if you'd rather have CWBARS do it for you, you can simply place the diskette into its drive, and run the program. If it's drive A, type a:cwbars to the DOS prompt. You'll be asked the following configuration questions: Is your Laserjet the only printer connected to your computer? Chances are the answer is Yes. If you have more than one printer, or if there are other devices connected to your printer ports, you need to determine whether your Laserjet is known as LPT1, LPT2, or LPT3, and tell CWBARS which it is. Would you like CWBARS to automatically print Postnet barcodes whenever it sees that a zipcode is the last thing that has been printed on an envelope? You'll probably want to answer Yes if you're now using your Laserjet to print addresses on your envelopes. In that case, the barcodes should start appearing on your envelopes, without any adjustment to your software. Do you use business-sized envelopes (about 9.25 inches long) more often than personal-sized envelopes (about 6.5 inches long)? This determines the default envelope size assumed if you are using CWBARS manually to print barcodes on an envelope, and you don't explicitly give the size (Business or Personal). Have you specially modified your Laserjet's power-up default font to be a landscape font? If you're not sure, answer No. The answer if Yes only if you have fiddled with your Laserjet's front-panel switches, so that the printing comes out sideways when the printer is powered on. Page 7 The HP Laserjet Plus doesn't have an adjustable feed-guide, so you must feed envelopes along the edge, not the center, of the feed slot. Do you have a Laserjet Plus? Type N if you have a Series II or later model. Almost everyone will answer N to this question -- all HP printers from the Series II forward have the feed-guide that centers the envelope within the paper path. If you're having trouble getting CWBARS to recognize that an envelope is being printed, or if you simply want selective control over barcode printing, you can have CWBARS print Postnet barcodes whenever it sees a tilde (~) or some other specific character following a zipcode as the last printable characters on a page. Would you like this feature to be enabled? This option is a last resort if you've failed to get automatic barcodes via any other method. Answer No to this question when you are configuring for the first time. If you don't see barcodes printed automatically on your envelopes, read the "Troubleshooting Automatic Barcodes" section later in this manual. You may be able to adjust the escape sequences put out by your software to get the barcodes to appear. If that fails, you can reconfigure, answer Yes to this question, and add a tilde to every zipcode in your database. If you answer Yes to this question, CWBARS will ask you what character you want, just in case you wish to choose something other than the tilde character. To make it easier for you to send escape sequences to your printer, CWBARS can look out for the 5-character sequence {Esc} being printed, and substitute an escape character. Would you like CWBARS to do so? You can use this option if you find it difficult to put Escape characters directly into your word-processing documents. The curly-brackets are usually found as the shifted characters to the right of the P key on your keyboard. The letters Esc must be capitialized exactly as shown: big E, little s, little c. Would you like the installation of CWBARS to be made permanent by adding a line to the AUTOEXEC.BAT file on your hard drive? If you're finicky and protective of your AUTOEXEC.BAT, you can answer No to this question and edit AUTOEXEC.BAT yourself. You also answer No if you'll be using CWBARS only in its manual mode, and not to automatically print barcodes or use escape sequences to print barcodes. Reconfiguring CWBARS You can repeat the configuration process any time you wish to change any settings, by typing CWBARS C to the DOS prompt. Page 8 Printing Barcodes Manually You can print barcodes any time you see the DOS prompt, by simply typing CWBARS followed by the zipcode and the envelope size -- Business or Personal. You can abbreviate the envelope size as much as you wish, down to one letter if you like. You don't even need to give the size at all if it's the default size you gave when you configured CWBARS. As in all commands given to the DOS prompt, you need to put a space after the name of the program (CWBARS), and you need to complete the command with the Enter key. You don't need to worry about whether or not your letters are capitalized. CWBARS doesn't care whether the zipcode or the size comes first, and it doesn't care whether there are spaces between them. For example, suppose you told CWBARS that you use business-sized envelopes more often than personal-size envelopes. If you wish to append the barcodes for 60615-5802 to your envelope, simply type cwbars 60615-5802 to the DOS prompt. The embedded hyphen is optional -- it's ignored by CWBARS since it isn't a part of the barcode encoding scheme. If you wish the same zipcode on a personal-sized envelope, any one of the following commands will work: cwbars p60615-5802 cwbars 60615-5802 pers CWBARS 60615-5802P cwbars personal 60615-5802 Installing the CWBARS Driver in Your Computer's Memory If you wish to see barcodes printed automatically whenever you print addresses on envelopes, or if you wish to use escape sequences to print barcodes, then you need CWBARS' printer driver installed in your computer's memory. If you answered Yes to the AUTOEXEC.BAT question during configuration, this will happen automatically every time your computer is powered on. If you didn't, you can install the CWBARS driver any time by typing cwbars install to the DOS prompt. The driver is very small (less than 2K of memory); but if you are tight on memory you can later uninstall it by typing cwbars uninstall to the DOS prompt. As with all CWBARS keywords, the words "install" and "uninstall" can be abbreviated, all the way down to their first letters "i" and "u" if you like. Page 9 Automatic Printing of Barcodes If you answered Yes to automatic printing during your CWBARS configuration, and if you installed CWBARS in memory as described in the previous section, then barcodes should appear whenever you print an address on an envelope using your Laserjet printer. The CWBARS driver monitors all data flowing from your computer to your printer. If it sees that an envelope is being printed, and if it sees that a zipcode was the last thing on the envelope, it will append the barcodes for that zipcode. If your application has an option to print directly to your printer without using your computer's BIOS, you must disable the option for CWBARS to work. In particular, WordPerfect has this option. CWBARS works with the majority of programs that print addresses on envelopes. However, there might be some exotic printer sequences that will fool CWBARS into thinking that an envelope isn't being printed when it is. The best way to find out is to simply try it. If you see the barcodes, you're in business. If you don't, you may be able to adjust your software to make CWBARS work: read the next section for details. Note that the barcodes are for the destination of your mail, not for the return address. If you are making a bunch of envelopes containing only your return address, you should first disable CWBARS with the CWBARS U command, to avoid printing the unwanted return barcodes. Troubleshooting Automatic Barcodes If you can't get barcodes to print automatically, there are a couple of adjustments you can try. First, you should make sure that CWBARS can print barcodes in the first place. Some Laserjet "clones" aren't compatible enough to run CWBARS. Type CWBARS to the DOS prompt and choose the menu item to fill out an order form. Answer Yes when you're asked if you wish to print an envelope for the order form. If the envelope has barcodes on it, continue reading this section -- you ought to get CWBARS to work. If it doesn't, send us a note with the brand and model number of your printer -- if and when we support it, we'll let you know. If the order-form software worked, we recommend that you next try to modify the escape sequences sent by your software to prepare your Laserjet for envelope printing. Most applications allow you to create and modify "template files" that define those escape sequences. The names and formats of those files depend on the application you're using -- consult your application's manual to find out what they are. Included in the template should be a sequence that tells the Laserjet to print sideways -- they call it "landscape" mode. The left column in the following chart gives some of the ways the beginning of this escape sequence might be represented in your template file. You should substitute the corresponding sequence in the right column: Page 10 If you see: Instead use: 27 38 108 27 33 108 1B 26 6C 1B 21 6C & lower-case-L ! lower-case-L When you send the new escape sequence to your printer, CWBARS will substitute the old sequence, thus telling the Laserjet to enter landscape mode. In addition, CWBARS will record the fact that you're printing an envelope. If you can't find the template file containing one of the listed sequences, you can try typing CWBARS C to reconfigure, and answering Yes to the Tilde option. This option allows you to invoke the CWBARS barcodes feature by placing a tilde ~ immediately after the zipcode in each individual address. Another method you could try would be to provide a barcode escape sequence at the correct position on the envelope. This is described in the next section. Escape Sequences for Barcodes If you are a programmer, or if you can configure your printing program to output any bytes you wish, then you can control the printing of barcodes via a special escape sequence output to your Laserjet. The escape sequence is effective whenever the CWBARS driver is installed in your computer's memory, as we already described. Your HP Laserjet user's manual describes the various escape sequences, which they call "printer commands", built into your printer. CWBARS simply adds another command to HP's set. You should read your HP manual for a detailed discussion of how to output escape sequences, using various major software packages. For example, we have the Second Edition of the Laserjet Series II User's Manual. Chapter 3 of that manual talks about printer commands. Page 3-14 has a nice chart of how to represent the escape character within Lotus, WordPerfect, Wordstar, etc. Or you can enable the CWBARS option to accept the five-character sequence {Esc} for the escape character, and output the sequences literally as we show them. The escape sequence for barcodes is: {Esc}!z#B where {Esc} is the Escape character (27 decimal, 1B hexadecimal), the exclamation point, z and B are ASCII characters just as you see them, and # stands for the sequence of digits representing the zipcode. NOTE that the z must be lower-case, and the B must be upper-case. You may embed the hyphen in a 9-digit zipcode, but you must not embed any spaces or other characters within the codes. Page 11 If a zipcode was the last non-blank sequence of characters printed, you may omit the zipcode from this escape sequence. In that case, CWBARS will use that zipcode. If some other non-blank character was printed, a zipless escape sequence will be ignored. This allows you to print an address, position the printer cursor to the desired location for barcodes, and issue the zipless escape sequence. If a U.S. address with zip was printed, the barcodes will be printed also. Otherwise (for foreign and no-zip addresses), the barcodes are correctly omitted. The printer will print barcodes at the current printing position on the page. After the codes are printed, the current position is immediately to the right of the barcodes. The escape sequence works in either portrait or landscape mode. For example, to print the barcodes for 60615-5802 on your printer, you can output the sequence {Esc}!z60615-5802B to the printer. The hexadecimal codes for this are: 1B 21 7A 34 37 34 30 32 2D 33 32 34 32 42 Order Form Generation You can generate an order form for CWBARS by typing CWBARS ORDER (or simply CWBARS O) to the DOS prompt. This is primarily for the evaluation version, to encourage people to register. But we've also included it in the registered version, just in case you want to order more copies. INDEX Page 12 address, our, 5 ampersand sequence, modifying, 10 Association of Shareware Professionals, 6 AUTOEXEC.BAT, automatic modification, 7 automatic printing of barcodes, 9 automatic selection, 6 barcodes, automatic printing, 9 barcodes, escape sequences, 10 barcodes, manual printing, 8 barcodes, printing via tilde, 7 barcodes, troubleshooting automatic, 9 brackets {Esc} code, 7 business-sized envelopes, 6 buying a copy of CWBARS, 11 character-after-zip option, 7 charges for CWBARS, 11 clone printers, trouble with, 9 configuring CWBARS, 7 contacting us, 5 contents, 2 copying to hard drive, 7 copyright terms, 4 curly-brackets {Esc} code, 7 CWBARS {zipcode} command, 8 CWBARS B (Business) command, 8 CWBARS C (Configure) command, 7 CWBARS I (Install) command, 8 CWBARS O (Order) command, 11 CWBARS P (Personal) command, 8 CWBARS U (Uninstall) command, 8 default size of envelopes, 6 disclaimer, 4 discounts, postal, 3 disputes, resolving, 6 distribution conditions, 5 distribution houses, shareware, 1 DOS, printing barcodes while in, 8 driver, printer, installing, 8 edge-feeding envelopes, 7 envelope printing, automatic barcodes, 9 envelopes, size of, 6 escape codes, easy printing of, 7 escape sequences for barcodes, 10 evaluation vs. registered version, 4 exclamation point, in escape sequence, 10 feed-guide, adjustable, 7 fees for using CWBARS, 11 generating an order form, 11 hard drive, copying to, 7 HP Laserjet Plus, 7 HP User's Manual, 11 how to contact us, 5 how to order, 11 inserting Escape codes, 7 installing CWBARS in memory, 8 installing CWBARS on your disk, 6 INDEX Page 13 invoice, generating, 11 landscape font, default, 6 landscape sequence, modifying, 9 legal conditions for free distribution, 5 legal terms, 4 license, how to obtain, 11 LPTn device selection, 6 Lotus escape sequences, 11 machine requirements, 4 manual printing of barcodes, 8 manual, overview, 3 memory, installing CWBARS in, 8 money, how to send, 11 Ombudsman, ASP, 6 operating requirements, 4 order form, generating, 11 overview of CWBARS, 3 overview of manual, 3 payment for CWBARS, 11 personal-sized envelopes, 6 Plus, HP Laserjet, 7 positioning barcodes manually, 11 postal discounts, 3 power-up HP font, default, 6 price policy, 5 printer driver, installing, 8 printer requirements, 4 printer selection, 6 printing barcodes manually, 8 Reconfiguring CWBARS, 7 registered version, 4 registering, how to, 11 release date, 1 removing CWBARS from memory, 8 selective control of barcodes, 7 send money, how to, 11 shareware, nature of, 1 size of envelopes, default, 6 table of contents, 2 telephone number, our, 5 template files, modifying your, 9 testing CWBARS, 4 tilde-after-zip option, 7 troubleshooting automatic barcodes, 9 uninstalling CWBARS, 8 warning, 4 WordPerfect direct print option, 9 WordPerfect escape sequences, 11 word processing and escape codes, 7 Wordstar escape sequences, 11