I bought the 74HC245, just to find a couple of Google searches later that it is not the best solution. Now it looks like the 74HCT4050 is a sure thing, but I wasn’t able to find it in local shops.
HC series is not level shifting, they have full protection diodes on the
inputs - trying to feed them 5V signals whilst powered from 3.3V will pull the 3.3V
rail up to 4.5V or so and probably damage something…
HCT series can only be used to raise 3.3V signals to 5V, they must be powered at 5V.
The LVC family are 1.6 to 3.3V powered and 5.5V input tolerant, although I can’t recall
if they are readily available in DIP. 74LVC245 gives you 8 buffers from 5V → 3.3V, but
can’t map the other way (though you don’t normally need to, Arduinos should read 3.3V
I want it to interface Arduino with SD cards, accelerometers and such stuff, using soething “better” than just a resistor divider. What are the bes solutions?
Better means what exactly? You do need fairly low impedance resistor dividers because
SDcards need fast edges, I’ve used 1k/2.2k before, but that’s rather marginal for 8MHz
For I2C bus you just put pull-up resistors to 3.3V, it should just work (if the I2C
driver correctly uses open-drain). True open drain and open collector outputs will drive any voltage from any voltage, Arduino I2C bus isn’t true open-drain so you have to limit
the output to 5V.