I am using ESP module which operates in 3.3V so the GPIO pin will also speak only 3.3V. But I have a sensor that operates on 5V and communicates with I2C. How can I interface these two to communicate with each other.
Please suggest some quick way because I do not want to spend time in buying a logic converter.
When two people are talking with each other, the conversion medium is a crucial factor. If someone is talking in Chinese and the other one understands English, the conversion will not take place. If both can not change their language, you need a person who understands both language and converts the Chinese to English or vice-versa.
This person in electronics is a level converter, that converts two voltage level in both directions.
I have done a similar project in the circuit digest.
https://circuitdigest.com/tutorial/bi-directional-logic-level-controlle…
Please check the circuit along with the testing video.
Hey Sourav thanks for your wonderful idea, your link was very useful. I did not have the BS170 IC so I used the one that was available with me and it works great. I also tested the circuit for bi-directional communication and it worked.
Now my question is, is it reliable. Can I just finalize the circuit and work forever in my product? Because i worked out the BOM cost and using mosfet in place of converter IC saves me cost. Please need your advice on this
An I2C supports 300kHz to 1.9MHz depending on the switching time. Can you confirm what is the MOSFET part number and what is the I2C frequency for your work?
In one of my project, I faced same issue, of voltage/logic level converter, for which I preferred to use the voltage divider circuit to convert voltage from 5V to 3.3V for one of my module. For this I contacted with the support of SSLA, for getting better solution using my available resources. They guide me in completion of the project. I suggest you to get in touch with the experiecde support team of SSLA to get better solution.
Debasis Parida
PermalinkThe best solution for the problem is to use is to use a logic converter.But if you do not want to use that, you can use a voltage divider resistive level shifters which can do this for you.
- Log in or register to post comments
Joined August 22, 2019 125Thursday at 12:29 PM