[S905] Device trees

  • kszaq , there is some problem with downloaded file.

    I tried

    dd if=/dev/dtb > /sdcard/dtb.img

    and

    cat /dev/dtb > /sdcard/dtb.img

    but file, downloaded with

    adb pull /sdcard/dtb.img

    has not same file header, not like in your dtb files, if I view it in HEX...

    It also can't be processed with dtc, that was installed on ubuntu with command

    sudo apt-get install device-tree-compiler

    Result is

    dtc -I dtb -O dts -o dts dtb.img

    FATAL ERROR: Blob has incorrect magic number

    and

    boot.img-ramdisk.gz dtb.img env.img extract-dtb.py mmcblk0boot0.img mmcblk0boot1.img mmcblk0rpmb.img split_bootimg.pl

    root@scw-97b47e:/tmp/qqq# fdtdump dtb.img

    /dts-v1/;

    // magic: 0x414d4c5f

    // totalsize: 0x2000000 (33554432)

    // off_dt_struct: 0x3000000

    // off_dt_strings: 0x206d7867

    // off_mem_rsvmap: 0x20202020

    // version: 538976288

    // last_comp_version: 538976288

    // boot_cpuid_phys: 0x31303271

    // size_dt_strings: 0x20202020

    // size_dt_struct: 0x20202020

    Segmentation fault


    My downloaded file is here dtb.img - Google Drive .

    Can you take a loot at him?

    Thank you!

  • kszaq , I found a very strange thing.

    In my extracted dts file there is info

    amlogic-dt-id = "gxm_q201_1g";

    and

    memory@00000000 {

    device_type = "memory";

    linux,usable-memory = <0x0 0x100000 0x0 0x3ff00000>;

    };

    Ie, in /etc/dtb there is file for 1GB RAM version of the TV box, but I have Ultimate version, that has 3GB RAM and Android used 3GB very well.

    How could it be?

    Looks like Android doesn't use that dtb file and developers of Beelink didn't updated DTB file for Ultimate version with 3GB RAM!!! :(

  • ArtUrlWWW Your device uses so-called multi-dtb which means that /dev/dtb consists of a few (usually 2-3) device trees for devices with different RAM amount. A correct device tree is chosen automatically by u-boot.

    I don't understand the reason why you posted blobs from your device. Isn't any of device tree provided working with your device?

  • kszaq , you are right, your gmx_q201_3g.dtb works fine with your libreelec distrib for s912, thank you very much for this distrib.

    Looks, like you have a very good memory - I wrote, that I have successfully started libreelec with gmx_q201_3g.dtb some time ago :) .

    But currently I am trying to start armbian ubuntu-based distrib from balbes150. I know, that it's not your distrib and, possible, not your area, but I trying to ask you only as an expert, not distrib owner.

    Display Spoiler

    The problem is that tv box starting well without any DTB files in BOOT and trying to start X, failed, console only:

    IMG_20171220_215905.jpg


    After that I've rebooted TV box with CTLR+ALT+DEL and got another view:

    Display Spoiler


    IMG_20171220_220728.jpg

    I've tried all files from dtb directory and, as result, TV box booted only with kvim****.dtb files, but the similar boot error.

    With other files from dtb directory TV box didn't booted at all - it hangs on Beelink boot logo.

    Here is my /var/log/ directory from TV box, booted with kvim multiboot dtb - log.zip - Google Drive .

    I also tried to start it with gmx_q201_3g.dtb from your libreelec distrib, but armbian distrib hangs on bootloader Beelink logo too.

    Can you advise me, how to fix such error?

  • OK, I figured out, what is the multi-dtb file :) .

    Here is my a very simple Python 3.3 code for my multi-dtb file parsing:

    It may be useful for somebody in the future, I hope :)

    I plan to test splitted dts files tonight.

  • What is the benefit ?

    To learn and to start Armbian on Beelink GT1 Ultimate.

    I also have done it to check, is kszaq's version of gmx_q201_3g.dtb similar to mine - I'll check for differences those decompiled dts data in text format.

    I couldn't start balbes150's Armbian with kszaq's version of gmx_q201_3g.dtb , so I have a suspicion, that my dtb file could be different from kszaq's version of gmx_q201_3g.dtb . So, I'll check it now.

  • Nope :) . I am in correct thread, because I plan to provide kszaq a new version of gmx_q201_3g.dtb for my TV box.

    Good news, everyone! :)

    My decompiled dts is different from kszaq's gmx_q201_3g.dtb decompiled dts.

    So I have a little hope, that my TV box could start with gmx_q201_3g.dtb, splitted from my multi-DTB file and will work with libreelec and balbes150's Armbian.

    But it just a hope, I'll check it tonight at home :).

    Thank you again for info, kszaq !