{"id":12399,"date":"2015-09-24T12:40:21","date_gmt":"2015-09-24T12:40:21","guid":{"rendered":"http:\/\/randomnerdtutorials.com\/?p=12399"},"modified":"2019-04-02T10:23:34","modified_gmt":"2019-04-02T10:23:34","slug":"how-to-level-shift-5v-to-3-3v","status":"publish","type":"post","link":"https:\/\/randomnerdtutorials.com\/how-to-level-shift-5v-to-3-3v\/","title":{"rendered":"How to Level Shift 5V to 3.3V"},"content":{"rendered":"<p>In this tutorial, I show how you can shift a signal from 5V to 3.3V. This is very useful if you want to connect an <a href=\"https:\/\/randomnerdtutorials.com\/category\/arduino\/\">Arduino<\/a> (operates at 5V) to an <a href=\"https:\/\/randomnerdtutorials.com\/category\/esp8266\">ESP8266<\/a> (operates at 3.3V).<!--more--><\/p>\n<p>The following Figure describes\u00a0what we want to accomplish by\u00a0the end of this tutorial.<\/p>\n<p><img data-recalc-dims=\"1\" fetchpriority=\"high\" decoding=\"async\" class=\"aligncenter size-full wp-image-12436\" src=\"https:\/\/i0.wp.com\/randomnerdtutorials.com\/wp-content\/uploads\/2015\/09\/FEATURED-level-shifter-Copy.jpg?resize=750%2C150&#038;quality=100&#038;strip=all&#038;ssl=1\" alt=\"FEATURED level shifter - Copy\" width=\"750\" height=\"150\" srcset=\"https:\/\/i0.wp.com\/randomnerdtutorials.com\/wp-content\/uploads\/2015\/09\/FEATURED-level-shifter-Copy.jpg?w=750&amp;quality=100&amp;strip=all&amp;ssl=1 750w, https:\/\/i0.wp.com\/randomnerdtutorials.com\/wp-content\/uploads\/2015\/09\/FEATURED-level-shifter-Copy.jpg?resize=300%2C60&amp;quality=100&amp;strip=all&amp;ssl=1 300w\" sizes=\"(max-width: 750px) 100vw, 750px\" \/><\/p>\n<h2>Method #1 &#8211; Voltage Divider<\/h2>\n<p><span style=\"color: #ff0000;\">Warning:<\/span> This method works for slow signals, but\u00a0it&#8217;s not very reliable. I recommend using Method #2.<\/p>\n<p>A voltage divider is a simple circuit which reduces\u00a0a large voltage into a smaller one.<\/p>\n<p>Using 2\u00a0resistors and an input voltage, we can create an output voltage that is a fraction of the input. Below you can see\u00a0the formula that you need to use to calculate the resistors that you need in your circuit:<\/p>\n<h2><img data-recalc-dims=\"1\" decoding=\"async\" class=\"aligncenter wp-image-12438 size-full\" src=\"https:\/\/i0.wp.com\/randomnerdtutorials.com\/wp-content\/uploads\/2015\/09\/voltage-divider-equation.png?resize=349%2C97&#038;quality=100&#038;strip=all&#038;ssl=1\" alt=\"voltage divider equation\" width=\"349\" height=\"97\" srcset=\"https:\/\/i0.wp.com\/randomnerdtutorials.com\/wp-content\/uploads\/2015\/09\/voltage-divider-equation.png?w=349&amp;quality=100&amp;strip=all&amp;ssl=1 349w, https:\/\/i0.wp.com\/randomnerdtutorials.com\/wp-content\/uploads\/2015\/09\/voltage-divider-equation.png?resize=300%2C83&amp;quality=100&amp;strip=all&amp;ssl=1 300w\" sizes=\"(max-width: 349px) 100vw, 349px\" \/><\/h2>\n<p>Solving the formula above with<em> Vin=5V, R1=1000ohms<\/em> and <em>Vout=3.3V<\/em>.<\/p>\n<p>We get <em>R2~=2000ohms<\/em>.<\/p>\n<p><img data-recalc-dims=\"1\" decoding=\"async\" class=\"aligncenter wp-image-12437 size-full\" src=\"https:\/\/i0.wp.com\/randomnerdtutorials.com\/wp-content\/uploads\/2015\/09\/voltage-divider.png?resize=300%2C208&#038;quality=100&#038;strip=all&#038;ssl=1\" alt=\"voltage divider\" width=\"300\" height=\"208\" \/><\/p>\n<p>So, here&#8217;s how the final circuit looks like:<\/p>\n<p><img data-recalc-dims=\"1\" loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-12441\" src=\"https:\/\/i0.wp.com\/randomnerdtutorials.com\/wp-content\/uploads\/2015\/09\/voltage-divider-circuit.png?resize=408%2C151&#038;quality=100&#038;strip=all&#038;ssl=1\" alt=\"voltage divider circuit\" width=\"408\" height=\"151\" srcset=\"https:\/\/i0.wp.com\/randomnerdtutorials.com\/wp-content\/uploads\/2015\/09\/voltage-divider-circuit.png?w=408&amp;quality=100&amp;strip=all&amp;ssl=1 408w, https:\/\/i0.wp.com\/randomnerdtutorials.com\/wp-content\/uploads\/2015\/09\/voltage-divider-circuit.png?resize=300%2C111&amp;quality=100&amp;strip=all&amp;ssl=1 300w\" sizes=\"(max-width: 408px) 100vw, 408px\" \/><\/p>\n<h2>Method #2 &#8211; Bi-Directional Logic Level Converter<\/h2>\n<p>A Bi-Directional Logic Level Converter (LLC) also reduces the voltage from a\u00a0signal. This the recommended method to level shift signals that require high speed communication (serial at a high baud rate, I2C, etc&#8230;).<\/p>\n<p>You can <a href=\"https:\/\/makeradvisor.com\/tools\/logic-level-converter-module\/\" target=\"_blank\" rel=\"noopener noreferrer\">check this page to find the bi-directional logic level converter module<\/a> best price.<\/p>\n<p><a href=\"http:\/\/ebay.to\/1h4TNPy\" target=\"_blank\" rel=\"noopener noreferrer\"><img data-recalc-dims=\"1\" loading=\"lazy\" decoding=\"async\" class=\"aligncenter wp-image-12571\" src=\"https:\/\/i0.wp.com\/randomnerdtutorials.com\/wp-content\/uploads\/2015\/09\/12009-06.jpg?resize=267%2C199&#038;quality=100&#038;strip=all&#038;ssl=1\" alt=\"12009-06\" width=\"267\" height=\"199\" srcset=\"https:\/\/i0.wp.com\/randomnerdtutorials.com\/wp-content\/uploads\/2015\/09\/12009-06.jpg?w=573&amp;quality=100&amp;strip=all&amp;ssl=1 573w, https:\/\/i0.wp.com\/randomnerdtutorials.com\/wp-content\/uploads\/2015\/09\/12009-06.jpg?resize=300%2C224&amp;quality=100&amp;strip=all&amp;ssl=1 300w\" sizes=\"(max-width: 267px) 100vw, 267px\" \/><\/a><\/p>\n<p>You simply connect\u00a0the signal with the High Voltage to the HV pins\u00a0and it outputs the signal with the lower voltage on the other side\u00a0(LV). With the board shown in the Figure above you have 4 channels available.<\/p>\n<p>Do you have any questions?\u00a0Leave a comment down below!<\/p>\n<p>Thanks for reading. If you like this post probably you might like my next ones, so please support me by subscribing my <a href=\"https:\/\/randomnerdtutorials.com\/download\" target=\"_blank\" rel=\"noopener noreferrer\">blog<\/a> and my\u00a0Facebook Page.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>In this tutorial, I show how you can shift a signal from 5V to 3.3V. This is very useful if you want to connect an Arduino (operates at 5V) to &#8230; <\/p>\n<p class=\"read-more-container\"><a title=\"How to Level Shift 5V to 3.3V\" class=\"read-more button\" href=\"https:\/\/randomnerdtutorials.com\/how-to-level-shift-5v-to-3-3v\/#more-12399\" aria-label=\"Read more about How to Level Shift 5V to 3.3V\">CONTINUE READING \u00bb<\/a><\/p>\n","protected":false},"author":1,"featured_media":12435,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"jetpack_post_was_ever_published":false,"_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_jetpack_memberships_contains_paid_content":false,"footnotes":""},"categories":[305,3,247,8,11],"tags":[],"class_list":["post-12399","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-0-other","category-circuits","category-level-shifter","category-c-theory-and-blog","category-c-tutorials"],"aioseo_notices":[],"jetpack_featured_media_url":"https:\/\/i0.wp.com\/randomnerdtutorials.com\/wp-content\/uploads\/2015\/09\/FEATURED-level-shifter.jpg?fit=750%2C400&quality=100&strip=all&ssl=1","jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/randomnerdtutorials.com\/wp-json\/wp\/v2\/posts\/12399","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/randomnerdtutorials.com\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/randomnerdtutorials.com\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/randomnerdtutorials.com\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/randomnerdtutorials.com\/wp-json\/wp\/v2\/comments?post=12399"}],"version-history":[{"count":0,"href":"https:\/\/randomnerdtutorials.com\/wp-json\/wp\/v2\/posts\/12399\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/randomnerdtutorials.com\/wp-json\/wp\/v2\/media\/12435"}],"wp:attachment":[{"href":"https:\/\/randomnerdtutorials.com\/wp-json\/wp\/v2\/media?parent=12399"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/randomnerdtutorials.com\/wp-json\/wp\/v2\/categories?post=12399"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/randomnerdtutorials.com\/wp-json\/wp\/v2\/tags?post=12399"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}