Skip to content

A small project to make overlays work, and then to apply one to enable the edp

Notifications You must be signed in to change notification settings

EricaLinaG/armbian-boot-edp-overlay

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Armbian boot with edp device tree overlay.

Turn an armbian media iso into a full uboot so that dts overlays work. Then apply an eDP overlay to get the eDP touchscreen working.

This is being tested and used on a Friendly Elec nanopc-t4 running Armbian Jammy which is a -media distribution and does not support dts overlays out of the box. The goal has been to get the Friendly Elec K116e eDP display panel to work with mainline linux/Armbian.

This is working! For the DTS overlay go here. [https://github.com/iamdrq/panel-edp-friendlyelec] (https://github.com/iamdrq/panel-edp-friendlyelec)

A Makefile and some files.

This is really a Makefile with a some rules and dependencies to document and automate the steps that I have done to my nanopc-t4.

You can read about it here, but the guts are in the Makefile.

If you dont want to read, and you know what you want you can just pull the trigger and make all. If you like to go slow, read this, read the Makefile, look at your /boot/. Maybe do one make rule at a time so you can watch every step.

Note: This is still not quite working. The eDP panel I have is the K116E from Friendy Elec the K116E is supported in 4.4 Friendly Elec Lubuntu, but not 5.x and 6.x.

These first two dts files will result in a lit, but blank screen. (60hz the problem?)

The first two dts files edp.dts1, and 2, Do work for an edp panel which matches this one,

LG or lp079qx1-sp0v is a 7.9" display at 2048x1536 which is used in the ipad mini.

[Find a working dts overlay for the K116e here.] (https://github.com/iamdrq/panel-edp-friendlyelec)

Copy the dts file that you desire here to edp.dts and follow the directions below. Or just do the make install step here and do the overlay yourself with

armbian-add-overlay <whatever>.dts

The process

Basically, create armbianEnv.txt and boot.scr then put them and boot.cmd in /boot/. Move /boot/extlinux out of the way. Then apply a device tree overlay.

Files

  • boot.cmd - This is the boot script we turn into boot.scr.
  • armbianEnvOrig - This is a minimal version that we start with.
  • armbianEnv - This is the configuration data for boot.cmd.
  • edp.dts1,2 - These are the edp device tree overlays. Chronological.
  • edp.dts - The current edp device tree overlay.

The Steps applied here.

  • Put the root device UUID into armbianEnv.txt
    • Make sure there are no spaces around '='.
  • Build boot.scr from boot.cmd with mkimage
    • This is shadowed by extlinux which must be moved.
  • Move /boot/extlinux to /boot/_extlinux.
  • Copy all three files to /boot/.
  • Apply the edp.dts overlay.
    • Requires that armbianEnv.txt and boot.cmd are in /boot/.
    • Modifies /boot/armbianEnv.txt,
  • Reboot when ready.

Make commands

The overlay is the last step as it will not work until there is boot.cmd and armbianEnv.txt in /boot/.

Applying an overlay with armbian-add-overlay will modify /boot/armbianEnv.txt. This step will not work at all if files are missing.

There are smaller make targets, but these should do it.

  • make all -- does it all.

    • install : Set up /boot/ for dts overlays.
    • edp-overlay : Apply the overlay for subsequent boots.
  • make install -- Just the /boot/ setup.

    • show-uuid: Show the root device UUID as detected.
    • set-rootdev-uuid: Make an armbianEnv.txt with the root device uuid.
    • boot-scr: Use mkimage to create boot.scr from boot.cmd.
    • install-boot: Copy armbianEnv.txt, boot.cmd and boot.scr to /boot/.
    • extlinux-out: Move extlinux out of the way.
  • make edp-overlay

    • Compile and install the edp.dts overlay to /boot/ with armbian-add-overlay.

Read the Makefile for more.

Conclusion

This is fairly straightforward, but we have had some problems, I think mostly my mistakes. And I am just learning a lot of this and trying to follow the instructions I'm being given. For which I am very thankful.

This seems like a good way to document this and help it be repeatable.

Most of this is to get dts overlays working for a -media Armbian distribution which does not support dts overlays. In my case this is Armbian 'Jammy' for a FriendlyElec nanopc-t4.

The second part is that the screen I have, the FriendlyElec K116E, an 11.6", 1920x1084 touchscreen is not supported in the mainline kernel. Thanks to iamdrq this is now working.

Resources

[Find a working dts overlay for the K116e here.] (https://github.com/iamdrq/panel-edp-friendlyelec)

Device trees keep coming up so it must be time to learn them for real.

Heres the doc for touchscreen parameters. The the K116e has inverted x and y.

[device tree touchscreen properties] (https://github.com/torvalds/linux/blob/master/Documentation/devicetree/bindings/input/touchscreen/touchscreen.yaml)

Just device trees in general.

About

A small project to make overlays work, and then to apply one to enable the edp

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published