Epson TM-DT Series User Manual

Epson TM-DT Series User Manual

Server direct print

Advertisement

Quick Links

Server Direct Print
User's Manual
Overview
Describes the operating environment and system
configuration of Server Direct Print.
Sample Program
Describes how to use the sample program and how to
configure the system.
Request and Response
Describes the requests and responses of Server Direct
Print.
Status Notification
Describes the Status Notification function.
M00062909
Rev.J

Advertisement

Table of Contents
loading

Summary of Contents for Epson TM-DT Series

  • Page 1 Server Direct Print User’s Manual Overview Describes the operating environment and system configuration of Server Direct Print. Sample Program Describes how to use the sample program and how to configure the system. Request and Response Describes the requests and responses of Server Direct Print.
  • Page 2 • Neither is any liability assumed for damages resulting from the use of the information contained herein. • Neither Seiko Epson Corporation nor its affiliates shall be liable to the purchaser of this product or third parties for damages, losses, costs, or expenses incurred by the purchaser or third parties as a result of: accident, misuse, or abuse of this product or unauthorized modifications, repairs, or alterations to this product, or (excluding the U.S.) failure to strictly comply with Seiko Epson Corporation’s operating and...
  • Page 3: For Safety

    For Safety Key to Symbols The symbols in this manual are identified by their level of importance, as defined below. Read the following carefully before handling the product. Provides information that must be observed to avoid damage to your equipment or a malfunction.
  • Page 4: About This Manual

    This manual presents information that is necessary information for using the TM-Intelligent. The TM-Intelligent series in this manual is a generic term for the TM-DT series, TM-i series, and TM-T88VI. The TM-DT series in this manual is a generic term for the following printers.
  • Page 5: Table Of Contents

    Contents ■ For Safety ..........................3 Key to Symbols ............................3 ■ Restriction of Use ........................3 ■ About this Manual ........................ 4 Aim of the Manual ..........................4 Manual Content ............................ 4 ■ Contents..........................5 Overview ..................7 ■ Overview of Server Direct Print ................... 7 Printing Process............................
  • Page 6 Request and Response ............... 37 ■ Request (Print Request)...................... 37 ■ Response (Print request)....................38 Format of the response message .......................39 Response When No Printing Is Performed..................46 ■ Request (Printing Result) ....................47 Format of the request message ......................47 ■ Response (Printing Result) ....................54 ■...
  • Page 7: Overview

    It also allows you to control display of a Customer Display connected to the printer. *2 : For TM-i Firmware Ver.4.1 or later of the TM-i series. For TM-DT Software Ver.3.0 or later of the TM-DT series. : Only for TM-T88VI.
  • Page 8 Difference from General Printing System In general printing systems, the application sends a print instruction to the printer. With Server Direct Print, the printer sends an Inquiry of print request to the Web application, and the Web application returns a response that has print data included in it. Server Direct Print General Printing Computer...
  • Page 9: Printing Process

    : If the spooler is enabled in the TM intelligent printer, a request (print result) is returned upon receipt of a response (print request). (For TM-i Firmware Ver.4.1 or later of the TM-i series. For TM-DT Software Ver.3.0 or later of the TM-DT series. For TM-T88VI)
  • Page 10: Response Data

    <PrintRequestInfo> tag version. There is no compatibility between versions. Check the printer before use. TM Intelligent Printer Function Respons <PrintRequestInfo> Customer Print job eFile Tag Version TM-i series TM-DT series TM-T88VI display Notificat control <PrintRequestInfo Version="1.00"> Unavaila Unavailabl Unavaila All version...
  • Page 11: Overview Of Status Notification

    Chapter 1 Overview Overview of Status Notification Status Notification is the function used to periodically notify the printer status to the Web server. The web server registers status from TM intelligent printer to database, then responds with an empty response to TM intelligent printer.
  • Page 12: Operating Environment

    Operating Environment TM Intelligent Printer The TM Intelligent Printers that allow you to use Server Direct Print are listed below. TM Intelligent Printer Software TM-H6000IV-DT TM-DT series TM-T70II-DT TM-DT software Ver.2.2 or later TM-T88V-DT TM-L90-i TM-i firmware Ver.3.0 or later TM-T20II-i TM-i firmware Ver.4.3 or later...
  • Page 13: How To Access The Web Server

    Chapter 1 Overview How to Access the Web server How to access TM-DT series TM-i series TM-T88VI TM-DT software TM-i firmware Proxy server All firmware version Ver.3.0 or later Ver.4.0 or later TM-DT software TM-i firmware Proxy authentication All firmware version Ver.3.0 or later...
  • Page 14: Contents In The Package

    For the utility to register the NV logo to a printer other than the TM intelligent printer, refer to the Technical Reference Guide for each printer. Download For customers in North America, go to the following web site: http://www.epson.com/support/ and follow the on-screen instructions. For customers in other countries, go to the following web site: https://download.epson-biz.com/?service=pos...
  • Page 15: Restriction

    If you are using a TM-i series (TM-i firmware Version 3.0 or later), TM-DT series (TM-DT software Version 2.2 or later) and TM-T88VI, if you designate forced transmission mode with ePOS-Print XML, it will operate offline.
  • Page 17: Sample Program

    Chapter 2 Sample Program Sample Program This chapter describes how to use the sample program for Server Direct Print. • In this chapter, a system configuration using a Web server is explained as an example. • In this chapter, the Web server is described as a Web server configured with IIS (Microsoft Internet Information Services)....
  • Page 18 Version 2.00 Specification of Version 2.00 is available in the TM-i Firmware Ver.4.1 or later/TM-DT Software Ver.3.0 or later/ TM-T88VI.
  • Page 19 Chapter 2 Sample Program Version 3.00 Specification of Version 3.00 is available in only TM-T88VI.
  • Page 20: Hardware Configuration (For Ver.1.00 Or Ver.2.00)

    Hardware Configuration (For Ver.1.00 or Ver.2.00) The system configuration of the sample program is as shown below. Web Server [192.168.192.10] TM Intelligent Printer (TM-T88V-i) [192.168.192.20] Router [192.168.192.1] TM Printer [192.168.192.21] ❏ Web Server (Its operation has already been checked using IIS and XAMPP .) ❏...
  • Page 21: Hardware Configuration (For Version 3.00)

    Chapter 2 Sample Program Hardware Configuration (For Version 3.00) The system configuration of the sample program is as shown below. Web Server [192.168.192.10] TM Intelligent Printer (TM-T88VI) [192.168.192.20] Customer Display Router [192.168.192.1] ❏ Web Server (Its operation has already been checked using IIS and XAMPP .) ❏...
  • Page 22: Printing Result

    Printing Result Cooking Slip Delivery Slip Program Flow The flow from the initial display to the print completion of the sample program is as shown below. 1. Start the browser. 2. Enter the order. 3. Receive a request from the printer. 4.
  • Page 23: Environment Settings

    3. TM Printer Network Settings Configure the network settings such as IP address to the TM printer to be connected. Configure the network settings such as IP address to the printer by using EPSON TMNet WebConfig from a Web browser on the setup computer.
  • Page 24  IP Address Setting  Server Direct Print Setting  (Including Server authentication setting and Proxy server setting)  Register the TM Printers (Device ID, IP Address) ❏ TM-DT series  IP Address Setting  Initial OS Settings  Initializing the ePOS-Device ...
  • Page 25: Sample Program Configuration

    Chapter 2 Sample Program Sample Program Configuration Save the sample program files to the Web server. Save the files directly under the following folders: Environment Folder Saved File inetpub\wwwroot Test_print.php demo\index.html XAMPP xampp\htdocs \sample.xml (Expansion of epsonsample_eposprint.zip) For details about how to create a zip file, refer to the Technical Reference Guide for each printer.
  • Page 26: Tm Intelligent Printer Settings

    29 Server Direct Print Settings Configure the Server Direct Print settings by using EPSON TMNet WebConfig. For TM-i Firmware Ver.4.0 or later, configure the server authentication and the proxy server settings when necessary. For TM-i Firmware Ver.3.x or earlier, the server authentication and proxy server setting are unavailable.
  • Page 27 Chapter 2 Sample Program The “Server Direct Print Setting” screen appears. Set the following items and click [Submit] / [Apply]. For TM-i Firmware Ver.4.0 or later Item Description Server Direct Print Select the [Enable]. Set ID for the server-side program to identify TM-i series. This ID becomes the user ID used for Digest access authentication.
  • Page 28 When using the proxy server, select [System Settings] - [Proxy]. The “Proxy” screen appears. Set the following items, then click [Apply]. Item Description Enter the proxy server URL and port number in the following: Proxy URL and Port Number "http://host name: port number". Example: http://10.0.0.1:8008 Registers the proxy authentication ID.
  • Page 29 Chapter 2 Sample Program Registration of TM Printer Register the device ID and IP address of the controlled TM printer to TM-i series. Use EPSON TMNet WebConfig to register the device ID. • TM-i printer cannot be deleted from the device.
  • Page 30 Start EPSON TMNet WebConfig from the shortcut on the desktop. EPSON TMNet WebConfig starts. If you are making settings from an external device, set the TM-DT series IP address in the address for the Web browser. The default IP address for TM-DT series is 192.168.192.168.
  • Page 31 For TM-DT Software Ver.3.0 or later: Item Description Set ID for the server-side program to identify TM-DT series. This ID becomes the user ID used for Digest access authentication. The set value will also be passed as an ID parameter value for the form data posted to the server.
  • Page 32 Registration of TM Printer Register the device ID and IP address of the controlled TM printer to TM-DT series. Use EPSON TMNet WebConfig to register the device ID. This printer is already registered with the "local_printer" device ID, and therefore this setting is not required.
  • Page 33 Chapter 2 Sample Program TM-T88VI Settings Configure the following settings to TM-T88VI. ❏ IP Address Settings : Refer to the Technical Reference Guide for each printer. ❏ Server Direct Print Settings p. 33  Server authentication setting  Proxy server setting ❏...
  • Page 34 Item Description Specifies whether to enable or disable the server authentication. Server Authentication Register certificates in advance. Not required for the sample program. When using the proxy server, click the [TM-Intelligent] - [Proxy]. The “Proxy” screen appears. Set the following items, then click [Set]. Item Description Proxy...
  • Page 35 Chapter 2 Sample Program Registration of TM Printer Register the device ID and the IP address of the TM printer to be controlled. Use the following procedure for registration. Connect the Customer Display to TM-T88VI. Connect all TM printers to the network and power on. Starting the TM-T88VI Utility.
  • Page 36: Execution Of Sample Program

    Execution of Sample Program When using the TM-DT series or TM-i series, confirm that Server Direct Print is enabled in EPSON TMNet WebConfig. When using TM-T88VI, confirm that Server Direct Print is enabled in TM-T88VI Utility. Open the sample program page from the Web browser.
  • Page 37: Request And Response

    Chapter 3 Request and Response Request and Response This chapter describes requests from the TM intelligent printer and responses from the Web server. User's application can start printing by returning a response containing print data to a HTTP POST request (print request) from the printer.
  • Page 38: Response (Print Request)

    Response (Print request) This section describes the response (print request) containing the print data from the Web server. Web Server TM Intelligent Printer 1 : HTTP Request (Print request) 2.1 : Create XML from a database or other system 2.2 : HTTP Response (Print request) Response data created in XML(text/xml) from the application is returned.
  • Page 39: Format Of The Response Message

    Chapter 3 Request and Response Format of the response message Basic Structure The structure is different depending on the <PrintRequestInfo> version. <PrintRequestInfo Version="1.00"> When no version for the <PrintRequestInfo> tag is specified, the same structure as with <PrintRequestInfo Version="1.00"> is applied. Create the <ePOSPrint>...
  • Page 40 <PrintRequestInfo Version="2.00"> You can specify the print job ID with the TM-i series TM-i firmware Ver. 4.1 and later, TM-DT series TM-DT software Ver. 3.0 and later, and TM-T88VI. Specify the print job ID with the <printjobid> tag in the <Parameter> tab.
  • Page 41 Chapter 3 Request and Response <PrintRequestInfo Version="3.00"> Available with TM-T88VI. Printing to the printer and control of customer display can be performed. ❏ <ePOSPrint> tag: Printer control ❏ <ePOSDisplay> tag: Customer display control The <ePOSPrint>/<ePOSDisplay> tag consists of the following tags: ❏...
  • Page 42 </Parameter> <PrintRequestInfo Version="2.00">/<PrintRequestInfo Version="3.00"> You can specify the print job ID with the TM-i series TM-i firmware Ver. 4.1 and later, TM-DT series TM-DT software Ver. 3.0 and later, and TM-T88VI. If specifying a print job ID, specify the print job ID in the <printjobid> tag of the <Parameter> tag.
  • Page 43 <?xml version="1.0" encoding="utf-8" ?> <PrintRequestInfo> <ePOSPrint> <Parameter> <devid>local_printer</devid> <timeout>10000</timeout> </Parameter> <PrintData> <epos-print xmlns="http://www.epson-pos.com/schemas/2011/03/epos-print"> <text lang="en" /> <text smooth="true" /> <text align="center" /> <text font="font_b" /> <text width="2" height="2" /> <text reverse="false" ul="false" em="true" color="color_1" /> <text>DELIVERY TICKET</text> <feed unit="12" />...
  • Page 44 <?xml version="1.0" encoding="utf-8" ?> <PrintRequestInfo Version="2.00"> <ePOSPrint> <Parameter> <devid>local_printer</devid> <timeout>10000</timeout> <printjobid>ABC123</printjobid> </Parameter> <PrintData> <epos-print xmlns="http://www.epson-pos.com/schemas/2011/03/epos-print"> <text lang="en" /> <text smooth="true" /> <text align="center" /> <text font="font_b" /> <text width="2" height="2" /> <text reverse="false" ul="false" em="true" color="color_1" /> <text>DELIVERY TICKET</text> <feed unit="12" />...
  • Page 45 Content-Type: text/xml; charset=utf-8 Content-Length: xxx <?xml version="1.0" encoding="utf-8"?> <PrintRequestInfo Version="3.00"> <ePOSPrint> <Parameter> <devid>local_printer</devid> <timeout>10000</timeout> <printjobid>ABC123</printjobid> </Parameter> <PrintData> <epos-print xmlns="http://www.epson-pos.com/schemas/2011/03/epos-print"> <text lang="en"/> <text smooth="true"/> <text align="center"/> <text font="font_b"/> <text width="2" height="2"/> <text reverse="false" ul="false" em="true" color="color_1"/> <text>DELIVERY TICKET&#10;</text> <feed unit="12"/> <text>&#10;</text> <text align="left"/>...
  • Page 46: Response When No Printing Is Performed

    Response When No Printing Is Performed When no printing is required, to notify no print data, the following response is returned for a HTTP request (print request) sent from the TM intelligent printer. See Test_print.php of the sample program. HTTP/1.1 200 OK Content-Type: text/xml;...
  • Page 47: Request (Printing Result)

    Chapter 3 Request and Response Request (Printing Result) TM intelligent printer sends a HTTP POST request (printing result) shown below after printing. TM Intelligent Printer Web Server 1 : HTTP Request (Print request) 2.1 : Create XML from a database or other system 2.2 : HTTP Response (Print request) 3 : Create print data 4 : Print...
  • Page 48 When no version for the <PrintRequestInfo> tag is specified, the same structure as with  <PrintRequestInfo Version="1.00"> is applied. <?xml version="1.0" encoding="utf-8"?> <PrintResponseInfo Version="1.00"> #Success <response xmlns="http://www.epson-pos.com/schemas/2011/03/epos-print"  <response> tag success="true" code="" status="251854870" battery="0"/> </PrintResponseInfo> <PrintRequestInfo Version="2.00"> The <ePOSPrint> tag is created in the <PrintResponse> tag, and the <Parameter> tag and <PrintResponse>...
  • Page 49 <PrintResponseInfo Version="3.00"> <ServerDirectPrint> <Response> tag <Response Success="true"/> </ServerDirectPrint> <ePOSPrint> tag <ePOSPrint> <Parameter> <devid>local_printer</devid> <printjobid>ABC123</printjobid> </Parameter> <PrintResponse> tag <PrintResponse> <response xmlns="http://www.epson-pos.com/schemas/2011/03/epos-print"  <response> tag success="true" code="" status="251658262" battery="0"/> </PrintResponse> </ePOSPrint> <ePOSDisplay> <Parameter> <devid>local_display</devid> <printjobid>ABC456</printjobid> </Parameter> <DisplayResponse> tag <DisplayResponse> <response xmlns="http://www.epson-pos.com/schemas/2012/09/ <response> tag epos-display"...
  • Page 50 On failure, an error code is described in code element. For details, see "Error code" (p.52). ❏ <PrintRequestInfo Version="1.00"> Example of a success <PrintResponseInfo Version="1.00"> <response xmlns="http://www.epson-pos.com/schemas/2011/03/epos-print" success="true"  code="" status="251854870" battery="0"/> </PrintResponseInfo> ❏ <PrintRequestInfo Version="1.00"> Example of a failure <PrintResponseInfo Version="1.00"> <response xmlns="http://www.epson-pos.com/schemas/2011/03/epos-print" success="false"...
  • Page 51 <?xml version="1.0" encoding="utf-8"?> <PrintResponseInfo Version="2.00"> <ePOSPrint> <Parameter> <devid>local_printer</devid> <printjobid>ABC123</printjobid> </Parameter> <PrintResponse> <response xmlns="http://www.epson-pos.com/schemas/2011/03/epos-print" success="false"  code="EX_BADPORT" status="1" battery="0"/> </PrintResponseInfo> </ePOSPrint> <PrintResponseInfo> ❏ <PrintRequestInfo Version="3.00"> In the following example, printer printing was successful but customer display control failed. <?xml version="1.0" encoding="UTF-8"?>...
  • Page 52 Error code Request Error This occurs when the device has a problem. The following table shows errors that can occur. Code Message Cause An automatically recoverable error Continuous printing of high-density EPTR_AUTOMATICAL occurred. printing EPTR_BATTERY_LOW No remaining battery. No battery EPTR_COVER_OPEN The device has a problem.
  • Page 53 Chapter 3 Request and Response ResponseFile If the XML structure obtained from the server is incorrect, an error notification is sent to the server with SetResponse. (TM-T88VI only) Error Description Details of ResponseFile in SetResponse The XML obtained with GetRequest <?xml version="1.0"...
  • Page 54: Response (Printing Result)

    Response (Printing Result) The Web server sends a response (print result) upon receipt of print result to the TM intelligent printer. TM Intelligent Printer Web Server 1 : HTTP Request (Print request) 2.1 : Create XML from a database or other system 2.2 : HTTP Response (Print request) 3 : Create print data 4 : Print...
  • Page 55: Digest Access Authentication

    Digest access authentication requires settings for the TM intelligence printer and the server. TM Intelligent Printer Use EPSON TMNet WebConfig of TM-i series/TM-DT series to set your user ID and password required for Digest access authentication. For details, see "Server Direct Print Settings" for individual TM intelligent printers.
  • Page 56: Program Example

    Program Example See the following programming data (file name: Test_print.php) <?php header('Content-Type: text/xml; charset=UTF-8'); define("REQUEST_XML_PATH", "demo/request/sample.xml"); define("RESPONSE_XML_PATH", "demo/response/sample.xml"); if (isset($_POST["ConnectionType"])) { $http_request = $_POST["ConnectionType"]; if ($http_request == 'GetRequest') { # send print data # ID $shop_id = $_POST["ID"]; # create print data if (file_exists(REQUEST_XML_PATH)) { # return print data $handle = fopen(REQUEST_XML_PATH, "r");...
  • Page 57: Status Notification

    1 : HTTP Request (Status Information) 2 : Register the status to the database 2.1 : HTTP Response (Status Information) For TM-DT series, enable the following settings in EPSON TMNet WebConfig. • ePOS-Device • Service startup settings • Device control •...
  • Page 58: Overview Of Status Notification Sample Program

    • "TM-DT Series Settings" (p.60) TM-i Series Settings Configure the Status Notification settings using EPSON TMNet WebConfig. Use the following procedure for registration. Connect the printer to the network and turn the power ON. Start the Web browser on the setup computer and enter as follows: For TM-i Firmware Ver.4.0 or later...
  • Page 59 Chapter 4 Status Notification The "Status Notification" / "Status Notification Settings" screen appears. Set the following items and click [Apply] / [Submit]. For TM-i Firmware Ver.4.0 or later Item Description Status Notification Select the [Enable]. Set ID for the server-side program to identify TM-i series. This ID becomes the user ID used for Digest access authentication.
  • Page 60 Start EPSON TMNet WebConfig from the shortcut on the desktop. EPSON TMNet WebConfig starts. If you are making settings from an external device, set the TM-DT series IP address in the address for the Web browser. The default IP address for TM-DT series is 192.168.192.168.
  • Page 61 For TM-DT Software Ver.2.6 or earlier Item Description Set ID for the server-side program to identify TM-DT series. This ID becomes the user ID used for Digest access authentication. The set value will also be passed as an ID parameter value for the form data posted to the server.
  • Page 62 TM-T88VI Settings Configure the Status Notification settings using TM-T88VI Utility. Starting the TM-T88VI Utility. After TM-T88VI Utility starts, click [TM-Intelligent] - [Status Notification]. The Server Status Notification appears. Set the following items and click [Set]. Item Description Status Notification Specifies whether to enable or disable the status notification. Notification Specifies the Web server URL and the application path.
  • Page 63 Chapter 4 Status Notification When using the proxy server, click the [TM-Intelligent] - [Proxy]. The “Proxy” screen appears. Set the following items, then click [Set]. Item Description Proxy Specifies whether to enable or disable the proxy. Enter the proxy server URL. Enter the authentication ID.
  • Page 64: Execution Of Sample Program

    Execution of Sample Program Confirm that Status Notification of TM intelligent printer is set. Open the sample program page from the Web browser. Example: http://[IP address of the Web Server]/demo/indexStatus.html The “resultPrint.log” is created from the message from the TM intelligent printer and the result is displayed on the screen.
  • Page 65: Status Type

    Chapter 4 Status Notification Status Type The following types of ASB (AutoStatusBack) status can be obtained from the TM-i series. Code Description 0x00000004 Status of the drawer kick number 3 connector pin = "H" Offline due to a weak battery (supported model only) 0x00000008 Offline status 0x00000020...
  • Page 66 Program Example Refer to the programming below. (File name: Test_status.php) <?php header('Content-Type: text/xml; charset=UTF-8'); # Open the file to save status. $fhandle = @fopen("ResultStatus.log", "wt"); # Update the printer status. if (isset($_POST["Status"])) { $status = $_POST["Status"]; $xml = simplexml_load_string($status); foreach ($xml->printerstatus as $printerstatus) { $asb = hexdec($printerstatus['asbstatus']);...
  • Page 67 Chapter 4 Status Notification if (($asb & 0x00080000) == 0x00080000) $strmsg .= " No paper in the roll paper end detector \n"; if (($asb & 0x01000000) == 0x01000000) $strmsg .= " Buzzer activated (supported model only) \n"; if (($asb & 0x01000000) == 0x01000000) $strmsg .= "...
  • Page 68: Request And Response

    Request and Response Request The format of request message is URL-encoded form data (application/x-www-form-urlencoded). Parameter Value ConnectionType Status The ID set with WebConfig ResponseFile Status Information POST /demo/Test_status.php HTTP/1.1 Host: 192.168.192.10 Content-Type: application/x-www-form-urlencoded Content-Length: xxx ConnectionType=SetStatus&ID=&Status=Status Information The status information configuration is as follows: <?xml version="1.0"...
  • Page 69 Chapter 4 Status Notification Server Access Error Notification With TM-T88VI, a notification can be sent for errors that occur when the server is accessed. Code Description %Function% Server Direct Print Server Direct Print Web Contents Updater Web Contents Updater Network Network Status Notification Status Notification...
  • Page 70 Code Description No Last-Modified No Last-Modified information in a header. information in a header. Insufficient Disk Space to Not enough ROM space to download the web contents download. Failed to download Failed to download contents. contents. Insufficient Disk Space to Not enough ROM space to expand the web contents extract.
  • Page 71: Response

    Chapter 4 Status Notification Response The format of response message is XML(text/xml). To indicate that the server received the status notification, the Web server returns a response as follows: HTTP/1.1 200 OK Content-Type: text/xml; charset=utf-8 Content-Length: 0 Digest Access Authentication Digest access authentication can be used for the status notification.

Table of Contents