Jump to content

Recommended Posts

Posted

I am digging in my orangipi board (OPi Zero H2+) again, and have come across some questions relating to device tree overlay.

 

Eventually, aim is to activate a hardware component of my board, and I think I have the right option found. Problems are currently with compiling and applying the overlay.

 

From the basics upwards:

 

1. Is there a way to know which overlay (of the many listed in /boot/dtb/*) is actually used during boot process? For example, I know I have a board with a H2+ soc, but my armbianEnv.txt says "overlay_prefix=sun8i-h3". In any case, even this prefix cannot be the full information, since in /boot/dtb/ there are overlays for 18 different sun8i-h3 boards. Clearly, uname only refers to the kernel, i.e. does not state the board.

 

2. My immediately latest challenge was then to compile an overlay fragment. I followed instructions from [1],

but (upon other errors) got a Syntax error from a "dtc -I dts -O dtb .." call. I used an overlay along the lines of [2]. Posting the code in follow up.

 

Thanks for help.

 

[1] https://docs.armbian.com/User-Guide_Allwinner_overlays/

 

[2] https://github.com/armbian/sunxi-DT-overlays/blob/master/examples

 

Posted

Ok, an answer to the first question is using the uboot prompt:

 

At that, use "env print" and find the fdtfile variable.

 

Posted

There is easier approach. This below is common for all H2/H3 boards but not all boards have easy access to all functions.

 

armbian-config -> system -> hardware

 

There (armbian-config) is also full featured DTB editor in there for advanced hacking which automatically decompile / compile device tree blob.

 

hwconfig.png

Posted

Hello Igor,

 

with the knowledge of the correct "base" overlay file, I ventured into directly editing this (dts) file and recompiling that worked (as has it worked already months ago).

 

This hurdle was thus in fact overcome (I guess the now built-in DT editor in armbian-config does this decompiling and compiling as well.). I leave the route using the user overlays for now.

 

The actual issue was to get the micro-USB port to work, and this - inspite of the above - is still not yet resolved. I'll post it in a separate topic.

 

 

 

Guest
This topic is now closed to further replies.
×
×
  • Create New...

Important Information

Terms of Use - Privacy Policy - Guidelines