Tuesday, 6 June 2017

RTL8723BS Wifi and BT firmware package for Ubuntu mainline v4.12 kernels

The RTL8723BS wifi module is now in v4.12 release candidates but to get wifi working it is necessary to load the firmware.

I've build a package 'rtl8723bs_4.12.0_amd64.deb' which includes not only the wifi firmware from Bastien Nocera's 'rtl8723bs' GitHub (hadess) but also the bluetooth firmware from Larry Finger's 'rtl8723bs_bt' GitHub (lwfinger).

After downloading it can be installed using the 'dpkg -i' command:

sudo dpkg -i rtl8723bs_4.12.0_amd64.deb

If bluetooth fails to start automatically then it can be started manually with the command:

sudo systemctl start rtl8723bsbt.service

If you find this useful then please donate using the following link http://goo.gl/nXWSGf as everything helps with development costs.

16 comments:

  1. I'm having a torrid time trying to get BT to work with a Click Mini,
    Can you post the source code for this combination, so that I can try to compile for 4.14/4.15 kernel builds?
    Thanks for all your efforts.

    ReplyDelete
    Replies
    1. The source is from 'https://github.com/lwfinger/rtl8723bs_bt' (credited in earlier postings).

      Delete
  2. Thanks. That's what I have already looked at. :-|

    ReplyDelete
  3. Thnks! Its work the wifi, but not the bluetooth

    ReplyDelete
    Replies
    1. Have you tried starting it manually with the command:

      sudo systemctl start rtl8723bsbt.service

      Delete
  4. Hi there. Im having a serious issue with this driver since i cannot install it (thus it was a 2014 driver compiled for the linux 3 kernel...).


    This is the error that im getting after running dpkg -i

    trying to overwrite '/lib/firmware/rtlwifi/rtl8723bs_bt.bin', which is also in package linux-firmware 1.173.3

    ReplyDelete
    Replies
    1. This implies your userland already has the wifi files so you need the bt only deb 'rtl8723bt_4.12.0_amd64.deb' from https://goo.gl/h8WSwX

      Delete
  5. I created my linuxium iso using isorespin.sh -i ubuntu-16.04.6-desktop-amd64.iso --atom and my tablet is Baytrail (Vulcan Challenger II)
    When I do journalctl I see that broadcom bluetooth service daemon failed and so did rtl8723bsbt - I am confused. I can see from dmesg that RTL8723BS chip is there . Any tips for debugging?
    I need the bluetooth by the way so that I can use bluetooth keyboard that comes with the tablet

    ReplyDelete
  6. Here is aditional info I found for my Vulcan Challenger II above

    systemctl status rtl8723bsbt.service
    ● rtl8723bsbt.service - RTL8723BS Bluetooth daemon
    Loaded: loaded (/lib/systemd/system/rtl8723bsbt.service; enabled; vendor preset: enabled)
    Active: failed (Result: exit-code) since Sat 2019-07-13 09:59:59 CDT; 2min 34s ago
    Process: 2363 ExecStart=/usr/sbin/rtk_hciattach -n -s 115200 ttyS4 rtk_h5 (code=exited, status=1/FAILURE)
    Process: 2360 ExecStartPre=/bin/bash -c grep -qm 1 r8723bs /proc/modules (code=exited, status=0/SUCCESS)
    Main PID: 2363 (code=exited, status=1/FAILURE)

    Jul 13 09:59:59 VTA0801S systemd[1]: Starting RTL8723BS Bluetooth daemon...
    Jul 13 09:59:59 VTA0801S systemd[1]: Started RTL8723BS Bluetooth daemon.
    Jul 13 09:59:59 VTA0801S rtk_hciattach[2363]: Can't open serial port: No such file or directory
    Jul 13 09:59:59 VTA0801S rtk_hciattach[2363]: Can't initialize device: No such file or directory
    Jul 13 09:59:59 VTA0801S systemd[1]: rtl8723bsbt.service: Main process exited, code=exited, status=1/FAILUR
    Jul 13 09:59:59 VTA0801S systemd[1]: rtl8723bsbt.service: Unit entered failed state.
    Jul 13 09:59:59 VTA0801S systemd[1]: rtl8723bsbt.service: Failed with result 'exit-code'.

    ReplyDelete
  7. Furthermore

    dmesg|grep tty
    [ 0.000000] console [tty0] enabled
    [ 2.666133] 00:02: ttyS0 at I/O 0x3f8 (irq = 26, base_baud = 115200) is a 16550A
    [ 7.568363] 80860F0A:00: ttyS4 at MMIO 0x50947000 (irq = 16, base_baud = 2764800) is a 16550A
    [ 7.568652] serial serial0: tty port ttyS4 registered
    [ 7.592319] 80860F0A:01: ttyS5 at MMIO 0x5094d000 (irq = 17, base_baud = 2764800) is a 16550A

    However ttyS4 is not there in /dev directory!?

    ReplyDelete
  8. I saw some posts in http://linuxiumcomau.blogspot.com/2018/04/installing-ubuntu-on-new-device-ie.html that suggests there is a fix for this from 2018 but I am not sure if it is fixed in linuxium for ubuntu 16.04 - when I boot from linuxium for ubuntu 18.04 iso it cripples my tablet, also the screen is rotated, so wondering if ubuntu 16.04 can be directly fixed

    ReplyDelete
  9. I tried to rebuild the 16.04 iso (most functioning one for my tablet) using the -u option at the end, but running into Cannot find mainline kernel header...seems something changed in Kernel 5.x that broke the assumptions in your script v8.2.8
    Then I decided to try the same with different versions of 4.x kernels starting with 4.19-rc1 and finally with 4.20.17 I can see bluetooth being recognized, however when I try to pair the keyboard it fails, it's as if the numbers in the PIN that I type are not reaching the tablet!

    ReplyDelete
  10. @pman: You could try editing the /lib/systemd/system/rtl8723bsbt.service service and point to ttyS0 instead of ttyS4 if this is what you dmesg is saying.

    ReplyDelete
    Replies
    1. The '-u' option failed as the Canonical build for amd64 failed (see https://kernel.ubuntu.com/~kernel-ppa/mainline/v5.2/ for example). If you try '-u' now it should work and give you v5.3-rc1.

      Delete