WIP selectBitrate

This is work-in-progress. The constants will likely need to be changed.

What is the maximum size of the buffer?