
Chapter 3: Programming Commands 41
Set relative print position
ASCII ESC \ n1 n2
Hexadecimal 1B 5C n1 n2
Decimal 27 92 n1 n2
Value of n:
Tomovetherelativestartingpositionrightofthecurrentposition:
n = Number of dots to be moved right of the current position
n1 = Remainder after dividing n by 256
n2 = Integer after dividing n by 256
The values for n1 and n2aretwobytesinlowbyte,highbytewordorientation.
Tomovetherelativestartingpositionleftofthecurrentposition:
n = Number of dots to be moved left of the current position
n1 = Remainder after dividing (65,536-n) by 256
n2 = Integer after dividing (65,536-n) by 256
The values for n1 and n2aretwobytesinlowbyte,highbytewordorientation.
Movestheprintstartingpositionthespeciednumberofdotseitherright(uptotherightmargin)orleft(uptotheleft
margin)ofthecurrentposition.Theprintstartingpositionisresettotherstcolumnaftereachline.
Formulas
To move to the left:
Determine the value of nbymultiplyingthenumberofcolumnstomoveleftofthecurrentpositionby10(standard)or
8(compressed)pitch.Theexampleshowshowtosettherelativepositiontwocolumnsinstandardpitch(10dotsper
column) to the left of the current position.
2 x 10 = 20 dots (two columns to be moved left of the current position)
65,536–20 = 65516
65,516/256 = 255, remainder of 236
n1 = 236, n2 = 255
To move to the right:
Determine the value of nbymultiplyingthenumberofcolumnstomoverightofthecurrentpositionby10(standard)
or8(compressed)pitch.Theexampleshowshowtosettherelativepositiontwocolumnsinstandardpitch(10dotsper
column) to the right of the current position.
2 x 10 = 20 dots (two columns to be moved left of the current position)
20/256 = 0, remainder of 20
n1 = 20, n2 = 0
Related information
Ifthesethorizontalandverticalminimummotionunitscommand(1D50)isusedtochangethehorizontalandvertical
minimummotionunit,theparametersofthiscommand(setrelativeprintposition)willbeinterpretedaccordingly.Inpage
mode,upperleftorlowerrightusesthehorizontalmotionunit,andupperrightorlowerleftusestheverticalmotionunit.
Formoreinformation,seethedescriptionofthesethorizontalandverticalminimummotionunitscommand(1D50)in
this document.
Ifunderlineisset,spacesskippedbythiscommandarenotunderlined.
Compatibility information (A798II receipt vs. A793 receipt)
ThereisadifferenceinthenormalbehaviorofthiscommandinA793emulationmodeascomparedtotheoriginalA793.
Thedifferenceexistswhenthecommandisusedtomovetotheleft.TheA793processesthewholeprintstringpriorto
puttingitinthebufferfortheprinthead.ThismethodofprocessingallowstheA793tobackupintheprintstringand
replacecharactersandtheirassociatedattributeswhena“Setrelativeprintposition”commandinstructstheprinterto
move the print position to the left.
Inordertoimprovethespeedofprinting,theA798IImovesthedataintoabufferfortheprintheadwhenitreceivesit.
Whenthe“Setrelativeprintposition”commandcontainsamovetotheleft,thiscausesthenewdatatooverstrikethe
Continued...
Comentários a estes Manuais