![Epson C31C514452 Technical Reference Manual Download Page 93](http://html.mh-extra.com/html/epson/c31c514452/c31c514452_technical-reference-manual_108845093.webp)
Rev. H
Application Development Information
5-5
TM-U220 Technical Reference Guide
5.2.1.2 Checking Drawer Status
You can get drawer status by using Status API. Below is examples of program which checks the
drawer status.
There are the other checking method (Bi BiSetStatusBackFunction, BiSetStatusBackWnd) in
Status API. Refer to the Status API User’s Manual and the sample programs for detail.
5.2.2 OPOS
Programming examples of how to use API function relating to a Cash Drawer are shown below.
5.2.2.1 Drawer Open/Close
Using the OpenDrawer method opens the cash drawer. The DrawerOpened property can be
used to check the current state of the drawer. To pause the program until the drawer is closed,
the WaitForDrawerClose method is used.
Below is as example of a program to open and close a cash drawer.
5.2.2.2 Checking Drawer Status
There are methods other than explained in section 5.2.2.1 that can be used to check drawer
status. A StatusUpdateEvent is fired whenever the drawer is opened or closed.
'get the current printer status
rtn = BiGetStatus(m_hApi, getstatus)
If rtn < 0 Then
ErrMsg (rtn) ’Error handling
Exit Sub
End If
If (getstatus And ASB_DRAWER_KICK) = ASB_DRAWER_KICK Then
MsgBox("Drawer is opened") ’Pin No.3 is high
Else
MsgBox("Drawer is closed")
End If
If Not OPOSCashdrawer1.DrawerOpened Then
OPOSCashdrawer1.OpenDrawer
OPOSCashdrawer1.WaitForDrawerClose 10000, 1000, 100, 100
End If
Summary of Contents for C31C514452
Page 1: ...TM U220 Technical Reference guide EPSON English Rev H 404455408 ...
Page 8: ...vii Rev H ...
Page 14: ...xiii Rev H ...
Page 30: ...1 16 General Information Rev H 1 7 1 2 Overview Type B ...
Page 31: ...Rev H General Information 1 17 TM U220 Technical Reference Guide 1 7 1 3 Overview Type D ...
Page 32: ...1 18 General Information Rev H ...
Page 80: ...3 38 Setup Rev H ...
Page 100: ...5 12 Application Development Information Rev H ...
Page 128: ...B 10 How to Install the Printer on a Wall with the WH 10 Rev H B 2 2 TM U220 Type D 5 14 146 ...
Page 130: ...C 2 Character Code Table Rev H C 2 Page 1 Katakana ...
Page 132: ...C 4 Character Code Table Rev H C 4 Page 3 PC860 Portuguese ...
Page 134: ...C 6 Character Code Table Rev H C 6 Page 5 PC865 Nordic ...
Page 138: ...C 10 Character Code Table Rev H C 10 Page 16 WPC1252 ...
Page 140: ...C 12 Character Code Table Rev H C 12 Page 18 PC852 Latin2 ...
Page 141: ...Rev H Character Code Table C 13 TM U220 Technical Reference Guide C 13 Page 19 PC858 Euro ...
Page 149: ...Rev H Character Code Table C 21 TM U220 Technical Reference Guide C 21 Page 254 Blank page ...
Page 150: ...C 22 Character Code Table Rev H C 22 Page 255 Blank page ...
Page 152: ...C 24 Character Code Table Rev H ...