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
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