Error Handling - Epson TM-T88V-i User Manual

Epos-print api
Hide thumbs Also See for TM-T88V-i:
Table of Contents

Advertisement

Error handling

Refer to the following program for the error handling method by a callback function.
//Create an ePOS-Print object
var epos = new epson.ePOSPrint(address);
// Set a response receipt callback function
epos.onreceive = function (res) {
// Obtain the print result and error code
var msg = 'Print' + (res.success ? 'Success' : 'Failure') + '\
// Obtain the printer status
var asb = res.status;
if (asb & epos.ASB_NO_RESPONSE) {
}
if (asb & epos.ASB_PRINT_SUCCESS) {
}
if (asb & epos.ASB_DRAWER_KICK) {
}
if (asb & epos.ASB_OFF_LINE) {
}
if (asb & epos.ASB_COVER_OPEN) {
}
if (asb & epos.ASB_PAPER_FEED) {
}
if (asb & epos.ASB_WAIT_ON_LINE) {
}
if (asb & epos.ASB_PANEL_SWITCH) {
}
if (asb & epos.ASB_MECHANICAL_ERR) {
}
if (asb & epos.ASB_AUTOCUTTER_ERR) {
}
if (asb & epos.ASB_UNRECOVER_ERR) {
}
if (asb & epos.ASB_AUTORECOVER_ERR) {
}
if (asb & epos.ASB_RECEIPT_NEAR_END) {
}
if (asb & epos.ASB_RECEIPT_END) {
}
if (asb & epos.ASB_BUZZER) {
}
if (asb & epos.ASB_SPOOLER_IS_STOPPED) {
}
//Display in the dialog box
alert(msg);
}
50
msg += ' No printer response\n';
msg += ' Print complete\n';
msg += ' Status of the drawer kick number 3 connector pin = "H"\n';
msg += ' Offline status\n';
msg += ' Cover is open\n';
msg += ' Paper feed switch is feeding paper\n';
msg += ' Waiting for online recovery\n';
msg += ' Panel switch is ON\n';
msg += ' Mechanical error generated\n';
msg += ' Auto cutter error generated\n';
msg += ' Unrecoverable error generated\n';
msg += ' Auto recovery error generated\n';
msg += ' No paper in the roll paper near end detector\n';
msg += ' No paper in the roll paper end detector\n';
msg += ' Sounding the buzzer (limited model)\n';
msg += ' Stop the spooler\n';
' + res.code 
nCode:
+ '\
\n';
nStatus:

Hide quick links:

Advertisement

Table of Contents
loading

This manual is also suitable for:

Tm-t70-iTm-l90-i

Table of Contents