Hello,
maybe I completely misunderstood what you are doing. But here are my thoughts about it:
man echo will tell you that the numbers in \0xxx are the octal equivalent of the characters to be echoed. This way often is choosen when the characters cannot be typed in easily.
man ascii will tell you what these characters actually are, e.g. you will see that 033 is the escape character, aka Esc. And a sequence of characters beginning with an escape is called an escape sequence. As you probably know, they are used to change the behaviour of hardware like printers and terminals. HP's Printer Control Language PCL is in essence made up from quite a lot of them.
Then I suppose the $spoolfile in your script is the PCL file you are talking about.
And your $TTY seems to be a serial port, aka tty, on your Unix box. I suppose the printer is connected to it. I can't see how Windows and Telnet come in though.
So you send your PCL file to your printer, enclosed between two additional escape sequences.
This may well work, as long as your file is in a version of PCL that your printer is able to understand.
Now you introduced a Windows bitmap into the PCL file. (How did you do that, btw?)
We may assume that in this bitmap file there are all kinds of bytes, including quite a number of Esc, and therefore there will be a lot of randomly choosen escape sequences. Some of them have no meaning, and so will cause an error, if anything at all. But others will randomly change your printer settings.
Anything else but a complete havoc would be a huge surprise.
You cannot print a bitmap that way, imho.
May I ask why you are trying to reinvent the wheel?
Why don't you use the Unix or Windows spool system?
hope this helps a bit.