Jump to content

OrangePi win plus no Bluetooth adapter?


Maciej Sujecki

Recommended Posts

Hi,

 

I've the same issue on my orange pi win plus.

 

On legacy kernel i get bt working and i've contribute the patches on ap6212-patch but now with 5.3 (v5.3-rc5 vs 5.4  dts from what i can see differs just by ir initialization) mainline kernel it doesn't initialize the bt anymore.

I'm on armbian bionic.


[   18.785676] IPv6: ADDRCONF(NETDEV_CHANGE): wlan0: link becomes ready
[   57.606953] Bluetooth: BNEP (Ethernet Emulation) ver 1.3
[   57.606962] Bluetooth: BNEP filters: protocol multicast
[   57.606981] Bluetooth: BNEP socket layer initialized
[  186.200243] IPv6: ADDRCONF(NETDEV_CHANGE): wlan0: link becomes ready

 

by trying hciattach i just get a timeout.

@jernej: I've seen that you contributed some of the patch for bt, so i suppose you get it working...Could you give an hint on how to fix it?

 

Regards

 

Eddi

 

Link to comment
Share on other sites

My patch for OPi Win BT is already in 5.3 so all you have to do is to place properly named BT FW in appropriate place. This repo has all needed files, but I forget which are really needed. I guess you can put everything in /lib/firmware and try again. hciattach is not needed at all. If that doesn't work, please provide full dmesg log.

Link to comment
Share on other sites

looks like it almost wants to work with 4.x and that firmware.

 

modprobe r8723bs; modprobe hci_uart; modprobe bluetooth; modprobe rfcomm
systemctl restart bluetooth
hciattach -s 1500000 /dev/ttyS1 any bdaddr 43:29:B1:55:01:01

hciconfig -a
hci0:   Type: Primary  Bus: UART
        BD Address: 00:00:00:00:00:00  ACL MTU: 0:0  SCO MTU: 0:0
        DOWN INIT RUNNING
        RX bytes:0 acl:0 sco:0 events:0 errors:0
        TX bytes:12 acl:0 sco:0 commands:3 errors:0
        Features: 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00
        Packet type: DM1 DH1 HV1
        Link policy:
        Link mode: SLAVE ACCEPT

 

hciconfig hci0 up
Can't init device hci0: Connection timed out (110)

Link to comment
Share on other sites

i've copied all firmware from your repository over /lib/firmware/brcm, 

then

 

cp BCM43430A1.vim BCM43430A1.hcd

modprobe hci_uart

systemctl restart bluetooth

 

however I'm not sure the firmware is loaded correctly

 

could your post a working dmesg just to compare it?

 

[   10.228391] cfg80211: Loading compiled-in X.509 certificates for regulatory database
[   10.242721] cfg80211: Loaded X.509 cert 'sforshee: 00b28ddf47aef9cea7'
[   10.459977] random: crng init done
[   10.459990] random: 7 urandom warning(s) missed due to ratelimiting
[   10.461328] brcmfmac: brcmf_fw_alloc_request: using brcm/brcmfmac43430-sdio for chip BCM43430/1
[   10.597875] zram0: detected capacity change from 0 to 52428800
[   10.666844] brcmfmac: brcmf_fw_alloc_request: using brcm/brcmfmac43430-sdio for chip BCM43430/1
[   10.666941] brcmfmac: brcmf_c_process_clm_blob: no clm_blob available (err=-2), device may have limited channels available
[   10.667394] brcmfmac: brcmf_c_preinit_dcmds: Firmware: BCM43430/1 wl0: Oct  8 2016 15:31:47 version 7.46.57.4.ap.r4 (A1 Station/P2P) FWID 01-3621395e es6.c5.n4.a3
[   10.915902] EXT4-fs (zram0): mounted filesystem without journal. Opts: discard
[   17.008015] dwmac-sun8i 1c30000.ethernet eth0: PHY [stmmac-0:01] driver [RTL8211E Gigabit Ethernet]
[   17.008032] dwmac-sun8i 1c30000.ethernet eth0: phy: setting supported 00,00000000,000062ff advertising 00,00000000,000062ff
[   17.011955] dwmac-sun8i 1c30000.ethernet eth0: No Safety Features support found
[   17.011970] dwmac-sun8i 1c30000.ethernet eth0: No MAC Management Counters available
[   17.011977] dwmac-sun8i 1c30000.ethernet eth0: PTP not supported by HW
[   17.011987] dwmac-sun8i 1c30000.ethernet eth0: configuring for phy/rgmii link mode
[   17.012003] dwmac-sun8i 1c30000.ethernet eth0: phylink_mac_config: mode=phy/rgmii/Unknown/Unknown adv=00,00000000,000062ff pause=10 link=0 an=1
[   17.023742] dwmac-sun8i 1c30000.ethernet eth0: phy link down rgmii/Unknown/Unknown
[   18.806751] IPv6: ADDRCONF(NETDEV_CHANGE): wlan0: link becomes ready
[  260.161716] Bluetooth: Core ver 2.22
[  260.161844] NET: Registered protocol family 31
[  260.161847] Bluetooth: HCI device and connection manager initialized
[  260.161868] Bluetooth: HCI socket layer initialized
[  260.161877] Bluetooth: L2CAP socket layer initialized
[  260.161893] Bluetooth: SCO socket layer initialized
[  260.194346] Bluetooth: HCI UART driver ver 2.3
[  260.194356] Bluetooth: HCI UART protocol H4 registered
[  260.194358] Bluetooth: HCI UART protocol BCSP registered
[  260.194406] Bluetooth: HCI UART protocol LL registered
[  260.194409] Bluetooth: HCI UART protocol ATH3K registered
[  260.194439] Bluetooth: HCI UART protocol Three-wire (H5) registered
[  260.194641] Bluetooth: HCI UART protocol Intel registered
[  260.194741] Bluetooth: HCI UART protocol Broadcom registered
[  260.194768] Bluetooth: HCI UART protocol QCA registered
[  260.194771] Bluetooth: HCI UART protocol AG6XX registered
[  260.194800] Bluetooth: HCI UART protocol Marvell registered
[  320.695223] Bluetooth: BNEP (Ethernet Emulation) ver 1.3
[  320.695233] Bluetooth: BNEP filters: protocol multicast
[  320.695254] Bluetooth: BNEP socket layer initialized
 

Eddi

 

PS: I've just installed libreelec nightly and i have bluetooth working but I can't figure out yet what differs

Link to comment
Share on other sites

[  231.171784] r8723bs: module is from the staging directory, the quality is unknown, you have been warned.
[  231.226752] RTL8723BS: module init start
[  231.226761] RTL8723BS: rtl8723bs v4.3.5.5_12290.20140916_BTCOEX20140507-4E40
[  231.226766] RTL8723BS: rtl8723bs BT-Coex version = BTCOEX20140507-4E40
[  231.226840] RTL8723BS: module init ret =0
[  231.308168] Bluetooth: Core ver 2.22
[  231.308277] NET: Registered protocol family 31
[  231.308281] Bluetooth: HCI device and connection manager initialized
[  231.308300] Bluetooth: HCI socket layer initialized
[  231.308309] Bluetooth: L2CAP socket layer initialized
[  231.308339] Bluetooth: SCO socket layer initialized
[  231.342572] Bluetooth: HCI UART driver ver 2.3
[  231.342584] Bluetooth: HCI UART protocol H4 registered
[  231.342588] Bluetooth: HCI UART protocol BCSP registered
[  231.342675] Bluetooth: HCI UART protocol LL registered
[  231.342680] Bluetooth: HCI UART protocol ATH3K registered
[  231.342739] Bluetooth: HCI UART protocol Three-wire (H5) registered
[  231.342989] Bluetooth: HCI UART protocol Intel registered
[  231.343157] Bluetooth: HCI UART protocol Broadcom registered
[  231.343207] Bluetooth: HCI UART protocol QCA registered
[  231.343212] Bluetooth: HCI UART protocol AG6XX registered
[  231.343216] Bluetooth: HCI UART protocol Marvell registered
[  231.371480] Bluetooth: RFCOMM TTY layer initialized
[  231.371501] Bluetooth: RFCOMM socket layer initialized
[  231.371527] Bluetooth: RFCOMM ver 1.11
[  231.530453] Bluetooth: BNEP (Ethernet Emulation) ver 1.3
[  231.530461] Bluetooth: BNEP filters: protocol multicast
[  231.530476] Bluetooth: BNEP socket layer initialized
[  233.543018] Bluetooth: hci0: command 0x1003 tx timeout
[  235.559107] Bluetooth: hci0: command 0x1001 tx timeout
[  237.575212] Bluetooth: hci0: command 0x1009 tx timeout

Link to comment
Share on other sites

I've just noticed that the dtb of libreerec is completly differnt from the dtb i own......I'm going to copy the one from libreelec...

 

didn't solved

 

It seems to me that for some reasons brcm,bcm43438-bt in the dts didn't match the string in hci_bcm.c

Link to comment
Share on other sites

We already have that setting defined on our dtb. I'm not sure we really need that on /boot/armbianEnv.txt. however I've seen that boot.scr may overwrite that so I will give a try asap.

 

That definition on haven't produced anything to me.

 

@t-bob: i think you shouldn't hciattach anymore.

 

modprobe hci_attach should do all the magic

Link to comment
Share on other sites

those details were just things i've read about on this and other forums.

 

some people had luck with using devmem2 and doing echo's to the gpio device.

 

that module doesnt exist for me.

 

hciattach seems to load everything but i'm unable to bring the network up

 

[   63.874269] Bluetooth: hci0: command 0x1003 tx timeout
[   65.890379] Bluetooth: hci0: command 0x1001 tx timeout
[   67.906448] Bluetooth: hci0: command 0x1009 tx timeout

Link to comment
Share on other sites

hi,

by reading /boot/config and double checking with /proc/config.gz:

CONFIG_SERIAL_DEV_BUS=m

CONFIG_BT_HCIUART=m

CONFIG_BT_HCIUART_BCM=y

 

when hci_uart is loaded it load serdev module as well

 

 

I expected to see  CONFIG_SERIAL_DEV_CTRL_TTYPORT=y but is missing...

 

I've tried to add it and i've created a pull request...

Link to comment
Share on other sites

Will see the next nightly build... I doubt to find spare time to setup a build environment... Just the tests take to me too much time.

 

I've already compared armbian config with libreelect config and i've see that entry missing here  while present in libreelec. And kconfig says that if you have a try serial you may need it set to y.. so I'm confident...

Link to comment
Share on other sites

[    8.586642] Adding 1004568k swap on /dev/zram1.  Priority:5 extents:1 across:1004568k SSFS
[    8.609952] brcmfmac: brcmf_fw_alloc_request: using brcm/brcmfmac43430-sdio for chip BCM43430/1
[    8.698664] Bluetooth: HCI UART driver ver 2.3
[    8.698674] Bluetooth: HCI UART protocol H4 registered
[    8.698677] Bluetooth: HCI UART protocol BCSP registered
[    8.698736] Bluetooth: HCI UART protocol LL registered
[    8.698739] Bluetooth: HCI UART protocol ATH3K registered
[    8.698770] Bluetooth: HCI UART protocol Three-wire (H5) registered
[    8.698914] Bluetooth: HCI UART protocol Intel registered
[    8.699026] Bluetooth: HCI UART protocol Broadcom registered
[    8.699064] Bluetooth: HCI UART protocol QCA registered
[    8.699067] Bluetooth: HCI UART protocol AG6XX registered
[    8.699101] Bluetooth: HCI UART protocol Marvell registered
[    8.785335] brcmfmac: brcmf_fw_alloc_request: using brcm/brcmfmac43430-sdio for chip BCM43430/1
[    8.785424] brcmfmac: brcmf_c_process_clm_blob: no clm_blob available (err=-2), device may have limited channels available
[    8.785826] brcmfmac: brcmf_c_preinit_dcmds: Firmware: BCM43430/1 wl0: Oct  8 2016 15:31:47 version 7.46.57.4.ap.r4 (A1 Station/P2P) FWID 01-3621395e es6.c5.n4.a3
[    8.887619] zram0: detected capacity change from 0 to 52428800
[    9.057515] Bluetooth: hci0: BCM: chip id 94
[    9.057901] Bluetooth: hci0: BCM: features 0x2e
[    9.059996] Bluetooth: hci0: BCM43430A1
[    9.060004] Bluetooth: hci0: BCM43430A1 (001.002.009) build 0000
[    9.809864] Bluetooth: hci0: BCM43430A1 (001.002.009) build 0106
 

@jernej great!!

Link to comment
Share on other sites

On 11/29/2019 at 10:46 AM, t-bob said:

in /boot/armbianEnv.txt add these lines.
overlays=uart1
param_uart1_rtscts=1

 

On 11/29/2019 at 10:46 AM, t-bob said:

in /boot/armbianEnv.txt add these lines.
overlays=uart1
param_uart1_rtscts=1

Thank you, it works for me in accessing BT my Banana Pi M2Zero

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...

Important Information

Terms of Use - Privacy Policy - Guidelines