一、使用的是开发板提供的固件 :tina_t113-100ask_uart3.img,(后我拉取tina SDK自己编译结果一样)
二、问题描述
1、使用 /etc/bluetooth/bt_init.sh 命令启动蓝牙,报错,信息如下:
hcidump_xr start
/etc/bluetooth/bt_init.sh: line 92: hcidump_xr: not found
[ 25.394676] sunxi-rfkill soc@3000000:rfkill@0: block state already is 1
[ 25.422408] sunxi-rfkill soc@3000000:rfkill@0: set block: 0
[ 25.438715] sunxi-rfkill soc@3000000:rfkill@0: bt power on success
[ 25.465891] [XR_BT_LPM] bluedroid_write_proc_btwake: bluedroid_write_proc_btwake 1
[ 25.474415] [XR_BT_LPM] bluedroid_write_proc_btwake: wakeup bt device
[ 25.481746] [XR_BT_LPM] bluedroid_write_proc_lpm: disable lpm mode
ln: /var/lib/bluetooth: No such file or directory
bluetoothd[256]: Bluetooth daemon 5.54
D-Bus setup failed: Failed to connect to socket /var/run/dbus/system_bus_socket: No such file or directory
bluetoothd[256]: Unable to get on D-Bus
2、使用 /etc/bluetooth/bluetoothd start 启动蓝牙服务失败,报错如下:
root@TinaLinux:/# /etc/bluetooth/bluetoothd start
root@TinaLinux:/# ln: /var/lib/bluetooth: No such file or directory
bluetoothd[279]: Bluetooth daemon 5.54
D-Bus setup failed: Failed to connect to socket /var/run/dbus/system_bus_socket: No such file or directory
bluetoothd[279]: Unable to get on D-Bus
3、使用 hciattach -n ttyS1 xradio & 初始化蓝牙,报错,通信超时,信息如下:
root@TinaLinux:/# hciattach -n ttyS1 xradio &
root@TinaLinux:/# xradio_init
set LPM mode:disabled[userial_sync] uart sync count: 1.
[userial_sync] read buf: 00 00.
[userial_sync] uart sync count: 2.
[userial_sync] read buf: 00 00.
[userial_sync] uart sync count: 3.
[userial_sync] read buf: 00 00.
[userial_sync] uart sync count: 4.
。。。。。。
[userial_sync] uart sync count: 128.
[userial_sync] read buf: 00 00.
Initialization timed out.
完整日志如下:
[ 6.430438] [SBUS] XRadio Device:sdio clk=50000000
[ 6.436342] [XRADIO] XRADIO_HW_REV 1.0 detected.
[ 6.518329] [XRADIO] xradio_update_dpllctrl: DPLL_CTRL Sync=0x01400000.
[ 6.554527] [XRADIO] Bootloader complete
[ 6.641863] [XRADIO] Firmware completed.
[ 6.647945] [WSM] Firmware Label:XR_C09.08.52.64_DBG_02.100 2GHZ HT40 Jan 3 2020 13:14:37
[ 6.657235] [XRADIO] Firmware Startup Done.
[ 6.662256] [XRADIO_WRN] enable Multi-Rx!
[ 6.667450] ieee80211 phy0: Selected rate control algorithm ‘minstrel_ht’
Successfully initialized wpa_supplicant
[ 6.890877] ieee80211_do_open: vif_type=2, p2p=0, ch=3, addr=dc:44:6d:8c:1c:6a
[ 6.899104] [STA] !!!xradio_vif_setup: id=0, type=2, p2p=0, addr=dc:44:6d:8c:1c:6a
[ 6.914557] [AP_WRN] BSS_CHANGED_ASSOC but driver is unjoined.
------run rc.final file-----
[ 7.136144] file system registered
numid=30,iface=MIXER,name=‘Headphone Switch’
; type=BOOLEAN,access=rw------,values=1
: values=on
BusyBox v1.27.2 () built-in shell (ash)
------run profile file-----
|_ ||| ___ _ [ 7.157180] configfs-gadget 4100000.udc-controller: failed to start g1: -19
| | || ___ _ _ _ _
| | _ | || | | |__ | || || | ||'|
| | | || | || _ | |___|||||||||,|
|| |||||||| Tina is Based on OpenWrt!
Tina Linux (Neptune, 61CC0487)
Mon Feb 6 00:00:00 GMT 2023
sh: write error: No such device
nodev debugfs
root@TinaLinux:/# [ 8.268144] sunxi_usb_udc 4100000.udc-controller: 4100000.udc-controller supply udc not found, using dummy regulator
[ 8.284027] read descriptors
[ 8.287274] read strings
[ 8.496147] android_work: sent uevent USB_STATE=CONNECTED
[ 8.527051] configfs-gadget gadget: high-speed config #1: c
[ 8.533389] android_work: sent uevent USB_STATE=CONFIGURED
root@TinaLinux:/#
root@TinaLinux:/# /etc/bluetooth/bt_init.sh
hcidump_xr start
/etc/bluetooth/bt_init.sh: line 92: hcidump_xr: not found
[ 25.394676] sunxi-rfkill soc@3000000:rfkill@0: block state already is 1
[ 25.422408] sunxi-rfkill soc@3000000:rfkill@0: set block: 0
[ 25.438715] sunxi-rfkill soc@3000000:rfkill@0: bt power on success
[ 25.465891] [XR_BT_LPM] bluedroid_write_proc_btwake: bluedroid_write_proc_btwake 1
[ 25.474415] [XR_BT_LPM] bluedroid_write_proc_btwake: wakeup bt device
[ 25.481746] [XR_BT_LPM] bluedroid_write_proc_lpm: disable lpm mode
ln: /var/lib/bluetooth: No such file or directory
bluetoothd[256]: Bluetooth daemon 5.54
D-Bus setup failed: Failed to connect to socket /var/run/dbus/system_bus_socket: No such file or directory
bluetoothd[256]: Unable to get on D-Bus
root@TinaLinux:/#
root@TinaLinux:/#
root@TinaLinux:/#
root@TinaLinux:/# /etc/bluetooth/bluetoothd start
root@TinaLinux:/# ln: /var/lib/bluetooth: No such file or directory
bluetoothd[279]: Bluetooth daemon 5.54
D-Bus setup failed: Failed to connect to socket /var/run/dbus/system_bus_socket: No such file or directory
bluetoothd[279]: Unable to get on D-Bus
root@TinaLinux:/#
root@TinaLinux:/# [ 194.504380] sunxi-rfkill soc@3000000:rfkill@0: set block: 1
[ 194.510680] sunxi-rfkill soc@3000000:rfkill@0: bt power off success
[ 194.537950] sunxi-rfkill soc@3000000:rfkill@0: set block: 0
[ 194.554213] sunxi-rfkill soc@3000000:rfkill@0: bt power on success
[ 194.581468] [XR_BT_LPM] bluedroid_write_proc_btwake: bluedroid_write_proc_btwake 1
[ 194.589993] [XR_BT_LPM] bluedroid_write_proc_btwake: wakeup bt device
[ 194.597270] [XR_BT_LPM] bluedroid_write_proc_lpm: disable lpm mode
[ 194.930762] sunxi-rfkill soc@3000000:rfkill@0: set block: 1
[ 194.937023] sunxi-rfkill soc@3000000:rfkill@0: bt power off success
[ 195.444324] sunxi-rfkill soc@3000000:rfkill@0: set block: 0
[ 195.460615] sunxi-rfkill soc@3000000:rfkill@0: bt power on success
[ 196.289136] sunxi-rfkill soc@3000000:rfkill@0: set block: 1
[ 196.295406] sunxi-rfkill soc@3000000:rfkill@0: bt power off success
[ 196.802677] sunxi-rfkill soc@3000000:rfkill@0: set block: 0
[ 196.818958] sunxi-rfkill soc@3000000:rfkill@0: bt power on success
[ 197.647461] sunxi-rfkill soc@3000000:rfkill@0: set block: 1
[ 197.653752] sunxi-rfkill soc@3000000:rfkill@0: bt power off success
[ 198.161021] sunxi-rfkill soc@3000000:rfkill@0: set block: 0
[ 198.177298] sunxi-rfkill soc@3000000:rfkill@0: bt power on success
[ 199.005819] sunxi-rfkill soc@3000000:rfkill@0: set block: 1
[ 199.012103] sunxi-rfkill soc@3000000:rfkill@0: bt power off success
[ 199.519359] sunxi-rfkill soc@3000000:rfkill@0: set block: 0
[ 199.535620] sunxi-rfkill soc@3000000:rfkill@0: bt power on success
[ 200.364128] sunxi-rfkill soc@3000000:rfkill@0: set block: 1
[ 200.370417] sunxi-rfkill soc@3000000:rfkill@0: bt power off success
[ 200.877658] sunxi-rfkill soc@3000000:rfkill@0: set block: 0
[ 200.893948] sunxi-rfkill soc@3000000:rfkill@0: bt power on success
[ 201.722481] sunxi-rfkill soc@3000000:rfkill@0: set block: 1
[ 201.728762] sunxi-rfkill soc@3000000:rfkill@0: bt power off success
[ 202.236015] sunxi-rfkill soc@3000000:rfkill@0: set block: 0
[ 202.252298] sunxi-rfkill soc@3000000:rfkill@0: bt power on success
[ 203.080814] sunxi-rfkill soc@3000000:rfkill@0: set block: 1
[ 203.087083] sunxi-rfkill soc@3000000:rfkill@0: bt power off success
[ 203.594349] sunxi-rfkill soc@3000000:rfkill@0: set block: 0
[ 203.610642] sunxi-rfkill soc@3000000:rfkill@0: bt power on success
[ 204.439151] sunxi-rfkill soc@3000000:rfkill@0: set block: 1
[ 204.445410] sunxi-rfkill soc@3000000:rfkill@0: bt power off success
[ 227.493586] sunxi-rfkill soc@3000000:rfkill@0: block state already is 1
[ 227.521356] sunxi-rfkill soc@3000000:rfkill@0: set block: 0
[ 227.537637] sunxi-rfkill soc@3000000:rfkill@0: bt power on success
[ 227.564797] [XR_BT_LPM] bluedroid_write_proc_btwake: bluedroid_write_proc_btwake 1
[ 227.573313] [XR_BT_LPM] bluedroid_write_proc_btwake: wakeup bt device
[ 227.580737] [XR_BT_LPM] bluedroid_write_proc_lpm: disable lpm mode