Since the total amount of profile data is not necessary a multiple of
the maximum packet size, the code may attempt to read outside the
ringbuffer area in some cases. Because the device supports a variable
packet size, the problem can simply be avoided by adjusting the packet
size.
As a side effect of this fix, the code will now also detect when the
profile ringbuffer is filling up faster than the logbook ringbuffer, and
the progress events are improved as well.