Go Down

Topic: 5V signal down to 3.3V and only 20mA (Read 9252 times) previous topic - next topic


Hello hope someone can shed some light on my situation.

I have a small ASIC that is powered from the 3.3V pin on the arduino mega.

The ASIC receives I/O on two digital lines, DATA and STROBE. I have it connected to pins 18 and 19.

My problem is that DATA and STROBE can only handle 20mA MAX and 3.3V the arduino mega on those pins sends out 5V and 40mA

I was thinking of using a sn74lvc245a to convert the levels down to 3.3 but that would supply to much current.

link to datasheet:

The ASIC can handle -0.3 to 4.0 V

So I can use a variety of voltages but I need to limit current.

Anywho hope you guys/gals can help me out.


You have a slight misconception regarding current. Current isn't "sent" at a particular level, it is drawn/required by something. So you can apply 3.3V to the ASIC I/O pin and it will only require (generally) 1uA or so. The fact that the 74LVC245 can supply lots of current doesn't mean it is forced into the ASIC.

As another example, even though a battery can supply 1A (for example) of current, if you attach it to some LED's that only draw 20mA, then only 20mA of current will flow.

A power source (or digital output) provides voltage, the current is determined by what you hook up to it.

If you just want to connect a 5V output from the Mega to a 3.3V input on the ASIC, the easiest connection scheme is a voltage divider:


The Quick Shield: breakout all 28 pins to quick-connect terminals


Ok, but won't that drop the voltage?

Ok so as an example if it needs 20mA max but and you connect directly to the arduino I/O pin its supplying 40mA. Won't it fry the chip. Im really confused on this, I understand it draws what it needs but when sending a signal that will be at 40mA right?


No no no :)

It does not "send" 40mA. It is not supplying 40mA. It sends a VOLTAGE: 5V.

The voltage divider then reduces the voltage from 5V to 3.3V. The ASIC then DEMANDS a certain amount of current from that 3.3V voltage, most likely a very small amount: 1uA. While the Arduino is CAPABLE of providing UP TO 40mA of current, the number of electrons that actually start flowing (i.e., the current) is determined by what the ASIC DEMANDS: 1uA.

Need a custom shield? Let us design and build one for you.


Ok so I can use that level shifter i posted earlier and everything will work out fine :-)

"I already have that level shifter in a box somewhere"


Yes, you can use the 74LVC245 as long as you hook everything up properly. I bet you have some resistors in a box too, and they are a lot less work :)

The Gadget Shield: accelerometer, RGB LED, IR transmit/receive, light sensor, potentiometers, pushbuttons


hahaha, yeah that one :-)

Its actually already bread boarded and working for an sd.

Thanks so much for all your guys' help


Oct 02, 2010, 03:17 am Last Edit: Oct 02, 2010, 04:02 am by davekw7x Reason: 1
It is never good design practice to use way more circuit than you need to reliably do the job.

Well, I subscribe to the philosophy of "Good Enough" engineering, but whether it is "Good Enough" depends on what the "job" is.

An example: For an SD memory card interface, it has been variously reported that resistive voltage dividers don't work at the speed that SDHC cards can support.

On the other hand, level shifters with 74LVC245 or 74HC4050 chips work at all speeds that can be cranked out by the Arduino SPI port.  For the price of a single chip (a few cents) I get consistent, reliable, efficient performance.  

I have SD interface circuits from adafruit and also homebrew ones.  Full speed Arduino SPI operation for FAT32 files on 8GByte SDHC cards.  Haven't missed a byte yet.  I mean, I'm not saying that it is impossible to use resistive level shifters in this application, but why would I waste my time on a questionable design?  (See Footnote.)

I haven't used the particular Sparkfun level shifter circuit that was linked in a previous post, but it is an excellent example of a bi-directional level shifter employing well respected methodology used in I2C and other circuits where 2-way data flow is necessary.  Typically I use a 2N7000 or some such thing. (Of course, it also works in applications that only require unidirectional traffic.)

Things like the 'LCV245 and '4050 are OK for one-way traffic.  (And the '4050 is readily available in a DIP package which is convenient for breadboarding.)



Been there; done that; got so excited that I spilled some good Sonoma County wine on the tee-shirt.  (But at least it's not blood, which it might have been if I had shown up at a design review with resistors as level shifters in an 8 MHz circuit.)


Oct 02, 2010, 03:55 am Last Edit: Oct 02, 2010, 04:10 am by davekw7x Reason: 1
Richard: With all due respect, I was responding to your unqualified criticism to the effect that there is no need to use active devices as level shifters since resistors will do the deed.

The specific example that I gave was gleaned from various posts on this forum where people have reported problems with store-bought SD card interface circuits using resistive voltage dividers.  Perhaps lower values of resistance could give satisfactory RC time constant, but at the expense of additional signal loading, which might or might not be detrimental.

I hate to repeat myself, but my conclusion is this: Whether or not it is overkill depends on what the "job" is, and sometimes it is not overkill.  (See Footnote.)


On this forum I am mainly concerned with breadboarding and other types of design where knowledge about carefully controlled circuit capacitance and transmission line characteristics is not available.  My idea is to recommend circuits and methodology that give greatest chances of success to questioners who do not have the lab equipment or knowledge to wring out problems arising from little details like unknown input capacitance and stray wiring capacitance at a even a few MHz.

There is room for more than one point of view, and I like the fact that different people can speak up with different opinions (in a civilized manner, of course) on this forum.

I always learn something here.  Every time.


Actually I should mention since I still havn't got this chip running, I think I might of fried it.

So in the datasheet it also mentions that there is a DATA and STROBE protection DIODE for sinking, max is 20mA and min is -20mA

I emailed the company that provides it and they wrote me this,

"The DATA and STROBE line will NOT be able to sink 50mA. Even the 20mA is not recommended as this is absolute MAX. Our datasheet shows the ASIC can only guarantee 0.4V when sinking up to 2mA."

So going back through what you guys said, I should just use resistors in series to lower the operating voltage/Current of the I/O pin to an acceptable level.

Will I still be able to send digitalwrite(HIGH) or LOW Commands to the chip operating at this low of a current?

And I guess if this is the case 3.3V droped by that level converter did fry the diode. (silent but deadly) haha

Hope someone can get back to me. Much appreciated.



And I guess if this is the case 3.3V droped by that level converter did fry the diode

I think you are confusing inputs with outputs. Outputs sink current, that is how much current they will pull down to ground. You were asking before about level converters they convert a 5V signal FROM the arduino to the 3V3 signal into your ASIC. This has nothing to do with current sinking.

It looks like the ASIC provides an OUTPUT on the data and strobe lines, this output can be directly connected into an ardunio INPUT. If you have a pull up resistor on the input going to 3v3 then that will give you current that your ASIC can sink. That pull up has to be very low to exceed 20mA. Do the sums  3.3 / 0.02 = 165R.
If you have the pull up to 5V then you are in danger of frying the outputs of your ASIC.


Oct 08, 2010, 01:05 am Last Edit: Oct 08, 2010, 01:06 am by MetroExpress Reason: 1
Ok, so on the data sheet the STROBE on the ASIC is just used to take inputs from the arduino for setting it to HIGH or LOW.

for strobe it says "STROBE Protection Diode Current" 20mA

and the DATA line is used to pull information from, when it goes LOW
but initially I have to set it to HIGH.

My problem is that its maximum voltage is 3.6V.

And maybe im still all confused, but if I use the level converter it will drop it to 3.3V which is within its voltage requirements and current?.

so as i think your saying


I/O Pin 6 <-> (5V) LVC (3.3V) <-> resistor -> ASIC       //DATA
I/O Pin 7 <-> (5V) LVC (3.3V) <-> resistor -> ASIC       //STROBE

Could you explain what he mean by

"the ASIC can only guarantee 0.4V when sinking up to 2mA. "

I've been working on interfacing for a while now, and the only thing i can figure is the problem is this part with the sinking which im not understanding.

edit: added to


"the ASIC can only guarantee 0.4V when sinking up to 2mA. "

You are still getting confused with inputs and outputs. That sentence means when the ASIC is acting as an output and is sinking 2mA then the output voltage will only be 0.4V as opposed to the zero volts that a logic zero is supposed to delver.

I/O Pin 6 <-> (5V) LVC (3.3V) <-> resistor -> ASIC       //DATA
I/O Pin 7 <-> (5V) LVC (3.3V) <-> resistor -> ASIC       //STROBE

There are a few things wrong with this:-
1) There should be no series resistor between the output of the LVC and the ASIC.
2) the symbol <> implies the signals are bi-directional, they are not this is a one way street between the arduino to the ASIC
3) The LVC MUST be powered from 3v3 in order for this to work.


Oct 08, 2010, 01:37 am Last Edit: Oct 08, 2010, 05:00 am by MetroExpress Reason: 1
Ok so far this is what I have let me know if im shooting in the dark lol.

1A)So that means if im using the level shifter I have, I won't be able to detect the LOW output from the ASIC?

1B) If thats true then I should just use some resistors for now to breaboard.

I/O Pin 6(5V) <-> 1.8K Resistor <-> ASIC <-> 3.3k <-> GND      //DATA
I/O Pin 7(5V) <-> 1.8K Resistor <-> ASIC <-> 3.3k <-> GND      //STROBE

3) The LVC MUST be powered from 3v3 in order for this to work.

2) How do you mean. I have it powered from 3V3 but it changes the 5V from the arduino I/O pin to 3V3 for the ASIC

*I should also mention the 5V I was talking about was the I/O pin supply voltage its 5V, 40-5mA i believe.


Oct 08, 2010, 09:50 am Last Edit: Oct 08, 2010, 09:50 am by Grumpy_Mike Reason: 1
1A) Yes
1B) Yes
But you only need the 1.8K resistor, this is because you have a protection diode in the ASIC which can take up to 20mA. So with a 1.8K resistor dropping 5 - 3.9 = 1.4 / 1800 = 0.8mA = Safe for this application.

The LVC is NOT a level translator. It is a buffer with 5V tolerant inputs. That means it will output what ever voltage is is powered with BUT you won't blow it up if you put an input of 5V into it.

Along with other people lately you are just drip feeding information in stead of coming out and saying what you are using. You haven't even linked the data sheet of this device you are trying to use. Without all the information the advice you receive will be less than perfect.

Go Up