code: function arrayBufferToBinaryString(buffer) {
    var binary = '';
    var bytes = new Uint8Array(buffer);
    var length = bytes.byteLength;
    for (var i = 0; i < length; i++) {
      binary += String.fromCharCode(bytes[i]);
    }
    return binary;
  }
docs: Can't find original post, but this is close http://stackoverflow.com/questions/6965107/ (continues on next line) converting-between-strings-and-arraybuffers