I
TwoimportantdetailsmakeLaserJetII commandsdifferentfromtheother
printeremulations.First,all Escapesequencesend witha capitalletter.If
youdon’tmakethelastcharacteruppercase,yourprinterwon’tknowwhen
theEscapesequenceendsandwilltreatfollowingcharactersas partof the
samecommand.
Second,inLaserJetIIcommandseachnumbcrorcharacteryouputafterthe
cESC>codeisan actualASCIIsymbol.Withtheothcremulations,usually
any number you put after an <ESC>code identifiesa characterin that
positionin the ASCIItable.
Forexample,theLaserJet11commandthatsetstherightmarginto column
65 is:
<ESC>&a 65 M
whichyou wouldcodein BASICas:
10 LPRINTCHR$(
27 ) ; “&a65M”
That commandsends your printer the symbols “6” and “5,” which its
LaserJet11programinterpretsas thecolumnnumber.
HowcvcrifyouwereusingEpsonEX-800emulation,thecommandthatsets
the rightmarginlookslikethis:
<ESC>Q 65
whichin BASICyouwouldwritethisway:
iO LPRINTCHR$(27) ; “Q”;CHR$(65)
Thatcommandsendsthepnntcrwhatevercharacterhappenstobein ASCII
position65. Yourprinter’sEpsonProgram,though,interpretsit only as a
decimalnumbermeaningcolumn65.
Combining Escape sequences
Laterin thischapterwedescribeonewayto selectafont,byjust specifying
whatfontattributesyouwant,suchas boldor proportionalspacing.If you
selectafontby specifyingeveryoneofitsattributes,youcanbecertainthat
you’reselectingsuccessfully.Butitcouldmeanafairbitofrepetitivetyping
eachtimeyouchoosea font.This appliesto othercommandstoo,notjust
fontselection.
52