Odroid N2 OLED I2C / SPI driver

What exactly is “CoreELEC clone directory”?

Running that command from an SSH session gives

-sh: ./build.CoreELEC-Amlogic-ng.arm-9.2-devel/toolchain/bin/armv8a-libreelec-linux-gnueabi-gcc: not found

I guess you have to install git and clone the CE source first to your local directory.

Yep, I’m really confused… Even if I cloned the CE source there is no build.CoreELEC-Amlogic-ng.arm-9.2-devel directory, not that it would matter as I’m on Windows anyway :frowning:

When you have a CoreELEC build environment you easily can compile such tools.
You should be able to compile it also on windows by cross compile for aarch64. I am sure you will get some hints on Google.

Unfortunately I don’t have access to a CoreELEC build environment :frowning:

I’ve have managed to get access to a logic analyser and can confirm that valid SPI data is being sent out of the N2’s SPI interface.

Now I just need to compare it to the data being sent from my working arduino code to see if there is any difference and try to figure out why the arduino can drive the display but the N2 can’t.

These screens support a maximum SPI clock of 10MHz, IIRC. Check what the SPI clock is set to on the N2.

I’ve tried various SPI clock speeds on the N2 with no luck. The Arduino UNO has a max SPI speed of I think 8MHz and I’ve tested it between 0.5MHz and 8MHz and it works fine.

As I said I’ve gotten access to a logic analyser so once I get some free time at the weekend I’ll capture the data from both the Arduino and the N2 and compare them. I’m guessing it’s just some simple timing issue.

1 Like

It’s possible that high/low logic is inverted. But you will see it with your logic analyser.

@roidy I’m currently using my epaper (it has reset,dc,cs,dat,clk,bsy pins) display with Le Potato running on an earlier NG build using SPI and it works fine, so I’m not sure what the problem you’re experiencing is.
Do you have the 2 GPIO pins hooked up? You need reset & dc connected and mapped correctly?

Yep, I’m using 2 GPIO pins, one for reset and one for D/C. I don’t think it’s a problem with the N2’s SPI interface or the Python SPI library I’m using as after a quick test with a logic analyser I’m getting valid SPI data out of the N2.

It will be something really simple like an error with my code or maybe a timing issue but I wont be able to have a proper look until I get some free time at the weekend.

1 Like

So yep… It was a simple error when I copied the arduino code to python, one byte of the display initialisation data was wrong :man_facepalming:

It now works

1 Like

This is awsome :+1: :+1: :+1:
How much do you actually have to change in the system to get it to work?

You just need to active SPI on the N2 using:-

mount -o remount,rw /flash
fdtput -t s /flash/dtb.img /soc/cbus@ffd00000/spi@13000/spidev@0 status "okay"
fdtput -t s /flash/dtb.img /soc/cbus@ffd00000/spi@13000 status "okay"
reboot
1 Like

Add-on has now been updated to support the 2.42" SPI displays. Full connection information is in the README.md on github, link in the first post.

1 Like

At the moment spi does work only on the nightlies rigt?

No, it should be already in 9.2.3 stable.

1 Like

I can confirm, spi also works with the aliexpress display on 9.2.3 stable :+1:
@roidy is there any chance to get HDR10+ shown when a file with HDR10+ is played?

1 Like

Is HDR10+ detected when you press o to bring up the player process information?

Do you have a small HDR10+ sample I could test with?

Unfortunately not. I also don’t know why the screenshot destroys the paused video.

I couldn’t find a demo video with HDR10+ but I have a sample of around 500Mb.
Would a google drive link be okay for you to download?

Sorry I should of said you need to be using a skin that supports the amlogic displayinfo script like the default Estuary skin.

H265 video always does that when you try to screen shot it.

1 Like