Important changes to forums and questions
All forums and questions are now archived. To start a new conversation or read the latest updates go to forums.mbed.com.
10 years ago.
How to interface 5V devices
Hi, I am working in a project and I need to use a flow sensor, exactly this model http://www.seeedstudio.com/wiki/index.php?title=G1/2_Water_Flow_sensor
It works with a Vcc of 5V. The water speed is sent via a pwm signal, the frequency of this signal is just proprotional to water speed, so doing a calculation you get your real value. Obiously this signal is 5V.
I am using Lpc1768 so I would like to know how to interface it with 3.3V.
3 Answers
10 years ago.
Hi Sergio, you can use a logic level converter like this:
https://www.sparkfun.com/products/12009
To interface 5v devices to 3.3v and 3.3v devices to 5v
I hope this help you
Greetings
Take care using that level shiftier for anything high speed, it is using a 10k pullup resistor to give the high levels, fine for most things but not what you want for high data rates or timing critical signals.
For 3.3V to 5V at high speeds you need to use a buffer IC of some sort.
For 5V to 3.3V you can normally get away with a series resistor and optionally a clamping diode. Or as Erik pointed out use a part which can take 5V inputs like the LPC1768.
posted by 28 Oct 201410 years ago.
The LPC1768 is 5V tolerant on its (digital) input pins, so you can directly connect them. The other way arround many deviced (but not all!) will accept 3.3V as a logic high, even if they are 5V devices. For those who do not reliably accept this you indeeed need a level shifter.
9 years, 8 months ago.
You must be sure that never when lpc is powered off(VDD=0) the 5v signal comes to lpc because lpc1768 is 5v tolerant as long as it has 3.3v supply