2024-10-08 03:13 AM
Hi,
We have a custom board with a STM32G071R8T6TR, PA4 is configured as input but it does not work.
All other inputs on the boards are working correct but PA4 is a problem.
If we configure PA4 as an output it works fine, we toggle hi/lo, we have checked IDR for PA4 and the IDR does not change which is a problem, it does that when we toggle PA5 and PA6 hi/lo the IDR for PA5 and PA6 change.
If PA4 is configured as input and we change input hi/lo there is no change in IDR either.
We have cheked MODER is correct.
What do we miss here or could this be a defect STM32 MCU ?
Kind regards
Morten
Solved! Go to Solution.
2024-10-16 01:18 AM
Hi,
We found the problem, its a problem with the MCU, in other similar products we don't see the issue.
We will replace the MCU.
BR
Morten
2024-10-08 03:43 AM
Sounds much like hardware damage.
Do you have a second board, perhaps a Nucleo?
JW
2024-10-08 03:50 AM
Hi,
did you check real connection to pin exists ?
Try re-solder pin, maybe has bad solder joint.
(Funny is: if you check with DMM or scope, pressing on the pin is enough, to see: is ok.
But is not - as soon, as you no more press on the pin ! )
2024-10-08 05:16 AM
Hi Jan,
I think we should buy one, tested code and verified registers on STM32F411 nucleo, it works fine.
BR
Morten
2024-10-08 05:18 AM
Hi AScha.3,
Please read my description, IDR does not change when we configure as output and toggle PA4 hi/lo, IDR does change when we do that on other pins PA5, PA6.
Kind regards
Morten
2024-10-08 05:19 AM
Just to be sure:
> If we configure PA4 as an output it works fine,
this means, that you set PA4 as GPIO Output toggled it, and measured the output using logic analyzer/oscilloscope, correct?
JW
2024-10-08 05:24 AM
Hi JAn,
Yes this is correct.
So when PA4 is configured to output and is set to 0 we read IDR as 0 - this is ok.
When we set PA4 to 1 we still read IDR as 0 even though we see 1 on the oscilloscope.
If we do the above on other pins like PA5 and PA6 this works perfect.
Kind regards
Morten
2024-10-08 05:32 AM
Assuming this is a minimal code doing nothing else but toggling that pin (i.e. no analog features setup), all clues point to damaged mcu, then.
Note, that PA4 and PA5 are not 5-volt tolerant.
JW
2024-10-08 05:45 AM
Hi Jan,
We went back to basics and we are running from a very basic program using no other features. :)
Yes the pins work at 3.3V.
MPF
2024-10-08 10:37 PM
Did you check GPIO_LCKR?