252301 Issue 2.0 - 第53页
GEM Manual for DEK Printers Capabilities I ssue 2.0 June 9th, 2011 page 53 of 156 Transition Table: # Current State Trigger New State Action Comm ent 1 SPOOL INACTIVE Comm unications failure detected. SPOOL ACTIVE Spooli…
GEM Manual for DEK Printers Capabilities
Issue 2.0 June 9th, 2011 page 52 of 156
The second flow control method is to allow the host to limit the maximum number of messages
sent from the spool in response to the S6F23 request. An equipment constant
“MaxSpoolTransmit” can be set by the host to achieve this behaviour. If MaxSpoolTransmit is
set to five, for example, the printer will send the first five messages from the spool and then
transition to the NO SPOOL OUTPUT state, awaiting the next S6F23 request. There is no
event report generated when MaxSpoolTransmit is reached. The host is responsible for
determining this situation by a) counting the messages received, b) timing out waiting for the
next message, c) inquiring to the printer for the current value of the SpoolCountActual status
variable, or d) some combination of the above. If MaxSpoolTransmit is set to zero, the spool
will be transmitted completely in response to S6F23.
Normal spooling continues during the spool transmit process. If the SPOOL LOAD component
transitions to SPOOL FULL, it will not have any effect on the SPOOL UNLOAD component. Once
full, the spool cannot make the transition back to SPOOL NOT FULL except via the SPOOL
INACTIVE state. Space made available due to the spool unload process will not be used in this case.
When a multi-block message is to be transmitted from the spool, any required inquire/grant transaction
will be initiated. If the host's response denies permission to send the multi-block message, the printer
will discard that message and continue with the transmit process. This sequence will count as one
message in the MaxSpoolTransmit count.
There is one area where SPOOL LOAD and SPOOL UNLOAD may interact: When the spool is full
and OverWriteSpool is True. During the spool transmit process, spooled messages are being removed
and new primary messages are being written to the spool. These new messages are overwriting the
oldest messages available, unless the unload process has freed sufficient spool space.
There is a possibility that the unload and overwrite processes may compete for control of the same
message area. For example, if the spool holds messages ABCDE, with A oldest and E newest, A might
be sent to the host, B (and the space from A) overwritten by the new message F, C sent to the host, D
and E (and the space from message C) overwritten by G, etc. The loss of continuity may be
disorienting to the host program receiving the messages. It is expected that the unload process will be
fast relative to the generation of new messages, so that this occurrence will be rare.
If a communication failure occurs during the spool transmit process, spooling will continue as before
the transmit process began. However, the spool unload sequence will terminate.
PURGE SPOOL - The printer will discard all messages in the spool and, when the spool is empty,
zero SpoolCountActual.

GEM Manual for DEK Printers Capabilities
Issue 2.0 June 9th, 2011 page 53 of 156
Transition Table:
# Current State Trigger New State Action Comment
1 SPOOL
INACTIVE
Communications failure
detected.
SPOOL
ACTIVE
SpoolingCountActual
and SpoolCountTotal
are initialised to zero.
Any open transactions
with the host are
aborted.
SpoolStartTime is set
to current time.
The default state in each
OR substate is entered.
The message that could
not be sent remains in the
send queue and is dealt
with in the Spool Active
state. The collection
event Spooling Activated
has occurred.
2 SPOOL NOT
FULL
A message is generated that
will not fit in the spool area.
SPOOL FULL SpoolFullTime is set
to current time.
The message that would
not fit into the spool is
dealt with after the
transition. No collection
event is generated.
3 SPOOL
OUTPUT
Spool area emptied. SPOOL
INACTIVE
Spooling process
disabled. The operator
is informed that
spooling has been
terminated.
The collection event
Spooling Deactivated has
occurred. Transition from
the substate Spool Load
occurs.
4 NO SPOOL
OUTPUT
S6F23 received with RSDC
= 1.
PURGE
SPOOL
No Action Initiates purging process.
No collection event is
generated since this is
based on host request.
5 NO SPOOL
OUTPUT
S6F23 received with RSDC
= 0.
TRANSMIT
SPOOL
No Action Initiates message
transmission from spool.
No collection event is
generated since this is
based on host request.
6 TRANSMIT
SPOOL
Communication failure or
MaxSpoolTransmit reached.
NO SPOOL
OUTPUT
Spool transmission
process suspended.
If communications
failure, the event Spool
Transmit Failure has
occurred. No collection
event generated for
MaxSpoolTransmit
reached.
7 POWER ON Printer loses power. POWER OFF No Action Spooling context has
been maintained in non-
volatile storage prior to
this transition.
8 POWER OFF Power restored to Printer. POWER ON Spooling context
restored from non-
volatile memory.
If spooling were active
prior to power down, it
will continue. If
TRANSMIT SPOOL
was active at power
down, transition #6 is
expected to follow since
communications state is
initially NOT
COMMUNICATING.

GEM Manual for DEK Printers Capabilities
Issue 2.0 June 9th, 2011 page 54 of 156
Scenarios:
Host defines messages to be spooled:
Comments Host Equipment Comments
Host defines messages to be spooled in
case of communication failure.
S2F43 -->
<-- S2F44 Equipment acknowledges setup.
Host sends value for MaxSpoolTransmit:
Comments Host Equipment Comments
Host sends value for equipment
constant MaxSpoolTransmit.
S2F15 -->
<-- S2F16 Equipment acknowledges equipment constant
change.
Host sends request or delete spooled data: (MaxSpoolTransmit = 0)
(Communications were lost and then re-established)
Comments Host Equipment Comments
Host requests data that includes spool
related status variables.
S1F3 -->
S1F3 is one of several methods that could be
used.
<-- S1F4 Send status data.
Host requests or deletes spooled data. S6F23 -->
<-- S6F24 Request Spooled data acknowledged.
[IF] RSDC = 0 (Spool data requested.)
[THEN] The appropriate streams and functions
are used to transmit the spooled data to the host.
[ELSE_IF] RSDC = 1
[THEN] Spool data discarded.
[END_IF]
<-- S6F11 Spooling de-activated Event Report sent.
Acknowledge S6F12
Host sends request or delete spooled data: (MaxSpoolTransmit > 0)
(Communications were lost and then re-established)
Comments Host Equipment Comments
Host requests data that includes spool
related status variables.
S1F3 -->
S1F3 is one of several methods that could be
used.
<-- S1F4 Send status data.
e.g. SpoolCountActual = 8
MaxSpoolTransmit = 5
Host requests spooled data.
RSDC = 0
S6F23 -->
<-- S6F24 Request Spooled data acknowledged.
The five oldest messages in the spool are
transmitted to the host.
Spooling remains active.
Host recognises that
MaxSpoolTransmit has been reached.
Host requests remaining data.
RSDC = 0
S6F23 -->
<-- S6F24 Request Spooled data acknowledged.
The three remaining messages in the spool are
transmitted to the host.
<-- S6F11 Spooling de-activated Event Report sent.
Acknowledge S6F12