DietPi Orange Pi Zero SSD1306 instantly clearing

I have no idea where to start looking for this.

I have installed DietPi and the luma drivers for an SSD1306 - https://luma-oled.readthedocs.io/en/latest/hardware.html
I have also installed WiringOP which works for Orange Pi.

So firstly - i2cDetect does not appear… I think that might be more to do with WiringOP but if anyone knows differently do let me know.

Anyway I installed an SSD12306 display and pullup resistors (all known to work perfectly). I tried the I2c demo for the display, changing the device to 0 from 1. The two demo lines show a rectangle and “hello world”

Except that they don’t - most of the rectangle appears, the text sometimes appears but instantly they both go black again. I can do this time and time again and the display time before going black is a tiny fraction of a second.

I tried obvious things - I went to /boot/config.text and it says that I2c is off - that can’t be right or I would not get anything remotely like a rectangle or text drawing correctly even if they do disappear instantly. But if I change the OFF status for I2c to ON or change the speed - on reboot the file reverts to it’s original setting - is there another file I should be altering instead??

That’s my only clue up to now as to why this is “almost” working. Any help apprecaited… this same code works on other hardware.

Hi,

/boot/config.txt is for the Raspberry Pi only. It will have no effect on OPi Zero. We leave this file in all images, because it reduces the sourcecode checks we need to run on files.

on reboot the file reverts to it’s original setting

You need to edit the file on the RAMdisk location:

/DietPi/config.txt

Although, as above, this will have no impact on OPi Zero.

is there another file I should be altering instead??

There is a file /boot/armbianEnv.txt, which you can use to set kernel runtime options. As for what you’ll need with regards to I2C, outside my knowledge.