have new encoding scheme mostly worked out, but there is a bug causing
the insufficient bytes to be read from the RAF