[STM8S003F3P6] GPIO(PB5) ouputs 5V when set HIGH using 3.3v power supply[RESOLVED]
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2022-03-13 12:34 AM
I am trying to run simple program to output HIGH on IO pin of microcontroller STM8S003F3P6.
I am using PB5 pin to output High. I am using 3.3v power supply and expect GPIO to output 3.3v when I set it HIGH but surprisingly I am getting 5V instead, below is the circuit diagram
Can someone help how to get 3.3v instead of 5V on GPIO output for above processor, is there anything wrong with above circuit?
Solved! Go to Solution.
- Labels:
-
GPIO-EXTI
Accepted Solutions
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2022-03-14 5:40 AM
Welcome, @SSaro.1​, to the community!
first of all: the schematic looks good, even if R16 on NRST is not necessary.
However, it is simply not possible to measure 5V on a pin of a device where nothing is connected to 5V, so you seem to have another connection not shown here. Please measure the voltage at net 3.3v (U7.9 or J23.1).
Please also include your code (init, GPIO setting) using the code button </> to verify.
Regards
/Peter
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2022-03-14 5:40 AM
Welcome, @SSaro.1​, to the community!
first of all: the schematic looks good, even if R16 on NRST is not necessary.
However, it is simply not possible to measure 5V on a pin of a device where nothing is connected to 5V, so you seem to have another connection not shown here. Please measure the voltage at net 3.3v (U7.9 or J23.1).
Please also include your code (init, GPIO setting) using the code button </> to verify.
Regards
/Peter
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2022-03-14 11:00 PM
Thanks, it seems somewhere there was loose connection, but it seems to be working now
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2022-03-15 12:07 AM
Great!
If the problem is resolved, please mark this topic as answered by selecting Select as best. This will help other users find that answer faster.
/Peter
