[9.0.0] LibreELEC builds for MX2/G18

  • LibreELEC-AML 9.2.8.8 (built 2nd March 2023) update for the Matricom G-Box MX/MX2 (AML8276-MX HD18 board)

    See post #341 for instructions on how to clean install, otherwise update as normal through copying to .update

    qUE_ARM
    January 23, 2023 at 7:29 PM

    Main fix I've added in this build is for the freezing on h264 (high) streams being interrupted by seeking or stop (which effects the Kodi BBC iPlayer add-on).

    Credit goes to dtech for maintaining and supporting this fork of LibreELEC.

    Update archive (copy to .update, as per instructions on first page);

    [link expired]

    Projects archive (for building LibreELEC-AML yourself, again see post #341);

    [link expired]


    Links will be solidified and updated once I've run it on my STB box for a while without issue, for now grab it while you can.

    qUE

    Edited once, last by qUE_ARM (November 30, 2023 at 2:01 PM).

  • LibreELEC-AML 9.2.8.8 (built 2nd March 2023) update for the Matricom G-Box MX/MX2 (AML8276-MX HD18 board)

    ...

    qUE

    Thanks for your work. Unfortunately after applying this update using the .update folder method, my g18ref reboots into recovery.

    I was using the latest 9.0 devel, but the same thing happens when updating from LibreELEC-Amlogic_MX2.arm-8.0.2-update.zip

    The same thing also happens when following post #341 of reloading matricom_g18_1.2.zip, updating uboot, and loading LibreELEC-Amlogic_MX2.arm-7.95.3.zip, before updating to LibreELEC-Amlogic_MX2.arm-9.2.8.8-20230802.tar

    LibreELEC-Amlogic_MX2.arm-9.2.8.8-20230802.tar Doesn't seem to work for me. It extracts and installs fine, but wont boot into LibreElec, only recovery. Any ideas?

    I got it to boot by replacing KERNEL and KERNEL.md5 with ones from LibreELEC-Amlogic_MX2.arm-9.0-devel-20190424160004-aca1ab5.tar, but would prefer to use your kernel if possible

    Edited 4 times, last by fragtion (May 23, 2023 at 1:24 AM).

  • Thanks for your work. Unfortunately after applying this update using the .update folder method, my g18ref reboots into recovery.

    I was using the latest 9.0 devel, but the same thing happens when updating from LibreELEC-Amlogic_MX2.arm-8.0.2-update.zip

    The same thing also happens when following post #341 of reloading matricom_g18_1.2.zip, updating uboot, and loading LibreELEC-Amlogic_MX2.arm-7.95.3.zip, before updating to LibreELEC-Amlogic_MX2.arm-9.2.8.8-20230802.tar

    LibreELEC-Amlogic_MX2.arm-9.2.8.8-20230802.tar Doesn't seem to work for me. It extracts and installs fine, but wont boot into LibreElec, only recovery. Any ideas?

    I got it to boot by replacing KERNEL and KERNEL.md5 with ones from LibreELEC-Amlogic_MX2.arm-9.0-devel-20190424160004-aca1ab5.tar, but would prefer to use your kernel if possible

    Sounds like you need to apply the u-boot environment patch, the kernel load bit in the boot script will crop the binary being loaded into memory if the patch hasn't been applied. see this post; RE: [9.0.0] LibreELEC builds for MX2/G18

  • Greetings, I can’t apply the u-boot patch, can I somehow check whether it worked or not, is there another way to install the patch?

    Unfortunately there isn't a simple way to verify the patch has taken, it's a blind patch. The only way you can actually see the environment variables in u-boot is to solder to the jtag pads on the board and use a FTDI cable with a serial terminal utility like putty, at that point printenv lists the set environment at the prompt.

    TBH, if you have a working version of libreelec installed (i.e. 7.95), and the toothpick AV boot with SD inserted, arrives at the recovery, it means it's definitely booted from the SD and the patch should have applied.

    I should mention the next boot should a normal one, not another toothpick AV boot, otherwise you're just re-applying the patch.

    It's really important the environment is changed, it won't effect any older version from booting, but not applying it will prevent any newer builds working. It's a massive short sight of the stock firmware that OS kernel sizes wouldn't exceed 1MB.

    Little bit of detail on what is modified;

    The environment variable that is changed is 'nandboot'. Basically where it loads the kernel is changed to 'nand read boot \${loadaddr} 0 800000' in it's sub-script. As you can see 0x800000 = 8MB, where as that would've been 0x100000 before the patch.

    I would've added some kind of notice (text/screen) it's been applied if I could, but u-boot's capabilities are very very basic. So not possible.

    To re-iterate what needs to be done to patch, unpack aml_autoscript from aml_autoscript.zip to a blank SD and toothpick AV boot with the SD inserted in the STB.

    Edit: I should also note, this will only work for NAND booting, I've not messed about with the SD boot side as to be cautious not to mess that up.

    Edited once, last by qUE_ARM: Caveat (July 22, 2023 at 12:46 AM).

  • Can i use it on a TV box that now has android 4.2.2? (its called doping box)
    It is the MBX reference motherboard q18ref

    If yes i can use it, can i use it using the usb and not install it on the internal storage;

    Also, i have not idea how can i install or boot a different operating system from usb or external sd card on a tv box, is there somewhere a guide how to for that box? Or someone can provide me a guide step by step to boot and use LibreELEC from USB?

    Screenshot of the device model/specs:

  • If the board/chipset is the same it may work, but the problem you have is the supporting peripheral chips like wired and wireless networking may be different, so you'll find those functions not working.

    The box I have was an Android box and has an MX logo on the top, but I'm using MX2 firmware.

    I'm not sure the boot process supports USB booting, SD booting is definitely supported, but like I said the modifications (based on work in this thread) I've made to get LibreElec-AML working do not touch the SD booting side and it'll likely still truncate the kernel binary load and then fail to boot.

    Afaik, none of the images on this thread modify the u-boot bootloader, so theoretically you'll be safe from bricking the box. It's only if you run an official MX/MX2 bootloader mod script it'll break u-boot (which I have done), but as long as you can access the "JTAG" serial console it is reversible. I would just stick to trying Libreelec images and seeing what boots.

    As long as you have the original firmware to roll back your box, it's worth trying images. Flashing the NAND (flash) isn't as destructive as I've heard several other places rant about. An SD will fail quicker than internal NAND, besides the NAND (flash) will get battered by any streaming you do anyway when it's used as cache by linux, so you have to accept it's wear either way.

  • I've made a change to the order of the actions to install Libreelec-AML in post RE: [9.0.0] LibreELEC builds for MX2/G18, I hadn't noticed 7.95 resets the u-boot environment. Patching should come post the 7.95 install. Sorry if this has caused any confusion. Basically, if libreelec keeps going to recovery, try patching the u-boot environment as it's likely the kernel load truncation issue.

  • Thank you for the updated instructions. Now the uboot patching worked!

    I've used your patched project to build an updated LibreELEC-AML v9.2.8.14 (Kodi v18.9 Leia), along with embedded addons inputstream.adaptive and inputstream.rtmp, and pvr.iptvsimple, which are required for many adaptive/widevine streaming plugins. It's working well😊

    The update image can be found here https://drive.google.com/drive/folders/…lDk?usp=sharing

    Edited 9 times, last by fragtion (June 7, 2024 at 5:07 PM).

  • Updated link for LibreELEC-AML 9.2.8.14 (built on 2024-06-06);


    https://www.sendspace.com/file/uncvg5


    and for those of you wanting to build LibreELEC-AML yourself, the connman dependency is broken so the package.mk is attached to fix it. It should be copied to /packages/network/connman

    The link is down, anyway you could reupload?

    I want to to follow you're guide but I have also have the q18ref model, not the MX2. If I follow the original guide and install version 9.0.0, can I still use your files to update or will I need a fresh install? Also, are there any guides for backing up my firmware incase my device gets bricked.

  • The link is down, anyway you could reupload?

    I want to to follow you're guide but I have also have the q18ref model, not the MX2. If I follow the original guide and install version 9.0.0, can I still use your files to update or will I need a fresh install? Also, are there any guides for backing up my firmware incase my device gets bricked.

    Updated zip containing LibreELEC-AML 9.2.8.16 and inputstream adaptive addon (for youtube)

    https://www.sendspace.com/file/ywr8f3


    Summary of what you need to do;

    Fresh install version 7.95 with 'toothpick AV port' boot.

    reboot

    'toothpick AV boot' the U-Boot environment patch, this will NOT show any 'patch done' just go to recovery menu (this is absolutely needed to update to the newest LibreELEC), you will only know if the patch hasn't taken when the latest LibreELEC refuses to boot, just redo the patch if this is the case.

    reboot

    SSH in to LibreELEC and label the data partition to LIBREELEC_DISK (again must be done for the newest LibreELEC)

    copy the latest update .tar file to /storage/.update

    reboot


    As for the unlikely brick, you can only nearly brick the box by installing a version of a U-Boot binary that isn't compatible (not ARM or wrong ARM build). This can be reversed with an FTDI cable soldered to the jtag pads on the Amlogic board and by factory booting u-boot on an SD to manually patch the NAND with a working U-Boot. But you won't need to do any of this if you stick to the versions posted here.

    The other thing that seems like a brick would be if you break the U-Boot environment (which will likely result in recovery menu), but that can easily be reversed by just reinstalling everything the same way as shown here.


    Download links only stay up for 30 days, so grab it while you can.

  • Updated zip containing LibreELEC-AML 9.2.8.16 and inputstream adaptive addon (for youtube)

    Feel free to use my WeTek_Play binary repository from my server, you just need to change the end of the file in your projects/Amlogic_MX2/options source:

    Code
      # Addon Server Url
        ADDON_SERVER_URL="http://libreelec.dtech.hu/packages"
    
      # set the addon dirs
        ADDON_PATH="$ADDON_VERSION/WeTek_Play/$TARGET_ARCH"
        ADDON_URL="$ADDON_SERVER_URL/$ADDON_PATH"

    The inputstream.adaptive addon that you attached to the update file is already there... ;)