2013-08-08 03:46 PM
Here's the situation - I'm transferring some data from I2S to a buffer in memory via DMA. The DMA is set up to be double buffered - I'll skip all the initialization code but here are what the DMA registers look like just before I enable the stream:
LISR: 0x00000000HISR: 0x00000000LIFCR: 0x00000000HIFCR: 0x00000000CR: 0x00062D5ENDTR: 0x00000200PAR: 0x4000380CM0AR: 0x20001A84M1AR: 0x20001E84FCR: 0x000000A0The I2S is setup for 48kHz and I have 2 int16_t buffers of 512 samples each. So, I would expect that I get an interrupt every 256/Fs = 5ms telling me a buffer has finished playing. Two questions:1) Which interrupts should I be looking for (HT or TC or both)?2) Regardless of the type I seem to only get interrupts every 10ms - any ideas why? The weird part is that I also seem to get the HT and TC flags set on the same interrupt (instead of offset 5ms as I'd expect).2013-08-12 10:13 AM
This is solved - I was losing interrupts due to some higher priority interrupts firing.