Assistance required recompiling LibreELEC with rtl88x2bu driver

  • Hi everybody

    I have been using LibreElec for quite some time and the vanilla install has always been perfect for me. But I am building a new box for my daughter and with the box connected using ethernet everything is wonderful. However, she has an cheap USB Wifi adapter (RTL88x2BU) which is not supported. Being rather scrooge-like rather than buy her a new USB Adadpter I thought I would have a go at building the module myself.

    First off on one of my servers (Ubuntu 20.04 LTS) to get some proof that this approach was going to work I cloned GitHub - cilynx/rtl88x2bu: rtl88x2bu driver updated for current kernels.

    Then I used dkms to add, build and install the module and finally ran a modprobe rtl88x2bu. Plugged in the USB Adapter and hey-presto I have a working Wireless Adapter on my server

    This small success set me off an a number of abortive attempts to build LibreElec locally but after a few attempts I now have an Ubuntu 18.04 LTS VirtualBox that will cleanly build Libreleec 9.2 Generic x86_64 and I have tested this by installing on my daughters machine and all is fine and dandy with the Ethernet connection.

    Small steps being the watch word I then followed one of the thread on this forum to try to build an rtl88x2bu module. Under ~/http://LibreELEC.tv/packages/ I created a folder RTL88x2BU and in that folder created a package.mk containing the following


    I edited distributions/LibreELEC/options and added the new driver
    ADDITIONAL_DRIVERS="RTL8192CU RTL8192DU RTL8192EU RTL8188EU RTL8812AU RTL88x2BU"

    I then rebuilt the LibreElec using "PROJECT=Generic ARCH=x86_64 make image" which threw no errors and when it had completed I had a number of files under ~/http://LibreELEC.tv/build.LibreELEC-Generic.x86_64-9.2-devel/RTL88x2BU-439c7dbd9e43acd91d5704a50b68647716c52505 including a 88x2bu.ko

    I then burned the new img file to USB and installed LibreElec as normal

    Sadly, plugging in the USB Adapter had no effect and no Wifi connections are showing

    As far as I can see there are no new modules under /lib/modules/5.1.16 (there are five RTL folders but they were there previously)

    I have obviously missed or mucked up something but for the life of me cannot see what

    Any assistance would be most appreciated

    Regards

    Paul

  • Nothing obvious. Did you install the correct image?

    To avoid a new installation just drop the new img to /storage/.update or use the "Update" samba share and reboot.

  • Hi mglae

    Just to be on the safe side I purged the target folder and rebuilt LibreElec using "PROJECT=Generic ARCH=x86_64 make image"

    I dropped the new LibreELEC-Generic.x86_64-9.2-devel-20210726153154-5d0330e.img.gz into the update folder (thanks for that, I would have been clean installing if not for the advice) but nothing seems to have changed. I was expecting to see my new module in /usr/lib/modules/5.1.16 but all I have there is

  • Hi all

    OK I seem to have moved on a bit, just thought I would update to save anyone wasting any time until I hit any other issues of course

    I had updated distributions/LibreELEC/options and added the new driver

    ADDITIONAL_DRIVERS="RTL8192CU RTL8192DU RTL8192EU RTL8188EU RTL8812AU RTL88x2BU"

    It would seem that I have to do that in projects/Generic/options either as well or instead of.

    Having rebuilt and updated my LibreElec I can now see the module in /usr/lib/modules/5.1.16/ (RTL88x2BU) and the wireless network is now available in the LibreElec GUI

    I'll let you know how it goes

    Thanks for your help

    Regards

    Paul

  • Morning all

    24 hours on and everything seems to be rock solid. Getting between 80 and 120Mbps download and 30-40Mbps upload speed through the RTL88x2BU driver. No disconnects. Streaming from a remote source seems perfect

    Thanks for the assistance

    Regards

    Paul