[comp.periphs.printers] DeskJet 500 underline problem

pegram@kira.UUCP (Robert B. Pegram) (12/07/90)

(Second try - no answers yet - possibly because original didn't get
posted 8-)

Ran into a problem helping my brother-in-law with his new DJ 500.
Underlines always end up in the middle of the next line down.  I tried
two different fonts, with single and double underlines and with
and without the "floating" option (whatever that is!).  Nothing
worked.  Is the machine defective or did I miss something?  Setting up
this beast is not as easy as the Epson compatibles I'm used to, since
some options must be sent out in strict order, or you don't get what
you want.  Any and all help appreciated, I will report if there is any
interest. Email or post to c.p.p.

Bob Pegram

Internet domain: pegram@griffin.uvm.edu
UUCP: ...!uvm-gen!pegram

sichermn@beach.csulb.edu (Jeff Sicherman) (12/07/90)

In article <1990Dec6.163104.23721@uvm.edu> pegram@kira.UUCP (Robert B. Pegram) writes:
>(Second try - no answers yet - possibly because original didn't get
>posted 8-)
>
>Ran into a problem helping my brother-in-law with his new DJ 500.
>Underlines always end up in the middle of the next line down.  I tried
>two different fonts, with single and double underlines and with
>and without the "floating" option (whatever that is!).  Nothing
>worked.  Is the machine defective or did I miss something?  Setting up
>this beast is not as easy as the Epson compatibles I'm used to, since
>some options must be sent out in strict order, or you don't get what
>you want.  Any and all help appreciated, I will report if there is any
>interest. Email or post to c.p.p.
>
>Bob Pegram
>
>Internet domain: pegram@griffin.uvm.edu
>UUCP: ...!uvm-gen!pegram

  Havent checked my Deskjet refs but the Laserjet is a page printer and
doesnt support the cr-no-lf sequence when  printing an ascii file in order
to produce underlining. It defaults to auto-lf with cr (newline). Even though
the Deskjet is essentially a rasterizing printer, they probably made it act
like a laserjet in order to have PCL type printers act compatibly with respect
to the same files and commands.  A character-backspace-(overprint-underline)
type sequence does work on both printers, in my experience.

Jeff Sicherman
up the net without a .sig

hardy@golem.ps.uci.edu (Meinhard E. Mayer (Hardy)) (12/07/90)

The deskjets have two sets of switches (front under the paper tray).
One of these is to be set for CR-LF, CR, etc; see the manual. If it is
not set correctly (personal experience) dvidjp will break pages
erratically.
If I remember correctly (see manual for detail) all switches down 
(except one which allows for 66 line pages) is the correct setting for
my HP 9000/370 serial port. PC-s (parallel port) insert an extra LF
after CR anyway.

Hardy Mayer
----****----
Professor Meinhard E. Mayer
Department of Physics
University of California
Irvine, CA, 92717
USA

pegram@kira.UUCP (Robert B. Pegram) (12/08/90)

From article <1990Dec7.060122.10632@beach.csulb.edu>, 
by sichermn@beach.csulb.edu (Jeff Sicherman):

Jeff quotes me saying:

>>Underlines always end up in the middle of the next line down.  I tried
>>two different fonts, with single and double underlines and with
>>and without the "floating" option (whatever that is!).  Nothing
>>worked.  Is the machine defective or did I miss something? 

He then writes:

>   Havent checked my Deskjet refs but the Laserjet is a page printer and
> doesnt support the cr-no-lf sequence when  printing an ascii file in order
> to produce underlining. It defaults to auto-lf with cr (newline). Even though
> the Deskjet is essentially a rasterizing printer, they probably made it act
> like a laserjet in order to have PCL type printers act compatibly with 
> respect to the same files and commands.  
> A character-backspace-(overprint-underline) type sequence does work on 
> both printers, in my experience.

> Jeff Sicherman
> up the net without a .sig

I'll try it, but I don't quite get it.  I'm not trying to overprint
with the underline character.  The DeskJet is also not set up to do an
auto line feed.  What I am doing is setting up the equivalent of
embedded commands (the word processor does it for me when I tell it to
underline) in the ascii to turn on automatic underlining before my text, 
and then embedding a turn off command after it.  It would read in
straight ascii something like:

(ESC "underline on")Underlined text(ESC "underline off")

The parenthesized codes are various printing or nonprinting
characters, beginning with the escape character.  The DeskJet does
have this command, more than one in fact - single, double, and
floating (??) characteristics all modify simple underlining.  What I
don't get is, why are the underlines I produce half way into the next
line, striking through the text there?  If your idea held, I would
produce text like this:

Underlined text
_______________ (a line with only an underline)
next line of text.....

If I misunderstand the commands dealing with underlines, somebody
straighten me out.  Do these commands actually flip the underscore
character between a single and a double line and print it somewhere?
Or are they supposed to work as I expect, causing each subsequent
ascii character to be printed with an underline?  If they do work as I
stated, is there some vertical spacing setup or adjustment I'm
supposed to do before using them?  BTW, this effect has also shown up
on another DJ 500 I know of, though it was probably from the same
store.  Thanks for all your help,

Bob Pegram

Internet domain: pegram@griffin.uvm.edu
UUCP: ...!uvm-gen!pegram

(what .sig?  I still type this in all the time! 8-)

neff@hp-vcd.HP.COM (Dave Neff) (12/11/90)

Having written much of the DeskJet 500 firmware and having personally
run through our regression test suite of PCL escape sequences I assure
you the DeskJet 500 can in fact underline :-). I would guess you have some
additional escape sequences mixed in with your string.  The DeskJet 500
does have specific bitmaps associated with a given font that are used to
generate the various kinds of underlines.  To do a simple underline your
escape sequence should look something like:

<Esc>&d1DThis text will be underlined<Esc>&d@

Where <Esc> is of course the escape character (1B Hex).  There should be
no carriage returns, line feeds, etc. between the escape sequences.

I really can't think of what would fully explain what you are seeing.
If you could mail me the exact data that is being sent I could maybe see
what is happening.

If the DeskJet 500 could not underline virtually every word processor in
the world would not be able to make the DeskJet 500 underline and I would
be stampeded with our product support people complaining at me :-).

Dave Neff
neff@hpvcfs1.HP.COM

rrd@hpfcso.HP.COM (Ray Depew) (12/12/90)

Re:  Bob Pegram's DeskJet underlining problem.

Your DeskJet should be set to print at a pitch of 6 lines per inch.  
Anything more dense than 6 lpi will cause jsut the problem you describe --
also problems with descenders (the thingies hanging on the bottom of 
letters like "g" and "j") running into capital letters on the next line.

Print pitch is controlled by an escape code, which I can't remember offhand.
It's in the book...  The Deskjet "remembers" the last pitch setting, you 
you have to reset the pitch to 6 lpi if it was changed.

This info should apply equally to the DJ, DJPlus and DJ500.

I don't speak for HP officially.  I only work here, and I've used the DJ
series a bit.

Regards
Ray Depew
HP ICBD -- IC's by Bill and Dave   
rrd@hpfitst1.hp.com

pegram@kira.UUCP (Robert B. Pegram) (12/13/90)

Ray Depew sez:

(about a problem I'm having getting underlines in the proper place on
 a DeskJet 500, it looks more like a strike through of the next line. 8-)

> Your DeskJet should be set to print at a pitch of 6 lines per inch.  
> Anything more dense than 6 lpi will cause just the problem you describe --
> also problems with descenders (the thingies hanging on the bottom of 
> letters like "g" and "j") running into capital letters on the next line.

Thanks Ray, I think it is either broken, or my init string is bad, I'd
bet on the init string 8-).  

By the way,
(NOTE: RETRACTION:) I was misinformed about the second DeskJet 500, it
is working fine.

Only my brother-in-law's machine is giving <him and me> trouble.  

Oh yeah, all you Atari ST people, get the DJ utilities that are
available at the U Mich archive and/or the mail server for c.b.a.s.,
OR, fire up the DeskJet first, the 500 still stops the ST parallel
port from working if you turn it on after the ST.

cheers,

Bob Pegram

pegram@griffin.uvm.edu