Recently studied thermal printer printing two-dimensional code, using the northern OPOs two times development package DLL, draw on this code: HTTP://WWW.CNBLOGS.COM/DATACOOL/ARCHIVE/2012/11/27/2014666.HTML  Here's a way to print a picture of the extension
<summary>///print Pictures///</summary>//<param name= "BMP" ></param> public void Printbmp (BITM
AP bmp) {byte[] data = new byte[] {0x1B, 0x33, 0x00}; Pos_writefile (Pos_intptr, data, (UINT) data.
Length);
Data[0] = (byte) ' x00 ';
DATA[1] = (byte) ' x00 '; DATA[2] = (byte) ' x00 ';
Clear to Zero.
Color Pixelcolor;
ESC * M NL NH d1...dk Select bitmap Mode//ESC * M NL nH byte[] escbmp = new byte[] {0x1B, 0x2A, 0x00, 0x00, 0x00};
ESCBMP[2] = (byte) ' x21 '; NL, NH escbmp[3] = (byte) (BMP.
Width% 256); ESCBMP[4] = (byte) (BMP.
WIDTH/256); Cycle picture pixel print picture//loop high for (int i = 0; i < BMP. HEIGHT/24 + 1); i++) {//Set mode for bitmap mode Pos_writefile (Pos_intptr, Escbmp, (UINT) escbmp.length);//loop width for (int j = 0; J < BMP. Width; J + +) {for (int k = 0; k < k++) {if (((i *) + K) < BMP. Height)//If within the BMP size {pixelcolor = bmp.
GetPixel (J, (I *) + K);
if (PIXELCOLOR.R = = 0) {DATA[K/8] + = (byte) (>> (k% 8));}} }//write one data,24 at a timePixel Pos_writefile (pos_intptr, data, (UINT) data.
Length);
Data[0] = (byte) ' x00 ';
DATA[1] = (byte) ' x00 '; DATA[2] = (byte) ' x00 ';
Clear to Zero.
}//newline, print second line byte[] data2 = {0xA}; Pos_writefile (Pos_intptr, data2, (UINT) data2.
Length);
}//Data byte[] data3 = {0xA, 0xA}; Pos_writefile (Pos_intptr, data3, (UINT) data3. Length);