Teensy 3.2 with IIC 128x64 OLED Module

Status
Not open for further replies.
Is the nano powered with 3.3V, too ?
Do you have the needed pullup-resitors to the I2C lines attached ?
 
No, as I read in the spec, the operating voltage for the screen is 3.3-5v.
You suggest to place a resistor on SCL and SDA to the 3.3v pin of the Teensy? What value? 10k?
Thanks!
 
I briefly tried a couple packages with all the bells and whistles, like u8g2 https://github.com/olikraus/u8g2/ which is not Teensy friendly
Or SSD_13XX https://github.com/sumotoy/SSD_13XX which may be the hot solution for Teensys, but doesn't handle the cheapest with SSD1306 drivers (due to lack of buffers

One simple one with limited features that big bangs the I2C worked on first try with the under $3, 2 control wire (no reset) displays one finds on Ebay.
It's evilOLED https://github.com/evilnick/evilOLED

Just spotted this promising library: "Enhanced I2C library for Teensy 3.x devices "
https://github.com/nox771/i2c_t3

Here's the examples I just got from China, getting a few other things spreads out the big $1.85 shipping fee
http://www.ebay.com/itm/0-96-I2C-II...isplay-Module-White-Blue-Yellow-/311953510285
 
Last edited:
I believe the OLEDs all operate at 3.3V (Adafruit says they re all 3.3 interface safe) you can spot the little 3 lead voltage regulator chip coming off the VCC pin that drops the 5V input to 3.3. My test with bitbanged I2C was successful without pullup resistors.

I noticed a post elsewhere that declared:
real pullup resistors for SDA and SCL are required when using Teensy 3.x or Teensy-LC.
 
Last edited:
Sometimes, I2C works without extra pull-ups but only if the target device (the display) has integrated pull-up resistors. You should look that information up in the display’s data sheet.

If code works on the Nano, but not with the Teensy, it might be a pin problem, but I think you made sure to use the correct pins, or a speed problem - the Teensy is incredibly faster. Which I2C data rate did you select on the Nano and which one on the Teensy?
 
I use this setup for both
Code:
U8GLIB_SSD1306_128X64 u8g(U8G_I2C_OPT_DEV_0|U8G_I2C_OPT_NO_ACK|U8G_I2C_OPT_FAST);  // Fast I2C / TWI
 
You see, the problem is most probably the U8G_I2C_OPT_FAST #define. I guess it resolves much faster on the Teensy (and thus too fast for the OLED) as on the Nano. I’ll have a look into the library’s code if you tell which one of the above listed you are finally trying.

Since the Oli Kraus library uses U8g2() as constructor, it can’t already be that one....
 
Last edited:
Indeed I am using U8glib. I have tried all samples from the library: no problem with the nano and no result with the teensy.
You're right, the initialization of the library is probably different. I have to dig that way.
Thanks
 
Update: work perfectly with pullup, U8g2lib and U8G2_SSD1306_128X64_NONAME_F_HW_I2C u8g2(U8G2_R0, /* reset=*/ U8X8_PIN_NONE);
Thanks
 
Status
Not open for further replies.
Back
Top