Apparently the error was just a logic error on my part.
To send things in binary, I had written a Message object that used bit shifting and integer addition to fill the Uint8Array. When I wrote my reset function, I only reset the position variable and not the array values under the assumption that its functions would just overwrite the array properly.
However, since adding new values to the array used addition (array[0] += newvalue) rather than sets (array[0] = newvalue), any new data was getting corrupted by the old values.
I feel kinda dumb right now.
Dhruv Chopra and Kanaka's comments helped point me in the right direction. I tested using a 10 second interval setTimeout function and it still was giving me wrong values, which led me to realize that it was just a stupid mistake of mine. I'd like to give credit to them but I'm unaware as to how.
Still, thanks a lot for the help! I appreciate it.
EDIT: Apparently I can only answer my own question after 8 hours. I will do so tomorrow to avoid confusion.
EDIT 2: Apparently I can upvote comments now. Thanks again.