I2C LCDs: Reverse Engineering the I2C Converter

If you need a basic LCD display for an Arduino or Raspberry Pi, it’s hard to beat these I2C LCD kits you can find for about $5 on eBay.

This is a companion discussion topic for the original entry at https://www.sevarg.net/2017/03/12/i2c-lcds-reverse-engineering-i2c/

(Comments from Blogger)

2017-03-13 by MaC

I’m wondering if those I2C adapters for LCD could be used as simple GPIO expanders ?

2017-03-13 by Russell Graves

GPO expanders, certainly - they’re not capable of input with these chips, though.

2017-03-14 by Aaron

Or you could spend $5 and get SparkFun 16 Output I/O Expander Breakout - SX1509 - BOB-13601 - SparkFun Electronics from SparkFun. Or go DIY from one of these http://www.mouser.com/Search/Refine.aspx?Keyword=I2C+GPIO+expander

2017-03-25 by vandi

Thank you!

2017-07-07 by An old fart engineer

Sorry, but these boards are not directly compatible with the GPIO pins on a Raspberry Pi. They’re 5V parts, RPi GPIO pins are 3.3V and not 5V tolerant.

Just wanting to keep people from frying their Pi boards.

2017-07-07 by Russell Graves

Since these are passive/slave devices that never drive the I2C bus lines, they’re OK with a Pi. The Arduino drives them from 0V to 5V, and the Pi will drive from 0V to 3.3V, which is still counted as a logical high.

Unless these are actively driving the bus to 5V, which they shouldn’t be, it’s not a problem. Even I2C stretching involves holding SCL low, not high.

2017-07-08 by An old fart engineer

If the adapter boards are strictly passive - and have no pull-up resistors - you’re right.

Pull-ups are an issue I had in mixing some 3.3 and 5V I2C devices on an Arduino. But on thinking back a bit, they were both ‘active’ devices that could send and receive data, and both had pull-ups. But (human) memory can be faulty.

2017-07-08 by Russell Graves

An I2C slave device can send data, but only on the request of the master - it’s capable of pulling the clock line low to stretch clock cycles, and pulling the data line low to transmit. All the pullups are on the master side, in a normal I2C setup.

I suppose I should put a scope on these and test them out at lower voltages, though!