3 ms·
I dug into the PDF above and and it looks like it's mostly due to the underlying codec. They use MPEG-1 Audio Layer II, which has a frame size of 1152 samples.
by mikeash 9y ago
I dug into the PDF above and and it looks like it's mostly due to the underlying codec. They use MPEG-1 Audio Layer II, which has a frame size of 1152 samples. They support 24kHz or 48kHz sample rates, which means that a 1152 sample frame is either 48ms or 24ms. Apparently they stuff 2 or 4 of these audio frames into each transmission frame.
- rlpb 9y agoThat just punts the question. Why does the codec have a frame size of 1152 samples? Is it because that brings the frame size to sums of powers of two milliseconds? :)
- mikeash 9y agoDamn, I was hoping nobody would notice that. I mean, good point. I dug a bit farther and found this document which discusses the design in some detail: https://web.archive.org/web/20040919073530/http://www.cs.columbia.edu/~coms6181/slides/6R/mpegaud.pdf https://web.archive.org/web/20040919073530/http://www.cs.col... It looks like MP1 has 32 subbands and works on 12 samples each, which results in a frame size of 384. MP2 works on 3 groups of 12 samples for each subband, resulting in 1152 samples. Of course this just punts it to the question of why 32, 12, and 3? To which I can only answer: quick, look behind you! <runs away> At least the mystery numbers are smaller. But seriously, I'm at (beyond) the limits of my understanding of this stuff, so if anyone with more knowledge would care to chime in and explain those, I'd be most interested to know.