This seems important. At the very least, this first octect representing octet count is missing from the raw conversion.
But also "application-defined format" leaves it open to interpretation. I'd look for an open-source implementation that is known to work and see if you can mimic the same data format. But start by prepending the octet count in your testing.
I wonder if @jvm33 can offer any pointers on this data format.
