Drawer Kick Connector
|
Most cash drawers are attached to a receipt
printer through what looks to be a phone jack. To open the cash
drawer the POS software must send "control codes" to your
printer which will then send an impulse to the cash drawer to
pop it open. You can use escape sequences to tell an Epson
printer to open a cash drawer. The following details the correct
codes and sequence you need to open the drawer or sound an
alarm.
Also see
how to open a cash drawer using the Epson driver for Windows
Requirements:
- A cash drawer connected to an Epson POS printer
through the drawer port (see diagram)
|
|

Drawer Connection Port on an Epson TM-U220 Printer |
Epson provides a Drawer Kick ( DK ) connector on the TM printer
line that allows the programmer to control up to two cash
drawers. The DK connector on the back of the printer looks like a phone
jack (see the green arrow, above). The DK connector supplies +24VDC to the drawer solenoid(s)
[Pin4] and then returns this signal to ground [Pin5 or Pin2] when the
printer receives the appropriate control command.
The connector also has
provision for the connection of a drawer position switch. This switch,
in conjunction with the Automatic Status Back command or similar, can
inform the application
of drawer position.
|

|
Controlling the Cash drawer
ESC POS Control
The Epson ESC POS Drawer Kick command enables the
control of either 1 or 2 Cash drawers
ESC p m t1
t2
Where
is the
drawer kick command
m is
the DK connector pin to output control signals ( 0 for
Pin2/drawer1 or 1 for Pin5/drawer2 )
t1 is
the ON time of the drawer kick signal. The ON time is
2 mS x t1
value.
t2 is
the OFF time of the drawer kick signal ( time before the next ON
signal can be received ) The OFF time is
2 mS x t2
value.
|

|
Programming Examples
ESC p m t1
t2
Decimal Example
MSComm1.Output = ESC + p +
0 + 25 + 250
MSComm1.Output =
Chr(27) + Chr(112) + Chr(0) + Chr(25) + Chr(250)
Kick drawer 1 with the following 50mS on / 500mS off
pulse
Hexadecimal Example
MSComm1.Output = Chr(&H1B) + Chr(&H70) + Chr(&H0) +
Chr$(&H19) + Chr$(&HFA)
Kick drawer 1 with the same 50mS on / 500mS off pulse
|

Decimal Example

Hexadecimal Example |
Windows Drivers
Epson supplies a Windows driver for the current range of
TM Series printers. Programmers can also use the Generic / Text Only
driver to control the cash drawer.
Epson Windows Driver
Epson has provided a ‘ control’
font in the Windows driver that sends the appropriate command to the
printer when triggered by certain control characters. The control
characters listed on the right are provided for cash drawer control.
Programming Examples
cash drawer 1 Kick
Printer.FontName = “control”
Printer.FontSize = 10
Printer.Print “A”
cash drawer 2 Kick
Printer.FontName = “control”
Printer.FontSize = 10
Printer.Print “a”
|
Control-Font Character Code
|
Function
|
Extended character code
(on
all fonts other than those marked "Ext.")
|
A
|
Open
Drawer 1 (50ms drive pulse width)
|
81H
|
B
|
Open
Drawer 1 (100ms drive pulse width)
|
82H
|
C
|
Open
Drawer 1 (150ms drive pulse width)
|
83H
|
D
|
Open
Drawer 1 (200ms drive pulse width)
|
84H
|
E
|
Open
Drawer 1 (250ms drive pulse width)
|
85H
|
a
|
Open
Drawer 2 (50ms drive pulse width)
|
89H
|
b
|
Open
Drawer 2 (100ms drive pulse width)
|
8AH
|
c
|
Open
Drawer 2 (150ms drive pulse width)
|
8BH
|
d
|
Open
Drawer 2 (200ms drive pulse width)
|
8CH
|
e
|
Open
Drawer 2 (200ms drive pulse width)
|
8DH
|
|
|
Epson Printer Control Font
The Epson printer control font is normally installed
along with the Epson printer driver. This control font gives you the
ability to embed control characters directly in a document.
If the Epson TM Series print driver is installed
as the Default Windows print driver additional fonts will appear in the
dropdown font combo box in Windows programs such as WordPad and Word.
In this font list there will be a number of Epson internal printer fonts
added. These fonts allow printing of internal font characters that speed
up printing of receipts to the maximum allowable speed. They also allow
selection of the control font. Using this font and the special printer
control characters listed previously we can easily control the printer
operation.
To kick cash drawer 1, we would only need to set the
font to control in WordPad, Word, Access or any other Window based
program that allows font selection, type the desired control character,
and print the data. The Epson print driver would see the control font
character and then send the required ESC POS command to the printer. See
the programming examples, above, on how to do this.
Also see how to
open a cash drawer using the Epson driver for Windows
|

Codabar - Epson Internal Barcode Font
c ontrol
- Epson printer control font
|
Entering Printer Control Commands
To enter printer control commands into the Generic/Text
Only driver you will need to access the correct ASCII characters via the
computer’s keyboard. To achieve this you hold down the
ALT key, then enter the desired ASCII
characters decimal equivalent on the numeric keypad, then release the
ALT key.
Example
Use Windows notebook for these examples
To obtain the ASCII character ‘ p’
we need to refer to the ASCII Character Code table. In this table we can
see the decimal equivalent of ASCII ‘p’
is 112. To enter this
character we do the following;
-
Press and hold the
ALT key
Press and release
1 on the numeric keypad, then
press and release 1 again,
then press and release 2.
Release the
ALT key
The ASCII character ‘ p’
should now appear.
To obtain the Æ
character
-
Press and hold the
ALT key
Press and release
1 on the numeric keypad, then
press and release 4, then
press and release 6.
Release the
ALT key
The ASCII character ‘ Æ’
should now appear.
Generic Driver Device Options Example
To enter the cash drawer command,
ESC p m t1 t2, we would have entered
the following data in the Device Options ‘End print job’ box
-
Press and release the
ESC key
Press and hold the
ALT key
Press and release
1 on the numeric keypad, then
press and release 1, then
press and release 2.
Release the
ALT key
Press and hold the
ALT key
Press and release
4 on the numeric keypad then
press and release 8.
Release the
ALT key
Enter { character twice
<ESC> p0{{ should now be showing in the Device
Options ‘End print job’ box;
This will cause the Generic/Text Only print driver to
output the Epson cash drawer command,
ESC p m t1 t2, after it has finished printing.
|
 |
Epson OPOS Drivers
Epson supplies an OPOS driver (Service Object) for a
Standard cash drawer.
In the cash drawer Device Specific Settings area in OPOS
you can set the values for m
(cash drawer Selection) and t1, t2
(ON / OFF time).
|
|