How should the FMAC of STM32G474 be configured to obtain correct calculation data?
Hi,
I encountered problems during the development process of using FMAC. To illustrate the problem simply, I used FMAC to implement an RC filter, by which I mean to illustrate the calculation problems of FMAC.
RC filter:10K+10nF

Its discrete z-domain expression:(Ts=1e-6,Tustin)

so I get fixed-point parameters :

I referred to the example program of AN5305 and used a 1-us timer to trigger ADC sampling. After the ADC sampling is completed, DMA writes to the WriteData of FMAC, and then the ReadData is processed in the interrupt as follows:





As shown above, my current ADC sample is 0, and my Vref is set to 800. I think the output of FMAC as an RC filter should be around 800 in the DC case, but actually it is not. It is a relatively small value. Why is that?


May I ask if there is a problem with my configuration of FMAC?
