![](http://pdfasset.owneriq.net/5/41/5415e1d1-85c1-4809-9868-15982204af4a/5415e1d1-85c1-4809-9868-15982204af4a-bg39.png)
3. Set the line counter (ESC d)
Sending this command causes the scanner to send data in block
format. If you don’t send this command at the beginning of each job,
the scanner defaults to line mode and sends data after each line is
scanned.
You can set the parameter in this command from 1 to 255 lines. This
tells the scanner how many lines to send to the computer at a time. In
other words, setting the parameter to 10 results in the printer sending
scanned data in blocks 10-lines long. During line mode, the scanner
confirms that the computer receives each line of data after it is sent.
By sending data in blocks of multiple lines, you can save the time
required for line-by-line confirmation.
Setting the line counter with this command does not necessarily mean
the final data block will include that exact number of lines. Make sure
your program always checks the line counter value included in each
data block when receiving data. For example, if the value X is the
number of total lines you are scanning, the number of lines in the final
data block would be MOD[
X
⁄
i
]. The operator MOD indicates the
remainder of the division operation.
ESC d and other commands
If you select color line scanning with the ESC C command, you must
select a parameter for the ESC d command that is a multiple of 3.
Command Usage 2-19