Need help with specific I2C DMA setup on STM32U5
Hello,
I am trying to implement the following: a timer (tim3) is set to PWM generation, outputting a pulse periodically. Its TRGO triggers the DMA channel to request I2C to initiate a read transaction, read 8 bytes and generate an event interrupt (TC probably) to process these data bytes. On the next PWM pulse the next 8 bytes should be read. Data should be put to a circular buffer (ideally 8 bytes long, so that data is just overwritten into the same memory buffer. Cycle should continue indefinitely.
I feel like this scenario should be implementable, however I don't seem to grasp how to set it up correctly. I have the timer generating pulses correctly, but no tinkering with GPDMA and I2C settings yields a working procedure, at best I manage to make I2C to trigger, but only read 2 bytes once and then not reacting to consecutive pulses. I don't ask to do my job for me, but at least could you confirm that it is doable and outline the correct way to set it up? Thx.
Here is how everything is set up now (pics attached) and how I start the cycle in the code:
