I am designing a board based on STM32F7 with a dozen of Digital inputs that need to be 12V tolerant. On the first design, I was using a voltage divider to have the right logical high detection when 12V is applied to the input. In addition to this, I added external pull-ups / pull-down manually soldered based on the configuration needed.
I wonder if I could use the internal pull-ups/pull-down of my microcontroller to do this. The problem is that those resistor (40K for the STM32F7) will also create a voltage divider with my voltage adaptation circuit and I think it won't work.. Here is an update with the schematics of the current adapter :
Maybe I can use two OP-amps in inverting mode to drive the voltage from 12V to 3.3V but it will cost a lot of space on the board. Another solution would be to add a follower OP-AMP at the end of the voltage divider like this :
Do you have any idea on how to do this ? Is their a simple solution to acheive this ?