Results 1 to 6 of 6

Thread: Bluetooth problem with Pi Zero W - Mac address AA:AA:AA:AA:AA:AA

  1. #1
    Join Date
    2019-Jun
    Posts
    1

    Bluetooth problem with Pi Zero W - Mac address AA:AA:AA:AA:AA:AA

    Hello

    I have a problem with the internal bluetooth controller of my Pi Zero W.
    Mac address is AA:AA:AA:AA:AA:AA !!

    I found this errors in dmesg
    [ 241.354143] bluetooth hci0: Direct firmware load for brcm/BCM43430A1.hcd failed with error -2
    [ 241.354366] Bluetooth: hci0: BCM: Patch brcm/BCM43430A1.hcd not found
    Code:
    ~/ uname -a
    Linux pizerow 4.19.29-Re4son+ #6 Wed Mar 27 17:20:18 AEDT 2019 armv6l GNU/Linux
    Code:
    ~/ lsb_release -a      
    No LSB modules are available.
    Distributor ID:    Kali
    Description:    Kali GNU/Linux Rolling
    Release:    2019.2
    Codename:    n/a
    Code:
    ~/ dmesg | grep -i bluetooth
    [  160.527078] Bluetooth: Core ver 2.22
    [  160.527665] Bluetooth: HCI device and connection manager initialized
    [  160.527891] Bluetooth: HCI socket layer initialized
    [  160.528070] Bluetooth: L2CAP socket layer initialized
    [  160.528336] Bluetooth: SCO socket layer initialized
    [  233.634253] Bluetooth: BNEP (Ethernet Emulation) ver 1.3
    [  233.634443] Bluetooth: BNEP filters: protocol multicast
    [  233.634613] Bluetooth: BNEP socket layer initialized
    [  241.173550] Bluetooth: HCI UART driver ver 2.3
    [  241.173732] Bluetooth: HCI UART protocol H4 registered
    [  241.179135] Bluetooth: HCI UART protocol Three-wire (H5) registered
    [  241.179693] Bluetooth: HCI UART protocol Broadcom registered
    [  241.327446] Bluetooth: hci0: BCM: chip id 94
    [  241.329964] Bluetooth: hci0: BCM: features 0x2e
    [  241.353642] Bluetooth: hci0: BCM43430A1
    [  241.353816] Bluetooth: hci0: BCM43430A1 (001.002.009) build 0000
    [  241.354143] bluetooth hci0: Direct firmware load for brcm/BCM43430A1.hcd failed with error -2
    [  241.354366] Bluetooth: hci0: BCM: Patch brcm/BCM43430A1.hcd not found
    Code:
    ~/ systemctl status bluetooth.service 
    ● bluetooth.service - Bluetooth service
       Loaded: loaded (/lib/systemd/system/bluetooth.service; enabled; vendor preset: disabled)
       Active: active (running) since Mon 2019-06-17 16:49:01 CEST; 26min ago
         Docs: man:bluetoothd(8)
     Main PID: 965 (bluetoothd)
       Status: "Running"
       CGroup: /system.slice/bluetooth.service
               └─965 /usr/lib/bluetooth/bluetoothd
    
    Jun 17 16:49:01 pizerow systemd[1]: Starting Bluetooth service...
    Jun 17 16:49:01 pizerow bluetoothd[965]: Bluetooth daemon 5.50
    Jun 17 16:49:01 pizerow systemd[1]: Started Bluetooth service.
    Jun 17 16:49:01 pizerow bluetoothd[965]: Starting SDP server
    Jun 17 16:49:01 pizerow bluetoothd[965]: Bluetooth management interface 1.14 initialized
    Jun 17 16:49:01 pizerow bluetoothd[965]: Sap driver initialization failed.
    Jun 17 16:49:01 pizerow bluetoothd[965]: sap-server: Operation not permitted (1)
    Code:
    ~/ systemctl status hciuart.service 
     hciuart.service - Configure Bluetooth Modems connected by UART
       Loaded: loaded (/lib/systemd/system/hciuart.service; disabled; vendor preset: disabled)
       Active: active (running) since Mon 2019-06-17 15:23:44 CEST; 1h 52min ago
     Main PID: 551 (btattach)
       CGroup: /system.slice/hciuart.service
               └─551 /usr/bin/btattach -B /dev/ttyAMA0 -P bcm -S 3000000
    
    Jun 17 15:23:44 pizerow systemd[1]: Starting Configure Bluetooth Modems connected by UART...
    Jun 17 15:23:44 pizerow systemd[1]: Started Configure Bluetooth Modems connected by UART.
    Code:
    ~/ hciconfig                         
    hci0:    Type: Primary  Bus: UART
        BD Address: AA:AA:AA:AA:AA:AA  ACL MTU: 1021:8  SCO MTU: 64:1
        UP RUNNING 
        RX bytes:1366 acl:0 sco:0 events:59 errors:0
        TX bytes:2294 acl:0 sco:0 commands:57 errors:0

    Code:
    ~/ bluetoothctl 
    [bluetooth]# list
    Controller AA:AA:AA:AA:AA:AA pizerow [default]
    Code:
    [bluetooth]# show           
    Controller AA:AA:AA:AA:AA:AA (public)
        Name: pizerow
        Alias: pizerow
        Class: 0x00000000
        Powered: yes
        Discoverable: no
        Pairable: yes
        UUID: Generic Attribute Profile (00001801-0000-1000-8000-00805f9b34fb)
        UUID: A/V Remote Control        (0000110e-0000-1000-8000-00805f9b34fb)
        UUID: PnP Information           (00001200-0000-1000-8000-00805f9b34fb)
        UUID: A/V Remote Control Target (0000110c-0000-1000-8000-00805f9b34fb)
        UUID: Generic Access Profile    (00001800-0000-1000-8000-00805f9b34fb)
        Modalias: usb:v1D6Bp0246d0532
        Discovering: no
    Code:
    ~/ lsmod | grep -i blue
    bluetooth             395415  24 hci_uart,bnep,btbcm
    ecdh_generic           20083  2 bluetooth
    rfkill                 23237  7 bluetooth,cfg80211
    Code:
    ~/ hcitool scan
    Scanning ...
    Scan found nothing.

    What can I do ?

  2. #2
    Join Date
    2019-Aug
    Posts
    2
    Got same problem on my RPi 3b+, the address of bluetooth module is all 00:00, the scan don't working. I guess, the internal bluetooth module is just not compatible with kali linux.

  3. #3
    Join Date
    2019-Aug
    Location
    Russia, Moscow
    Posts
    5
    Seems that BCM43430A1.hcd firmware file is missing in some of this packages packages:

    Code:
    kalipi-re4son-firmware
    bluez-firmware
    pi-bluetooth+re4son
    You can download it manually and place into /lib/firmware/brcm/BCM43430A1.hcd

    Code:
    wget https://github.com/RPi-Distro/bluez-firmware/blob/master/broadcom/BCM43430A1.hcd -O /lib/firmware/brcm/BCM43430A1.hcd
    but this still not resolving the issue. I'm not sure what actually wrong.
    You can check the another image Kali Linux RPi0w Nexmon P4wnp1 Aloa where bluetooth works correctly and look what is missing.

  4. #4
    Join Date
    2019-Aug
    Location
    Russia, Moscow
    Posts
    5
    I've tried Kali Linux RPi0w Nexmon P4wnp1 Aloa and bluetooth works correctly:

    Code:
    # lsb_release -a
    No LSB modules are available.
    Distributor ID: Kali
    Description:    Kali GNU/Linux Rolling
    Release:        2019.2
    Codename:       n/a
    
    # uname -a 
    uname -a
    Linux kali 4.14.80-Re4son+ #1 Fri May 17 20:25:41 UTC 2019 armv6l GNU/Linux

    Code:
    # hciconfig
    hci0:   Type: Primary  Bus: UART
            BD Address: B8:27:EB:42:A0:D2  ACL MTU: 1021:8  SCO MTU: 64:1
            UP RUNNING PSCAN
            RX bytes:2317 acl:0 sco:0 events:230 errors:0
            TX bytes:38705 acl:0 sco:0 commands:230 errors:0
    Code:
    # hcitool scan
    Scanning ...
            18:CF:5E:A4:A6:D3       WS088
            9C:5C:F9:B8:CE:50       hello
            90:F0:52:8A:F0:A1       MEIZU 16
    Only one build script in kali-arm repo rpi0w-nexmon-p4wnp1-aloa.sh have manage the bluetooth firmware file:

    Code:
    rpi0w-nexmon-p4wnp1-aloa.sh line 519:
    
    
    cp "${basedir}"/../misc/brcm/BCM43430A1.hcd "${basedir}"/kali-${architecture}/lib/firmware/brcm/BCM43430A1.hcd
    This probably a bug, cause all list images for raspberry pi zero W and 3b should have this file.
    Last edited by zhovner; 2019-08-30 at 15:25.

  5. #5
    Join Date
    2019-Aug
    Location
    Russia, Moscow
    Posts
    5
    I've put bluetooth firmware file BCM43430A1.hcd into kali-linux-2019.2-rpi0w-nexmon.img image and get this. As you can see, btattach correctly enumerates bluetooth device but after we get timeout and hciconfig shows bluetooth device with zeroes MAC address and scans not working.

    Code:
    # uname -a
    Linux kali 4.19.55-Re4son+ #1 Tue Jul 2 18:44:01 AEST 2019 armv6l GNU/Linux
    
    
    # zcat /proc/config.gz | grep -E "CONFIG_BT_HCIUART_SERDEV|CONFIG_SERIAL_DEV_BUS|CONFIG_BT_HCIUART_BCM"
    CONFIG_BT_HCIUART_SERDEV=y
    CONFIG_BT_HCIUART_BCM=y
    CONFIG_SERIAL_DEV_BUS=m
    
    
    # lsmod | grep serdev
    serdev                 11120  1 hci_uart
    
    
    ### Try to execute hciuart.service step by step
    
    # cat /proc/device-tree/aliases/uart0
    /soc/serial@7e201000
    
    # cat /proc/device-tree/aliases/serial1
    /soc/serial@7e201000
    
    # wc -c /proc/device-tree/soc/gpio@7e200000/uart0_pins/brcm\,pins | cut -f 1 -d ' '
    16
    
    # /usr/bin/btattach -B /dev/ttyAMA0 -P bcm -S 3000000
    [ 1032.533166] uart-pl011 20201000.serial: no DMA platform data
    [ 1032.643665] Bluetooth: Core ver 2.22
    [ 1032.647491] NET: Registered protocol family 31
    [ 1032.652143] Bluetooth: HCI device and connection manager initialized
    [ 1032.668647] Bluetooth: HCI socket layer initialized
    [ 1032.673656] Bluetooth: L2CAP socket layer initialized
    [ 1032.681544] Bluetooth: SCO socket layer initialized
    [ 1032.710625] Bluetooth: HCI UART driver ver 2.3
    [ 1032.715177] Bluetooth: HCI UART protocol H4 registered
    [ 1032.736370] Bluetooth: HCI UART protocol Three-wire (H5) registered
    [ 1032.752477] Bluetooth: HCI UART protocol Broadcom registered
    [ 1032.902736] Bluetooth: hci0: BCM: chip id 94
    [ 1032.910252] Bluetooth: hci0: BCM: features 0x2e
    [ 1032.938542] Bluetooth: hci0: BCM43430A1
    [ 1032.942489] Bluetooth: hci0: BCM43430A1 (001.002.009) build 0000
    [ 1035.048197] Bluetooth: hci0: command 0x0a0a tx timeout
    [ 1043.048223] Bluetooth: hci0: BCM: Patch command 0a0a failed (-110)
    
    # hciconfig
    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:7 acl:0 sco:0 events:1 errors:0
            TX bytes:8 acl:0 sco:0 commands:2 errors:0
            
    # hciconfig hci0 up
    [ 1704.170543] Bluetooth: hci0: command 0x1001 tx timeout

  6. #6
    Join Date
    2019-Aug
    Location
    Russia, Moscow
    Posts
    5
    I've build a new image with bluetooth fix:

    https://zhovner.com/tmp/kali-linux-n...0-04-54.img.xz

    Just enable hciuart service after boot:

    Code:
    systemctl enable --now  hciuart

Similar Threads

  1. Replies: 0
    Last Post: 2014-03-09, 23:13

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •