Download as pdf or txt
Download as pdf or txt
You are on page 1of 65

CBDSMEN0022 Date March 05, 2018

SOFTWARE REFERENCE Release N. 2


MANUAL Page 1 of 65

CBD 1000HT
CHEQUE BOOK DISPENSER

SOFTWARE REFERENCE MANUAL

Issued March 05, 2018


Release No. 2

ROTOTYPE S.p.A Tel +39 055 8825444


Via F. Bessi, 15 Fax +39 055 8873643
50041 Calenzano info@rototype.com
(Firenze) Italy www.rototype.com
CBDSMEN0022 Date March 05, 2018
SOFTWARE REFERENCE Release N. 2
MANUAL Page 2 of 65

This software reference manual relates to CBD 1000HT equipped with


the following firmware releases:

DDO Board:
BCH 3.11 / BCI 3.11 (or higher release numbers)
ECH 3.11 / ECI 3.11 (or higher release numbers)
ECM 4.3 / FTM 2.9 (or higher release numbers)

PRT Boards 1-3:


PRT xxxx 3.0 / PRN xxxx 3.0 (or higher release numbers)
(xxxx: 4-letters group indicating
available fonts)
CBDSMEN0022 Date March 05, 2018
SOFTWARE REFERENCE Release N. 2
MANUAL Page 3 of 65

All rights reserved. No part of this document may be reproduced


or transmitted in any form without written permission by
ROTOTYPE S.p.A.
CBDSMEN0022 Date March 05, 2018
SOFTWARE REFERENCE Release N. 2
MANUAL Page 4 of 65

CONTENTS

1. COMMUNICATION BETWEEN HOST COMPUTER AND CBD 1000HT


EQUIPMENT 6

1.1 LINE PROTOCOL...................................................................................................................................6

1.2 CLASSES OF MESSAGES.....................................................................................................................7

1.3 MESSAGES FROM CBD 1000HT TO HOST COMPUTER..............................................................7


1.3.1 Status Message.........................................................................................................................................7
1.3.1.1 Error Codes.....................................................................................................................................10
1.3.1.2 Jamming Error Codes......................................................................................................................12
1.3.1.3 Hardware Failure Codes..................................................................................................................14
1.3.2 Other messages.......................................................................................................................................15

1.4 MESSAGES FROM HOST COMPUTER TO CBD 1000HT............................................................15

2. ORDERS 18

3. ORDINARY INSTRUCTIONS 21

3.1 INSTRUCTION SYNTAX.....................................................................................................................21

3.2 INSTRUCTIONS DESCRIPTION.......................................................................................................22


3.2.1 Document production.............................................................................................................................22
3.2.1.1 String 1,2 and 3 definition...............................................................................................................22
3.2.1.2 String 4 definition............................................................................................................................23
3.2.1.3 Further details..................................................................................................................................25
3.2.2 Other instructions...................................................................................................................................27
3.2.3 OCR Text Reader...................................................................................................................................37

4. SPECIAL INSTRUCTIONS 38

4.1 SOLENOIDS AND READER WINDOW ACTIVATION.................................................................39

4.2 MOTORS CONTROL...........................................................................................................................39

4.3 TRIMMING (OFFSETS SET-UP)........................................................................................................41

4.4 INTERNAL DEVICES CONTROL......................................................................................................43

4.5 HARDWARE TEST...............................................................................................................................44

5. PRINTERS 45

5.1 GENERAL DESCRIPTION..................................................................................................................45

5.2 STRINGS.................................................................................................................................................47

5.3 GRAPHIC CAPABILITIES..................................................................................................................47


CBDSMEN0022 Date March 05, 2018
SOFTWARE REFERENCE Release N. 2
MANUAL Page 5 of 65

5.4 RAM FONTS..........................................................................................................................................48

5.5 GENERAL FORMAT OF COMMANDS ...........................................................................................49

6. PRINTERS COMMANDS 50

6.1 PRINTER COMMANDS SUMMARY (ORDERED BY THE OP-CODE)....................................50

6.2 PRINTER COMMANDS (GROUPED BY FUNCTION)..................................................................52


6.2.1 Pointer positioning - Margin Setting - Text Justification.......................................................................52
6.2.2 Font selection - Upper and lower row selection - Character spacing setting ........................................54
6.2.3 Voiding string selection..........................................................................................................................56
6.2.4 Miscellaneous commands.......................................................................................................................57
6.2.5 Graphic images definition......................................................................................................................57
6.2.6 Ram font downloading...........................................................................................................................59
6.2.7 Strings definition and recall...................................................................................................................61

7. APPENDIX A - CODE LINE ENCODER


63

8. APPENDIX B - PROGRAMMING HINTS 64

1. GENERAL NOTES ON CBD 1000HT..................................................................................................64

2. DOCUMENTS PRODUCTION SEQUENCE......................................................................................64

3. RECOVERIES.........................................................................................................................................64

4. USER SETTABLE CONFIGURATION...............................................................................................65

5. FACTORY SET CONFIGURATION...................................................................................................65


CBDSMEN0022 Date March 05, 2018
SOFTWARE REFERENCE Release N. 2
MANUAL Page 6 of 65

1. COMMUNICATION BETWEEN HOST COMPUTER AND CBD


1000HT EQUIPMENT

1.1 LINE PROTOCOL


Communication between host-computer and CBD 1000HT is accomplished through a
standard 3-wire RS-232 link or USB, 1.1 and 2.0 compatible. USB interface is implemented
via a virtual COM Port driver (VCP) from FTDI Ltd.
(http://www.ftdichip.com/Drivers/VCP.htm).
The VCP allows running any existing software driving the machine via RS232 serial
through physical USB cabling without any modification as it emulates a standard COM port.
Therefore, throughout this document all commands will be referred as serial commands
regardless the used interface. Do not try to use both interfaces at the same time, only one of
them it is allowed to be connected to the machine.
Line parameters are as follows:
 Speed: 9600 bits/s
 8 data bits
 No Parity
 1 Stop Bit
Synchronisation is obtained by means of a simple XON/XOFF protocol.
According to that protocol, two characters, called XON (ASCII 17d, 11Hex) AND XOFF
(ASCII 19d, 13Hex), have the task of synchronising the equipment in the same way as
transition to active state and transition to idle state of a CTS line do. This way, CTS line may
be not wired.
As CBD 1000HT receive buffer occupation exceeds a given threshold value (for the sake
of precision: when there are exactly 1024 bytes free) the equipment sends the XOFF character.
Then, host-computer suspends transmission. It will resume operation of serial line when
CB1000 sends the XON character. This happens as occupation of receive buffer falls below a
given threshold that, in this application, is 75% of the XOFF threshold.
Receive buffer size is 25600 bytes (one hundred 256-bytes pages).
As it will be discussed later in this manual, there is a communication mode according to
which CBD 1000HT only transmits when polled by host computer. Nevertheless, host
computer can suspend and resume CBD 1000HT transmission by sending XON and XOFF
characters.
More, this is the only correct method of suspending CBD 1000HT transmission when the
equipment is producing chequebooks.
CBDSMEN0022 Date March 05, 2018
SOFTWARE REFERENCE Release N. 2
MANUAL Page 7 of 65

1.2 CLASSES OF MESSAGES


Host computer issues messages (commands) in order to set up CBD 1000HT for specific
book parameters.
The host receives from the CBD 1000HT messages, which are either diagnostic or answers
to data requests.
CBD 1000HT transmission mode is programmable by means of a command whose format
is outlined in chapter 2. There are two possible options for transmission mode.
With the first option the equipment cyclically sends a status message - outlined later in this
chapter. This option is selected with the command "OQN". This transmission mode is useful
when the CBD 1000HT is manually driven through a terminal or a terminal emulation
program for training or debugging purposes.
In the second option (selected with command "OQY") the host must explicitly request
transmission of the status message from the CBD 1000HT (with order "@Q"). While the unit
is in production, frequency of polls should not exceed one poll per second. This mode is
preferable when the unit is driven by a host program, since the host knows exactly the kind of
the message that will be transmitted next by the machine (a status message can not be
automatically inserted before the data expected by the host).
Transmission mode switching must only be forced when unit is not in book production.
Information relating to programmed transmission mode is retained in permanent memory.
Mode unaffected by turning unit on/off.

1.3 MESSAGES FROM CBD 1000HT TO HOST COMPUTER

1.3.1 Status Message

Status message is of variable length. The first eight characters are always present. They
represent, in hexadecimal notation, a 32-bit integer and may or may not be followed by error
status report (prefixed by capital 'E') and other special condition signals. These can be
jamming codes (prefixed by capital 'J'), failure codes (prefixed by capital 'F') or individual
flags (single capital letters) each related to a specific condition.
The 32 bits of the number given by the first eight characters represent the status of the
CBD 1000HT position detectors (whether engaged or not). Each bit is set to one if the
corresponding sensor is engaged and to zero if not engaged. The only exception to this rule is
for bits 11/12/13/14, which signal the presence of a minimum stock of sheets in the feed
stations. Regardless of the method used for detecting the presence of paper, these bits are set
to one when paper is present.
As mentioned above, the eight characters sequence must be decoded as an eight
hexadecimal digits sequence, MSB first.
Numbering bits from 0 (lsb) to 31 (msb) the meaning of each is as follows.

 Bit 0: PHOTO1, first paper path detector.


 Bit 1: PHOTO2, encoder paper detector.
CBDSMEN0022 Date March 05, 2018
SOFTWARE REFERENCE Release N. 2
MANUAL Page 8 of 65

 Bit 2: PHOTO3, reader window sensor.


 Bit 3: PHOTO4, printers paper detector.
 Bit 4: PHOTO5, printer exit detector.
 Bit 5: PHOTO6, second stacker sensor.
 Bit 6: PHOTO7, first stacker sensor.
 Bit 7: PHOTO8, binder paper input detector.
 Bit 8: PHOTO9, upper mark detector.
 Bit 9: PHOTO10, lower mark detector.
 Bit 10: PHOTO11, horizontal alignment sensor.
This sensor detects pushing lug home position
 Bit 11: PHOTO12, low stock detector (cheques).
If zero there is not a minimum stock.
 Bit 12: PHOTO13, low stock detector (covers).
If zero there is not a minimum stock.
 Bit 13: PHOTO14, feeder empty detector (cheques).
If zero, the cheques are exhausted.
 Bit 14: PHOTO15, feeder empty detector (covers).
If zero, the paper is exhausted.
 Bit 15: Not Used.
 Bit 16: PHOTO17, binder press folding position detector.
 Bit 17: PHOTO18, blades cam home detector
 Bit18: PHOTO19, tape end sensor.
If zero, binding tape is nearly exhausted.
 Bit 19: PHOTO20, tape elevator home detector.
 Bit 20: stapler microswitch.
 Bit 21: PHOTO22, blades jam detector.
 Bit 22: PHOTO23, reject bin sensor.
It is a one if rejects bin is full.
 Bit 23: Not Used.
 Bit 24: PHOTO25, feeder lock sensor.
It is a one if security cover is locked.
 Bit 25: PHOTO26, security box lock sensor.
It is a one if the security box is locked.
 Bit 26: PHOTO27, security box sensor.
This is a barrier sensor for detecting security box full. It is a one if security box is full.
 Bit 27, bit 28, bit 29, bit 30 and bit 31 are not used.
CBDSMEN0022 Date March 05, 2018
SOFTWARE REFERENCE Release N. 2
MANUAL Page 9 of 65

Coding for the previously mentioned error and special conditions, which may or may not
follow the 8-digit hex number, is as follows (more than one may be present in the message).

 Capital ‘B’ indicates that the binding process or book withdrawal is finished.
Differently from flag 'O' (see below), flag 'B' is not reset upon book withdrawal by the
user. So, even if the user is quick in drawing the book from the machine (and the host
polling frequency is very low) there is no information loss. The host must reset the flag
with the command "@B" in order to be able to detect next end-of-binding or next end-
of-withdrawal.
 Capital 'D' indicates double feed.
 Capital 'E' followed by a two-digit number. This represents an error code related to
host messages. As such an error occurs, the decoding process of incoming instructions
is suspended. "Orders" (see chapter 2.) are still decoded.
 Capital 'F' followed by a two-digit number. This code informs host about possible
electrical and/or mechanical failure. The related number gives location and cause.
 Capital 'J' followed by a two-digit number. This code informs host that a paper or book
jam has occurred. The two-digit number indicates the cause of the jam. In case of paper
jam, document(s) under production, and immediately following the jammed piece will
also be involved in the jam. In the case of a simultaneous paper/book jam taking place,
then only the jam occurring last is signalled to the host.
 Capital 'K' indicates that withdrawal of a book has not been carried out successfully.
One of the following is true:
1) The CBD 1000HT received the command when the book had already been extracted
2) The book has been extracted while the CBD 1000HT was trying withdrawing it
3) A jam has occurred at a location where none of CBD 1000HT position sensors is
able to detect the book. Very low probability for this event.
 Capital 'L'. This code informs host of transmission line error.
 Capital 'M' indicates incorrect paper sequence as indicated by binary code reading.
 Capital ‘N’ indicates a failed comparison between the cheque’s pre-printed S/N and the
S/N field of the code-line going to be printed
 Capital ‘O’ indicates that a book is pending withdrawal. This flag is reset when the
user withdraws the chequebook or when withdrawal command ('P') is executed.
 Capital 'P' indicates one of the feed stations is empty or nearly empty. The unit stops
production and the 'P' flag is sent with every status message until host re-enables
operation by issuing order <@R>, the meaning and purpose of which is described later
in this chapter.
If the unit is turned ON with one of the feed stations in "nearly empty" condition flag
'P' is sent with the very next status message and again every 20 sheets in the case of the
cheque station and every 10 sheets in the case of the cover feed station.
After reaching the "attention threshold" while the unit is in operation the first 'P' alarm
occurs with cheque feed station after 120 sheets and with cover feed station after 30
sheets have been fed.
 Capital 'R' indicates code line (either pre-printed or home produced) unreadable.
CBDSMEN0022 Date March 05, 2018
SOFTWARE REFERENCE Release N. 2
MANUAL Page 10 of 65

 Capital 'T' indicates that initialisation is absent or that permanent data has been lost.
Unit must be trimmed. Permanent data may be lost due to board mishandling. When
permanent data are lost they are replaced by default values which make for possible
bad operation - Flag T can be removed only by command “OTY” after restoring proper
values in permanent memory.
 Capital 'U' indicates low voltage on 24V supply.
 Capital 'V' indicates low voltage on 36V supply.
 Capital 'W' indicates codeline printer inoperable. Usually due to ribbon exhaustion.
 Plus sign ('+') indicates unit in Extended Operation mode.
 An exclamation mark ('!’) is set in the status message when the machine is reset. The
host must perform all data set-up (if any) that are required just after the power-on reset.
If the host computer receives the flag while the machine is in operation (the host can
check for book completion by looking for flag 'B') this usually means that the machine
had a separate power failure and the production has been interrupted. In this case, of
course, some jamming condition will be detected by the CBD 1000HT.
The machine clears this flag when it receives the command "@!" (at-sign followed by
exclamation mark).

The status message is terminated by a Carriage Return + Line Feed sequence.


In the case of code line read error (flag 'R') or OCR check error (flag 'N'), then another
string immediately follows. This is the result of the code-line read back process. Its first
character is always a colon (':'). Characters read are reported back in sequence following the
colon, with question marks ('?') in place of characters unreadable and which reader could not
decode. This string is also terminated by a CR+LF sequence.
Automatic transmission of the codeline following the status message (under the above
mentioned circumstances) can be disabled by the host (command "OAN", see section 3.2.2 -
opcode "O"). In this case, order "@L" can be used to request code-line transmission.

1.3.1.1 Error Codes


Error codes the unit may send to host have the meaning described in the following list.
In some cases the description given makes some reference to specific commands. Please, refer
to section 3 for further details.
The unit issues an error code when it is unable to go on with instruction decoding. Of
course, the programming error may reside in an instruction, which is previous to the one that
could not be correctly decoded. In such case, being the resulting error, i.e. the error that
caused the decoding process to halt, different from the programming error, the error code
cannot be appropriate.
E10 Unknown instruction. The decoder was in the reset condition or it had just
finished decoding an instruction and an invalid op-code was encountered.
Usually, this means that host computer has prematurely interrupted a parameter
or a parameter list with a spurious terminator - or, in the case of a numeric
parameter, it interrupted a number with a non-digit, which was neither a white
space (blank or CR or LF or Tab) nor a valid op-code.
CBDSMEN0022 Date March 05, 2018
SOFTWARE REFERENCE Release N. 2
MANUAL Page 11 of 65

E15 Instruction not allowed. An instruction that is incompatible with present


settings has been issued.

E18 Nothing to emit - related to the command "XV" if no book is waiting in the
binder.

E20 String is too long. A string parameter is too long for the device it is addressed
to, or its length exceeds the allocated buffer length.

E21 Code-line format error. The string in the code-line field of an instruction does
not comply with code-line constraints.

E22 Code line overlap. When a number is encoded on the stub (symbol "&" in
string 4 of command "A") and this number overlaps the standard code line.

E24 Related to the commands "QA", "QB", "QC", "QD", if any printer parameter
other than the pre-printed code is specified.

E30 Error in option field. Op-code 'O' ("activate/deactivate a function" command)


was encountered, but the parameter in option selection field was invalid.

E31 Incorrect termination of option select command. An 'O' command was


encountered, the parameter in option selection field was legal but the command
was not terminated by either a 'Y' or a 'N'.

E32 Error in double detector set-up command. This error is similar to E10, since it
is also an invalid op-code error. The only op-codes starting with capital letter S
are SI, SJ, SL, SM and SN (plus, for compatibility with previous releases, SK)
but the decoder, after encountering an 'S' at op-code decoding time, could not
find any of them.

E33 Error in offset set-up command. A non-existing offset was referenced in the
command. See 4.3 - opcode 'XO' - for details on allowed parameters.

E40 Unknown order. The order identification prefix was received, but the letter that
followed it did not correspond to any order. ("Orders", as described later in this
chapter, are commands that are immediately executed).

E41 Unexpected restart order. The restart order ('@R') was received without a jam
or another error condition being in effect.

E50 Error in "XU" command. Similar to the case of E32 error, E50 indicates that
letters "XU" were encountered at op-code fetch time, but no valid instruction
starting with those letters was decoded.

E51 Invalid Extended Operation access code. The number issued by host computer
for accessing the Extended Operation mode was not the one stored in the
CB1000.
CBDSMEN0022 Date March 05, 2018
SOFTWARE REFERENCE Release N. 2
MANUAL Page 12 of 65

E52 Access denied. Operation of a command that requires Extended Operation mode
for execution was attempted while the unit was not in that mode of operation.

E53 Too many retries. More then three attempts to issue the "XU+" command,
which sets up the Extended Operation mode, have been carried out by host
without the right access number. When this happens, CBD 1000HT goes into a
locked state and there is no way of soft-restarting it. The equipment must be
turned off and then turned on again to resume operation.

E55 Error in "XK" command. Similar to the E50 case, no valid opcode starting with letters
"XK" could be decoded after encountering those letters at op-code fetching time.

E90 Invalid opcode following direct mode prefix. An instruction for which "direct
mode" is not allowed has been issued.

E98 Direct mode overrun. A command issued in "direct mode" has not been
properly terminated.

E99 Immediate commands (orders) overrun. An order was issued by host computer
without the execution of a previous one being complete.

1.3.1.2 Jamming Error Codes


Jamming errors coding is as follows:
For paper jam, the Jam Code in the status message only refers to the jammed sheet. There
is no signal for segments engaged by other halted documents. For the process to be correctly
restarted, all paper path segments must be cleared.

 Jamming error at initialisation


J01 Paper path not clear at power-up. Any obstructing sheet must be removed from
the paper path before issuing the restart command (@R).

J02 The document stacker is not clear. The restart command (@R) is allowed
without the paper having been removed from the stacker, thus allowing the
"reject" command (opcode 'R') to be used. This command causes the sheets in
the stacker to be stapled and stored in the collection box (if available) or in the
interior of the machine housing. Of course, manual intervention is also possible
- just clear the stacker and issue "@R".

J04 Book in the binding section at power-up. The book must be removed before
issuing "@R" or the command will have no action.

J03 Of course, any combination of the above mentioned jam conditions is possible.
J05 The resulting jam code is given by the sum of jam codes for each obstruction
J06 detected. Having these jam-codes weights 1, 2 and 4 the individual jams can be
J07 detected by decoding the jam code in a binary fashion. So, for example, J05
(=J04+J01) means that a book is in the binding section and that the paper path
is obstructed.
CBDSMEN0022 Date March 05, 2018
SOFTWARE REFERENCE Release N. 2
MANUAL Page 13 of 65

To remove all the above Jam conditions (at initialisation) you must use (of course after
removing the cause of the jam) the order @R that retries the initialisation procedure.

 Jamming error at documents production

J13 Jam at paper feed. Paper feed has been started, but PHOTO1 has not been
engaged within a given time. Paper may be involved before the selection roller.

J16 Jam after paper feed. After engaging PHOTO1, paper could not enter barrier
PHOTO2. It could not be positioned for code-line printing.

J23 Code-line printer jam. After/during code-line printing paper could not leave
PHOTO1 or double-detector gap.

J26 Jam before reading. Paper could not engage PHOTO3, which is just after the
magnetic read-back head.

J31 Jam on read-back path. This jamming code is issued when paper is unable to
reach PHOTO4 or it is unable to leave that detector within a given time. Paper
could also have been pulled forward by text printers rollers due to pressure
plate loosening, in which case the J31 code is caused by paper being unable to
properly decelerate before printing.

J33 Printers jam. A paper jam occurred at print time or while leaving printers path
or at rejection.

To remove all the above Jam conditions (at document production) you can use the order
@R or the order @C (of course after removing the documents jammed in the path) :
- with @R the machine try again to produce the documents involved in the jam.
- with @C all the instruction suspended are cleared.

 Jamming error at book issuing


J41 Quick eject jam. Related to the commands "QQ" or "QO" if the unit is not able
to send out the documents or the book from the stacker.

J42 Jam at stapling. A chequebook could not leave the stapler.

J44 Jam before tape application. A chequebook could not enter the pressing plates
for binding tape application.

J45 Tape lift jam. The tape lifting mechanism was unable to reach the cutting
position after applying tape to the book.

J46 Jam at bypass (1). A jamming condition occurred at binding tape application.

J47 Jam at bypass (2). A jamming condition whose probable cause is a bad tape
cut.
CBDSMEN0022 Date March 05, 2018
SOFTWARE REFERENCE Release N. 2
MANUAL Page 14 of 65

J48 Tape cutter jam. The tape cutter could not return to its normal position, likely
due to tape adhesive excess.

J49 Blades jam. The unit is unable to cut the binding tape, even if the lifting
mechanism is at cut position.

J50 Book-out jam. A jam occurred during book withdrawal that caused the book to
remain at the exterior of the unit.

J53 Jam at withdrawal. A jam occurred while a book is moving to the rejected
books trap door.

J52 Ejector jam. On machines capable of total book eject (i.e. machines with
additional rollers that can eject the book by its full length) code J52 signals that
book ejection could not be successfully performed.

J56 Jam at book sinking. A jam occurred while the book was falling into the
rejected book box. The book remained, partly or completely, out of the box.

J57 Security box jam. On machines with a security box, code J57 signals that a
chequebook can not be stored because the security box is full. Action is
stopped just before book storage. So, when host computer commands book
withdrawal, the book in any case is drawn at the interior of the machine, just
above the security box.

To remove all the above Jam conditions (at book issuing) you must use the order @R that
tries to restore the initial condition of the unit (of course after removing documents
jammed).

1.3.1.3 Hardware Failure Codes


Hardware failures coding are as follows. Recall that, besides failure codes, two flags, 'U'
and 'V', are also present in the status message that point out failures in 24V and 36V power
supplies. In some applications these power supplies may be interrupted by door-activated
security switches intervention. The programmer must be aware that, in the case that 24V
power and 36V power are absent and mechanical operation is commanded by host, spurious
fault signalling is possible.

F10 Cutter not at home position at init. If CBD 1000HT is turned on while the
cutter driving cam is not at its home position, the unit is not able to determine a
mechanically safe sequence of actuations, which restores the initial position.

F20 Pushing lug failure. Malfunction in the device that pushes paper sheets into the
stapling unit.

F30 Stapler failure (1). The stapler could not start moving.
CBDSMEN0022 Date March 05, 2018
SOFTWARE REFERENCE Release N. 2
MANUAL Page 15 of 65

F31 Stapler failure (2). The stapler was unable to make a 360 deg. travel.

F40 Cutter failure (1). The cutter-driving cam could not start revolving. Likely, a
D.C. motor fault.

F41 Cutter failure (2). The cutter-driving cam could not complete a 360-deg. travel.
A mechanical jam is the most probable cause.

F43 Cutter failure (3). Probable failure in both the cutter motor and the connected
mechanism.

F45 Ejector failure. On machines capable of total book eject, failure code F45 may
appear in the status message. Failure F45 involves almost the same hardware as
F41 and F43. The only difference is that the moving blade is not involved in
the problem and that a book is engaged by the cam/roller pair.

F50 Pressing mechanism failure. Failure to actuate the pressing plates for binding
tape application.

F60 Tape lifting mechanism failure. Failure to actuate the mechanism which lifts
binding tape to book top.

F90 Printers fault. One printer is not responding to central unit. This is an electrical
problem.

1.3.2 Other messages.

Special messages are sent as answers to immediate commands ("orders", see below).
These messages may be either mere acknowledgements to orders received or special
informations requested by the host.
More, on host request (see commands XDD / XDL / XDE in chapter 3.2.2), the status
message can be substituted by the opacimeter (double feed detector) output. Transmission
happens according to the mode (i.e. timed transmission or transmission on host poll) selected
for the status message.

1.4 MESSAGES FROM HOST COMPUTER TO CBD 1000HT


Before describing in detail the messages that host computer may send to CBD 1000HT, let
us spare a moment to consider the CBD 1000HT capabilities and the chosen method for
allowing a simple, effective CBD 1000HT programming.
The production process of a chequebook is made by a series of operations ranging from
single documents production to book binding. Flexibility requirements imply that to some of
the production steps is associated some host defined data and that the sequence of operations
is under host control. Nevertheless, this should not require the host to issue orders for each
single step.
CBDSMEN0022 Date March 05, 2018
SOFTWARE REFERENCE Release N. 2
MANUAL Page 16 of 65

More, host computer must have control upon execution of exception recovering. That is,
whenever the normal operation is interrupted by special events, it must be the host
responsibility to decide which action should be undertaken.
So, host computer should be able to perform two classes of operations.
The first class is the programming activity, that is the operations host computer must
perform in order to set up CBD 1000HT for a specific work. To accomplish this, host
computer must rely on a variable-parameters base as wide as possible. At the same time, this
should not imply the reiteration of parameters and commands that, for a given task, are always
the same.
The second activity is monitoring CB1000 in order to have control on the regularity of the
production process.
Programming should be allowed regardless of document production activities. That is,
CBD 1000HT must be able to accept commands, which will be executed on a sequential basis
and with the appropriate timing. For maximum efficiency, the unit must be able to begin
operations as soon as enough data is received. Normal production activity should not cause
the instruction acquisition process to suspend.
Host computer ability to control CBD 1000HT activity, on the other hand, implies the
existence of commands that, for their own nature, are accepted and put into execution in real
time, that is without being queued after previously received instructions. More, these
commands must be decoded by a process having higher priority than instruction decoding.
Thus, commands issued by host computer fall into two classes.
The first is the class of those commands that are stored as they are received by CBD
1000HT and put into execution strictly on a sequential basis. We call them "instructions".
The second is the class of immediately executed commands. We refer to these commands
with the term "orders".
To avoid reiteration of commands that, in a given application, are always the same, the
CBD 1000HT has some instructions that are stored in the unit and establish in advance certain
CBD 1000HT behaviours. Host issues these instructions just once without reference to any
specific chequebook.
Commands of this kind are, as an example, the command that instructs the equipment to
perform binary identification code check, and the command that instructs to perform binding
as soon as the production of the front cover, which is the last to be stacked, is over.
To prevent blackouts destroying such information, CBD 1000HT is equipped with a
permanent back-up memory.
Each instruction is decoded by CB1000 as soon as the previous one is put into execution.
It is not possible to say in advance how much time each instruction takes to be put into
execution since this depends (at least in the case of instructions that imply mechanical
actuation) on the availability of some resources. These can be either hardware or, given the
concurrent execution of similar procedures, software resources.
Thus, the only thing the programmer can rely on, concerning the succession of events
subsequent to host commands, is the intrinsic sequentially of the decoding process.
CBDSMEN0022 Date March 05, 2018
SOFTWARE REFERENCE Release N. 2
MANUAL Page 17 of 65

A thorough explanation of instruction format and syntax is given in chapters 3 of this


manual.
Orders are put into execution as soon as they are decoded.
They follow a decoding path different from normal instructions and the two processes are
carried out each with its own timing. As a general rule, order decoding is of higher priority
than instruction decoding. Consequently, the reception of an order interrupts instruction
decoding, regardless of the decoding step in progress.
The above consideration must be kept in mind by the programmer when he issues an order
whose effect should apply only after a specific command is decoded.
A typical example is that of the instruction that causes double-detector output to be
transmitted.
When the unit is programmed for transmitting messages only on host request (peripheral
polling, order "@Q"), the programmer, if unaware of decoding priorities, could expect that the
message sent by the peripheral is always the one relative to the last instruction issued. On the
contrary, CBD 1000HT immediately reacts to the polling order, while the message switching
instruction is still undecoded.
It is, of course, a matter of process duration in the range of a few hundred microseconds.
But, taking into account transmission line speed, which allows about one character per
millisecond, and the necessity of some form of bufferization, the effect must be taken into
consideration.
No special message for instruction acknowledgement or decoder status signalling is
provided. On the other hand their use, given the short duration of the decoding processes,
would result in the waste of a longer time than simply allowing the unit enough time for
decoding. In fact, from CBD 1000HT point of view, a few milliseconds separation between
the instruction and the order is enough. This can be easily accomplished, even in large systems
which are not real-time and that provide bufferization of outgoing messages, by inserting a
few, say ten, white spaces (either blanks, CR or LF) between the instruction and the polling
order. Of course, at that time no other time-consuming instruction must be waiting for
execution.
From a formal point of view, orders can be distinguished from instructions by their initial
character, which is always a '@' (ASCII 40Hex, 64d).
Each order is acknowledged by CBD 1000HT, thus indicating the completion of its
execution.
Concerning orders that cause the transmission of some data (for instance order "@Q",
which causes status message to be transmitted), acknowledgement is intrinsic to the
transmission originated by that command.
Other orders are acknowledged by retransmission of the received order itself.
Host computer cannot issue a new order before the previous one has been acknowledged,
or an E99 error will be originated.
CBDSMEN0022 Date March 05, 2018
SOFTWARE REFERENCE Release N. 2
MANUAL Page 18 of 65

2. ORDERS
The following orders are available on the CBD 1000HT.

@A: Send the list of aborted processes.


This is the list of documents that were being produced at the moment of production
exception (jam, double-feed etc.). A list of comma-separated integer numbers is
transmitted by the CBD 1000HT. The list is terminated by a CR+LF sequence.
If this order is issued while no process is pending, then the machine returns capital 'N'
followed by CR+LF.
See 3.2.2 - opcode 'Z' for information on how document numbers are assigned.
@B: Clear the 'B' flag in the status message.
This flag is set when book binding or book withdrawal is finished and is also set at the
end of the execution of the reject command. The host must reset the 'B' flag in order to
be able to detect next end-of-process.
@C: Restart instruction decoder.
This order restores decoder initial conditions, thus breaking any possible instruction
decoding which was in progress. It removes an error condition that halted the decoding
process. Empties the instruction queue, i.e. the buffer of instructions waiting to be
decoded, thus allowing an instruction, which is sent after the order to be immediately
decoded. Resets the receive buffer. Empties the list of halted document-producing
processes that were waiting for a recover order. It removes any error condition caused
by faults in document production processes (jams) or by errors encountered in
instructions decoding. @C should be used only for decoder reset or for exiting jam
condition related to documents production (i.e. not book binding or withdrawal jams)
without resuming operation.
@F: Returns all the "Options" setting (see 3.2.2 opcode 'O').
@K: Reset 'K' flag in status message.
It tells CBD 1000HT that the 'K' flag in the status message has been decoded by host
computer. This flag, as already seen, tells that a book, which should have been
withdrawn, has been extracted from the unit.
@L: Transmit code-line.
When option 'A' is disabled (see 3.2.2, opcode 'O') there is not automatic transmission of
the code-line when a read-back error occurs. "@L" must then be used if code-line
transmission is required (one transmission per order received - option 'A' remains in
effect).
Even if option 'A' is enabled, order "@L" can be issued any time the host wants the last
read code-line to be transmitted. If this order is issued while a code-line read-back is in
progress, then a partial transmission (i.e. the characters already read) is obtained.
@M Transmit offsets settings.
This is useful to service personnel, who can read the settings with a normal ASCII
terminal or a P.C. equipped with a simple terminal program.
CBD 1000HT output is in readable form. This is the list of commands (described in 4.3)
that set up that configuration. A typical output would appear as follows:
XOH3 XOM2- XOL0 XOS1- XOB2 XOF1 XOT0 XOR15 XOC0
CBDSMEN0022 Date March 05, 2018
SOFTWARE REFERENCE Release N. 2
MANUAL Page 19 of 65

@N: Returns the “wildcard” strings, one string at a time.


Related to pre-encoded documents handling (see 3.2.1.2 - “string 4” description in
commands ‘A’-‘B’-‘C’-‘D’).
@O: Returns the number of rejected documents.
Returns a string having the format: "O N1/N2" - Where:
N1 no. of cheques that actually reached the reject bin
N2 no. of cheques that were to be rejected (included jammed ones)
@Q: Send message.
In the operation mode in which host computer must poll the peripheral to obtain a
message, this is the poll request. As soon as CB1000 receives this order, it sends the
message that at that time was waiting for transmission (usually the status message,
unless the unit is programmed to send opacimeter readings).
@R: Recover from exception (malfunction, jam etc.).
It orders the unit to resume operation after it was halted due to a malfunction. In any
situation CBD 1000HT will restore operation as well as possible.
In case of jam error (book or paper) it is supposed that the jam has been physically
removed. In case of paper jam, the paper path is supposed to have been cleared, i.e. all
documents in the paper path (from paper feeder on) that were following the one which
caused the unit to halt must be removed.
If a document that has been drawn from the smaller feeder station is involved in the jam
and mark (binary code) check is enabled, then the machine will attempt restoring correct
document succession (see 3.2.2, opcode 'O', options 'U' and 'L' for details on how this
process works).
In case of hardware failures the unit only attempts to reinitialise hardware, without
resuming the halted process.
@S: Stack occupation query.
This order returns the number of documents in the stacker
(Produced by: A, B,…QA, OB…)
followed by: "+" still in production
"=" production completed or halted
@T: Returns Double Detector Thresholds.
"SIn, SLn, SMn, SNn".
@U: Clears the two numbers “N1” and “N2" (see order @O).
@V: Transmit firmware release.
Firmware identifiers, i.e. name, version and release are transmitted. This transmission is
in readable format too. The format is the following:
- capital “B” or “E” , which identifies the program
- one capital letter identifying the electronic hardware compatible with the program
- one capital letter identifying the mechanical hardware compatible with the program
- one space (blank)
- one or more digits identifying the version
- a decimal point
- one or more digits identifying the release
CBDSMEN0022 Date March 05, 2018
SOFTWARE REFERENCE Release N. 2
MANUAL Page 20 of 65

Other variable-length information, separated by a blank, may or may not follow - no


specific format.
@W: Wildcard count query.
Related to pre-encoded documents handling.
Returns the number (in decimal form) of stored “wildcard” strings, and to initialise the
pointer on the 1st string.
@$: Transmission of last "wildcards string".
Related to pre-encoded documents handling.
@!: ('@'+ exclamation mark) Clear the exclamation mark ('!') in the status message.
This order must be sent if the host wants to be able to detect next power-up.
CBDSMEN0022 Date March 05, 2018
SOFTWARE REFERENCE Release N. 2
MANUAL Page 21 of 65

3. ORDINARY INSTRUCTIONS

3.1 INSTRUCTION SYNTAX


From a syntactical angle, instructions are made by an op-code (usually one or more capital
letters) which may be followed by one or more parameters. These may be of either fixed or
variable length.
The end of an instruction which has arguments is determined by the end of its parameter or
parameter list. The end of a parameter, in turn, may be either implicit (for fixed length
parameters) or determined by an explicit terminator. When the parameter is a number in
decimal notation its end is determined by the first non-digit character encountered. This latter
one may be the first character of the immediately following op-code or a white space.
All white spaces between an instruction and another are stripped by the decoder.
Precisely, all blanks (ASCII 20Hex/32d), TAB (ASCII 9), CR (ASCII 0DHex/13d), LF
(ASCII 0AHex/10d) and EOF (ASCII 1AHex/26d) are skipped.
When it is not expressly stated to the contrary in the instruction format, a numeric
parameter may be separated from the op-code by any number of blanks and TABs.
To allow easy debugging and testing, all instructions and their parameters may be encoded
in readable form, i.e. even binary parameters may be transmitted to the CBD 1000HT as
strings (prefix '\' + number in decimal notation).
Comments are allowed between instructions. Comments start with an asterisk (i.e. '') and
end with the next CR or LF (the LF which possibly follows the CR and the CR which possibly
follows the LF are discarded as they are blank separators).
Comments are also allowed between specific fields in some instructions. The syntax of
such comments can be found in the sections describing the commands to which the comments
relate.
CBDSMEN0022 Date March 05, 2018
SOFTWARE REFERENCE Release N. 2
MANUAL Page 22 of 65

3.2 INSTRUCTIONS DESCRIPTION

3.2.1 Document production

OPCODE FUNCTION FORMAT


A Make cheque A<string1>¦<string2>¦<string3>¦<string4>¦

B Make last cover B<string1>¦<string2>¦<string3>¦<string4>¦

C Make front cover C<string1>¦<string2>¦<string3>¦<string4>¦

D Make order form D<string1>¦<string2>¦<string3>¦<string4>¦

The op-code (capital ‘A’, 'B', 'C' or 'D') is followed by four character strings. Each string
must be terminated by the character '¦' (ASCII Hex 7C, dec. 124). Any character (white spaces
included) between the op-code and the first '¦' is considered to be part of string 1. Similarly,
any character between one '¦' and another is considered to be part of the corresponding string.
String 1, string 2 and string 3 are sent respectively to text printers 1,2 and 3. Text printer 1
is the first encountered by documents on paper path.
String 4 is sent to code-line encoder.
All four strings must be present even if they are empty, in which case no character is inserted
before the corresponding terminator and nothing will be sent to the corresponding device.
How strings are handled depends on printers version (see chapter 5. for details). Format
rules and syntax are the same for all versions.
They are the following.

3.2.1.1 String 1,2 and 3 definition


Any character is allowed except the following:
'¦' (ASCII Hex 7C), which is the separator itself
'@' (ASCII Hex 40), which is orders prefix
XON (ASCII Hex 11) and XOFF (ASCII Hex 13), which are transmission line control characters
'\' (Backslash, ASCII Hex 5C), for reasons we will see soon
These characters, like any other, may be inserted in printers strings by transmitting a
backslash (‘\’) followed by their ASCII code in decimal form. Any number of blanks or TABs
may be inserted between the backslash and the first digit.
The ASCII code is terminated as one of the following conditions becomes true:
 a non-digit character is encountered ( this character will be considered to be part of the
text and will be sent to the printer)
 three digits are found after the backslash and (possible) initial white spaces
CBDSMEN0022 Date March 05, 2018
SOFTWARE REFERENCE Release N. 2
MANUAL Page 23 of 65

Even a white space may be used as a terminator. Of course at least one digit must precede
it on the string.
These two methods for ASCII code termination allow the length of transmitted text to be
the shortest possible. At the same time any combination of ASCII codes and numbers may be
sent to printers.
As an example, substring "@max" can be transmitted either as "\64max" or as "\064max",
but substring "@101" can only be transmitted as "\064101".
White spaces stripping allows the programmer to ignore, if he so wants, any problem
related to formatting rules for numbers in specific EDP environments/languages.
To function as a printed character, the backslash must be transmitted as in backslash-
ASCII code sequence.
The above mechanism allows the host to transmit only printable characters, even when
escape sequences must be sent to printers. Thus, transmission is possible even in the case that
escape sequences contain special characters that, for their function within the EDP system in
use, would cause the serial link to be closed.
Maximum length of string 1,2 and 3 is 197 characters. Of course, a backslash-ASCII code
sequence counts as one character.

3.2.1.2 String 4 definition


String 4 is made by letters and numbers that must be printed by the code-line encoder.
Allowed set depends on the code in use (see appendix A).
After encoding, the unit reads back the code-line and checks it for any possible error. In
the case that the code-line field of the cheque contains pre-printed codes, the CBD 1000HT
must be informed of their existence or the extra characters will generate an error. Pre-printed
codes must be inserted in string 4 in the exact position they have with respect to home-printed
characters. To avoid over-striking (which would make the code-line unreadable) they must be
enclosed in double quote pairs. Their presence is also checked by the unit.
For instance, let us consider the case of sheets with the pre-printed string <100033> (we
are using angle brackets for delimiting strings and fields, in place of usual double quotes, for
obvious reasons). Let us put, also, that <a2300> must be printed on the left of the pre-printed
string, and <1500> on the right, so that the resulting codeline will be:

<a2300 100033 1500 >.


Then, string 4 must be:
<a2300 "100033" 1500 >.

The position of encoded characters is set (with respect to the standard right margin) by
adding the required number of blanks on the right of the significant (non-blank) part.
For MICR codelines the minimum number of blanks on the right is 13. As a
consequence the first position allowed for encoding is the 14 . While the leftmost character
th

cannot exceed position 52, i.e. the maximum number of characters in string 4 (including pre-
printed characters and blanks and excluding double quotes) is 52.
CBDSMEN0022 Date March 05, 2018
SOFTWARE REFERENCE Release N. 2
MANUAL Page 24 of 65

For OCR codelines there is not a minimum number of blanks on the right and the
maximum number of characters is 64.
No blank must precede (to the left of) the first (leftmost) significant character.
Double quotes represent no character (even blanks). They are not "place takers" and must
not be considered in string format. Thus, they must not be computed in character count.
The instruction is terminated by string 4 delimiter.

One alternative mode to handle pre-encoded documents is the use of the wildcard "?"
(question mark) to tell the machine to read pre-encoded characters at specific positions on the
codeline and store the readings for successive transmission to the host. This feature is useful
when the already encoded characters are unknown or can vary from one document to another
and the host wants to check for proper sequencing.
Example:
A||| ....1234 ????...?? 789012 |

“wildcards”
The internal buffer can store up to 1000 characters. Each reading (e.g. each document with
wildcards passed) occupies an amount of buffer space equal to the number of wildcards plus
one. In other words:
M+N  1000, where
M = no. of cheques and N = tot no. of characters stored
Max. no. of wildcards per cheque: 19
 buffer space is enough for books up to 50 cheques (occupation = 19+1)
Command “W” resets the buffer

Order “@W” asks no. of stored strings and to initialise the pointer to the 1st string. The
number is returned in decimal form.

Order “@N” returns one string at a time


CBDSMEN0022 Date March 05, 2018
SOFTWARE REFERENCE Release N. 2
MANUAL Page 25 of 65

Another feature of string 4 allows specifying the encoding of some MICR Characters
(max. 13) on the counter foil (not verified by the reader). These characters must be added at
the end of the standard codeline, described earlier, and must be preceded by the ‘&’
(ampersand) character. The resulting format is the following:

(according to ISO rules)

A<st1>¦<st2>¦<st3>¦o12345 t153000........&....123456¦

at least 13 blanks
 Sequence of digits and blanks that
will be encoded starting at half inch
from the lefty edge of the document.
 Max 13 leading blanks (attached to
the ‘&’ character) allowed for left-
justifying the string. They can be
followed by a maximum of 13
characters.

3.2.1.3 Further details


Comments are allowed between strings 1,2,3 and 4. For a comment to be allowed between
one string and the following one, an asterisk ('') must immediately follow the string
terminator ('¦'). The comment ends with the next LF, CR or CR+LF or LF+CR sequence (the
programmer must avoid any ambiguity at this regard when the system issues only CR or only
LF as line terminators), but if the first character in the following line is still an asterisk then
also this line will be considered a comment - and so on until a line beginning with another
character is encountered.
In the following example, a "Make Cheque" command is encoded in an ASCII text file
(for test purposes). Usage of comments also makes it possible to encode the instruction on
many lines, rather than on one, too long, line.
*opcode 'A' + text for first printer (print "the quick ..."
*then move to100 mm from left margin and print "jumps over ..."
*- thetext contains all the 26 letters of English alphabet):

Athe quick brown fox\27N\100jumps over the lazy dog¦*


*
*text for printer 2:
*
THE QUICK BROWN FOX\27N\100JUMPS OVER THE LAZY DOG¦*
*
*text for printer 3:
*
the QUICK brown FOX\27N\100jumps OVER the lazy DOG¦*
*test code-line:
888888510888888 ¦
CBDSMEN0022 Date March 05, 2018
SOFTWARE REFERENCE Release N. 2
MANUAL Page 26 of 65

Note that (according to the rules on comments and blank separators between commands)
the blank line preceding the op-code 'A' does not need an asterisk as its first character, but
blank lines between strings need it, since white spaces (like CR and LF) would be considered
to be part of the following string and therefore would interrupt the comment.
Instructions 'B','C' and 'D' are substantially identical to instruction 'A', since they can
produce identical documents. They differ one from another for the station from which the
document is drawn, for the binary document identification code expected and (in the case of
instruction 'C') for the operation subsequent to document production.
The following drawing depicts document/binary code relationship.

The suggested relationship is not mandatory. It relates to a typical use of CBD 1000HT,
but is not the only one possible.
More, if option 'I' is enabled (see opcode 'O" for details), the unit checks binary
identification code ("Identification Marks") only for documents in the small feeder store (i.e.
for covers and order forms). This allows some saving in paper sheet encoding, because it does
not require to pre-print marks on cheques, that are always many more than covers.
To allow a certain degree of flexibility all four instructions have the same format. The
code-line field will be left empty (only the terminator present) where nothing is required.
If option 'B' is set to 'Y' (the default), then instruction 'C' also causes the binding procedure
to commence as soon as the front cover has been stacked with the rest of the documents.
Note
Book production carried out in reverse - front cover is last
document to be processed.
CBDSMEN0022 Date March 05, 2018
SOFTWARE REFERENCE Release N. 2
MANUAL Page 27 of 65

3.2.2 Other instructions

OPCODE FUNCTION FORMAT


E Start binding process E (opcode 'E' with no parameter)

When option 'B' is disabled ("OBN") this instruction starts the binding process. When
option 'B' is enabled ("OBY") usage of this instruction will cause error E15 to be set in the
status message.

OPCODE FUNCTION FORMAT


H Set paper height Hn

Capital 'H' followed by a number in decimal notation. The number is made by an integer
and, optionally, a fractional part separated by a decimal point (".").
Number scan stops at the first character which cannot be part of a number with the above
format. This character can be the immediately following instruction.
Any number of white spaces may be inserted between the op-code and the number.
The number represents document height in millimeters. Of the fractional part, only the
first digit is used for calculations (1-digit truncation). Following digits are simply discarded,
i.e. their presence is tolerated.

OPCODE FUNCTION FORMAT


I Send a string to printer 1 I<string>¦

Capital 'I' followed by a string terminated by '¦' (ASCII Hex 7C).


The string is sent to printer 1, which is the first encountered by documents.
The string format is the same as for strings 1 to 3 in instructions 'A', 'B', 'C', and 'D', except
that there is no constraint on string length. Backslash-ASCII code sequences are also allowed.
This command, like the following two ('J' and 'K') is provided for printer set-up purposes.
They must be used before the production of documents is commanded, since, for its
execution, the unit waits that the paper path is clear (this means that no document is using
printers). Set-up parameters that are related to a specific document must be sent within string
fields 1-3 in the instruction ('A' to 'D') for that piece.

OPCODE FUNCTION FORMAT


J Send a string to printer 2 J<string>¦
CBDSMEN0022 Date March 05, 2018
SOFTWARE REFERENCE Release N. 2
MANUAL Page 28 of 65

OPCODE FUNCTION FORMAT


K Send a string to printer 3 K<string>¦

As mentioned above, instruction 'J' and 'K' are analogue to instruction 'I', except that these
latter relate, respectively, to printers 2 and 3.

OPCODE FUNCTION FORMAT


L Set paper length Ln

Capital 'L' followed by an integer number in decimal notation. The number represents
document length in millimeters. Range is 150 to 270.

OPCODE FUNCTION FORMAT


M Send a string to a group of printers Md<string>¦

Capital 'M' immediately followed by a digit which, in turn, is followed by a string


terminated by '¦' (ASCII Hex 7C).
This command extends the capabilities offered by commands 'I', 'J' and 'K', allowing a
string to be sent to more than one printer at a time (this will bring great time savings in the
case of character font downloading - a feature that is available with printers having firmware
version numbers higher than 3.0).
The digit following the op-code represent a number which is given by the sum of any of
the following:
1 (one) if the string is to be sent (also) to printer 1
2 (two)if the string is to be sent (also) to printer 2
4 (four) if the string is to be sent (also) to printer 3.
Thus, as an instance, "M7\27O¦" will cause the string "<Esc>O" to be sent to all printers.
The string can be of any length and is subjected to the same constraints that apply to
strings in commands 'I', 'J' and 'K'.

OPCODE FUNCTION FORMAT


Enable/disable an option of
O O[A|B|C|D|G|I|L|M|P|Q|R|S|T|U|V|X][Y|N]
operation

Capital 'O' followed by one of capitals 'A', 'B', 'C', 'D', 'G', ‘I’, 'L', 'M', 'P', 'Q', 'R', 'S', 'T',
'U', 'V' and 'X', followed, in turn, by either capital 'Y' or capital 'N'.
The letter following the op-code selects the option that is to be enabled/disabled. The
option is enabled (activated) if its code is followed by 'Y', disabled (deactivated) if followed
by 'N'.
CBDSMEN0022 Date March 05, 2018
SOFTWARE REFERENCE Release N. 2
MANUAL Page 29 of 65

"Options" are used to set up operation modes which are permanently retained in memory.
Options enabled/disabled are used to establish in advance CBD 1000HT behaviour. They add
flexibility to host protocol and allow instruction stream size saving.
The following is a list of available options.
 Option 'A'
When option 'A' is disabled, the code-line is no longer appended to the status message
when a code-line error occurs.
By default, the machine comes from the factory with option 'A' enabled.
 Option 'B':
If enabled the unit staples and binds documents after the front cover is produced.
If disabled, the unit staples and binds only on specific command (opcode 'E').
 Option 'C'
When enabled, coding of the identification marks for cheques and back-cover are
reversed i.e. cheques are identified by two white marks and back-covers by two black
marks near the left edge of the document.
By default, when the machine is first initialized (in factory) this option is disabled.
 Option 'D':
When enabled this option causes a second staple to be applied on the book before it is
bound. This option should not be enabled on documents having a height < 80mm.
 Option 'G'
When enabled, books are automatically stored in the collection box (if fitted) or at the
interior of the machine housing (if no collection box is installed). Differently from the
operation of instruction 'P', the book is immediately stored i.e. the leading edge of the
book never trespasses the tape sticking unit.
This option provides automatic storage in batch-mode production.
 Option ' I ':
When 'I' is enabled, the unit checks binary identification code ("Identification Marks")
only for documents in the small feeder store (i.e. for covers and order forms).
 Option 'L'
This option has meaning only when option 'U' (see below) is disabled,.
While recovering from an error involving a document of the type front-cover/back-
cover/order-form, the machine tries to restore the correct document flow. If
identification marks are not (all) unique to each document type (i.e. documents that are
different have the same coding), the machine searches a document whose
identification marks correspond to a specific document type that is unique within a
book.
Option 'L', if enabled, means that the document that must be used for synchronisation
is the front cover (no other document has the same code for identification marks). If
disabled, it is assumed that the document in question is the back-cover.
CBDSMEN0022 Date March 05, 2018
SOFTWARE REFERENCE Release N. 2
MANUAL Page 30 of 65

 Option 'M':
When 'M' is enabled, the unit checks binary identification code ("Identification
Marks") on documents.
 Option 'P'
If enabled, document production will be PIN-protected i.e. the machine must be in the
Extended Operation mode when document production is commanded or an E52
"access denied" error will be set in the status message and execution aborted.
The machine must be in the Extended Operation mode for the whole duration of the
production process.
Of course, access to commands that set/reset option 'P' is also PIN-protected.
By default, the machine comes with option 'P' disabled.
 Option 'R':
Option 'R' enables code-line read back. If disabled, the unit does not check codeline
integrity
 Option 'Q':
When enabled, this option causes the unit to send messages only on host request (order
"@Q").
If disabled the unit cyclically sends a status message (see 1.2).
 Option 'S':
Parameter 'S' is accepted for compatibility with previous software. No action is
undertaken.
 Option 'T':
This is not a real operation mode switch.
An internal flag in the unit is initialized to a default value of 'false' (unit not trimmed)
when permanent data is lost. When this happens, a 'T' in the status message informs
the host (see 1.3.1). The command "OTY" clears flag 'T' in status message. This
command must be issued after factory set data is restored by service personnel.
 Option 'U'
As previously mentioned, option 'U', when enabled, means that each document type
has a different identification code (no more than three different document types in the
smaller feed station, each having its own binary code).
When disabled, this means that two or more different documents in a book have the
same identification code.
 Option 'V'
If "Yes" (OVY), the completed book waits in the binder without reaching the output
slot and the flag ">" appears in the CBD status.
[Note. In case of single cheques production (QQ) the waiting is the stacker]
Flag "> "can be removed only by the commands:
CBDSMEN0022 Date March 05, 2018
SOFTWARE REFERENCE Release N. 2
MANUAL Page 31 of 65

"XV"  book output


"P"  withdrawal
No other command is executed while flag ‘>’ is present in the status message.
 Option 'X'
When enabled, this option causes the machine to check that the security box is not full
before storing a chequebook. This option must be disabled on machines that do not
have a standard security box (chequebooks stored at the interior of the
cabinet/housing). The machine comes from factory with this option already properly
set.

OPCODE FUNCTION FORMAT


QA Quick cheque production QA<string4>¦

QB Quick last cover production QB<string4>¦

QC Quick front cover production QC<string4>¦

QD Quick order form production QD<string4>¦

Pre-encoded documents handling.


Documents are fed (in a similar way as for commands ‘A’,’B’,’C’ and ‘D’) and sent to the
stacker without any printing, to restore the sequence after an error (with pre-printed,
sequentially numbered, documents).
String 4 is allowed to specify wildcards position.

OPCODE FUNCTION FORMAT


QO Quick book issuing QO (opcode 'QO' with no parameter)

If sent before starting production it causes the book issuing with stapling but without
binding tape application

OPCODE FUNCTION FORMAT


QQ Quick documents issuing QQ (opcode 'QQ' with no parameter)

If sent before starting production, command “QQ” disables stapler + binder thus allowing
unstitched documents to be issued.
 With the QQ setting the command “E” must be used to bring the documents in the
stacker to the output slot.
 The QQ setting is removed by “E” and @C
CBDSMEN0022 Date March 05, 2018
SOFTWARE REFERENCE Release N. 2
MANUAL Page 32 of 65

OPCODE FUNCTION FORMAT


QR Quick document reject QR (opcode 'QR' with no parameter)

This command sends in the security box what is in the stacker (without stapling) [In case
of documents waiting in the binder (flag “>“) command “P” must be used]

OPCODE FUNCTION FORMAT


R Stacked documents reject R (opcode 'R' with no parameter)

Documents in the stacker are stapled and then stored in the security box below the paper
path (if present) or at the interior of machine housing.

OPCODE FUNCTION FORMAT


SI Set double-detector threshold for cheques SI n

Capitals 'S' and 'I' followed by an integer in decimal notation in the range 0 to 255.
The number represents the threshold value in terms of opacimeter output. It must be
determined by reading opacimeter (see op-code XDL) with one and with two sheets inserted
in its gap (the higher is the output the less opaque is the media).
The threshold should be set to the mean value between one-sheet and two-sheets output.
Taking more samples (repositioning sheet(s) between one sample and another) causes
operations to draw out but improves reliability.

OPCODE FUNCTION FORMAT


Set double-detector threshold for covers and
SJ SJ n
order forms
Capitals 'S' and 'J' followed by an integer in decimal notation in the range 0 to 255.
This function is identical to "SI" except that it relates to documents in the smaller feeder
station. This command sets the same threshold value for all three document types.
In the case that opacity is quite different, the thresholds must be individually adjusted with
the following three instructions.
OPCODE FUNCTION FORMAT
SL Set double-detector threshold for order forms SL n

SM Set double-detector threshold for back-covers SM n

SN Set double-detector threshold for front-covers SN n

Three different thresholds are available on the machine. These can be individually set to
different values using the instructions above. The threshold setting can be checked by order
'@T' , that returns all threshold values: "SIn, SLn, SMn, Snn".
CBDSMEN0022 Date March 05, 2018
SOFTWARE REFERENCE Release N. 2
MANUAL Page 33 of 65

OPCODE FUNCTION FORMAT


P Withdraw a book P (opcode 'P' with no parameter)

This command instructs the unit to withdraw and store a book that has not been taken by
the user.
In the case that command 'P' is received after the book has been taken by the user, or that
withdrawal contention arise between the user and the unit (both are trying withdraw), flag 'K'
is sent with status message until the host issues order "@K".
To avoid ambiguity, command 'P' can be sent only when a book is waiting for withdrawal.
To allow host to use withdrawal/book storage as an "abort" procedure, command 'P' is
accepted also when binding is in its terminal phase (PHOTO 8 engaged).
When command 'P' is received while the unit is printing documents it is considered non
sense and flag 'K' is also set in status message.

OPCODE FUNCTION FORMAT


U Clears reject documents count U (opcode 'U' with no parameter)

This command resets the numbers returned by order “@O”.

OPCODE FUNCTION FORMAT


W Clears wildcard strings buffer W (opcode 'W' with no parameter)

For pre-encoded documents handling.

OPCODE FUNCTION FORMAT


XDD Read minimum opacimeter output XDD (opcode 'XDD' with no parameter)

This command causes the unit to transmit opacimeter output in place of status message
(see 1.3.2).
The message containing opacimeter output is a string with an integer in the range 0 to 255
expressed in decimal notation. The string is terminated by a CR+LF sequence.
The integer represents opacimeter output when infrared beam is OFF. This value is not an
offset (displacement). It is the minimum value (max opacity) the double detector can measure.
In the case that document transparency is so low that double detector output, as measured
with command "XDL" (see below), is near double detector minimum (a difference of at least
30 units is necessary), service must be contacted for higher opacimeter gain setting.
Nevertheless, trimming of opacimeter gain is necessary only with documents which are
heavily printed through all their length, since double detector samples are taken in a very
narrow area at the end of the sheet, and gain is factory set to a value which is suitable for all
paper kind used in CBD 1000HT typical applications.
CBDSMEN0022 Date March 05, 2018
SOFTWARE REFERENCE Release N. 2
MANUAL Page 34 of 65

OPCODE FUNCTION FORMAT


XDL Read opacimeter output XDL (opcode 'XDL' with no parameter)

This command is similar to the previous, from which it differs only in that opacimeter
output with infrared beam ON is sent.
Read values are used to set threshold values (see op-codes "SI", "SJ", "SL", "SM" and
"SN").

OPCODE FUNCTION FORMAT


XDE End double detector acquisition XDE (opcode 'XDE' with no parameter)

This command restore status message transmission.

OPCODE FUNCTION FORMAT


XE Eject book XE (opcode 'XE' with no parameter)

On machines with eject rollers, this command causes the book to be completely ejected,
while on machines without an appropriate mechanical hardware, it will cause error E10
"unknown instruction" to be set.

OPCODE FUNCTION FORMAT


XK1L Secure paper feed stations cover lock XK1L (opcode 'XK1L' with no parameter)

This command causes security lock blocking shaft (in paper stations) to be released (lock
secured). Machines where the installed DDO firmware has an 'X' or an 'Y' as third letter of the
identifier (for instance: BCX 3.3), have automatic (mechanic) securing mechanism and do not
need "XK1L" command (the same is true for the "XK2L" command depicted later in this
manual).

OPCODE FUNCTION FORMAT


XK1U Enable paper feed stations cover unlock XK1U (opcode 'XK1U' with no parameter)

This command is the reverse of the above. Lock blocking shaft is attracted, thus allowing
paper station armour to be unlocked.
This command can be issued only when the unit is in the Extended Operation (E.O.)
mode, which can be accessed only with command "XU+" which requires a (secret) access
code.
An attempt to issue command "XK1U" without the unit in E.O. mode causes condition
E52 "access denied" to be entered. CBD 1000HT returns from condition E52 when it receives
order "@C".
CBDSMEN0022 Date March 05, 2018
SOFTWARE REFERENCE Release N. 2
MANUAL Page 35 of 65

OPCODE FUNCTION FORMAT


XK2L Secure collected books box lock XK2L (opcode 'XK2L' with no parameter)

This command is similar to "XK1L" except that it relates to collected books (unit-
withdrawn) box rather than to paper stations armour.

OPCODE FUNCTION FORMAT


XK2U Enable collected books box unlocking XK2U (opcode 'XK2U' with no parameter)

This command is similar to "XK1U" except that it relates to collected (unit withdrawn)
books rather than to paper stations armour.
This command requires E.O. mode enabled too.

OPCODE FUNCTION FORMAT


XU+ Enter Extended Operation mode XU+ n

Capital 'X' and 'U' followed by a plus sign ('+') which, in turn, is followed by an integer in
the range 0 to 65535 in decimal notation. The number represents an access code.
This command enables some CBD 1000HT special (protected) functions. If the access
code is wrong, condition E51 "wrong security code" is entered. The unit returns from E51
condition when order "@C" is issued by host. Then a new attempt can be made to enter E.O.
mode, but, as three unsuccessful attempts are reached, the unit enters E53 "too many retries"
condition. Once E53 condition is entered there is no way of soft-restoring normal operation.
The unit must be switched OFF and then switched ON again.

OPCODE FUNCTION FORMAT


XU- Leave Extended Operation mode XU-

Capital 'X' and 'U' followed by a minus sign ('-') .


Operation mode set by function "XU+" is exited.

OPCODE FUNCTION FORMAT


XUC Change security code XUC n

Capitals 'X', 'U' and 'C' followed by an integer in the range 0 to 65535 in decimal notation.
The number represents the new value to which access code is to be changed. If unit is not
in E.O. mode condition E52 "access denied" is entered.
After command "XUC" has been executed the unit is still in E.O. mode.
CBDSMEN0022 Date March 05, 2018
SOFTWARE REFERENCE Release N. 2
MANUAL Page 36 of 65

OPCODE FUNCTION FORMAT


XV Booklet output XV (opcode 'XV' with no parameter)

When option ‘V’ is set (“OVY”), this command causes the output of the book that is
waiting in the binder (flag ‘>’ present in the status message).
If sent when no book is waiting, it causes a specific error (E18).

OPCODE FUNCTION FORMAT


XX Stapler test XX (opcode 'XX' with no parameter)
As command "XX" is received the stapler is activated for one complete travel. To avoid
damage to the mechanism, some paper must be inserted in stapler gap before the command is
issued.

OPCODE FUNCTION FORMAT


Z Reset document number Z (opcode 'Z' with no parameter)

The CBD 1000HT associates an increasing number in the range 1 - 255 to each document
that is being produced.
This number (that does not appear on the document) is used to identify documents whose
production has been interrupted by execution exception(s) (codeline error, jam etc.).
The host can request the list of aborted processes with order "@A" (see chapter 2.). With
pre-encoded documents, this information can be used, for instance, to evaluate the number of
next sheet in the feeder station.
Instruction 'Z' resets document number, i.e. next document will be assigned number 1.
CBDSMEN0022 Date March 05, 2018
SOFTWARE REFERENCE Release N. 2
MANUAL Page 37 of 65

3.2.3 OCR Text Reader

Optionally, CBD 1000HT includes an OCR text reader whose function is to handle pre-
printed cheques. It is possible to validate the cheque comparing a part of the code-line just
going to be printed against the pre-printed serial number, or to validate the cheque if a
minimum of valid characters is read. In case of mismatch the flag 'N' is added to the status and
machine doesn’t print the cheque addressing it to the reject bin. Operator intervention is
required to restore the proper sequence.
With this mode active, it is advisable to disable the code-line read-back feature as the
cheque can’t be reprinted avoiding disrupting the sequence.

OPCODE FUNCTION FORMAT


Sets the leading char position in the
NB NB n
code-line for text comparison.

The n decimal number represents the position, according to MICR ISO1004 specification,
of the first character of the code-line to be compared. It should be included in the range 14 to
52. Spaces are ignored.
It can take the special value of 99, in this case there is no code-line comparison but the cheque
is validated if a minimum of characters is read.
An invalid parameter supplied will raise an ‘Error 10’ in the status meaning ‘Unknown
instruction’. This parameter is kept permanent.

OPCODE FUNCTION FORMAT


Set the extension of the code-line
characters to verify against the pre-
NL printed string, or the minimum NL n
number of read characters needed to
accept the cheque.

The n decimal number must be included in the range 0 to 16. This value can be the
number of character to be compared, or the minimum number of read characters needed in
order to accept the cheque. Failing to accomplish this will raise an ‘Error 10’ in the status
meaning ‘Unknown instruction’. This parameter is kept permanent. Setting the parameter as 0
is the way for disabling the OCR text verifying feature and therefore it is compatible with
previous firmware versions and model without an OCR reader.
CBDSMEN0022 Date March 05, 2018
SOFTWARE REFERENCE Release N. 2
MANUAL Page 38 of 65

4. SPECIAL INSTRUCTIONS

In the following pages some functions are described that, as a rule, are not used in
application programs.

!!! WARNING ! ! !

Misuse of some of these instructions can cause permanent damage


to mechanical structures and/or electronic boards and bring
physical injury to the operator.
These instructions have been implemented for technical personnel
use. The documentation herein is issued for the purpose of
allowing the user to implement on his system simple procedures
for home-repairing and parameter restoring. Such procedures
must be used only with service personnel advice.
Syntax check and parameter validity check are loose. Not
necessarily an aid is given to the programmer for error detection
while debugging procedures.
Therefore the use of special functions is not recommended to
programmers that are not experienced with CBD 1000HT.
In the following description, functions are grouped by the
actuation they command. A letter 'd' in op-code description stands
for one digit.
CBDSMEN0022 Date March 05, 2018
SOFTWARE REFERENCE Release N. 2
MANUAL Page 39 of 65

4.1 SOLENOIDS AND READER WINDOW ACTIVATION

OPCODE FUNCTION FORMAT


XA Actuate solenoid/relay | Open read window XA[W|n]

 Capitals 'X' and 'A' immediately followed (no white space allowed) by capital 'W' or
 Capitals 'X' and 'A' followed by an integer in decimal notation in the range 1 to 12. The
integer may be separated from the op-code and terminates at the first non-digit or after
two digits are read.
Instruction <XAW> opens read window of code-line reader.
In the case of a numeric parameter, command "XA" actuates the corresponding
solenoid or relay.
If the device in question is devoted to release a security lock E.O. mode is required.

OPCODE FUNCTION FORMAT


XS Release solenoid/relay | Close read window XS[W|n]
Format is analogue to the previous instruction, except that capital 'S' is in place of 'A'.
This command is the reverse of the above.

4.2 MOTORS CONTROL

OPCODE FUNCTION FORMAT


XCd Start a D.C. motor | Stop a D.C. motor XCd[O|A|S]

Capitals 'X' and 'C' immediately followed by a digit which, in turn, is immediately
followed by one of the capitals 'O', 'A' + 'S'.
The digit is the motor number (1 to 4) and is considered to be part of the op-code (exactly
one digit - no blanks).
The parameter that follows the motor number indicates the operation to perform.
With parameters 'O' and 'A' the motor is started in different directions for the two
parameters. If the feeder motor is involved, then E.O. mode is required.
With parameter 'S' the motor is stopped.

OPCODE FUNCTION FORMAT


XLd Start a stepper motor | Stop a stepper motor XLd[O|A|S]

Capitals 'X' and 'L' immediately followed by a digit which, in turn, is immediately
followed by one of the capitals 'O', 'A' + 'S'.
CBDSMEN0022 Date March 05, 2018
SOFTWARE REFERENCE Release N. 2
MANUAL Page 40 of 65

This command is similar to the above except that it relates to stepper motors.
The motor number must be in the range 1 to 8 and is still considered to be part of the op-code.
Parameters 'O', 'A' and 'S' have the same meaning as above.

OPCODE FUNCTION FORMAT


XMd Advance a stepper motor by 13.5 deg XMd (opcode only)

Letters 'X' and 'M' immediately followed by a digit in the range 1 to 8.


The digit is the motor number. The direction is the same as it was set by the last actuation.
After the operation is performed, the motor is left in a powered state (the motor offers
resistance to any attempt to manually move it).

Warning:
Motor drivers and motor windings are dissipating heat. To release
the motor, command "XLdS" must be issued.

OPCODE FUNCTION FORMAT


XN Issue a command to stepper motors control board XN n

Capitals 'X' and 'N' followed by an integer in decimal notation in the range 0 to 255. The
integer may be separated from the op-code and terminates at the first non digit encountered.
The number, which represents a command, is sent to stepper motors controller. The
command code / operation relationship can vary with board releases.
Specific information for the installed release must be obtained before attempting to use
this function.
CBDSMEN0022 Date March 05, 2018
SOFTWARE REFERENCE Release N. 2
MANUAL Page 41 of 65

4.3 TRIMMING (OFFSETS SET-UP)

OPCODE FUNCTION FORMAT


XO Set offset XO[B|C|F|H|L|M|R|S|T] n[-]

Capitals 'X' and 'O' immediately followed by one of capitals 'B', ‘C’, 'F', 'H', 'L', 'M', 'R', 'S'
or 'T' then followed by numeric parameter in decimal form.
If capitals X' and 'O' are not immediately followed by one of the letters in the list above
then error E33 will be generated.
If terminated by a minus sign, the number is considered negative. When the terminator is
CR, LF, TAB or blank, the number is taken as positive.
When the third letter is 'R', negative values are not allowed (error E10 will be generated).

 Offset 'B'
Offset 'B' adjusts book position at binding tape bonding position therefore affecting the
symmetry of tape on the book.
Parameter range is -8 to +7 (according to syntax, 8- to 7). Each unit in the parameter
corresponds to a difference in book positioning of about 0.3 mm or, in terms of sticked
tape symmetry, to a change of the difference between front and rear of about 0.6 mm
(when the book position is changed by 1 mm the difference between front and rear
changes by 2 mm because there is 1 mm less tape on one side and 1 mm more on the
other).
Positive values cause the book to advance (less tape on the front).
 Offset 'C'
Offset 'C' affects binding tape cutting height.
Parameter range is -8 to +7 (according to syntax, 8- to 7). Each unit in the parameter
corresponds to a difference in tape height of about 0.25 mm.
Positive values cause height to increase.
 Offset 'F'
Offset 'F' affects book position at binding tape folding i.e. the pressure that is applied
to the tape when this is bonded to book edge.
Parameter range is -8 to +7 (according to syntax, 8- to 7). Each unit in the parameter
corresponds to a difference in book positioning of about 0.6 mm.
 Offset 'H'
Offset 'H' adjust font wheel offset (on code-line encoder), i.e. angular position of
characters font when the hammer solenoid is fired. Range is -31 to +31 (31- to 31).
When characters are voided on the left then offset 'H' must be decreased, when
characters are voided on the right then the offset must be increased.
CBDSMEN0022 Date March 05, 2018
SOFTWARE REFERENCE Release N. 2
MANUAL Page 42 of 65

Once complete character printing has been obtained, two print tests should be
performed: one with the offset increased by 6 and another with the offset decreased by
6. Symmetrical voiding should be obtained. This indicates that the selected (center)
value is in the middle of the suitable range.
 Offset 'L'
Offset 'L' affects the position of the pushing lug in the document stacker.
Since document length greatly affects pushing lug position, trimming must be
performed only after document length has been accurately measured and the resulting
value transmitted to the machine.
Parameter range is -16 to +15 (according to syntax, 16- to 15). Each unit in the
parameter corresponds to a difference in pushing lug positioning of about 0.5 mm.
 Offset 'M'
Offset 'M' affects code-line position on the cheque.
Parameter range is -16 to +15 (according to syntax, 16- to 15). Each unit in the
parameter corresponds to a difference in code-line position of about 0.25 mm.
Positive values move the codeline right.
 Offset 'R'
Offset 'R' affects MICR ribbon advancement (between characters).
Parameter range is 12 to 19. Since ribbon advancement depends on cartridge
construction, units are arbitrary. Usual values are in the range 14 to 17.
 Offset 'S'
With offset 'S' the force with which unstitched sheets are pushed against the stapler
may be adjusted.
Offset 'S' affects the pushing lug position at stapling. Parameter range is -16 to 15,
each unit representing a change in position of about 0.5 mm.
Positive values cause an increase in force.
 Offset 'T'
Offset 'T' affects binding tape height.
Parameter range is -8 to +7 (according to syntax, 8- to 7). Each unit in the parameter
corresponds to a difference in tape height of about 0.25 mm.
Positive values cause tape height to increase.
CBDSMEN0022 Date March 05, 2018
SOFTWARE REFERENCE Release N. 2
MANUAL Page 43 of 65

4.4 INTERNAL DEVICES CONTROL

OPCODE FUNCTION FORMAT


XW Send a command string to code-line printer (encoder) XW<string>¦

Capitals 'X' and 'W' immediately followed by a string terminated by '¦' (ASCII Hex 7C).
The string ('¦' not included), is sent to code-line printer. Backslash-ASCII code sequences
are still allowed.

Available commands depend on the installed board version. Specific information for the
installed release must be obtained before attempting to use this function.

OPCODE FUNCTION FORMAT


Xd Pulse Sync signal (text printers or code-line encoder) Xd (opcode only)

Capital 'X' immediately followed by one of digits '1', '2', '3' and '4'.
Commands "X1", "X2" and "X3" assert the Sync signal, respectively, on printers 1,2 and 3.
Command "X4" asserts code-line printer Sync.
Actuation is impulsive, so there is no reverse command.
CBDSMEN0022 Date March 05, 2018
SOFTWARE REFERENCE Release N. 2
MANUAL Page 44 of 65

4.5 HARDWARE TEST

OPCODE FUNCTION FORMAT


XTA Perform hardware test 'A' XTA (opcode 'XTA' with no parameter)

Hardware test 'A' is performed. This test is intended to be an aid in machine trimming.
The pushing lug is moved to the position for stapling.
The pressure plates mechanism is moved half-way.
The tape lifting mechanism is moved to the cut position (no scissors activation).
The test has a duration of a few seconds, then the mechanisms will be moved back to the
normal positions.

OPCODE FUNCTION FORMAT


XTB Perform bind test XTB (n)

Opcode "XTB" followed by an integer in decimal notation less or equal to 53.


Hardware test 'B' is performed. This test is intended to be an aid to machine trimming.
The test consists in binding a book whose thickness is evaluated from the numeric
parameter value. This is the number of sheets in the book.
A stapled block (without tape on it) must be first placed in the stacker.
Document height and length must have been communicated to the machine with the usual
instructions (opcodes 'H' and 'L').
CBDSMEN0022 Date March 05, 2018
SOFTWARE REFERENCE Release N. 2
MANUAL Page 45 of 65

5. PRINTERS
The CBD 1000HT has up to three text printers. Each of them is regarded as an internal
device, to which the host program can issue commands in the appropriate fields of the
instructions that command document production.
More, specific instructions are provided which allow direct communication with the
printers. These instructions allow parameter set-up, images definition and font downloading.
Regarding each printer as a separate device (as they actually are), provides a suitable
programming scheme according to which the op-code of the command (or the field in use or,
in the case of op-code 'M', the parameter immediately following the op-code) selects the print-
head influenced by the transferred data. Transferred data, in turn, can contain instructions
which will affect the addressed print-head behaviour and/or text.
So, in the following paragraphs, we will discuss certain commands that must be regarded
as commands for separate devices, rather than true CBD 1000HT instructions.
These commands are implemented by the printers firmware. Any upgrade in printers
firmware will therefore enhance printers capabilities without affecting CBD 1000HT general
features.
When an upgrade to printers firmware is released, only a specific upgrade to the software
reference manual could be produced (if no other contextual upgrade has been carried on the
machine).

5.1 GENERAL DESCRIPTION


Text printers in the CBD 1000HT are 24 needles impact printers. Each of them allows
both a full height single-line printing and a half height two-rows per line printing. The two
types of printing may be interleaved.
They are available either in a version with a single needles column or in a version with
staggered needles columns.
The first version allows printing of large characters (up to about 8.45 mm heigh, font
dependant) on a single row and printing of normal size (up to about 3.1 mm high, font
dependant) on two rows.
The second, which, thanks to the doubled needles density, allows a near letter quality
printing, prints out characters up to 3.45 mm high or up to 1.35 mm high, respectively for one
row and two rows per line.
With the exception of characters in the RAM font (see 5.4) small characters are obtained
by separate fonts. Once a small characters font has been selected, the user program must issue
a specific command to the printer in order to select printing in the upper part or in the lower
part of the line.
All character fonts may have proportional character spacing. Conservative programming
suggests that any font is regarded as having proportional spacing. A complete set of print
pointer (an imaginary cursor) manipulation commands has been implemented for this task.
Driving software is the same for both types of printer.
CBDSMEN0022 Date March 05, 2018
SOFTWARE REFERENCE Release N. 2
MANUAL Page 46 of 65

Printers are intrinsically graphic. Each character sent by the host causes some bits in a
buffer (which is an image of printed dots) to be set to one or cleared to zero. We will call print
buffer the buffer above, and character transfer the process of converting ASCII codes to bit
map.
Two different print modes are presently available on the printers.
The first is the compatibility mode. This is the mode that is set at power-on and provides
full compatibility with previous printer firmware releases.
In this mode the print buffer, which stores an image of the printed text, is not cleared when
a document is printed. Thus, only the text that is different in consecutive documents must be
transferred to the printers.
However, a problem may arise when document sequence is altered because of production
exception. In fact, in this case an instruction that changes the print buffer could be processed
before a document which assumes the print buffer intact is processed for the second time (for
recovering). The solution is to transmit the full text for those documents at boundaries of
blocks of documents having constant text.
So, in the compatibility mode, the programmer is involved in considerations about the
maximum possible number of rejected documents. Since this number is strongly related to the
maximum number of documents processed at a time, it is not guaranteed that in future
improved versions of the machine it will not change.
So, unless retransmission of the text is used (regardless of constant strings), usage of the
second print mode is strongly recommended.
In this mode, which must be expressly set up by the programmer (command [Esc] P - see
6.2.4), the print buffer is cleared as the document is printed.
To keep the total count of transmitted characters as low as possible, string variables have
been implemented in the printers. The host computer simply loads the printers (before
production is started) with all constant fields, storing each of them in a specific variable.
Then, each constant string is recalled with an escape sequence (within fields dedicated to
printers text in commands 'A', 'B', 'C' and 'D') and any variable information added.
Another important question concerning the second print mode is how characters are
transferred to the print buffer (i.e. the memory image of the text).
In the compatibility mode, characters are transferred in a way that causes pre-existing
patterns to be overwritten (i.e. the existing characters are substituted by the new ones). This
allows constant fields to be left untouched while variable fields are substituted to the previous
ones. The only exception is when small-size characters (two rows per print-head) are printed
in the lower part of the line: in that case existing characters in the lower row are substituted,
but characters in the upper row (if they are present) are left unchanged.
In print mode #2 the overwrite feature is no longer necessary (since buffer is cleared as
documents are printed). More, having the printers graphic capabilities, it is desiderable to
allow the user to mix graphics with text. For this reason, all transfers to the print buffer are
made in a way (OR-writing) that causes subsequently transferred patterns to be mixed (i.e. it
will be marked any dot that is programmed to black in whichever of the two patterns).
Printing is physically carried out from right to left. From a logical point of view, instead, it
starts at an imaginary left margin to which the print buffer pointer is reset after each print. If a
CBDSMEN0022 Date March 05, 2018
SOFTWARE REFERENCE Release N. 2
MANUAL Page 47 of 65

left margin is not set with the appropriate escape sequence, then the left margin will coincide
with the left edge of the paper.
The rightmost position for left margin is limited by parameter range in the commands
(which are escape sequences) that set it. This is about 87 mm from right edge for the
command "[ESC] M [n]" (described later) and 255 mm from the left edge for the command
"[ESC] Q [n]" (also described later).
Another feature of CBD 1000HT printers is that they keep a buffer with the image of a
document voiding string always ready for printing. The programmer may choose one of four
different strings for this text. They are "VOID ", "ANNULLATO ", "CANCELLED " and
"NULL". Selected text is repeatedly printed on rejected documents from left edge up to right
edge.
One important thing the programmer must be aware of is that, differently from general set-
up parameters, printers parameters and constant strings are not retained in permanent memory.
So, a black-out, even of short duration, will cause them to be lost. Therefore, each time that
the reset flag (the exclamation mark) is detected in the status message, host computer must
reinitialize constant strings, document voiding string selection, left margin and any other user-
defined or user-settable item.
The method used to distinguish commands (within data transferred to printers) from
normal text is the well known, widely used, escape sequence method.

5.2 STRINGS
Strings are sequences of commands and/or text that are stored in the text printers.
Each string is identified by a capital letter (which is declared in the escape sequence that
defines the string) and is recalled with a three characters escape sequence. All 26 letters are
used (i.e. 26 different strings can be stored). Strings can be redefined in subsequent program
runs.
The strings can contain escape sequences but cannot contain further string definitions or
reference to other strings, even if they have been already defined.
Strings are expanded (i.e. encoded commands are executed and text is copied to the print
buffer) when the appropriate command (which references a specific string in its parameter
field) is issued in the field of instructions 'A', 'B', 'C' or 'D' that is dedicated to the data for the
printer in matter.

5.3 GRAPHIC CAPABILITIES


Printers allow user-defined patterns to be downloaded in memory (before document
production is started) and recalled at print time.
Each printer can hold four images up to 100 mm wide (in terms of dot columns: 938
columns max) plus seven images up to 50 mm wide (469 columns max), regardless of the
installed print-head (NLQ or draft).
The user software must issue to the printer device an escape sequence that selects a buffer
and communicates to the printer the number of columns which make up the image. Then,
CBDSMEN0022 Date March 05, 2018
SOFTWARE REFERENCE Release N. 2
MANUAL Page 48 of 65

user program must send a stream of bytes representing the image. The format of the bit stream
data is described in the section that gives detailed description (the format) of the command.
Buffers are identified with capitals 'A' to 'D' for 100 mm buffers and with capitals 'A' to 'G'
for 50 mm buffers.
Four CBD 1000HT general commands (opcodes 'I', 'J', 'K' and 'M') are suitable for bit
patterns download. There is no restriction for message length in these commands, but care
must be used (especially with binary parameters and bit patterns, which can produce any bit
configuration - and therefore any character) so that command syntax is not violated.
Images are copied to the print buffer when the appropriate command (which references a
specific buffer in its parameter field) is issued in the field of instructions 'A', 'B', 'C' or 'D' that
is dedicated to the text for the printer in matter.

5.4 RAM FONTS


Printers allow a user-defined character font to be stored in R.A.M. and used in place of
fixed fonts any time the host-computer selects it as the working font (up to three different
fonts can be downloaded to the CBD 1000HT - each printer is a separate device).
Each character in the font can be individually defined as a small character (for two rows
printing) or as a full size character.
The memory used is the same used for graphics. Graphic images and downloaded font can
be used at the same time as long as no memory contention arises.
Therefore, a thorough comprehension of how memory is allocated and deallocated (as
more characters or bit images are defined) is necessary. Of course, even if both features are
not used at a time, knowledge of maximum allowable font size is required, as well as
knowledge of the deallocation process (if a font is to be redefined successively).
First, the host computer must issue an escape sequence with some general information
about the font. We call it the font definition.
Then, individual escape sequences must be issued for each character used. These escape
sequences define characters shapes and we call each command a character definition.
When the RAM font is defined, a block of memory is allocated and a data structure of
fixed size is built in RAM.
Then, as characters are defined, more memory is used and, when necessary, other blocks
are allocated to the font.
First (i.e. at font definition), buffer 'D' for (up to) 100 mm images is allocated. Then, as
memory demand increases, buffers 'C', 'B' and 'A' are allocated to the font. When all 100 mm
buffers have been allocated, it is the turn of buffer 'G' of 50 mm images, and so on until also
buffer 'A' of 50 mm images is allocated. At this point, memory is exhausted.
The following table reports memory allocation as a function of the total columns count in
characters bit-patterns:
100mm buffer 'D' is allocated when the font is defined
100mm buffer 'C' is allocated when the 683rd column is defined
CBDSMEN0022 Date March 05, 2018
SOFTWARE REFERENCE Release N. 2
MANUAL Page 49 of 65

100mm buffer 'B' is allocated when the 1621st column is defined


100mm buffer 'A' is allocated when the 2559th column is defined
50mm buffer 'G' is allocated when the 3497th column is defined
50mm buffer 'F' is allocated when the 3966th column is defined
50mm buffer 'E' is allocated when the 4435th column is defined
50mm buffer 'D' is allocated when the 4904th column is defined
50mm buffer 'C' is allocated when the 5373rd column is defined
50mm buffer 'B' is allocated when the 5842nd column is defined
50mm buffer 'A' is allocated when the 6311th column is defined

MAX SIZE OF RAM FONT: 6779 columns

When a memory conflict arises between graphic functions and downloaded font,
contended memory is assigned to the last requested function.
In other words, when an image buffer is allocated to the RAM font, then any previously stored
image in that buffer is lost and any print command concerning that buffer will be ignored.
Similarly, when an image buffer that had been previously assigned to RAM font is used
for graphic image storage then the whole RAM font is cleared. If, at that time, RAM font
was the working font, then (fixed) font 0 is selected.
A character can be defined more than once, in which case the last shape defined will be in
effect. However, previously allocated memory is not released (i.e. successive character
definitions will cause more memory to be assigned to the RAM font). When a new font is to
be loaded in memory, the host computer should start from the beginning with RAM font
definition, even if general parameters are the still same. This causes the allocation process to
restart from the beginning too.

5.5 GENERAL FORMAT OF COMMANDS


Chapter 6 is fully dedicated to printer command description.
They are all in the form of escape sequences. Escape sequences are called so after the
name of their first character, which is always the escape character (ASCII decimal 27, hex 1B)
that allows the printers to distinguish the immediately following data (which represent a
command) from ordinary text.
Immediately following the escape character comes the op-code, defining which kind of
action the printer is to take. Depending on the op-code, variable data may or may not follow.
A specific escape sequence (two consecutive escape characters) allows character number
27 of the selected font to be prin
CBDSMEN0022 Date March 05, 2018
SOFTWARE REFERENCE Release N. 2
MANUAL Page 50 of 65

6. PRINTERS COMMANDS
In next paragraphs a description of command syntax is given. We give here some general
rules concerning syntax description that are valid to the end of this manual.
The following symbol:
[Esc]
means the escape character (ASCII decimal 27 or Hexadecimal 1B)
A number between square brackets (i.e. like those used in the symbol above) means a
constant one-byte binary value.
When the number in brackets has no suffix it is intended to be a decimal value.
A binary value is transmitted either as is or as a backslash plus decimal value sequence
(this is mandatory when the binary value produces a character which conflicts with CBD
1000HT general syntax). So, the following symbol:
[16]
stands for the character corresponding to ASCII decimal 16 or hexadecimal 10. It can also
be transmitted to the printers as \016.
Any other combination of characters between square brackets means a symbolic reference
(to one or more characters or to a one-byte binary value) whose meaning is to be described in
the command explanation.
For readability, items (binary values, characters or symbolic references) may be separated
in the descriptions by white space that must be ignored.
Any other character must be taken literally.

6.1 PRINTER COMMANDS SUMMARY (ORDERED BY THE OP-CODE)

Clear print buffer [Esc] [16] see 6.2.4


Copy character no 27 to print buffer [Esc] [Esc] see 6.2.4
elect needle impact strength [Esc] # [n] see 6.2.4
Select font [Esc] % [n] see 6.2.2
Select font #0 [Esc] [38] see 6.2.2
Select font #1 [Esc] [39] see 6.2.2
Select font #2 [Esc] [40] see 6.2.2
Select font #3 [Esc] [41] see 6.2.2
elect RAM font [Esc] [45] see 6.2.2
Select voiding string "VOID" [Esc] [46] see 6.2.3
Select voiding string "ANNULLATO" [Esc] [48] see 6.2.3
Select voiding string "CANCELLED" [Esc] [50] see 6.2.3
CBDSMEN0022 Date March 05, 2018
SOFTWARE REFERENCE Release N. 2
MANUAL Page 51 of 65

Select voiding string "NULL" [Esc] [52] see 6.2.3


Move print buffer pointer left [Esc] < see 6.2.1
by 2 dot columns
Recall saved pointer value [Esc] = see 6.2.1
Move print buffer pointer right [Esc] > see 6.2.1
by 2 dot columns
Center text around current pointer [Esc] C [text] [Esc] E see 6.2.1
position
Define RAM font [Esc] F [s1] [s2] see 6.2.6
Move print buffer pointer right [Esc] K [n] see 6.2.1
(millimeters)
Move print buffer pointer right (in [Esc] L [n] see 6.2.1
multiples of 8 dot columns)
Set left margin [Esc] M [n] see 6.2.1
Set print buffer pointer to specified [Esc] N [n] see 6.2.1
position
Set print buffer pointer to left margin [Esc] O see 6.2.1
Select print mode #2 [Esc] P see 6.2.4
Set left margin [Esc] Q [n] see 6.2.1
Right-align text [Esc] R [text] [Esc]E see 6.2.1
Define string [Esc] S [i] [c] [Esc] [0] see 6.2.7
Define full-size character [Esc] W [c] [n] [i] see 6.2.6
Define an image up to 100 mm [Esc] X [b] [nh] [nl] [i] see 6.2.5
(938 dot columns) wide
Define an image up to 50 mm [Esc] Y [b] [nh] [nl] [i] see 6.2.5
(469 dot columns) wide
Save pointer value [Esc] ^ see 6.2.1
Select upper row printing [Esc] d see 6.2.2
Select lower row printing [Esc] f see 6.2.2
Expand string [Esc] s [i] see 6.2.7
Temporarily set character spacing [Esc] t [n] see 6.2.2
Define small character [Esc] w [c] [n] [i] see 6.2.6
Copy an image up to 100 mm (938 dot [Esc] x [b] see 6.2.5
columns) wide to print buffer
Copy an image up to 50 mm (469 dot [Esc] y [b] see 6.2.5
columns) wide to print buffer
CBDSMEN0022 Date March 05, 2018
SOFTWARE REFERENCE Release N. 2
MANUAL Page 52 of 65

6.2 PRINTER COMMANDS (GROUPED BY FUNCTION)


In this paragraph, commands are grouped by functional operation. For each command, a
short description of its operation is given first. Then, the syntax of the command is described
and then command operation more widely explained. Finally, one or more examples of how
the command can be transmitted to the printers are given. The examples are enclosed in
double quotes (which are not part of the transmitted text).

6.2.1 Pointer positioning - Margin Setting - Text Justification

 Set left margin


[Esc] M [n]
[n] is a one-byte binary value.
With respect to a line 305 mm left from the right edge, left margin is set at its right by
a distance equal to parameter value multiplied by 0.855 mm.
Therefore its distance in mm from right edge is:
305 - n * 0.855
Print buffer pointer is immediately set to the new margin.
This command is present for compatibility with previous software. Usage of the
next described command is suggested.
Examples: "\27M\100" (Set left margin 219 mm from right edge)
"\27\77\181" (Set left margin 150 mm from right edge)

 Set left margin


[Esc] Q [n]
[n] is a one-byte binary value which gives the distance, in millimeters, from the left
edge to the left margin.
Example: "\27Q\100" (Set left margin 100 mm from left edge)

 Set print buffer pointer to left margin


[Esc] O
Operation is intuitive.
Example: "\27O"

 Set print buffer pointer to specified position


[Esc] N [n]
[n] is a one-byte binary value.
This is the distance, in millimeters between the left margin (as set by the previously
described command) and the new print position.
Since parameter range is 0 to 255, if the left margin is left to 0 and document length
exceeds 255 mm, then print pointer advancement command must be used.
Example: "\27N\100" (places print pointer 100 mm right from the left margin)
CBDSMEN0022 Date March 05, 2018
SOFTWARE REFERENCE Release N. 2
MANUAL Page 53 of 65

 Move print buffer pointer right (millimeters)


[Esc] K [n]
[n] is a one-byte binary value.
Print buffer pointer is advanced by a distance equal, in millimeters, to the numeric
parameter. This causes the point where subsequently received characters will be
printed to move right.
Example: "\27K\100" (advances print pointer by 100 mm)

 Move print buffer pointer right (in multiples of 8 dot columns)


[Esc] L [n]
[n] is a one-byte binary value.
Print buffer pointer is incremented by a quantity proportional to numeric parameter.
This causes the point where subsequently received characters will be printed to move
right.
Each unit in the parameter corresponds to 8 dot columns, i.e. to a distance of about
0.855 mm.
Examples: "\27L\100" (advances print pointer by 85.5 mm)
"\27\76\117" (advances print pointer by 100 mm)

 Save pointer value


[Esc] ^
The present position of the pointer is stored.
Example: "\27^"

 Recall saved pointer value


[Esc] =
The pointer is set to the previously saved position
Examples: "\27="

 Move print buffer pointer right by 2 dot columns


[Esc] >
The pointer is moved right by two columns
Example: "\27>"

 Move print buffer pointer left by 2 dot columns


[Esc] <
The pointer is moved left by two columns.
This function and the previous one can be used, together with pointer save/restore
functions, to implement character composition.
Example: "\27<"
CBDSMEN0022 Date March 05, 2018
SOFTWARE REFERENCE Release N. 2
MANUAL Page 54 of 65

 Right-align text
[Esc] R [text] [Esc] E
[text] is a string of characters (literal and/or reference to strings)
The string is positioned such that it ends at the current pointer position.
The pointer must be moved to the place where printed text should end before the
command is issued.
There are some restrictions to the text between the "[Esc] R" and the "[Esc] E".
First, its length cannot exceed 64 characters. More, no escape sequence other than
string invocations or the "[Esc] [Esc]" sequence (which prints the character having
ASCII code decimal 27) can be used. This inhibits font switching within aligned text
as well as usage of functions which are incompatible with the function in progress.
If string constants are used, then total text length (literal text in the escape sequence
above plus text in recalled strings), cannot exceed 64 characters.
Example: "\27R125.80\27E"

 Center text around current pointer position


[Esc] C [text] [Esc] E
[text] is a string of characters (literal and/or reference to strings)
The string is positioned such that it will be centered around the current pointer
position.
The pointer must be moved to the place where printed text should centered before the
command is issued.
Constraints on the text are the same as the previous command (i.e. length cannot
exceed 64 characters, no escape sequence other than string invocations or the "[Esc]
[Esc]" sequence can be used, if string constants are used then total text length cannot
exceed 64 characters).
Example: "\27CFlorence branch\27E"

6.2.2 Font selection - Upper and lower row selection - Character spacing setting

 Select font
[Esc] % [n]
[n] is either a one-byte binary value in the range 0 to 3 or a digit in the range '0' to '3'
(i.e. the character representation of a number less or equal to 3).
The font indicated by the parameter is selected.
Please contact our Customers Service Division for details on available fonts.
Examples: "\27%0", "\27%\000"

 Select font #0
[Esc] [38]
Short form of font #0 selection (only opcode, no parameter).
Examples: "\27&", "\27\038"
CBDSMEN0022 Date March 05, 2018
SOFTWARE REFERENCE Release N. 2
MANUAL Page 55 of 65

 Select font #1
[Esc] [39]
Short form of font #1 selection (only opcode, no parameter).
Examples: "\27'" (character 39 is the single quote), "\27\039"

 Select font #2
[Esc] [40]
Short form of font #2 selection (only opcode, no parameter).
Examples: "\27(", "\27\040"

 Select font #3
[Esc] [41]
Short form of font #3 selection (only opcode, no parameter).
Examples: "\27)", "\27\041"

 Select RAM font


[Esc] [45]
The RAM font is selected. A font must have been downloaded before the command is
issued or it will have no effect (i.e. a successively downloaded font will not be in
effect just after downloading).
Examples: "\27-", "\27\045"

 Select upper row printing


[Esc] d
This command operates only when "small" characters are printed.
Fixed fonts are either small characters fonts or full-height fonts (but not both at the same
time). RAM fonts can contain both small and full-height characters at the same time.
The command remains in effect even when full-height characters are printed (taking no
action). It resumes operation when small character are selected again.
Examples: "\27d", "\27\100"

 Select lower row printing


[Esc] f
Also this command operates only when "small" characters are printed. Operation is
similar to that of the command described above.
Examples: "\27f", "\27\102"

 Temporarily set character spacing


[Esc] t [n]
[n] is a one-byte binary value in the range 0 to 15.
CBDSMEN0022 Date March 05, 2018
SOFTWARE REFERENCE Release N. 2
MANUAL Page 56 of 65

Actually, only the lower four bits of the value are considered, thus allowing any
printable character whose lower four bits correspond to the desired value to be used. In
particular, when the parameter is in the range 0 - 9, then a digit representing the value
is allowed.
This command overrides the default spacing that is automatically set when a font is
selected. If a RAM font (which sets two different default spacing values, one for small
characters and one for full-height characters) is in use, then this commands sets both
values to the same amount.
When the font in use is selected again, default value(s) are restored.
Examples: "\27t9", "\27t\009"

6.2.3 Voiding string selection

 Select voiding string "VOID"


[Esc] [46]
The string "VOID" is repeatedly printed on the document when it is discarded (code-
line band is cut and document is sent to the collection bin).
Examples: "\27\046", "\27."

 Select voiding string "ANNULLATO"


[Esc] [48]
Similar to the one described above.
Examples: \27\048", "\0270"

 Select voiding string "CANCELLED"


[Esc] [50]
Similar to the one described above.
Examples: "\27\050", "\0272"

 Select voiding string "NULL"


[Esc] [52]
Similar to the one described above.
Examples: "\27\052", "\0274"
CBDSMEN0022 Date March 05, 2018
SOFTWARE REFERENCE Release N. 2
MANUAL Page 57 of 65

6.2.4 Miscellaneous commands

 Select print mode #2


[Esc] P
Print mode #2 is strongly recommended for new installations. Refer to section 5.1 for
details.
Example: "\27P"

 Copy character no 27 to print buffer


[Esc] [Esc]
Since character no 27 is the escape itself, a special sequence is needed when character
27 must be interpreted literally or the immediately following character would be
considered an op-code.
Example: "\27\027"

 Clear print buffer


[Esc] [16]
Print buffer is cleared. Print buffer pointer is not moved.
Example: "\27\016"

 Select needle impact strength


[Esc] # [n]
[n] is a digit in the range from '0' to '3'.
This command sets the energy which the needles have when the print ribbon is struck.
Printer default value is 2.
Impact force should be increased to 3 only if printed text appears light. It should be
decreased only if dots sharpness is insufficient due to ink spread or if print-heads
overheat.
Example: "\27#0"

6.2.5 Graphic images definition

 Define an image up to 100 mm (938 dot columns) wide


[Esc] X [b] [nh] [nl] [i]
[b] is a capital letter in the range from 'A' to 'D' indicating the buffer where the image
is to be stored.
[nh] is a 1-byte binary value which is the most significant byte of the 2-bytes count of
dot columns in the image.
[nl] is a 1-byte binary value which is the least significant byte of the 2-bytes count of
dot columns in the image.
CBDSMEN0022 Date March 05, 2018
SOFTWARE REFERENCE Release N. 2
MANUAL Page 58 of 65

[i] is a byte stream defining the image. It is a stream of 3 X (256 X Count_High +


Count_Low) bytes.
The byte stream which defines the bit pattern is considered to be made of triplets of
bytes. Each triplet represents a column of dots (there are 24 needles in each print-
head). The stream depicts the image from left to right, i.e. triplets transmitted first
define the left part of the image.
Numbering dots from 1 (for the top needle) to 24 (for the bottom needle), encoding is
as follows:
- Byte 1 (the first transmitted) represents dot 8 (in the most significant bit) to dot 1
(in the least significant bit)
- Byte 2 represents dot 16 (m.s.b.) to 9 (l.s.b.)
- Byte 3 (the last in each triplet) represents dots 24 (m.s.b.) to 17 (l.s.b.)
Bits which are set to one produce marked dots, bits set to zero produce blank dots.
Vertical spacing between dots is 0.352 mm ( 0.0139" ) for "draft" print-heads (24
needles on one column) and 0.14 mm ( 0.0056" ) for NLQ print-heads (24 needles,
staggered columns).
Column spacing is 0.10668 mm ( 0.0042" ) for both print-heads. Since printers cannot
fire the same needle on adjacent columns, the minimum distance between consecutive
marked dots is twice the value above.
Thus, dot position accuracy is 0.10668 mm ( 0.0042" ), while image resolution is
0.21336 mm ( 0.0084" ).
Needles diameter is 0.30 mm ( 0.012" ) for draft printers and 0.25 mm ( 0.010" ) for
NLQ printers. So, even if image resolution is half the position accuracy, adjacent dots
will overlap regardless of the inked ribbon used.
If the same dot is programmed to be marked on immediately subsequent columns, the
printer will automatically clear the bit that comes second at print time (i.e. the dot on
the left, since printing proceeds from right to left in the CBD 1000HT).
Example: "\27XA\2\88\255\255\255\0\0\0\254\255\255....."
--- (1800 bytes total) ---

 Define an image up to 50 mm (469 dot columns) wide


[Esc] Y [b] [nh] [nl] [i]
[b] is a capital letter in the range from 'A' to 'G' indicating the buffer where the image
is to be stored.
[nh] and [nl] are 1-byte binary values whose meanings are the same as in the
command described above.
[i] is a byte stream defining the image. Its format is the same as in the previous
command.
Operation also is identical.
Example: "\27YA\1\44\255\255\255\0\0\0\254\255\255....." ( 900 bytes total)
CBDSMEN0022 Date March 05, 2018
SOFTWARE REFERENCE Release N. 2
MANUAL Page 59 of 65

 Copy an image up to 100 mm (938 dot columns) wide to print buffer


[Esc] x [b]
[b] is a capital letter in the range from 'A' to 'D' indicating the buffer where the image
has been stored.
The contents of the selected image buffer are transferred to the print buffer starting
from the current print buffer pointer position.
Print buffer pointer is then moved to the right of the last transferred column.
If the image does not fit in the print buffer then automatic clipping occurs and the
pointer is set to the end of the buffer.
Example: "\27xA"

 Copy an image up to 50 mm (469 dot columns) wide to print buffer


[Esc] y [b]
[b] is a capital letter in the range from 'A' to 'G' indicating the buffer where the image
has been stored.
Operation is identical to that of the previous command.
Example: "\27yA"

6.2.6 Ram font downloading

 Define RAM font


[Esc] F [s1] [s2]
[s1] and [s2] are one-byte binary values.
Parameter range is in both cases 0 to 15 but any printable character whose lower four
bits correspond to the given value can be used (i.e. only the lower four bit of the
received characters are considered by the printer).
RAM fonts can contain both small characters (capable of two rows printing) and full-
height characters at the same time.
Parameter [s1] specifies default spacing for small characters, parameter [s2] specifies
default spacing for full height characters. When the RAM font is selected, two default
spacing are in effect at the same time. The first or the latter is used, depending on the
size of the character copied to the print buffer.
When a RAM font is defined, a fixed-size structure is built in memory, preparing the
device for individual characters loading.
The memory allocation/deallocation process has been described in paragraph 4.4. For
convenience, table 1 reports the already discussed memory limits.
Examples: "\27F46","\27F\4\006"
CBDSMEN0022 Date March 05, 2018
SOFTWARE REFERENCE Release N. 2
MANUAL Page 60 of 65

 Define full-size character


[Esc] W [c] [n] [i]
[c] is a single character (either printable or not printable). It must be the same character
to which the definition refers. It is worth to recall that in case of CBD 1000HT
instruction syntax conflict, the character must be sent as a backslash-decimal value
sequence. Of course, this option is always allowed.
[n] is a one-byte binary value corresponding to the number of columns of which the
character is made.
[i] is a byte stream defining character image. Its format is the same as in graphic
images definition.
Character definition must be preceded by font definition or the command will have no
effect.
Example: "\27Wi\4\140\255\7\0\0\0\140\255\7\0\0\0"

 Define small character


[Esc] w [c] [n] [i]
[c], [n] and [i] have identical meaning as in the previous command.
Bit-patterns defining small-size characters depict two identical images, one above the
other. Each image makes use of 12 needles.
When a small-size character is defined the (double) image is stored with an attribute
that signals that the character in question contains two shapes. When the character
image is copied to the print buffer, only the upper or the lower 12 bits are transferred,
depending on whether upper or lower row printing is selected.
Fig. 1 depicts how bit patterns for small-size characters are made.
Example: "\27wi\4\244\67\63\0\0\0\244\67\63\0\0\0"

FIG. 1 SMALL - SIZE CHARACTERS PATTERN DEFINITION


CBDSMEN0022 Date March 05, 2018
SOFTWARE REFERENCE Release N. 2
MANUAL Page 61 of 65

--------------------------------------------------------------------------------------------------------------------
TABLE 1 MEMORY ALLOCATION AS A FUNCTION OF COLUMNS IN THE RAM FONT
--------------------------------------------------------------------------------------------------------------------
100mm buffer 'D' is allocated when the font is defined
100mm buffer 'C' is allocated when the 683rd column is defined
100mm buffer 'B' is allocated when the 1621st column is defined
100mm buffer 'A' is allocated when the 2559th column is defined
50mm buffer 'G' is allocated when the 3497th column is defined
50mm buffer 'F' is allocated when the 3966th column is defined
50mm buffer 'E' is allocated when the 4435th column is defined
50mm buffer 'D' is allocated when the 4904th column is defined
50mm buffer 'C' is allocated when the 5373rd column is defined
50mm buffer 'B' is allocated when the 5842nd column is defined
50mm buffer 'A' is allocated when the 6311th column is defined

MAX SIZE OF RAM FONT: 6779 columns


-----------------------------------------------------------------------------------------------------------------------

6.2.7 Strings definition and recall

 Define string
[Esc] S [i] [c] [Esc] [0]
[i] is a capital letter (all 26 are allowed) which identifies the string being defined.
[c] is a character sequence representing commands and/or literal text.
The character sequence can contain any escape sequence except reference to other
strings. Maximum length is 64 characters.
When escape sequences are included in strings each character (be it the "Escape"
character or a parameter) counts exactly for one, regardless the number of characters
used to encode it in the CBD 1000HT instruction field dedicated to the text.
Thus, as an instance, the sequences:
\27N\50BANKNAME
and
\027N\050BANKNAME
which move the print pointer to a position which is 50 mm from the left margin and
then print the text "BANKNAME", both take 11 bytes (8 for the text plus 3 for the
escape sequence) of string space.
The maximum number of different strings that can be defined at a time is limited only
by the range of parameter [i]. It is therefore 26.
Example: "\27SB\27N\50Bank Name\27\000"
CBDSMEN0022 Date March 05, 2018
SOFTWARE REFERENCE Release N. 2
MANUAL Page 62 of 65

 Expand string
[Esc] s [i]
[i] is a capital letter which identifies the string that must be expanded.
When such an escape sequence is issued the string is expanded, i.e. an image of the
stored text is copied to the print buffer and any escape sequence (other than further
references to strings) is executed.
In other words, when a string is expanded, its contents are processed as they were
directly input to the printer. So, strings can end with the beginning of a new escape
sequence, provided that the escape sequence is properly concluded later.
Example: "\27sB"
CBDSMEN0022 Date March 05, 2018
SOFTWARE REFERENCE Release N. 2
MANUAL Page 63 of 65

7. APPENDIX A - CODE LINE ENCODER

Code line encoder may be equipped with one of three fonts, CMC7, E13B or OCRB
(Eurobanking). Character set is font dependent. Valid characters for MICR codes are:

 For E13B, digits and small letters a, t, d, o


 For CMC7, digits and capital letters A,B,C,D,E

CBD 1000HT makes no check on the validity of characters sent to the encoder, since
allowed set may change in other versions. The programmer must be aware that issuing
characters not in the list above may result in equipment lock or, in the worst case, font head
motor overheating.
Following drawings show, for each of the non numeric characters, the corresponding
graphic sign.
CBDSMEN0022 Date March 05, 2018
SOFTWARE REFERENCE Release N. 2
MANUAL Page 64 of 65

8. APPENDIX B - PROGRAMMING HINTS

1. GENERAL NOTES ON CBD 1000HT


While programming CBD 1000HT for a specific job, the programmer must keep in mind
how the equipment works, both from the mechanical and logical angle.
CBD 1000HT is a highly specialized equipment. It has been designed for the production of
a well defined item.
Firmware has been designed in sight of a typical application, taking care, in the
meanwhile, of good flexibility, which should make the equipment suitable for any possible
application.

2. DOCUMENTS PRODUCTION SEQUENCE


The first two things the programmer should bear in mind are the document stacking
method and the orientation documents assume before staples are applied.
From these, it follows that book production proceeds backwards, starting, in a typical
application, with last cover and ending with front cover.

3. RECOVERIES
Another, very important, general feature the programmer should always take into
consideration, is how the system for recovering from production exceptions works.
These exceptions have four possible causes: double feed, wrong type sheet feed,
unreadable code-line and paper/book jam.
As one of the first three exceptions occurs, the document involved is discarded and sent to
the reject collection bin. Any immediately following document is also discarded, since it
would, if stackered with other documents, be out of sequence. Document production is then
halted, with the unit waiting for an order to resume operation.
Then, host computer may consent resuming operation (with order '@R') or it may reset the
decoder and clear the list of processes waiting for recovering by issuing order '@C'.
In the first case operation will be resumed with the proper document sequence.
In the second case, host computer must instruct the operator to clear the unit of all
documents already produced, or issue the reject command (opcode 'R').
Recovery from jam is similar to the above, except that the operator must be instructed to
clear paper path of all halted documents.
CBDSMEN0022 Date March 05, 2018
SOFTWARE REFERENCE Release N. 2
MANUAL Page 65 of 65

4. USER SETTABLE CONFIGURATION


CBD 1000HT must be initialised by user with document length and height.
Double detector parameter must be set as well as any other user-settable parameter (like
options of operation).
Once this data has been set, it is retained by the unit in permanent memory.

5. FACTORY SET CONFIGURATION


Host computer should monitor CBD 1000HT and check for the absence of 'T' flag in status
message.
If 'T' flag appears, field service should be contacted for factory set up parameters
restoration.
User-settable data must loaded again.

You might also like