So I am writing a program in Java that does amplitude demodulation. I am reading in a sine wave value by value and determining whether I have a '1' or a '0'. For now I am saving them as chars, but am open to suggestions. I know the number of samples per bit, so determining the bit is not an issue.
I can't figure out a way to convert every set of 8 bits in to a byte, so I can then decode the final array of bytes using UTF-8. Is there an effective way of doing that?