We have upgraded the community system as part of the upgrade a password reset is required for all users before login in.

bluetoothctl Omega2Plsu



  • @UFD said in bluetoothctl Omega2Plsu:

    bluez-daemon

    I’ve been sitting on this for 2 days. Thank you for writing. I did not find (bluez-daemon) in the (opkg list) I also deleted (bluez) several times



  • @UFD BusyBox v1.28.3 () built-in shell (ash)


    / __ ___ ()__ ___ / __ _ _ ___ ___ ____ _
    / // / _ / / _ / _ \ / // / ' / -) _ / _ /
    _
    /////___//// _////_/_, /_,/
    W H A T W I L L Y O U I N V E N T ? /
    __/

    Ω-ware: 0.3.2 b233

    Your JFFS2-partition seems full and overlayfs is mounted read-only.
    Please try to remove files from /overlay/upper/... and reboot!
    root@Omega-318B:~#
    root@Omega-318B:~# hciconfig -a
    hci0: Type: Primary Bus: USB
    BD Address: 5C:F3:70:97:79:F8 ACL MTU: 1021:8 SCO MTU: 64:1
    DOWN
    RX bytes:574 acl:0 sco:0 events:30 errors:0
    TX bytes:368 acl:0 sco:0 commands:30 errors:0
    Features: 0xbf 0xfe 0xcf 0xfe 0xdb 0xff 0x7b 0x87
    Packet type: DM1 DM3 DM5 DH1 DH3 DH5 HV1 HV2 HV3
    Link policy: RSWITCH SNIFF
    Link mode: SLAVE ACCEPT

    root@Omega-318B:~# ^C
    root@Omega-318B:~# hciconfig hci0 up
    root@Omega-318B:~# hciconfig hci0 sspmode enable
    root@Omega-318B:~# hciconfig hci0 piscan
    root@Omega-318B:~# bluetoothctl
    -ash: bluetoothctl: not found
    root@Omega-318B:~# hciconfig -a
    hci0: Type: Primary Bus: USB
    BD Address: 5C:F3:70:97:79:F8 ACL MTU: 1021:8 SCO MTU: 64:1
    UP RUNNING PSCAN ISCAN
    RX bytes:1160 acl:0 sco:0 events:62 errors:0
    TX bytes:744 acl:0 sco:0 commands:62 errors:0
    Features: 0xbf 0xfe 0xcf 0xfe 0xdb 0xff 0x7b 0x87
    Packet type: DM1 DM3 DM5 DH1 DH3 DH5 HV1 HV2 HV3
    Link policy: RSWITCH SNIFF
    Link mode: SLAVE ACCEPT
    Name: 'BCM20702A'
    Class: 0x000000
    Service Classes: Unspecified
    Device Class: Miscellaneous,
    HCI Version: 4.0 (0x6) Revision: 0x1000
    LMP Version: 4.0 (0x6) Subversion: 0x220e
    Manufacturer: Broadcom Corporation (15)

    root@Omega-318B:~#



  • I also can’t connect through another command. (USB adapter asus bt400)

    m2- it MI band2

    root@Omega-318B:~# hcitool -i hci0 lescan
    LE Scan ...
    52:07:6E:9C:54:74 (unknown)
    52:07:6E:9C:54:74 (unknown)
    C8:4E:20:69:29:22 M2
    C8:4E:20:69:29:22 (unknown)
    63:83:1B:AA:48:7D (unknown)
    root@Omega-318B:~#
    root@Omega-318B:~# gatttool -i hci0 -b C8:4E:20:69:29:22 -I
    [C8:4E:20:69:29:22][LE]> connect
    Attempting to connect to C8:4E:20:69:29:22
    Error: connect: Connection refused (146)



  • @Velera-OKON bluez-daemon is in the packages repository. You need to edit /etc/opkg/distfeeds.conf and uncomment lines 2 and 5, then run opkg update, then run opkg install bluez-daemon



  • Hi @Velera-OKON,

    @crispyoz is correct, you need to enable opkg feeds for openwrt_base and openwrt_packages here is a working log from a fresh image:

    root@Omega-XXXX:~# vi /etc/opkg/distfeeds.conf
    
    root@Omega-XXXX:~# cat /etc/opkg/distfeeds.conf
    #src/gz openwrt_core http://downloads.openwrt.org/releases/18.06-SNAPSHOT/targets/ramips/mt76x8/packages
    src/gz openwrt_base http://downloads.openwrt.org/releases/18.06-SNAPSHOT/packages/mipsel_24kc/base
    #src/gz openwrt_luci http://downloads.openwrt.org/releases/18.06-SNAPSHOT/packages/mipsel_24kc/luci
    #src/gz openwrt_onion http://downloads.openwrt.org/releases/18.06-SNAPSHOT/packages/mipsel_24kc/onion
    src/gz openwrt_packages http://downloads.openwrt.org/releases/18.06-SNAPSHOT/packages/mipsel_24kc/packages
    #src/gz openwrt_routing http://downloads.openwrt.org/releases/18.06-SNAPSHOT/packages/mipsel_24kc/routing
    #src/gz openwrt_telephony http://downloads.openwrt.org/releases/18.06-SNAPSHOT/packages/mipsel_24kc/telephony
    src/gz omega2_core http://repo.onioniot.com/omega2/packages/core
    src/gz omega2_base http://repo.onioniot.com/omega2/packages/base
    src/gz omega2_packages http://repo.onioniot.com/omega2/packages/packages
    src/gz omega2_routing http://repo.onioniot.com/omega2/packages/routing
    src/gz omega2_onion http://repo.onioniot.com/omega2/packages/onion
    
    root@Omega-XXXX:/etc/opkg# opkg update
    Downloading http://downloads.openwrt.org/releases/18.06- 
    SNAPSHOT/packages/mipsel_24kc/base/Packages.gz
    Updated list of available packages in /var/opkg-lists/openwrt_base
    Downloading http://downloads.openwrt.org/releases/18.06-SNAPSHOT/packages/mipsel_24kc/base/Packages.sig
    Signature check passed.
    Downloading http://downloads.openwrt.org/releases/18.06-SNAPSHOT/packages/mipsel_24kc/packages/Packages.gz
    Updated list of available packages in /var/opkg-lists/openwrt_packages
    Downloading http://downloads.openwrt.org/releases/18.06-SNAPSHOT/packages/mipsel_24kc/packages/Packages.sig
    Signature check passed.
    Downloading http://repo.onioniot.com/omega2/packages/core/Packages.gz
    Updated list of available packages in /var/opkg-lists/omega2_core
    Downloading http://repo.onioniot.com/omega2/packages/core/Packages.sig
    Signature check passed.
    Downloading http://repo.onioniot.com/omega2/packages/base/Packages.gz
    Updated list of available packages in /var/opkg-lists/omega2_base
    Downloading http://repo.onioniot.com/omega2/packages/base/Packages.sig
    Signature check passed.
    Downloading http://repo.onioniot.com/omega2/packages/packages/Packages.gz
    Updated list of available packages in /var/opkg-lists/omega2_packages
    Downloading http://repo.onioniot.com/omega2/packages/packages/Packages.sig
    Signature check passed.
    Downloading http://repo.onioniot.com/omega2/packages/routing/Packages.gz
    Updated list of available packages in /var/opkg-lists/omega2_routing
    Downloading http://repo.onioniot.com/omega2/packages/routing/Packages.sig
    Signature check passed.
    Downloading http://repo.onioniot.com/omega2/packages/onion/Packages.gz
    Updated list of available packages in /var/opkg-lists/omega2_onion
    Downloading http://repo.onioniot.com/omega2/packages/onion/Packages.sig
    Signature check passed.
    
    root@Omega-XXXX:/etc/opkg# opkg install bluez-libs
    Installing bluez-libs (5.49-1) to root...
    Downloading http://downloads.openwrt.org/releases/18.06- SNAPSHOT/packages/mipsel_24kc/packages/bluez-libs_5.49-1_mipsel_24kc.ipk
    Configuring bluez-libs.
    
    root@Omega-XXXX:/etc/opkg# opkg install bluez-utils
    Installing bluez-utils (5.49-1) to root...
    Downloading http://downloads.openwrt.org/releases/18.06-SNAPSHOT/packages/mipsel_24kc/packages/bluez-utils_5.49-1_mipsel_24kc.ipk
    Installing libffi (3.2.1-3) to root...
    Downloading http://repo.onioniot.com/omega2/packages/packages/libffi_3.2.1-3_mipsel_24kc.ipk
    Installing libattr (20170915-1) to root...
    Downloading http://repo.onioniot.com/omega2/packages/packages/libattr_20170915-1_mipsel_24kc.ipk
    Installing glib2 (2.58.1-2) to root...
    Downloading http://repo.onioniot.com/omega2/packages/packages/glib2_2.58.1-2_mipsel_24kc.ipk
    Installing libdbus (1.10.4-1) to root...
    Downloading http://repo.onioniot.com/omega2/packages/packages/libdbus_1.10.4-1_mipsel_24kc.ipk
    Installing dbus (1.10.4-1) to root...
    Downloading http://repo.onioniot.com/omega2/packages/packages/dbus_1.10.4-1_mipsel_24kc.ipk
    Configuring libffi.
    Configuring libattr.
    Configuring glib2.
    Configuring libdbus.
    Configuring dbus.
    Configuring bluez-utils.
    
    root@Omega-XXXX:/etc/opkg# bluetoothctl
    -ash: bluetoothctl: not found
    
    root@Omega-XXXX:/etc/opkg# opkg install bluez-daemon
    Installing bluez-daemon (5.49-1) to root...
    Downloading http://downloads.openwrt.org/releases/18.06-SNAPSHOT/packages/mipsel_24kc/packages/bluez-daemon_5.49-1_mipsel_24kc.ipk
    Installing libical (1.0-1) to root...
    Downloading http://downloads.openwrt.org/releases/18.06-SNAPSHOT/packages/mipsel_24kc/packages/libical_1.0-1_mipsel_24kc.ipk
    Configuring libical.
    Configuring bluez-daemon.
    
    root@Omega-XXXX:/etc/opkg# bluetoothctl
    Waiting to connect to bluetoothd...
    

    Regards,
    UFD



  • @UFD

    It helped thanks. I downloaded it and launched. (bluetoothctl).
    But the problem with connecting to the Mi band remained.
    Tell me what's wrong.

    root@Omega-318B:~# gatttool -b C8:4E:20:69:29:22 M2 --characteristics
    connect error: Connection refused (146)

    [C9:74:86:37:CB:14][LE]> connect
    Attempting to connect to C9:74:86:37:CB:14
    Command Failed: Disconnected
    Error: connect error: Connection refused (146)

    Ω-ware: 0.3.2 b233

    root@Omega-318B:~#
    root@Omega-318B:~# hciconfig hci0 up
    root@Omega-318B:~# hciconfig -a
    hci0: Type: Primary Bus: USB
    BD Address: 5C:F3:70:97:79:F8 ACL MTU: 1021:8 SCO MTU: 64:1
    UP RUNNING
    RX bytes:1178 acl:0 sco:0 events:65 errors:0
    TX bytes:1066 acl:0 sco:0 commands:65 errors:0
    Features: 0xbf 0xfe 0xcf 0xfe 0xdb 0xff 0x7b 0x87
    Packet type: DM1 DM3 DM5 DH1 DH3 DH5 HV1 HV2 HV3
    Link policy: RSWITCH SNIFF
    Link mode: SLAVE ACCEPT
    Name: 'BlueZ 5.49'
    Class: 0x000000
    Service Classes: Unspecified
    Device Class: Miscellaneous,
    HCI Version: 4.0 (0x6) Revision: 0x1000
    LMP Version: 4.0 (0x6) Subversion: 0x220e
    Manufacturer: Broadcom Corporation (15)

    root@Omega-318B:~# hcitool -i hci0 lescan
    LE Scan ...
    C8:4E:20:69:29:22 M2
    C8:4E:20:69:29:22 (unknown)
    ^Croot@Omega-318B:~# ^C
    root@Omega-318B:~# gatttool -i hci0 -b C8:4E:20:69:29:22 -I
    [C8:4E:20:69:29:22][LE]> connect
    Attempting to connect to C8:4E:20:69:29:22
    Error: connect error: Connection refused (146)

    thanks



  • @Velera-OKON I wonder if your Mi Band is in discovery mode for too short time. A common problem with bluetooth discovery and connection is that the discovery takes some time then when you execute the connection the target device has timed out on discovery mode. I don't have a Mi Band so I am not sure about how long it is in discovery mode or if you can extend it, but it would be worth checking.



  • @crispyoz

    I can connect via (bluetoothctl)
    and even if I can’t connect I can’t connect through (gatttool -i hci0 -b C8: 4E: 20: 69: 29: 22 -I)

    ^Croot@Omega-318B:~# gatttool -i hci0 -b C8:4E:20:69:29:22 -I
    [C8:4E:20:69:29:22][LE]> connect C8:4E:20:69:29:22
    Attempting to connect to C8:4E:20:69:29:22
    Error: connect error: Connection refused (146)

    Agent registered
    [bluetooth]# agent on
    Agent is already registered
    [bluetooth]# discoverable on
    Changing discoverable on succeeded
    [bluetooth]# pairable on
    Changing pairable on succeeded
    [bluetooth]# scan on
    Discovery started
    [CHG] Controller 5C:F3:70:97:79:F8 Discovering: yes
    [NEW] Device C8:4E:20:69:29:22 M2
    [NEW] Device C9:74:86:37:CB:14 Mi Band 3
    [NEW] Device A4:50:46:25:C8:92 A4-50-46-25-C8-92
    [CHG] Device A4:50:46:25:C8:92 Name: POCOPHONE
    [CHG] Device A4:50:46:25:C8:92 Alias: POCOPHONE
    [bluetooth]# pair
    [bluetooth]# pair C8:4E:20:69:29:22
    Attempting to pair with C8:4E:20:69:29:22
    [CHG] Device C8:4E:20:69:29:22 Connected: yes

    [M2]# quit
    root@Omega-318B:~# hcitool con
    Connections:
    < LE C8:4E:20:69:29:22 handle 64 state 1 lm MASTER AUTH ENCRYPT
    root@Omega-318B:~# gatttool -i hci0 -b C8:4E:20:69:29:22 -I
    [C8:4E:20:69:29:22][LE]> connect
    Attempting to connect to C8:4E:20:69:29:22
    Error: connect error: Connection refused (146)
    [C8:4E:20:69:29:22][LE]> char-write-cmd 0x0051 01
    Command Failed: Disconnected
    [C8:4E:20:69:29:22][LE]>



  • @Velera-OKON Try adding -I (interactive mode)

    Did you try adding -t random ?



  • @crispyoz
    Thanks, that helped. I am very grateful to you.


Log in to reply
 

Looks like your connection to Community was lost, please wait while we try to reconnect.