Working Playback and Gain Code

This code is up to date as of 4/10/14. The code is able to convert the
inout byte array to a float array of samples, apply a gain to the
signal, and play it back.

Note that the rxBuf0 has the format [lsb_lch[0] ; msb_lch[0] ; zero ;
zero ; lsb_rch[0] ; msb_rch [0] ; zero ; zero ; lsb_lch[0] ; msb_lch[0]
; zero ; zero ; ……..]

Therefore, the number of samples in the buffer is actually
NUM_SAMPLES_PER_AUDIO_BUF / 2 because of the zeros in-between each lch
and rch value.

Also note: the unsigned integers for in which the data is stored (two
bytes) are actually read as twos compliment values…. i.e..
1111111111111110 is actually the value -1. 1111111111111100 would be
read as -3.

The shifting of these values is taken care of in the ByteBuftoFloatBuf
function. So the InputDataBuffer is an array of floats that ranges from
2^15 to (- 2^15). One must make sure the data doesn't fall outside this
range, else the data will be clipped.