P* PROTOCOL AND SOFTWAREBY PATRICK BAUDELAIRE, DAN SWINEHART, AND CHUCK WALLACEMARCH 1979, updated by Bob Sproull, March 1983ABSTRACTThis document describes the communication protocol between a printer of the P* family (Puffin,Penguin, and Pimlico) and its host Alto, and presents an overview of the microprocessor programs thatimplement the protocol and control the operation of the printer.Penguin engine control information is missing from this document. The only known reference is sourcecode for Spruce. It is advisable to consult printer-control code found on [indigo] and[indigo] for details omitted from this document.This document is for Xerox internal use onlyThis document is for Xerox internal use onlyXEROXADVANCED SYSTEM DEPARTMENT3333 Coyote Hill Road / Palo Alto / California 94304 W;p Sqr$qr O=q. Blr >s<" <A$ :@ 7f-7 5xH 34|rX,|f,)Wt)`)r)` qF4* rAdeP* Protocol and Software1IntroductionHardware overviewP* is a family of printer-copier devices based on modified Xerox copiers. Members of the family areknown under the names Pimlico, Puffin, and Penguin. Pimlico and Puffin are based on the 6500 colorcopier; PEnguin on the 5400 black-and-white copier. Each printer can operate either as a regular stand-alone copier or as a raster-scan printer driven by an Alto/Orbit.The P* family uses the Orbit/ROS-adapter technology developed for the Dover printer [3]. In additionthese printers are controlled by a microprocessor system. Puffin and Penguin have two processors, butPimlico has only one. The main microprocessor is a Motorola M6800 equipped with 8K bytes of PROMmemory (4K on Pimlico), 8K bytes of RAM memory, a programmable timer module MC6840, twostandard peripheral interfaces MC6820 (also known as a Peripheral Interface Adapter, or PIA). Themicroprocessor controls the marking engine via one PIA interfaced to the Engine Control Module, and itcommunicates with its host Alto via the other PIA and the standard ROS adapter. Direct memory accessto reserved areas of RAM memory (DMA) is also used by the ROS adapter and the Engine InterfaceModule.The second microprocessor (in Puffin and Penguine only) is an Intel 8748 microprocessor equipped witha little bit of RAM, and 1K or 2K of PROM. It performs auxiliary engine control functions undercommand of the M6800.Software overviewAlto programs and a P* program communicate via a simple software protocol based on interrupts anddirect memory access capabilities (DMA). The protocol can be viewed as two sub-protocols correspondingto two main functions. A control protocol enables basic communication between the Alto and themicroprocessor (including loading the RAM), and permits debugging of the M6800 from Alto programs.It is common to all printers. A printing protocol is used by Alto printing software for operating themarking engine. Puffin and Penguin use different protocols. Pimlico software (version B2) implementsonly a subset of the Puffin protocol. Another simple protocol is used between the main M6800microprocessor and its 8748 helper. It is also common to all printers. This document covers the variousmicroprocessor control software and communication protocols. It is organized as follows:-Section 1 describes the Alto-M6800 control protocol;-Section 2 presents the M6800 microprocessor program that drives the 6500 and 5400 engines,and the data structures;-Section 3 covers the Alto-M6800 printing protocols for Penguin and Puffin;-Section 4 describes the M6800-8748 protocol and the 8748 programs.This document is mainly intended for the Alto programmer who wants to use a Penguin or a Puffin.(Most Pimlico-related information has been merged into this document from [1], but is not guaranteed.)It is assumed that the reader is familiar with the concepts and terminology relating to the Orbit electronicimage processor and the standard ROS adapter [3]. Some knowledge of the M6800 and Intel 8748microprocessors [6,7,8] and the 6500 and 5400 copiers [9,10] is also useful. These devices are described in$RgsXJjf'Zau \v Ys@$ Wvsvsvs1 U*g S<A Ows( Mf K Gws w Iswsws ws0 G:ws Fws0 D-wsws B%wswsws @7 <W :wswswsws7 8 51v 1s@! /#ws: -vs6 +&ws* )!vs, '&? & > $W "-Y2424'2J2B KP ]Y oW !ws9 57 J LB\HP* Protocol and Software2the references.To satisfy both traditional microprocessor usage and Alto conventions, protocol codes and other numbersare presented in octal and hexadecimal format (e.g. 304b=C4x).PenguinPenguin is a printer/copier based on a modified Xerox 5400 copier. It outputs paper at a speed ofapproximately 11 inch/sec, producing a copy in about 1 second. Penguin is equipped with a 20-binsorter, a document handler, and an auxiliary paper tray used mainly for two-sided copying and printing.Penguin uses landscape-mode scanning.The parameters for the Penguin ROS are (see [3] for defintions):p (paper speed) = 11.0 ipsf (number of facets on the polygon) = 22r (polygon motor clicks/rev) = 24d (duty cycle) = .98h (scan-line length) = 12.1 inchesPuffinPuffin is based on a modified Xerox 6500 color copier. It outputs paper at a speed of approximately 4inch/sec, producing a 3-color copy in about 18 seconds. A specially-designed fourth developer housing isadded, and may be used to hold black toner to be used in 4-color printing. Puffin scans in portrait mode.The parameters of the Puffin ROS are:p = 4.0 ipsf = 22r = 24d = .99h = 11.8 inchesx (scan-line repeat factor) = 2Note that some machines have Puffin engine control and Pimlico ROS equipment.PimlicoPimlico is an ancestor of Puffin with a different ROS and slightly different engine control. Pimlico hasonly 3 toner housings. Pimlico scans in portrait mode.The parameters of the Pimlico ROS are:p = 4.0 ipsf = 12r = 24d = .87$RgsXJjf b ^_ \> Yv Ups5- SX QY O% Lws2H6vs2FHvs'2DZvs2Blvs2@~vs! J,ws2 <\ 7x 4^vy 0sc .&v svsws+Ews)Wwsws&ws'iws%|ws%ws!-ws w s$ws/wsws/9v swsv swsAwsws v svs3 )5vs ' ;f M?$ B](=P* Protocol and Software5However, execution control commands are accepted only during wait state.Memory access from the AltoThe Alto may ask the control program to read and write M6800 memory at any time, as long as theinterrupts are being serviced. Since these read/write requests are not queued in the current design, it isnecessary to wait for a positive status result of a write request, to make sure everything gets done.Addresses that can be read and written include the machine state registers (see 1.4), but access to theselocations is only meaningful during the wait state, and is ignored during active state. The currentmemory address of read and write requests is preserved in a specific memory location (CMA). Wait stateThe purpose of the wait state is to suspend all processing so that the M6800 can respond to programloading, debugging, and other control requests from the Alto. This is particularly useful for systemdevelopment. The wait state routine is a simple endless loop: the only activity is the servicing of thecontrol protocol interrupts (those should be the only interrupts received, since the engine is not supposedto be running). During wait, the state of the microprocessor may be freely tested and queried,breakpoints may be set and cleared, and execution may be "continued" based on the possibly modifiedmachine state. By creating a new state, the Alto can effect a "go to" or "start" operation. The M6800enters the wait state either via a software interrupt (SWI), issued in response to a previously queued waitrequest command (see 1.3 and 3.4), or in response to a non-maskable interrupt (NMI).When the wait state program is started, it moves the machine state (five registers saved by the interrupt,plus the stack pointer) to a separate private stack. At this point read and write access to the stateregisters is possible. Thus the Alto program can inspect and revise any part of the state, including stackpointer (SP) and program counter (PC), before continuing.The wait state is initialized on reset, which can be caused by hardware (turning power on) or software(execution of the reset routine or the memory test routine).Active stateThe M6800 software is configured as a series of separate initialization, test, and engine control routines.The microprocessor is in active state when it runs any of these routines, except the reset and memory testroutine which take complete control of the processor and fall into wait state after completion. Activestate routines may be invoked from the wait state by execution control commands. Conversely, wait statemay be entered after completion of the routine, or by interrupt (NMI or SWI).The main active state routine is the printer program that operates the engine autonomously, carrying outvery precisely timed sequences of events. Printing protocol commands and memory access commandsarrive relatively infrequently and can be processed immediately. However, it is usually unwise to allowcommands from the Alto to suspend the printing routine in an arbitrary fashion. For debugging orexamining the state of the microprocessor, the Alto may send a wait request command which is queuedby the printing routine. At some appropriate place in the printing loop, when things are quiet and safe,processing will be suspended and the wait state will be entered. The main printer loop will invoke thewait state routine via a software interrupt (SWI), for compatibility with the NMI mechanism. Routine$RgsXJjf bH ^v ZsW YL W_ U*@xs S<H QNVvs MvX J#sv s; H6F FHd DZP BlD @~Q >16 < vsvs"ws1 :xsxs/ws 7<. 51=) 3CO 1Uvsvs -!vs( +< (=v $s/< "vsvsE ` #vs Awsws [$vs" m*6 J P 7v s c 43 -wsws B\JP* Protocol and Software6interruption by NMI is used only in emergency: this is usually done only after the M6800 does notrespond to the more polite request.Execution controlActive processing resumes from the wait state in one of the following ways:- Continue: If the machine state registers were not changed, control resumes at the point ofinterruption. Of course, memory modifications or timing changes introduced by the wait statedalliance may affect system operation. If the machine state was changed (particularly the SP orPC), control resumes at a point defined by the new state.- Routine execution: The CMA address is used as a starting address of a parameterlessprocedure. This procedure is called, using the SP in effect at the time of interrupt, butpreserving the previous machine state. The wait state is reentered on return from the procedure.If wait state is entered, via NMI or breakpoint, during execution of the routine, the wait stateroutine will be recursively entered.- Known routines: Standard routines are identified by small integer "names" (or index), so thattheir absolute addresses need not be known by the Alto. A command sets CMA to the addresscorresponding to the supplied index. Execution of the routine may then proceed as above.- Breakpoints: Pseudo breakpoints may be planted by replacing a one-byte instruction by an SWIinstruction. No attempt is made to save the replaced instruction or execute it on return, so itshould be a No-op.The execution control commands are accepted only during wait state.1.2 Status ReportThe microprocessor reports status via the 16-word ROS status packet. It uses 4 bits in the first word forreporting standard printer information (PageSync, PrintMode, etc), and the last 4 words of the packet forprinter specific information about the state of the M6800 program, and the operation of the printer. Thisis described in the following BCPL-like structure definition:$RgsXJjf bwsN `0# \v YsKUpvsF SJQZvsOvs7Lvsvs&J#/vs%H6&xs*FHws?DZ$@vsG>7vs<I9TvsMw7fs@5x 1C -zx )s2ws" '&vsvs. & 37 $ws #ADZP* Protocol and Software7structure ROS-STATUS [[ Row0 word 2 ] = [PageSync bit 1PrintMode bit 1Local bit 1BeamEnable bit 1etc... bit 28]Row1 word 2...Row5 word 2[ Row6 word 2 Row7 word 2 ] = @PRINTER-STATUS]The 4 standard printer status bits in Row0 are sent via 4 output lines of the ROS adapter PIA. The ROSadapter reads the 4 printer status words (Row6 and Row7) by direct memory access (DMA) to a reservedarea of the microprocessor RAM memory. It issues an interrupt (Row7 IRQ) to the M6800 at thecompletion of each status poll. This interrupt is used to insure that the chunk of status written into thestatus area is consistent. The status is written by the M6800 program in a private area; when a consistentchunk is ready to be sent, the Row7 IRQ is enabled; the Row7 interrupt routine then copies the statusinto the reserved DMA area and disables Row7 IRQ.The structure below defines the uses that have been assigned to fields within the Printer status area:structure PRINTER-STATUS [StatusBits byte = [WaitState bit 1WaitAck bit 1NoRAMcode bit 1(Pimlico only)Ignored bit 1QueueLate bit 1QueueFull bit 1QueueError bit 1(Puffin only)8748Status bit 1(Puffin, Penguin only)]CommandCount byte 1Mode-Sequence byte 1 = [Mode bit 2MainSequence bit 3SubSequence bit 3]Malfunction byteAddressOfData byte 2 = MalfRevNumber byte 2Data byte 2 = MalfCopyNumber byte 2]$RgsXJjfb`0vs ^Bvs\TvsZfvsXxv sVvsTRvsPNvsLvsJvsI Et.wswsw Cs Ews Awsws ?g =k ;#ws> 9wsws 6K$B20v s.vs,vs*vs){)vs'#vs%5vs#Gv s){!Yv s){ k}v sv s vsv sv sv sv s v svs v s X A\UP* Protocol and Software8WaitState is set if the microprocessor is running in the wait state, cleared if it is in the active state.WaitAck is set after reception of a WaitRequested command (see 1.3).The Ignored bit is set in response to an unimplemented, untimely, or unsuccesful command.Status bits NoRAMcode, QueueLate, QueueFull, and QueueError are used for the printing protocol (see3). If they are set, Ignored will also be set.8748Status is set if the 8748 is not responding to the M6800.CommandCount is incremented (or reset-- see below) in response to every command. This is used tosynchronize communication between Alto and M6800.AddressOfData and Data are used by the memory access protocol. The same byte locations are usedunder special circumstances to report printer malfunction (MalfRevNumber and MalfCopyNumber-- see3).The remaining bytes (Mode-Sequence and Malfunction) are used to report standard printing status (see 2).Of course, the Alto can also obtain arbitrary information about the microprocessor by reading from itsmemory using the control protocol.1.3 Control Protocol CommandsThe ROS adapter transmits from the Alto a 12-bit ROS command which is interpreted as a 4 bit commandand one byte of data. One of the commands (code: 12=14b=Cx) will cause a hardware-generated non-maskable interrupt (NMI) as it is presented to the PIA. The NMI routine will treat this interrupt as arequest to enter wait state. All the other commands generate a standard external maskable interrupt(IRQ), and each command is processed by a unique interrupt routine.For an Alto program, a printer control command is a 16-bit word with the following structure:structure CONTROL-COMMAND [ExternalCommand bit 4(this field is set to 6)ControlCode bit 4(see code assignement below)Arg bit 8(a data byte interpreted by the microprocessor)]The M6800 acknowledges completion of a command by incrementing the CommandCount status field,except after execution of command ResetCount. The Ignored status bit is set if the command is illegal. 0ResetCountUsed for initializing or synchronizing the command count.CommandCount _ Arg; 1LoadHighLoad Arg into the high order byte of the current memory address "register"(CMA).CMA^1 _ Arg;$RgsXJjf bvsA ^vsv s xs ZvsN W^ vsvsv s  Upxsvs Qv s3 NFv s6 LX1 Hv svs- Fv sv s Dxs ARv sv s2xs =J ;" 7fx 3sws*ws 1\ /wswsws' .H ,ws? ( R$(#vs+(!v s+(%vs+-(7 :v s "v svsv  s51vsv svs/ vs v  yA]3P* Protocol and Software92LoadLowLoad Arg into the low order byte of the current memory address "register"(CMA).CMA^2 _ Arg;3Read Read two bytes from current memory address, and increment the currentmemory address by 2; Arg is ignored.Data^1 _ CMA!0;Data^2 _ CMA!1;AddressOfData^(1,2) _ CMA;CMA _ CMA + 2;4WriteWrite one byte (Arg) into current memory address, and increment thecurrent memory address.@CMA _ Arg;Data^1 _ Arg; Data^2 _ 0;AddressOfData^(1,2) _ CMA;CMA _ CMA + 1;Arg is repeated in Data^1 just as additional confirmation.Automatic increment of the address permits loading of the RAM bysuccessive Write commands.5PrintArg is a data byte to be stored in a reserved location. A subsequent printArgumentcommand will use it as a parameter6PrintArg is a subcommand byte to be processed by the printing routine.CommandPrinting commands are described in section 3. One printing command,WaitRequested, is actually a control command. It sets the status bitWaitAck. When convenient, the wait state is entered via a software interrupt(SWI).7LoadLoad CMA with the address of the routine indexed by Arg. This isRoutinepresumably followed by an Execute Routine command (see below). TheAddressmost commonly used routines have indices:0Software reset.16500 program in RAM (if loaded).26500 program in PROM.3Test of RAM memory, followed by reset.12AttentionCauses a non-maskable interrupt (NMI) which immediately suspendsprocessing and enters wait state, setting status bit WaitState, and clearingstatus bit WaitAck.15ExecutionThis is a command to resume active processing. It is ignored unless inControlwait state. Arg specifies one of the following subcommands:1 Continue interrupted routine.2 Execute Routine at address CMA.$RgsXJjfbv svs. `0vs^Bv Zsv s ZV&Z1  Xvs VvTRsQv Mrsv s!hM&Mrvs/ KIv GEC  Asvs# ?"ws > vs :nv vs68v s"4v s>2v s xs 1v s) /!vs3 -3ws)v svs,vs'v svs %v s)#" !" ws " ws " wsuv sI!wsJ  'vs   vsv s2v s vs,)vs ;vs vs <[:cP* Protocol and Software101.4 M6800 State RegistersThe entire accessible machine state is contained in the M6800 memory and in the six main registers. Thecontents of these registers, just as wait state was entered, is available as otherwise illegal memoryaddresses:30000b=3000xAAn accumulator (1 byte)30002b=3002xBThe other accumulator (1 byte)30004b=3004xIXThe index register (2 bytes)30006b=3006xPCThe program counter (2 bytes)30010b=3008xCCThe condition code (1 byte-- low order six bits significant)30012b=300AxSPThe stack pointer (2 bytes)These values are not meaningful when when not in wait state, since there is no defined machine state:the read or write request will be ignored.1.5 Alto Software: OrbitTest and M68MidasOrbitTest is a diagnostic program for testing and debugging Orbit [4]. It can be used for poking at theM6800 controller. Running in test mode 2, individual commands can be sent to the microprocessor, andROS status is displayed.M68Midas is a version of the Alto program Midas for loading and debugging processors interfaced to anAlto [5]. It offers commands for reading from and writing into arbitrary memory location, sendingprinter commands and examining ROS status, executing routines specified by address or index,interrupting a routine by an attention command (NMI) or a wait request (SWI), and loading the M6800RAM from an Alto MB file containing the microprocessor object code. These operations are convenientlydone through mouse and display interactions.$RgsXIf bx ^s&A \/6 Z 2W vsX2U* vs2S< vs2QN vs2O` vs<2Mr vs I-8 G* Cx* ?sa >"C <ws 8!D 620 4ws0 2& wsws 0ws ws*) ., *A=0P* Protocol and Software112. M6800 Microprocessor ProgramAny P* printers can operate in three modes that are set by a key switch on the console. In standAlonemode (switch position copy), it operates exactly as a regular copier. In remote mode (switch positionprint), it functions as a raster-scan printer under control of the Alto. Finally local mode (switch positiontest) is used for printing alignment patterns synthesized by the ROS Adapter. In all three modes theprinter is controlled by the same microprocessor program. The flow of the program is organized inseveral phases, or sequences. The main sequences are the same for all printers: power on, warm up,standby, printing, and malfunction clearing. Different printers may have different printing sub-sequences. (See attached figure.)This section describes the main features of the internal design of the M6800 control program for Puffin,Pimlico, and Penguin. It also explains the status and error reporting conventions.2.1 Puffin and PimlicoIn the interest of flexibility, the main printing routine is implemented as a table driven interpreter. Thisallows, for each printed page, an arbitrary combination of primary colors in any order. Variation intiming and machine signal control can also be tried easily.2.1.1 Printing SequenceImages (whether copied or printed) are formed on the drum and transferred onto paper during thePrinting sequence. The operation of the 6500 engine during the printing sequence can be described interms of a series of actions to be taken during each revolution of the drum, for instance feeding a sheetof paper on the transfer roll, activating one developer housing, turning on the scan lamps, etc. In orderto permit most flexibility, the printing sequence is executed by a program interpreting a list of actionsspecified in a printing table. Interpretation of this table is conditioned by the values of printingparameters that are determined for every revolution.The printing table is fixed and built into the M6800 program: it is a parametrized description of the mostgeneral drum revolution. On the other hand, the printing parameters are variables that dictate whichspecific actions will take place for a given revolution. The printing parameters are determined by acommand queue and by a few printing controls. Each entry in a command queue (combined with theprinting controls) specifies some parameters for one printing revolution. The Puffin user sets a commandqueue and the printing controls via an Alto program (in remote mode) or via the console buttons (inlocal and test modes).2.1.2 Printing TableThe printing table is organized according to the 33 event times that subdivide a drum revolution (about 6seconds), and establish the timing for the 6500 engine [9]. These event times are detected by the enginein the standard fashion, and provided to the microprocessor as interrupts via the 6500 PIA. The printingtable has the following structure:$RgsXIf=aui \s:"v Zsvs0vs  XvsHvs Vvs=ws T>% Rvs* Q,5 O! IR GS Cx ?sg >X <; 7x 4sI 12)= 0; vsM .MK ,_Kv s *rv s>v ( svs $vs*% #)vs !Q %v s vs3 7,vs5 I V [ x ]sU o \ Qws " LA\-P* Protocol and Software12structure PRINTING-TABLE [EventEntry^0,32 @EVENT-ENTRY]structure EVENT-ENTRY [EventTime byteSignalCount byteSignalEntry^1,SignalCount @SIGNAL-ENTRY]structure SIGNAL-ENTRY [Condition^1,etc @CONDITIONAction byteSignal byte]structure CONDITION [And bitNot bitParameterIndex bit 6]A Condition refers to a particular printing parameter specified by a ParameterIndex. To satisfy thecondition, the printing parameter must be true (i.e. non-zero) if the Not bit is cleared, or false (i.e. zero)if the Not bit is set. Several simultaneous conditions may be required, in which case the And bit is set,except for the last condition in the list. A typical Action is to turn on or off a particular 6500 controlline specified by the argument Signal. More elaborate subroutines are also invoked by this mechanism.The table is actually written with assembly language symbols, and therefore it presents a fairly readabledescription of the 6500 engine timing. A section of the current printing table looks like:......T3(event time)4(number of signal entries)always(no condition to satisfy)TurnOffFullColorCount(signal Z5/X2)ifLowPaper(one condition to satisfy)TurnOffDev11Bias(signal Z11/X2)ifClearingRev2 + and(two conditions to satisfy)ifNotLowPaperTurnOnReadyLamp(signal Z1/X3)ifClearingRev2 + andifNotLowPaperSendEnginePIAProgrammerOff(6500 PIA output line)$RgsXIfb(`0v s(^BZ(Xvs(Vv s(Tv sv s (RO`(Mrvs(Kvs(Ivs(GD(B%vs(@7vs(>Jv s(<\ 8vs:v s 64vs% 4vsMvs 2* vs/ 1vs$ -zY +[(w'F%+ $+!+ b + c +~++\ w+    * +^ A]'P* Protocol and Software13T4(event time)0(number of signal entries)T5(event time)1(number of signal entries)ifShortPaperTurnOffDev9Bias(signal Z10/X2)......2.1.3 Command QueueA command queue entry defines a number of actions to be taken during one revolution. It contains thefollowing fields, set to one of the following values:Color:noColor, color6, color7, color9, color11Following standard 6500 nomenclature, the colors are identified by the "hour" positionof their developer housing, viewing the section of the drum as a clock dial. Usually 6 isblack, 7 is cyan, 9 is magenta, and 11 is yellow.Filter:noFilter, filter6, filter7, filter9, filter11.Filters are used only when an image is scanned from the platten.PaperAction:One of four values:noAction: do nothing!feedPaper: paper is to be fed onto the transfer roll at the beginning of the revolution.releasePaper: paper is to be stripped from the transfer roll at the end of therevolution.singlePass: feed then release paper within the same revolution.Notice that the validity of some of these commands is determined by the parameters ofthe previous revolution. Consistency is checked when a command queue entry isprocessed to generate the printing parameters for the next revolution, at about time T28of the current revolution. Inconsistencies cause printing to stop.LightSource:One of five values:video: video comes from the ROS Adapter.scanning: image is scanned from the platen.mixed: video and scanning.erasing: no video, no scanning, erase lamp on all around.noLight:nothing!Next:Pointer to the next queue entry. (Pimlico: There are two reserved values: endOfQueueand endOfQueueReached.)Flags(Puffin) These are bits used to indicate certain conditions for a queue entry, such as:free, inUse, endOfQueue, inProcess. These flags are only used and set internally.$RgsXIf`w+ _9+\+ [:+X WU+TyS< Nx KasX Is5 Evsv(CsBBW@1 <vv.:s@ 6v s5vs 3 v s;12v s2/D -Vv s4+i=){E'6vs w%sC " v s vsws.vs"@vsRvs1dvs vsAv svs LvsN ^vsvsv svs$ $ A[P* Protocol and Software14The endOfQueue flag indicates the end of a command queue. It causes termination of the printing runin an orderly fashion: all printed copies are cleared from the paper path and delivered in the output tray(see 2.5). The same happens if Next is zero.The command queue structure may be used in several ways. For instance, a cyclic queue may beconstructed that describes a repetitive series of drum revolutions, e.g. the magenta/yellow/cyanrevolutions for a standard 3-color copied or printed page. Termination of the run then depends on anexternal action: STOP button has been pressed, or the dialed copy count has been reached. This is thetechnique used when the engine runs with the key in the copy or test position.A finite queue terminated by endOfQueue describes a series of revolutions that will automatically finishwhen the last entry is processed. More queue entries may be appended to the queue, even whileprinting is happening, provided that the end of the queue remain at least two entries beyond the onebeing currently processed. This is the preferred technique when the engine is run as a printer (keyposition print), as it provides a better control of the engine by the Alto. The printing protocol, describedin 3.4, allows an Alto program to build and extend a command queue: one entry will be provided foreach drum revolution.2.1.4 Printing ControlsThe printing controls are printing parameters that are valid for all the revolutions of an uninterruptedprinting run.PrintingMode: one of three values, set by a 3-way switch on the 6500 console.remote: all printing is under control of the Alto (switch position print).standAlone: the 6500 acts as an ordinary color copier (switch position copy).local: all printing under control of the ROS adapter for generation of standard testpatterns (switch position test).PaperType:one of three values:shortPaper: 11 inch paper.longPaper: 14 inch paper (imposes DevCycle_longCycle)transparency.Value for this parameter is provided by the standard 6500 paper detection mechanism.PageSyncEventTime:This parameter applies only in remote or local mode. Sets event time (T1 to T32) atwhich PageSync is sent to the ROS adapter [3]. This is usually T13.2.1.5 Printing Parameters The printing parameters are determined before every drum revolution, at time T28 of the previousrevolution. They depend on a number of variables:- the parameters of the previous drum revolution: for instance, there is paper on the drum, or themachine is in the clearing cycle.- the next entry, if any, in the command queue.$RgsXIf bv sV `0P ^Bxsvs ZZ X6* Vb TwsQ R8vsvs O`v s, Mr'7 K ?:K-K  I@$ GvsL ExsA C ?dx ;sH 9 6Kv s@4^vs;vsv2p sJf <\B5<T<\ :n8- 85 3x 0;sxs9ws .Mvs;*(v s&vs$vs#vs){!vs%vs7vsIv s){[v s){ mv sv s vsv s v s  B\-P* Protocol and Software16Malfunction byteAddressOfData byte 2 = MalfRevNumber byte 2Data byte 2 = MalfCopyNumber byte 2]Mode Status (Puffin, Penguin only)The mode status reflects the state of the console key switch:1remote2standAlone3localSequence Status (Puffin, Penguin only)The sequence status is reported continuously. It shows the flow of control in the microprocessorprogram. It can be used from the Alto to verify that the operation of the 6500 is proceeding smoothly.The main sequences are the same for Puffin and Penguin:1Power On2Warm-up3Stand-by4Printing5Malfunction ClearingFor Puffin, the printing sequence subdivides into:0DoPrint1StopRequested: normal end of run2StopRequested: low paper3StopRequested: illegal paper feed request4StopRequested: illegal paper release request5ClearingThe Power On state is set as soon as the 6500 machine is turned on. At this point, one can decide to runthe M6800 program in the PROM or in the RAM. To run in the PROM (which means as a copier only),press the START button or start routine 2 from the Alto (see 1.3). To run in the RAM, load the programfrom the Alto and execute routine 1 (see 1.3).The 6500 then goes into Warm-up, a process that may take as much as 10 minutes if the engine is cold,and then into Stand-by. It is now ready to receive to receive commands, from the Alto or from theconsole buttons and switches. The normal course of events during a printing run is the cycle: Stand-by,Printing (DoPrint), Printing (StopRequested), Printing (Clearing), and again Stand-by. This regular cyclemay be interrupted by an engine malfunction, an illegal command queue entry, or a lack of paper.$RgsXIfbv s`0v s v s^Bvs v s\T Xv" U*s=QvOsv Msv J#& Fs;& D52 B7?>?=/<=/;A:T;A9T89T7f7 U7f 33y30;v.Msv s,_v s *rv s(v s&v #s" #;" !ws wsws % wsxsws 7)xs K ;  ]TG S FoT vsv s'kvs : T Kx BV`P* Protocol and Software17Mode-Sequence status (Pimlico only)Pimlico engine status is reported in a sliightly different form than for the Puffin and Penguin. The one-byte field Mode-Sequence is used:1Power On2Warm-up3Stand-by4Printing (state DoPrint)5Printing (state StopRequested): normal end of run6Printing (state StopRequested): low paper7Printing (state StopRequested): illegal paper feed request8Printing (state StopRequested): illegal paper release request9Printing (state Clearing)10Malfunction ClearingThe meanings of these states are the same as for Puffin, described above.Malfunction StatusWhen the microprocessor detects a malfunction, it stops the machine, reports the malfunction status code(table below), records the revolution and copy number. In most cases, and especially when paper jams, itwaits for operator intervention and for a signal to proceed (toggling the bottom tray handle). In all caseit then clears the machine, expelling all copies from the paper path, and returns to Stand-by.010b=08xFire detected032b=1AxLow paper or paper tray unlocked004b=04xMalfunction memory set016b=0ExPaper jam on transport A034b=1CxPaper grip jam036b=1ExPaper jam on transport B050b=28xFuser interlock open054b=2CxBottom tray interlock open056b=2ExPaper jam on transport B074b=3CxFront door open116b=4ExToo many toner calls150b=68xFunctional interlock open200b+nEvent Tn missed (from 200b=80x to 240b=A0x)After a malfunction stop, the 6500 must be restarted as for a fresh run. The only exception is for a lowpaper stop in standAlone or local mode: the machine remembers the copy count and the color settings,and the run will continue normally after pushing the START button. In all other cases, commands mustbe given again from the Alto or the console buttons.The Alto may obtain information about the revolution number and the copy number at the time of theinterruption with a special printing command (see 3.4).$RgsXIf bv# ^s$E \ v sYXYWVWU*TTU*S<RS<vsQNPQNv sO`O O`v s MrMMrv sKK-Kv sII?IvsGGQ UG DI ?dv ;sc 9 [ 7'D 6UE5T62p 0.,* (&$#!%7Ivsvs# 72  v svs# 5ws" 4 UR g2xs A\RP* Protocol and Software182.2 Penguin[your turn Chuck...]2.2.1 Penguin etc...[etc]2.2.2 Penguin etc...[etc]$RgsXIf bx ^s Z x Vs R"x Nsn J~/P* Protocol and Software193. Printing ProtocolsThe M6800 control program, described in the previous section, attempts to be fairly general andparameterized, in order to meet several requirements:- Running the machine in all modes with the same program;- Emulating a standard copier when in standAlone mode;- Allowing the Alto to have close control over the engine when in remote mode.This section describes the behavior of Penguin, Puffin, and Pimlico in the three different modes, anddiscusses the printing protocol that is used by Alto programs for controlling the printer in remote mode. 3.1 Puffin and PimlicoDriving these engines is primarily done by building a printing queue (see 2.1.3). The queue is specifiedeither via the console buttons (standAlone or local modes) or via printing commands (remote mode). Inthe current implementation (Puffin only), all printing queues should start with a blank revolution used toinitialize the ADC control routine.3.1.1 Printing ModesStand-alone ModeThis mode is set by turning the console key switch to the copy position. The 6500 then runs as a regularcopier. The image on the drum is provided by optical scanning of the platen: thus, all command queueentries have their LightSource field set to scanning.The control panel of the 6500 is enabled:- The START button, the 4 color selection buttons, the copy count dials are examined duringStand-by and during the Clearing phase of the printing sequence.- The STOP button is examined at all times.- The 3-way key switch is examined during Stand-by.A circular command queue is constructed according to the actions on the color selection buttons. Thusprinting can terminate only if the STOP button is depressed, or the requested copy count is reached. Iffull color is selected, the queue will look like:entry 0: noColor, noFilter, noAction, noLight, goto 1;entry 1: color9, filter9, feedPaper, scanning, goto 2;entry 2: color11, filter11, noAction, scanning, goto 3;entry 3: color7, filter7, releasePaper, scanning, goto 1;On Pimlico, the first null revolution is omitted.Local ModeThis mode is set by turning the console key switch to the test position. The 6500 runs under control of$RgsXIf$>aui ^Bs[ \T5Zf9Xx&v sVBvs RF QAvs Lx I s"(xs Gv svsvs E-O C@# >x :nv 6svs+ 4*; 2v s vs /h)-zws D +5T++5+)ws!'*/<'YT' $vsW "-#ws, ?1v-sv-sv.sv0 Ks1 v Ms:vs A]( P* Protocol and Software20the ROS adapter which provides a standard video test image. The command queue used is like the oneabove, except each entry uses a LightSource of video rather than scanning, and noFilter is usedthroughout.ROS adapter status Local is set. Status PrintMode is set during the Printing sequence. BeamEnable is setwhen the machine doors are closed. ROS adapter status PageSync is sent at event timePageSyncEventTime.The control panel of the 6500 is used as in standAlone mode (see 3.1). A circular command queue isconstructed according to the actions on the color selection buttons. Printing terminates only if the STOPbutton is depressed, or the requested copy count is reached.Remote ModeThis mode is set by turning the console key switch to the print position. All printing is under control ofthe Alto.ROS adapter status PrintMode is set during the Printing sequence. BeamEnable is set when the machinedoors are closed. ROS adapter status PageSync is sent at event time PageSyncEventTime of everyrevolution for which LightSource is either video or mixed.The control panel of the 6500 is disabled, except for the STOP button which can be used for stopping aprinting run, and the the 3-way switch which is examined in Stand-by. Control of the 6500 is done viaprinting commands. There are commands for starting and stopping the engine, specifying a commandqueue and other printing parameters, etc. The M6800 program that interprets the printing protocol mustbe loaded in the RAM.3.1.2 Printing Protocol CommandsThe printing protocol is implemented as a subset of control command PrintCommand (see 1.3). The 8-bit argument of PrintCommand specifies the printing operations by a two-part code: C (three leastsignificant bits), and P (five most significant bits). Viewed by an Alto program, a printing command is a16-bit word with the following structure:structure PRINTING-COMMAND [ExternalCommand bit 4(this field is set to 6)PrintCommand bit 4(this field is set to 6)Code-P bit 5Code-C bit 3]The assignment of printing command codes is as follows. (The full 16-bit printing command is alsogiven, in octal and hexadecimal form.) For Pimlico, if the printing program has not been loaded into theRAM by hand, all commands set status bits Ignored and NoRamcode.C=0$RgsXIf bwsC `0v svs vsvs ^B Zwsvsvs4ZVZ v s XEFwsvs Vvs S< v s xsvs QN'?w O`s< Jv Gbs1vs, Et Awsvs(AA v s ?wsvsvs >v s vsvs :n /ws( 8<18)T8 6H 4Y 2ws .Mx! *s$v sxs (v sE &A) $)!Y(kvs){(}v s+(vs(vs( KZ ]K ows'vsv s A\LP* Protocol and Software21P=0WaitRequested (63000b=6600x)Acknowledge wait request by setting status bit WaitAck. When convenient enter waitstate via software interrupt (SWI).P=1ResetRemoteQueue (63010b=6608x)This command clears and resets a ring buffer in RAM used for the remote commandqueue. This is the queue that can be constructed by an Alto program. The command isignored during Printing. The normal use of this command is at the beginning of eachprinting run.P=2AppendQueueEntry (63020b=6610x)This command appends a new entry to the remote queue. In order for that command tosucceed, the last queue entry must be at least two beyond the entry currently beingprocessed by the printing routine.If the command fails, status bits QueueLate and Ignored are set. This means that theprinting sequence has run ahead of the Alto program: the printing run will terminate.The remote queue is implemented similarly to a ring buffer that is "written" by printingcommands, and "read" by the Printing sequence. The command may also fail if the"ring buffer" is full: this means that the Alto program is too far ahead of the printer. Inthis case, status bits QueueFull and Ignored are set. The command may be retried atsome later time. A maximum of 64 outstanding entries in the remote queue is allowed(50 for Pimlico), much more than should ever be used.If the command is successful, a new entry NewQE is created with its fields defaulted asfollows:NewQE.Color _ noColor;NewQE.Filter _ noFilter;NewQE.PaperAction _ noAction;NewQE.LightSource _ noLight;P=3StopPrint (63030b=6618x)This command stops the printing run as soon as the current copy has been processedthrough all its color passes. Processing usually continues until the next releasePapercommand is found in the command queue. If the end of the queue is reached first, onerevolution will be added if paper must be stripped from the transfer roll.It is not usually necessary to use this command. The remote queue may be contructedas needed to describe all the revolutions of the drum, and printing will naturallyterminate when the end of the queue is reached. The stop command is needed if one ofthe standard cyclic queues is used.P=5SendMalfunctionData (63050b=6628x)This command is used to collect information about a reported malfunction (i.e. statusfield Malfunction was non-zero). It returns the revolution number and the copy numberin status fields MalfRevNumber and MalfCopyNumber, and clears status fieldMalfunction. Double buffering is used to guarantee that the information is consistentwith the reported malfunction: successive malfunctions are not reported untilMalfunction status has been cleared.$RgsXIfbv s`0/vs^BwsZvsX $ws v Vs2TTT<R O`vsMr?K"1I"G"vsvsEUC?A)YAA "?>>vsvs <L:'589 vs(6K4^vsv2psv0.sv*svs)R'#Ev %5s>#GJ!Y<k,&}C#vs Iv s21\v sv s ] Cv s-UV)W$ gv s t 7&\]P* Protocol and Software22P=37bSetLongCycle (63370b=66F8x). Sets longer development cycle (Pimlico only).P=17bSetShortCycle (63170b=6678x). Sets shorter development cycle (Pimlico only).C=1P=0SetNoColor(63001b=6601x)NewQE.Color _ noColorP=20bSetColor6(63201b=6681x)NewQE.Color _ color6P=10bSetColor7(63101b=6641x)NewQE.Color _ color7P=4SetColor9(63041b=6621x)NewQE.Color _ color9P=2SetColor11(63021b=6611x)NewQE.Color _ color11C=2P=0SetNoFilter(63002b=6602x)NewQE.Filter _ noFilterP=20bSetFilter6(63202b=6682x)NewQE.Filter _ filter6P=10bSetFilter7(63102b=6642x)NewQE.Filter _ filter7P=4SetFilter9(63042b=6622x)NewQE.Filter _ filter9P=2SetFilter11(63022b=6612x)NewQE.Filter _ filter11C=3P=0SetNoAction(63003b=6603x)NewQE.PaperAction _ noActionP=20bFeedPaper(63203b=6683x)NewQE.PaperAction _ feedPaperP=10bReleasePaper(63103b=6643x)NewQE.PaperAction _ releasePaperP=30SinglePass(63303b=66C3x)NewQE.PaperAction _ singlePassC=4P=0SetNoLight(63004b=6604x)NewQE.LightSource _ noLightP=20bSetVideo(63204b=6684x)NewQE.LightSource _ videoP=10bSetScanning(63104b=6644x)NewQE.LightSource _ scanningP=30SetMixed(63304b=66C4x)NewQE.LightSource _ mixedP=4SetErasing(63044b=6624x)NewQE.LightSource _ erasingC=5unusedC=6StartPrint with following command queue:P=0(63006b=6606x)remote command queueP=34b(63346b=66E6x)standard 3-color video queue (see 3.2)P=24b(63286b=66A6x)standard 3-color scanning queue (see 3.1)P=30b(63306b=66C6x)standard 4-color video queueP=20b(63206b=6686x)standard 4-color scanning queueC=7SetPageSyncEventTime (from 63017b to 63207b)Set PageSyncEventTime to event time P (allowed from P=1=T1 to P=37b=T31). It is defaultedto T13 on Puffin and T17 on Pimlico.$RgsXIfbv s>^v s? ZYv s .qvsvWsvs .qvsv U*svs .qvsv Sv s .qvsv Z Vvs4 Rv yvs Q M,vs+ IPvs* Ev"s B%v's >vs :v+s 7v0s /A8h Power OnMalfunctionWarm-upClearingStand-byPrintingT0T1T2T32T31T30Printing TableCommand QueueRev 1Rev 2Rev 3 etcfffshhk? 84!;46; 84;467 84!34/3 8434/746-4:- 841 84)46) 84!)46%4/% 841144 1 84!494/ 8449+- 241-46+%40+% 247%40!+ 44!3414:11711111114444 4 4 q"!q$!q(4!q+!q.!q" q$ '-''*'- ' ' * ' -''*#3'>r=]r->*_ r5[r.([r<+[rZs2Zs2]s2Ys2|Ys2|]s2|[s1s&~ s([zs([|s([ }s)~t-t%t7t1zt1tt*+ut1m$#v3'>} HELVETICA HELVETICA HELVETICA  TIMESROMAN LOGO TIMESROMAN  TIMESROMAN  TIMESROMAN TIMESROMAN  TIMESROMANSNEWVECiO")@ : HELVETICA  HELVETICA ArrowsZ:#:   't %(*/6<>@HLRZ`flnu|w =%*%i<  Z Y}: }Z" -iP=O;]N=L;]L=I;]J%G9IEG=G#= |=5;]X%39W-3M1 =)]K=(Z$"9 :  %A9a9`E<"$9[9ZB$=5]W: %S9P9O = )%AE_%^) E\%=[iX=C]R%=C%9OP B" -Ei%^9^B"j/9pmachine.pressSproull 5-Apr-83 12:21:13 PST: