7 years, 4 months ago.

Mbed 1768 - LPCexpresso 1796 I2C differences

My specific question is, are there any differences between the mbed 1768 board and the LPCxpresso 1769 board when using I2C?

I'm trying to work with an SSD1306 I2C OLED display, basically just starting with the code here: https://developer.mbed.org/users/nkhorman/code/Adafruit_GFX/

The code works fine on the mbed board. When I put it on the LPC board I don't get anything on the screen.

  • Both setups are using the same display module.
  • Both have 2.2k pullup resistors.
  • Both are running the same code (uploaded to the LPC board using lpc21isp).
  • I've tried both I2C ports (Pins 9&10, and Pins 28&27)

Has anyone got any ideas what could be wrong?

1 Answer

7 years, 4 months ago.

This thread suggest that it should work. Is any mbed code that you compiled for the LPC1768 executing on your LPC1769? I assume you use a bin2hex converter to convert the mbed binary into a hex file that is needed by the lpc21isp? There are some issues with bin2hex converters for larger binaries (64k). Make sure you use one that functions properly.

Thanks for the response. Yeah, everything I've seen says that it should work, and that the 1768 and 1769 only differ in max clock speed. The lpc21isp software works with bin files too (just needs the -bin option).

It's working with other code I'm building. This is a part of a bigger project to make a USB keyboard, and my keyboard and USB code run fine on the LPCxpresso board, just not the OLED I2C code.

If this doesn't work, I can always try SPI modules instead, it just seems a bit odd.

posted by Matthew Green 18 Dec 2016

Is the powersupply for the OLED and for the pull-up Ok. Note that the pinout functions for 3V3 and 5V on the LPCxpresso are not fully compatible with mbed lpc1768. I2C levels should be high when checked with a multimeter. Did you check I2C traffic using a scope or logic analyser?

posted by Wim Huiskamp 18 Dec 2016

Yeah, I'm using a 1A 3.3v LDO to power the LPC board and the OLED. Unfortunately, I don't have a scope or logic analyser to hand.

posted by Matthew Green 18 Dec 2016