How i can transsmit order with uart?

hello every one
i have a thermal printer with cutter for paper
i use it for printing text en barcode and other thing
now i use it on one project and i don't find any information for do ordering it to cut paper when is end
this printer is work with UART interface with bauderate (4800) mark masung Inc
on arduino ide if we use e.g ;

Serial.print(0x1B,0x69); 

or something else with print is just print it on the paper not other thing do
what exactly the command necessary for do order with UART interface not just send text

on the document technic i find those line

2.7.1 Transmit command (sending )
[interface]
int PrintTransmit(const char* bCmd,int iLength)
[function]
Transmit original command to printer
[parameter]
name
type
parameter description
bCmd
char*
command
iLength
int
command length
[return value]
0 success
1 failure
[sample]
char bCmd[2]={0x1B,0x69}; //cutting command
int r = PrintTransmit(bCmd,2);

and the complet document for this printer is :
MASUNG printers SDK reference manual-V2.2.pdf (750.7 KB)

Take a look at Serial.write()

1 Like

More like

Serial.print("\x1B\x69"); 
1 Like

all file included on the folder for this priner is her ;

Windows DLL V2.2.2.5.zip (3.4 MB)

its also like print

Please post an example that shows it is the same

that is text the printer just write that on printer

its same for the printer its write on the paper not applicant the order

The SDK reference manual seems to detail the high level function calls that you woukd use on Win or Linux. You need the document that details the low level instructions that the printer understands.

You may be lucky in that the seller has rebadged another manufacturers printer. You would probably need to look for some identifying model number on one of the internal boards.

I'm unclear whether that is a statement or question.

It's not clear from the document whether the PrintTransmit function applies additional bytes to the command or not. You could be missing an escape sequence.

No.

Predict what this will print, then try it:

void setup() {
Serial.begin(115200);
while(!Serial);
Serial.print("\x43\x45");
}

void loop() {
}
1 Like
Mechanism:	MS628MCL101
Printing method	Thermal dot line printing
Dots/line	384 dots/line
Dot pitch	8 dot/mm
Paper width	58 mm
Printing width	48 mm
Paper thickness	54~78 um
Printing speed	100 mm/s
Paper feed direction	180° horizontal
Sensors	Head temperature	Thermistor
Paper press shaft	Mechanical switch
Paper end	Photo interrupter
Paper loading	Easy loading
Font size	ASCII:9*17;12*24;
Chinese: 24*24
Power supply	Logic circuit	2.6~3.6 V
Motor	4.75 ~9.5 V
Dimension  (L*W*H)	 180.7*102*101.5 mm (with 80mm diameter paper roll)
Weight	 Approx 0.45 kg
Reliability	Circuit: over 1,000,000,000 pulses
Cutter: over 7,000,000 cuts
Thermal head: over 100 km
MCBF: 37,000,000 lines
Ambient environment	Work temperature	0 ℃~50℃
Work humidity	20~85% RH
Storage temperature	-20℃~60℃
Storage humidity	10~90% RH
Weight	450 g
Interface	   RS-232/TTL/USB
power supply	DC 12~24V/2.5A
Command set	ESC/POS
Barcode	supported
Firmware location	2 M  NV Flash memory
Buffer	4 KB
SRAM	20 KB
System	Windows/Android/Linux
Accessories:	paper near end sensor;
Paper holding unit;
Paper bezel (paper guide mouth)
Interface connector
Power supply unit
Cable 

its clear that line ( RS-232 / TTL / USB ) for TTL
i dont know what meaning this secret about those type of product i dont find any other information about this printer
his sitweb is

A shot in the dark, but have a look at:
https://escpos.readthedocs.io/en/latest/home.html
It's not your printer model but I suspect that they all share a fairly common set of commands.

If you look in the Print Movement section you will see the command for Partial Cut, which is 0x1B 0x69. The same as mentioned in your post #1.

I'm guessing that you would simply code something like:

Serial.write( 0x1B );
Serial.write( 0x69 );

According @farai

I am not inclined to believe it, but he/she has not provided any proof

1 Like

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.