Cannot the DMA controller of the codec chip return the current status (and the sample number) on request?
What I would like to have:
What about logging also the type of the gain change manual / AGC and the AGC type / preset?
1) no: at best it could be checked every transferred chunk but this would make it quite complex because you can't do much in the dma handler. so it would set a flag, wait for the dma handler to report the number of samples and then continue writing the log file....
2) no: the type of change would have to be passed through all layers, and I wouldn't know why you'd want to know it anyway.
I'm open to discussion, however