0
Follow
0
View

When STM32 sets the leak-open output of GPIO mode, why does the upper P-MOS tube not work at all and only the lower N-MOS work

duguqiangwei 注册会员
2023-02-25 18:30

When STM32 sets the GPIO mode to leak-open mode output, for each GPIO pin, there is actually an N-MOS tube and a P-MOS tube controlling the low and high level output of that pin, respectively.

In leak-open mode, for a high level output, P-MOS tube will be turned off and N-MOS tube will be turned on; For a low output, the N-MOS tube is turned off and the P-MOS tube is turned on. Thus, when a GPIO pin outputs a low level, only the P-MOS tube is operating while the N-MOS tube is off; When a GPIO pin outputs a high level, only the N-MOS tube is operating while the P-MOS tube is off.

If the upper P-MOS tube does not work at all when the leak-open mode is set, there may be the following reasons:

1. Wrong connection: There may be a wrong connection of the pin, or a problem with the connection of other components, resulting in the P-MOS tube can not work normally.

2. P-mos tube is damaged: The P-MOS tube may be damaged and cannot work normally.

3. Driver circuit problem: If the driver circuit of P-MOS tube and N-MOS tube is different, one of them may not work properly. In STM32, the driving circuit of P-MOS tube and N-MOS tube should be the same. If there is a difference, it is necessary to check whether there is a problem.

About the Author

Question Info

Publish Time
2023-02-25 18:30
Update Time
2023-02-25 18:30