Hola, aunque Delphi no es lo mío, a ver si te funciona así:
Código Delphi
[-]function Write_RAW_StringToPrinter(PrinterName:String; comando:AnsiString): Boolean;
var
PrinterHandle: THandle;
N: DWORD;
DocInfo1: TDocInfo1;
begin
Result := False;
if not WinApi.WinSpool.OpenPrinter(PChar(PrinterName), PrinterHandle, nil)
then raise exception.create(PrinterName+#13+'OpenPrinter error ' + IntToStr(GetLastError));
with DocInfo1 do
begin
pDocName := PChar('Keuken Doc');
pOutputFile := nil;
pDataType := 'RAW';
end;
if StartDocPrinter(PrinterHandle, 1, @DocInfo1) <> 0 then
begin
StartPagePrinter(PrinterHandle) ;
WritePrinter(PrinterHandle, PAnsiChar(comando), Length(comando), N);
EndPagePrinter(PrinterHandle);
EndDocPrinter(PrinterHandle);
ClosePrinter(PrinterHandle);
Result := True;
end;
end;