2024-04-03 6:51 AM
I have a project which uses both OPAMPs. For both OA I use dedicated VINM pin.
OPAMP1 works correctly.
OPAMP2 behaves like the dedicated pin (M2 ball) is not connected to the input multiplexer.
I 've tried
- mode FOLLOWER: OK
- mode STANDALONE, reconnected the signal on the board and used PA7 for VINM: OK
- mode STANDALONE, using the dedicated pin: the output is saturated at VDDA.
Checked the PCB connection, OK. Checked on 3 boards, identical results.
Is it possible it is really a bug in the silicon? What else should I check?
(I would like to use OPAMP tag, but it is not available :( )
Initialization code:
(GPIO to analog)
LL_APB3_GRP1_EnableClock(LL_APB3_GRP1_PERIPH_OPAMP);
LL_OPAMP_InitTypeDef OPAMP_Init;
OPAMP_Init.PowerMode = LL_OPAMP_POWERMODE_NORMALPOWER_NORMALSPEED;
OPAMP_Init.FunctionalMode = LL_OPAMP_MODE_STANDALONE;
OPAMP_Init.InputNonInverting = LL_OPAMP_INPUT_NONINVERT_IO0;
OPAMP_Init.InputInverting = LL_OPAMP_INPUT_INVERT_IO1;
LL_OPAMP_Init(OPAMP2, &OPAMP_Init);
LL_OPAMP_Enable(OPAMP2);
2025-09-03 1:20 AM - edited 2025-09-03 1:23 AM
Mads,
Here I am not talking about merits/demerits of using libraries for normal firmware, but about producing a minimal, easily and surely reproducible example exhibiting he problem, for purposes of problem analysis.
But whatever; the key point is in providing a minimal but complete compilable example exhibiting the problem, together with concise description of used hardware (e.g. VDDA voltages may matter very much in this case). With libraries or without them. Even better in this case would be *both* source and binary.
> first step is for ST to acknowledge that there is a problem
Witnessed by Amel's posts above, they did acknowledge that, and performed an experiment at their side, concluding that there is no problem.
However, we don't know, what experiment did they perform, under what circumstances, etc. Would they publish a reproducible example code as I've wrote above, together with what was the hardware used - unfortunately in this case a standard Nucleo is not an option - you and Tomas could then try to reproduce that code at their side, and would that result in working case, you/he could then investigate and try to find differences between working and non-working cases. And the same applies to you and Tomas, would you/he provide that minimal but complete code/binary, then you could mutually verify your findings and potentially come to some conclusions.
That's because the details usually do matter.
JW
[EDIT]
> Main coincidence is the matching date and revision code
Any photo?
2025-09-03 1:38 AM
Hi @mads_nielsen ,
Thanks for coming back to this discussion (while we generally prefer to start a new one).
In your case, are you using exactly the same product/package as Tomas?
As you are suspecting a quality issue, again I'll point to a FAE as we cannot handle FAR in the public community. It will be required to get the failing devices and make tests with them.
Thanks for your understanding. I'll try to follow on my side in case you submit a request on OLS.
-Amel
To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.
2025-09-03 7:26 AM
Hi @Amel NASRI
We have done some more testing at our end.
Dedicated VINM for OPAMP2 works, when PA7 is set to analog mode (reset state). When PA7 is set to input mode, general purpose output mode or alternate function mode, dedicated WINM for OPAMP2 stops functioning as an input to the opamp. This is our issue since, we use PA7 as an alternate function pin (PCB revision is initiated).
Maybe this is intended behaviour, but I haven't been able to find the information in the datasheet, you are welcome to point in that direction, if that exists.
Maybe one of the engineers at ST are able to look into the simulations for the logic and see if this indeed is the behaviour of PA7/WINM.
We will contact our local FAE and provide our custom board with mounted MCU, and we also have spare MCUs that we can provide, if requestet by ST for further investigation.
Thank you.
-Mads
2025-09-04 1:14 AM
I think you hit the nail. Unintended connection is not the first encountered (@waclawek.jan knows, bound timers). Thanks for investigation, it sounds reasonable.
In out project we finally made simpler circuit, without need of second OPAMP.
-Tomas