Have a look at this:
http://www.asciitable.com/[
^]
It is literally a case of casting the number as a character (or better an unsigned byte) and inserting it in the output stream.
#define AS_SOH ((unsigned byte) 0x01)
Bytes are generally better for this as there is no chance of a Unicode to ASCII conversion going on that you don't know about.