I'm writing an iOS application which needs to print using a Boca thermal printer. They use a proprietary language (FGL) to layout contents with commands in form of ASCII strings. I already enabled AirPrint for the Boca printer by using the AirPrint activator tool which can be downloaded for free.
My problem is that using UIPrintInteractionController
, all I can do is send either already formatted text (the BOCA will then not recognize the FGL commands, printing them as if they were normal text) or NSData
which needs to have a PDF header (which my data doesn't have, so I can't print this way).
Is there any way to bypass this framework and send raw ASCII data to the printer? Should I be using NSStream
s and manage the print job in a low level way?
In that case, is there any way to obtain the printer's address on the network so I can establish a socket connection to it?