2021-08-03 09:24 AM
Hello, I want to connect the op-amp built into the microcontroller directly to the ADC input in a non-inverting mode, without outputting the negative input (VINM0) outside, but I cannot find this configuration in CubeIDE.
For some reason, in the mode I need, a negative input is also displayed. It is written that it is for filtering, but it is completely incomprehensible to me what is meant, despite the fact that VOPAMP_OUT does not come out on the pin.
2021-08-03 10:34 AM
Which version of CubeIDE? What about "Follower Internally Connected" mode? Or do you need the PGA function? You can always edit/override the code that CubeMX generates and write to the OPAMP config reg directly to force the mode you need.
2021-08-03 12:49 PM
CubeIDE 1.7.0
Yes, I need the PGA mode.
Yes, I understand that it is possible to override the state of the configuration registers manually, but I want to understand why this simple mode is not already included in CubeIDE and what the phrase "for filtering" means in the pop-up tooltip.
2021-08-06 10:39 AM
The "for filtering" means that, with the output and negative input signals brought out to pins, you can add an external capacitor for filtering (i.e. low-pass filter). This is shown in figure 174 of rev 6 of RM0440 (STM32G4xx reference manual).
2021-08-08 11:28 AM
Thank you for your answer. I understood that I mean an external capacitor, it's just that this description about filtering is in the mode where the output signal is not output to the external pin. In general, I think this is a purely CubeIDE problem, not a microcontroller in general.
I found some typical configuration solutions in STM Motor SDK for G431CBU.
Thanks again for your help.