CashDrawer API: Difference between revisions
No edit summary |
|||
Line 6: | Line 6: | ||
This operation should be used before other operations. | This operation should be used before other operations. | ||
{| | {|class="wizarpostable" | ||
|- | |- | ||
! scope="row" colspan="2 | ! scope="row" colspan="2"| Returns | ||
|- | |- | ||
| | | int || The result code, >= 0, success; <0 [[Error_code|error code]]. | ||
|} | |} | ||
Line 18: | Line 18: | ||
The open and close apis are pair operations. If you don’t want to use this device, you should call the close api to release this device. | The open and close apis are pair operations. If you don’t want to use this device, you should call the close api to release this device. | ||
{| | {|class="wizarpostable" | ||
|- | |- | ||
! scope="row" colspan="2 | ! scope="row" colspan="2" | Returns | ||
|- | |- | ||
| | | int || The result code, >= 0, success; <0 [[Error_code|error code]]. | ||
|} | |} | ||
Line 29: | Line 29: | ||
Kick out the cash drawer. | Kick out the cash drawer. | ||
{| | {|class="wizarpostable" | ||
|- | |- | ||
! scope="row" colspan="2 | ! scope="row" colspan="2" | Returns | ||
|- | |- | ||
| style="text-align:left;background-color: #edf1f2; " width="100"| '''int''' || style="text-align:left;background-color: #f8f9fa;| The result code, >= 0, success; <0 [[Error_code|error code]]. | | style="text-align:left;background-color: #edf1f2; " width="100"| '''int''' || style="text-align:left;background-color: #f8f9fa;| The result code, >= 0, success; <0 [[Error_code|error code]]. | ||
Line 40: | Line 40: | ||
Enable or disable hardware | Enable or disable hardware | ||
{| | {|class="wizarpostable" | ||
|- | |- | ||
! scope="row" colspan="2 | ! scope="row" colspan="2" | Parameters | ||
|- | |- | ||
| nEnable || '''unsigned int:''' 1 - enable, 0 - disable. | |||
|} | |} | ||
{| | |||
{|class="wizarpostable" | |||
|- | |- | ||
! scope="row" colspan="2 | ! scope="row" colspan="2" | Returns | ||
|- | |- | ||
| | | int || The result code, >= 0, success; <0 [[Error_code|error code]]. | ||
|} | |} |
Revision as of 01:45, 2 May 2018
Interface Overview
The calling sequence is open>kick_out>close
open
int moneybox_open()
Open the cash drawer device. This operation should be used before other operations.
Returns | |
---|---|
int | The result code, >= 0, success; <0 error code. |
close
int moneybox_close()
Close the cash drawer device. The open and close apis are pair operations. If you don’t want to use this device, you should call the close api to release this device.
Returns | |
---|---|
int | The result code, >= 0, success; <0 error code. |
kick_out
int moneybox_ctrl()
Kick out the cash drawer.
Returns | |
---|---|
int | The result code, >= 0, success; <0 error code. |
setEnable
int moneybox_setEnable(unsigned int nEnable)
Enable or disable hardware
Parameters | |
---|---|
nEnable | unsigned int: 1 - enable, 0 - disable. |
Returns | |
---|---|
int | The result code, >= 0, success; <0 error code. |