| Electronics > Beginners |
| I2C - Clock looks OK, Data line has DC Bias |
| (1/2) > >> |
| optoisolated:
Hi All, This ones confusing me... I have a simple I2C circuit trying to drive a 128x32 OLED Display. Worked fine when I prototyped it on an Arduino, moved it to a Wemos D1 Mini, no good. Checked the signal on an oscilloscope, realised I had forgotten to pull the lines high. Put 3K3 resistors on the data and clock lines. Clock line looks good now. The data line however doesn't look right. Instead of having a full 0-5V it's ~3-5V, on the high side. Any idea what I'm missing here? |O Thanks :) (I'm assuming a lot of the noise and overshoot is from the excessive loop area from the test leads.) |
| AndyC_772:
Looks like the data line is shorted to a logic signal that's high, so the high level is OK but the low level is only halfway to where it should be. As an experiment, try putting an additional 3k3 resistor between SDA and GND. This should, in theory, create a potential divider that puts it at ~2.5V. My guess is it'll remain high. |
| optoisolated:
Had a dig around and couldn't see any shorts. I replaced the resistors, and tried a new Wemos D1. Didn't seem to help. I did try what you suggested with the divider, and it does bring down the high level. |
| garethw:
Next I would be disconnecting the wires from the Wemos and probing each side to determine where the 3.3v is coming from. Sent from my iPhone using Tapatalk |
| ledtester:
This guy got it working - blog post also shows his setup: https://blog.hau.me/2018/12/26/i2c-oled-display-on-a-wemos-d1-mini/ Another idea... here is an i2c bit-banging Arduino library. You can try using some other IO pins to see if that makes a difference: https://github.com/Testato/SoftwareWire The library has a printStatus() method. #define ENABLE_I2C_SCANNER on line 60 and it will perform a device scan when called. |
| Navigation |
| Message Index |
| Next page |