problem with a 128X64 oled i2c display

i just bought a 128X64 oled i2c display but when i try to use it with the u8glib library i have some problems making it work correctly. its like column 0 and 1 are outside the display... if i want to see a pixel on the first column of the display i need to place it in column number 2. its like the image is shifted left by 2 columns, in fact there are 2 columns at hte far right of the screen that display random stuff and can't be modified.

Hi simo9713, and welcome.

An 128*64 OLED display is a poor description.
But given the fact that this question has been asked over here for hundreds of times, it's likely you told u8glib that you have a ssd1306 driven display.
Possibly because the Chinese seller told you so.
Try what happens if you tell u8glib that it is a s~~sd~~h1106 instead, it will probably solve the problem.
You could have found that out would you have read the large u8glib thread in this forum.

simo9713:
i just bought a 128X64 oled i2c display but when i try to use it with the u8glib library i have some problems making it work correctly. its like column 0 and 1 are outside the display... if i want to see a pixel on the first column of the display i need to place it in column number 2. its like the image is shifted left by 2 columns, in fact there are 2 columns at hte far right of the screen that display random stuff and can't be modified.

I had a similar problem. It was solved by switching from SSD1306 to SH1106 such that the constructor now is U8G2_SH1106_128X64_NONAME_1_SW_I2C u8g2(U8G2_R0, SCL, SDA, U8X8_PIN_NONE);

(I posted in the U8g2 thread and had help from Oliver The Man.)