Pages: [1] 2 3   Go Down
Author Topic: Solution for the 5V vs 3.3V problem  (Read 10375 times)
0 Members and 2 Guests are viewing this topic.
Portland, OR
Offline Offline
Sr. Member
****
Karma: 5
Posts: 260
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

(This post is based partly on suggestions by @hiduino, @Graynomad, and @CrossRoads seen here: http://arduino.cc/forum/index.php/topic,128582.msg972824.html#msg972824
http://arduino.cc/forum/index.php/topic,128582.msg967376.html#msg967376
http://arduino.cc/forum/index.php/topic,136243.msg1026496.html#msg1026496)

Since there are numerous existent Arduino shields with 5V signal levels, versus the 3.3V level at which the Arduino Due runs, users would need to have some solution to maintain interfacing compatibility.

So, how about something like the following:

Design an "in-between shield" with a level translator IC, for example GTL2000 ( http://www.nxp.com/documents/data_sheet/GTL2000.pdf ). This IC does 22 channel level translation and costs < US $2

This in-between shield would be inserted first into the Due, and on top of the shield would be inserted any arbitrary existent Arduino shield.

To allow separation for routing between the 5V shield lines and the 3.3V Due lines via the level translators, the in-between shield could have either slightly offset headers&sockets, or else surface mount headers on the bottom.

In contrast to resistor/diode-based methods, the above level-translator IC based solution should work bi-directionally, for all signal types (digital I/O, PWM, analog lines, Serial, SPI, I2C), and thus for all shields.

Any thoughts or issues seen regarding this Adapter-Shield approach?

Perhaps someone (or the Arduino dev team) can design a shield like the above.
« Last Edit: December 10, 2012, 01:02:01 am by giantsfan3 » Logged

SE USA
Offline Offline
Faraday Member
**
Karma: 40
Posts: 3783
@ssh0le
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

sounds like the perfect kludge for a poor design
Logged


Portland, OR
Offline Offline
Sr. Member
****
Karma: 5
Posts: 260
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

@Osgeld: Don't understand. Are you saying the suggestion I am making is poor? If so, do please provide comments.
Logged

SE USA
Offline Offline
Faraday Member
**
Karma: 40
Posts: 3783
@ssh0le
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

no I am saying that using an ARM in a ecosystem where 5 volts is common in the first place was pretty dumb
Logged


Global Moderator
Boston area, metrowest
Online Online
Brattain Member
*****
Karma: 435
Posts: 23607
Author of "Arduino for Teens". Available for Design & Build services. Now with Unlimited Eagle board sizes!
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Think I've got ok start for it:


* DUE_shield.png (64.4 KB, 900x474 - viewed 245 times.)
Logged

Designing & building electrical circuits for over 25 years. Check out the ATMega1284P based Bobuino and other '328P & '1284P creations & offerings at  www.crossroadsfencing.com/BobuinoRev17.
Arduino for Teens available at Amazon.com.

Forum Administrator
Offline Offline
God Member
*****
Karma: 47
Posts: 629
I find plain exciting
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

@Osgeld

Please provide your invaluable contribution when you have something more interesting to say.
If you don't like Arduino Due nobody is forcing you to be on this forum.

Saying "dumb" doesn't contribute to the discussion.

m

Logged

Portland, OR
Offline Offline
Sr. Member
****
Karma: 5
Posts: 260
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

@CrossRoads:
Looking good -- That layout image of yours is just to show the orientation and not the actual level translation itself, yes? Have you looked into the GTL2000... or the TXB0108 would work too, although I believe the GTL2000 is significantly cheaper.
Logged

Offline Offline
Newbie
*
Karma: 0
Posts: 10
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Yes, it was just to get the headers defined, to show that 2 sets of headers could be made to fit next to each other - males down to the Due, and females up to shields.
I think I'll slide the 2nd set over some more to make room for signals to be buffered in the middle area  and then go back out, especially in the double row area.
Are there many mega shields? Maybe just drop that area and make sure the 20 Uno IO + power + ICSP headers are supported. Need to beef up the power traces.

Crossroads
(with the system calling me "derekmjenkins" for some reason - hopefully just a test towards solving my week day log in problems)
Logged

Offline Offline
Newbie
*
Karma: 0
Posts: 6
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Hey guys,

I've been looking into something like this for a while as well. One thing that caught my eye was this pin converter shield for the UNO/Leo to go between the old pinout and 1.0

http://mayhewlabs.com/products/go-between-shield

Something like this could be implemented with logic converters between the connection points. This could also leads in some other interesting directions as well:
  • Being able to select/designate individual pins as 5v or 3.3v logic
  • Integrating dynamic pin assignment so the pinout could be adaptable to older shields configurations
  • And if you really wanted to get crazy, you could even wire the whole thing up to be driven by an integrated IC so you just add a library to your sketch and assign the pinout and voltage in software.
  • And since I've already gone way out in left field, to complete the prefect conversion shield, add either an IC to linearly scale the analog inputs or a separate 5v 12 or 16 bit ADC

EDIT: Just read the post about the GTL2000 and it got me thinking there has got to be a chip that could route pins and shift logic levels... Yup.

http://www.intersil.com/en/products/audiovideo/video-switching/unbuffered-crosspoint-switches/CD22M3494.html

Thoughts?
Logged

nr Bundaberg, Australia
Offline Offline
Tesla Member
***
Karma: 121
Posts: 8430
Scattered showers my arse -- Noah, 2348BC.
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Quote
Being able to select/designate individual pins as 5v or 3.3v logic
Needs a lot of hardware, in banks of 4, 6, or 8 not so bad.

A crosspoint switch would be one way to go, you'd need a lot for them and last I looked they were not cheap. Also I don't think they level shift but at least they should pass the analog.

As for the analog you can get programmable gain chips or just make your own with opamps.

Either way you need more IO to control this lot, so add 1 or 2 I2C IO expander chips with jumpers to set the address so they don't clash with any shields.

In general I like the basic concept but it could very quickly turn into a cluster f*ck with 30 chips that cost 2x the Due and the shield you want to use.

Crossroads (aka derekmjenkins!?), you've obviously made a start, any thoughts on doing something?

Quote
Are there many mega shields?
I don't think so, I'd drop the extra stuff and just go for a standard shield.

EDIT: I just looked at the price for that CD22M3494 crosspoint switch, it's not too bad but still too much for this I think.

______
Rob

« Last Edit: December 11, 2012, 08:08:09 pm by Graynomad » Logged

Rob Gray aka the GRAYnomad www.robgray.com

Global Moderator
Boston area, metrowest
Online Online
Brattain Member
*****
Karma: 435
Posts: 23607
Author of "Arduino for Teens". Available for Design & Build services. Now with Unlimited Eagle board sizes!
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

I was thinking just TXB0108s or maybe a couple of GTL2000 for the bank of 18 header pins.
Bring the analog straight over, with TXB0108 in parallel, maybe a jumper to enable the OE/ when digital was required.
Or couple TXB0104s so analog/digital could be split up some.

Really stinks not being able to log in during the day except occasionally due to system conflicts or something.
Logged

Designing & building electrical circuits for over 25 years. Check out the ATMega1284P based Bobuino and other '328P & '1284P creations & offerings at  www.crossroadsfencing.com/BobuinoRev17.
Arduino for Teens available at Amazon.com.

nr Bundaberg, Australia
Offline Offline
Tesla Member
***
Karma: 121
Posts: 8430
Scattered showers my arse -- Noah, 2348BC.
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Remember that the SPI pins are already 5v, they may need to be shifted the other way.

EDIT: I think I take that back, it's just the power pin that's 5v.

_____
Rob
Logged

Rob Gray aka the GRAYnomad www.robgray.com

Global Moderator
Boston area, metrowest
Online Online
Brattain Member
*****
Karma: 435
Posts: 23607
Author of "Arduino for Teens". Available for Design & Build services. Now with Unlimited Eagle board sizes!
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

TXB0108 & TXB0104 seem to work & fit pretty well.
One ground wire to clean up still.


* shield_layout.png (66.65 KB, 920x484 - viewed 125 times.)

* shield_sch.png (72.06 KB, 2134x1076 - viewed 93 times.)
Logged

Designing & building electrical circuits for over 25 years. Check out the ATMega1284P based Bobuino and other '328P & '1284P creations & offerings at  www.crossroadsfencing.com/BobuinoRev17.
Arduino for Teens available at Amazon.com.

Offline Offline
Newbie
*
Karma: 0
Posts: 6
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Quote
Being able to select/designate individual pins as 5v or 3.3v logic
Needs a lot of hardware, in banks of 4, 6, or 8 not so bad.

A crosspoint switch would be one way to go, you'd need a lot for them and last I looked they were not cheap. Also I don't think they level shift but at least they should pass the analog.

As for the analog you can get programmable gain chips or just make your own with opamps.

Either way you need more IO to control this lot, so add 1 or 2 I2C IO expander chips with jumpers to set the address so they don't clash with any shields.

In general I like the basic concept but it could very quickly turn into a cluster f*ck with 30 chips that cost 2x the Due and the shield you want to use.

Crossroads (aka derekmjenkins!?), you've obviously made a start, any thoughts on doing something?

Quote
Are there many mega shields?
I don't think so, I'd drop the extra stuff and just go for a standard shield.

EDIT: I just looked at the price for that CD22M3494 crosspoint switch, it's not too bad but still too much for this I think.

______
Rob



Hey Rob, got a solution for ya.

http://www.ti.com/product/sn74lvc16t245  (I think there is a 32 channel unit as well)

Use something like this after a crosspoint switch and before exiting the shield. That way, each pin's output voltage can be selected and each pin can by dynamically assigned. Also, why do you think this would be too expensive? Mouser has the level shifter I just mentioned at $2 and the crosspoint at $4 or 6. Plus other parts and custom fab, you could almost surely get away under $20.

EDIT: Just thinking, you would just need the crosspoint for the pins that need to be moved like SCL and SDA, then just use a couple more of the level shifters I mentioned for the rest of the I/O. That way, the pins that might need to be moved can be, while all the pins can still be selected to be either 5v or 3.3v.
« Last Edit: December 12, 2012, 02:08:26 pm by OsuDan » Logged

nr Bundaberg, Australia
Offline Offline
Tesla Member
***
Karma: 121
Posts: 8430
Scattered showers my arse -- Noah, 2348BC.
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

That's a nice chip, I was aware of it's cousin the 74LVC16245 but this is more flexible.

One "problem" is that it's a wide package it won't fit where Crossroads has the TXB chips but that's easily fixed.

Quote
each pin's output voltage can be selected
Are you suggesting


                       |---5v buffer
SAM---switch---|
                       |---3v3 buffer

That way you could select 5v or 3v3 for each pin but you'd have to double the headers wouldn't you?

If not can you provide a drawing.

Quote
Also, why do you think this would be too expensive?
I was referring to the crosspoint switch, they used to be quite expensive but I've just found it for $3.04 1-off so that's pretty good.

______
Rob
Logged

Rob Gray aka the GRAYnomad www.robgray.com

Pages: [1] 2 3   Go Up
Jump to: