PSState.mesa
Copyright (C) Xerox Corporation 1983, 1984, 1985, 1986. All rights reserved.
Last edited by Jacks 15-Oct-85 9:50:07
Tim Diebert: December 19, 1986 2:07:22 pm PST
<<State defines the static state of the Print Service. State is mapped to a file and restored on system restarts. CurrentActivity defines the dynamic state of the Print Service.>>
DIRECTORY
BansheeStatus USING [Type],
BasicTime USING [GMT, nullGMT],
D1Status USING [Type],
FaxStatus USING [TransmissionRetryReason, Type],
FX3500Status USING [Type],
NSName USING [NameStore, nullNameRecord],
NSString USING [String],
PaperHandling USING [ BannerMode, -- D1Registration, Fax495BannerMode, FX3500Registration,-- PaperFeed, PaperStacking, PrintOrder, RavenRegistration, TwoPaperSizes],
PaperTypes USING [nullDimensions, Paper, -- PaperMMDimension, -- PaperSize],
PrintingTypes USING [Option, RavenBuild],
Process USING [Priority],
PSActivity USING [Basic, Marker, Spooler],
RavenStatus USING [Type],
Rope USING [ROPE],
TargetPSStatus USING [Communication],
XNS USING [Address, unknownAddress];
PSState: CEDAR DEFINITIONS =
BEGIN
blank: BYTE = LOOPHOLE[' ];
maxStopReasonLength: CARDINAL = 40;
maxUserNameLength: CARDINAL = 20;
ROPE: TYPE = Rope.ROPE;
ServiceState: TYPE = {notInitialized, starting, started, stopping, stopped};
OperationState: TYPE = {normal, diagnostic, repair, fileWrite, fileDelete, shutDown, notStarted};
OperationMode: TYPE = RECORD[ -- to keep track of overlapping modes
current, returnTo: OperationState];
SpoolerState: TYPE = {enabled, disabled, disabledForMarking, disabledForRepair, disabledForDiag};
ControlState: TYPE = RECORD [
spooler: SpoolerState,
formatterEnabled: BOOLEAN, -- formatter means decomposer and feps9700 merger
markerEnabled: BOOLEAN];
Counter: TYPE = RECORD [total: CARDINAL, grandTotal: LONG CARDINAL];
TraceLevel: TYPE = {none, mini, verbose};
FaxRetries: TYPE = RECORD[
count: CARDINAL ← 0,
delayInSecs: LONG CARDINAL ← 0];
CurrentActivity: TYPE = RECORD [ --Dynamic information indicating current PS activity status. (Not retained across boots.)
condition: ServiceState,
spooler: PSActivity.Spooler,
decomposer: PSActivity.Basic,
queuePages, fontPages: LONG CARDINAL, -- space allocated to queue and fonts
option: SELECT type: PrintingTypes.Option FROM
bansheeDl => [
marker: PSActivity.Marker,
bansheeStatus: BansheeStatus.Type
],
d1 => [
marker: PSActivity.Marker,
d1Status: D1Status.Type
],
fax295, fax495 => [
marker: PSActivity.Marker,
faxStatus: FaxStatus.Type
],
feps9700 => [
merger: PSActivity.Basic,
forwarder: PSActivity.Basic,
forwardingStatus: TargetPSStatus.Communication --valid only if forwarder=busy; indicates okay or error condition
],
fx3500 => [
marker: PSActivity.Marker,
fx3500Status: FX3500Status.Type
],
raven => [
marker: PSActivity.Marker,
ravenStatus: RavenStatus.Type
],
unknown => [],
ENDCASE
];
StateHandle: TYPE = REF State;
State: TYPE = MACHINE DEPENDENT RECORD [ --Static PS status information retained across boots in a backed file.
Current Mode--
mode(0): OperationMode ← [notStarted, notStarted],
clientControl(1): ControlState ← [
spooler: enabled, formatterEnabled: TRUE, markerEnabled: TRUE],
internalControl(2): ControlState ← [
spooler: disabled, formatterEnabled: FALSE, markerEnabled: FALSE],
System Statistics--
networkAddress(3): XNS.Address ← XNS.unknownAddress,
statisticsReset(9): BasicTime.GMT ← BasicTime.nullGMT,
lastInstallation(11): BasicTime.GMT ← BasicTime.nullGMT,
lastBoot(13): BasicTime.GMT ← BasicTime.nullGMT,
lastActivity(15): BasicTime.GMT ← BasicTime.nullGMT,
nBoots(17): CARDINAL ← 0, --since last installation
docsPrinted(18): Counter ← [total: 0, grandTotal: 0],
docsAborted(21): Counter ← [total: 0, grandTotal: 0],
testPatternsPrinted(24): Counter ← [total: 0, grandTotal: 0],
docsRetried(27): Counter ← [total: 0, grandTotal: 0],
docsPurged(30): Counter ← [total: 0, grandTotal: 0],
commErrors(33): Counter ← [total: 0, grandTotal: 0],
lastStopPrintingReason(36): NSString.String ← NIL,
lastUserToStopPrinting(38): NSString.String ← NIL,
lastUserToStartPrinting(40): NSString.String ← NIL,
lastStopQueuingReason(42): NSString.String ← NIL,
lastUserToStopQueuing(44): NSString.String ← NIL,
lastUserToStartQueuing(46): NSString.String ← NIL,
junk(48): ARRAY [48..59] OF WORD,
stopPrintingReasonBody(60): PACKED ARRAY [0..maxStopReasonLength) OF BYTEALL[blank],
stopPrintingUserBody(80): PACKED ARRAY [0..maxUserNameLength) OF BYTEALL[blank],
startPrintingUserBody(90): PACKED ARRAY [0..maxUserNameLength) OF BYTEALL[blank],
stopQueuingReasonBody(100): PACKED ARRAY [0..maxStopReasonLength) OF BYTEALL[blank],
stopQueuingUserBody(120): PACKED ARRAY [0..maxUserNameLength) OF BYTEALL[blank],
startQueuingUserBody(130): PACKED ARRAY [0..maxUserNameLength) OF BYTEALL[blank],
System Parameters--
decomposeWhileMarking(140): BOOLEANFALSE,
spoolWhileMarking(141): BOOLEANFALSE,
formatterPriority(142): Process.Priority, --decomposer and feps9700 merger
markerPriority(143): Process.Priority, --marker and feps9700 forwarder
spoolerTrace(144): TraceLevel ← none,
formatterTrace(145): TraceLevel ← none, --decomposer and feps9700 merger
markerTrace(146): TraceLevel ← none, --marker and feps9700 forwarder
decomposerRMPagesForMarker(147): LONG CARDINAL ← 256, --max real memory the marker can use; tells decomposer how much space is available for bands lists plus fontload
decomposerVMPages(149): LONG CARDINAL ← 6000, --max virtual memory reserved by decomposer
markerRMPagesForBands(151): LONG CARDINAL ← 48, --real memory reserved by marker for band buffers
Printing Option Independent Paper Handling--
printOrder(153): PaperHandling.PrintOrder ← lastPageOutFirst,
stapling(154): BOOLEANFALSE,
twoSidedCopy(155): BOOLEANFALSE,
Reserved for emergency future use:
unused1(156): UNSPECIFIED ← 0,
unused2(157): UNSPECIFIED ← 0,
unused3(158): UNSPECIFIED ← 0,
unused4(159): UNSPECIFIED ← 0,
Printing Option Specific Information--
printingOptionSpecific(160): SELECT option(160): PrintingTypes.Option FROM
bansheeDl => [
invertingTrayAttached(161): BOOLEANFALSE,
banner(162): PaperHandling.BannerMode ← oncePerJob,
paper(163): PaperTypes.Paper ←
[knownSize: letter, otherSize: PaperTypes.nullDimensions],
enableUnlimitedPrinting(166): BOOLEANTRUE
],
d1 => [
banner(161): PaperHandling.BannerMode ← oncePerJob,
paperSize(162): PaperTypes.PaperSize ← a4,
trayEmpty(163): BOOLEANFALSE,
registration(164): PaperHandling.D1Registration ← [long: 15, short: 15]
],
fax295 => [
banner(161): PaperHandling.BannerMode ← oncePerJob,
paperWidth(162): CARDINAL ← PaperTypes.PaperMMDimension[letter].short --millimeters
],
fax495 => [
docsTransmitted(161): Counter ← [total: 0, grandTotal: 0],
banner(164): PaperHandling.Fax495BannerMode ← [local: oncePerJob, remote: suppressed],
paperWidth(165): CARDINAL ← PaperTypes.PaperMMDimension[letter].short, --millimeters
fineResolutionSupported(166): BOOLEANTRUE,
multLocalCopiesAllowed(167): BOOLEANTRUE,
multRemoteCopiesAllowed(168): BOOLEANFALSE,
retries(169): ARRAY FaxStatus.TransmissionRetryReason OF FaxRetries ← ALL[]
],
feps9700 => [
paperSupply(161): PaperHandling.TwoPaperSizes ← [letter, max],
paper supply information saved since last call to target ps paper supply defaulted to one paper tray with letter size ('max' for second paper size means there is none)
targetPSAddress(162): XNS.Address ← XNS.unknownAddress,
targetPSName(168): NSName.NameStore ←
[record: NSName.nullNameRecord, org: ALL[blank], domain: ALL[blank], local: ALL[blank]]
],
fx3500 => [
banner(161): PaperHandling.BannerMode ← oncePerJob,
paperSupply(162): PaperHandling.TwoPaperSizes ← [a4, a4],
topPaperTrayEmpty(163): BOOLEANFALSE,
bottomPaperTrayEmpty(164): BOOLEANFALSE,
paperFeed(165): PaperHandling.PaperFeed ← fromBottomOrTop,
registration(166): PaperHandling.FX3500Registration ← [long: 15, short: 15]
],
raven => [
engineBuild(161): PrintingTypes.RavenBuild ← b1,
banner(162): PaperHandling.BannerMode ← oncePerJob,
paperSupply(163): PaperHandling.TwoPaperSizes ← [letter, letter],
paperFeed(164): PaperHandling.PaperFeed ← fromBottomOrTop,
paperStacking(165): PaperHandling.PaperStacking ← aligned,
registration(166): PaperHandling.RavenRegistration ← [long: 23, short: 8],
enableUnlimitedPrinting(167): BOOLEANTRUE
],
unknown => [],
ENDCASE
];
END. --PSState
LOG
18-Aug-83 14:20:14 - Jacks - Created as part of PSCommand rework; replaces PSExec.
8-Nov-83 10:33:25 - Jacks - Added StateHandle; replaced EngineType definition with PrinterTypes.EngineType; redefined SpoolerState, DecomposerState and MarkerState; added numberOfBoots and some default values to State; removed Paper Handling definitions and put them in their own defs module: PaperHandling; added unknown variant.
11-Nov-83 13:26:43 - Jacks - Added queueFull, spooler, decomposing and ravenActivity; added 'busy', 'spooling' and 'idle' to SpoolerState in place of 'enabled'; redefined ControlState.
16-Nov-83 16:18:32 - Jacks - Removed displayAbortedNames from State.
18-Nov-83 16:05:53 - Jacks - Added coLion, aps5 and fax495 variant choices.
3-Dec-83 8:45:16 - Jacks - Changed coLion to fx3500 (new PrinterTypes I/F)
16-Dec-83 9:53:33 - Jacks - Removed queue stages; added more engine specific stuff; placed all transient information about PS activity and current status in CurrentActivity record, which won't be backed by a file; made State MACHINE DEPENDENT.
24-Jan-84 18:24:42 - Jacks - Added lastStopReason, lastUserToStopPS, lastUserToStartPS; changes to fax variant.
9-Feb-84 11:14:42 - Jacks - Added lastStopQueuingReason, lastUserToStopQueuing, lastUserToStartQueuing, topPaperTrayEmpty and bottomPaperTrayEmpty.
22-Feb-84 11:23:57 - Jacks - Added statisticsReset.
19-Sep-84 13:28:24 - Jacks - Added fax295, banshee and feps9700 variants; removed aps5 variant; added paperSupply and fineResolutionSupported for fax495; added stapling and twoSidedCopy; removed decomposerMaxVMPages; moved "marking" into variant part of CurrentActivity.
12-Nov-84 13:34:00 - Jacks - Second round of changes for 9.0: deleted diagModeEntered and okayToFormat from State (they are obsolete); removed banner from feps9700 State variant; replaced MarkerControl dependence with Status interface.
14-Jun-85 11:08:18 - Jacks - Added copyright notice; updated to PS Euclid interfaces.
19-Jun-85 15:34:29 - Jacks - Activity renamed to PSActivity.
25-Jun-85 13:29:22 - Jacks - Added d1 variants.
19-Jul-85 9:44:52 - Jacks - Defined ServiceState and stopped using NSExec.ClientStatus; added queuePages and fontPages to CurrentActivity.
23-Sep-85 10:44:30 - Jacks - State: added unused1 to unused4, added enableUnlimitedPrinting to raven and banshee variants.
15-Oct-85 9:50:04 - Jacks - BansheeDl paper size now PaperTypes.Paper.