Copyright © 1998 Tim Norman
Disclaimer: This information may not be accurate. It has been compiled by me from experimentation and other means that may be prone to error.
The PPA protocol is actually composed of two protocols: a lower-level packet protocol called VLink and the Sleek Control Protocol (SCP). The VLink protocol regulates all data transfered back and forth between the printer and the computer. SCP sends command sequences to tell the printer to do things like load a sheet of paper, eject, and print a sweep.
Although PPA is a bi-directional protocol, I have mainly concentrated on its uni-directional component. It is not required for the host to be aware of the bi-directional nature of the device, which makes this easy to do.
All values are stored in big-endian format.
Note added: the utility program parse_vlink is a simple utility to step through the individual Vlink packets in a PPA stream. It also decodes the SCP packets and prints the information encoded in them.
VLink is a very simple protocol:
When image data is sent over the image data channel, it takes a form that is very close to how it is presented to the print head mechanism. The code in ppa.c best describes how this data is organized. I will also attempt to explain the PPA sweep data.
The image data may also be optionally compressed. I have not yet worked out the details of the compression method, though it seems similar to the compression used for the PCL protocol. My code currently generates uncompressed data only.
Note that there is a limit to the amount of data that can be sent to the printer. If you overflow that limit, the printer will get confused. This is why print_pbm uses only 150 of the 300 black nozzles; using all of them would overflow the printer's data buffer. I hope to improve this in the future with compression and multiple sweeps per line. This limit is somewhere around 100k for the Deskjet 820Cse.
(added 09/28/2000, by firstname.lastname@example.org): Printing on HP820 with pnmn2ppa-1.0 fails with flashing lignt syndrome if the vertical position of two successive sweeps differs by 1, 2, or 3 dots. (This was observed for the case when one sweep is black , the other is color). If the two sweeps have the same vertical position (as in Windows 9x printing, its OK)
SCP is the protocol that controls the printer's actions. I will describe several of the commands that I use in my software.
It appears that SCP differs depending on the series of printer that is being used.