Select your printer model

Parameters are refined by the selected printer.

<type>print</type>


Sends print data and configuration data to the printer and requests it for printing. The request result is acquired by the <type>onxmlresult</type> element.

Request

Child element

Data type

Description

timeout

int

Specifies the timeout for the request in milliseconds.

Value: 1000 to 300000 (integer)

printjobid

string

Specifies the print job ID (optional).

printdata

string

Specifies data to print.

Print data size

The following lists the maximum sizes of the print data that can be sent at one shot.

When sending print data whose size exceeds the limit, separate the data.

  • TM-m30: 2MB
  • TM-DT Series/TM-i Series:
  • Version

    Printing Speed

    TM-DT Software

    TM-i Firmware

    300 mm/s

    200 mm/s

    2.5 or earlier

    4.0 or earlier

    200 KB

    133 KB

    -

    4.1

    400 KB

    267 KB

    3.0 or later

    4.3 or later

    4 MB

    2.67 MB

Sample program

  • Request A: Does not specify the print job ID.
  •  
    <data>
    	<type>print</type>
    	<timeout>10000</timeout>
    	<printdata>
    		<!-- Printer Control XML -->
    		<epos-print xmlns=
    				.
    				.
    		</epos-print>
    	</printdata>
    </data>
    
  • Request B: Specifies the print job ID.
  •  
    <device_data>
    	<device_id>local_printer</device_id>
    		<data>
    			<type>print</type>
    			<timeout>60000</timeout>
    			<printjobid>ABC123</printjobid>
    			<printdata>
    				<epos-print xmlns="http://www.epson-pos.com/schemas/2011/03/epos-print">
    					<text>Hello, World!&#10;</text>
    					<cut />
    			</epos-print>
    		</printdata>
    	</data>
    </device_data>
    
  • Request C: Acquires the print result when the spooler function is enabled.
  •  
    <device_data>
    	<device_id>local_printer</device_id>
    	<data>
    		<type>print</type>
    		<printjobid>123</printjobid>
    		<timeout>60000</timeout>
    		<printdata>
    			<epos-print xmlns="http://www.epson-pos.com/schemas/2011/03/epos-print"/>
    		</printdata>
    	</data>
    </device_data>
    

Supplementary explanation

  • The print job ID can be specified using alphanumeric characters, underscore, hyphen, and period in 1 to 30 digits.
  • Refer to PrinterControl XML for details of print data specified in the printdata child element.
  • Blank print data needs to be sent to acquire the print result while the spooler function is enabled.
    Therefore, the child element of the <epos-print> element is not specified.
 

Quick Access

  • [Name]
  • [Format]
  • [Range]
  • [Description]
  • [Notes]

ePOS-Device XML includes patented or patent pending functions. The contents must not be disclosed to third parties.


ePOS-Device XML

Jump to the top