Epson Esc Pos抽屉踢命令启用1或2现金抽屉的控制
ESC P M T1 T2
我们想使用WebClientPrint API打开现金抽屉webclientprint.azurewebsites.net
问题:打印机在打印文本文件时正常工作。但是,当我们给出0x0A0x1B0x700x000x190xfa0x0a此命令到打印机现金抽屉不开放。
然后,我使用另一种方法ESC/POS来提供打印机。
[AllowAnonymous]
public void PrintCommands(string useDefaultPrinter, string printerName)
{
ClientPrintJob cpj = new ClientPrintJob();
cpj.BinaryPrinterCommands= System.IO.File.ReadAllBytes(Server.MapPath(@"~/App_Data/open.txt"));
cpj.FormatHexValues = true;
cpj.ClientPrinter = new DefaultPrinter();
System.Web.HttpContext.Current.Response.ContentType = "application/octet-stream";
System.Web.HttpContext.Current.Response.BinaryWrite(cpj.GetContent());
System.Web.HttpContext.Current.Response.End();
}
您是否尝试过将T1设置为更大的值(现在您有0x19,是25 x 2 msec)?