Jump to content

Recommended Posts

Posted

Hi all,

I'm starting with armbian and Banana pi m2p card. I entered image 4.19.21-sunxi, I can not make BT work.

with armbian-config  I have enabled the BT, next systemctl start bluetooth.

with systemctl status bluetooth:

Feb 18 18:01:30 bananapim2plus systemd[1]: Starting Bluetooth service...
Feb 18 18:01:30 bananapim2plus bluetoothd[1779]: Bluetooth daemon 5.48
Feb 18 18:01:30 bananapim2plus bluetoothd[1779]: Starting SDP server
Feb 18 18:01:30 bananapim2plus systemd[1]: Started Bluetooth service.
Feb 18 18:01:30 bananapim2plus bluetoothd[1779]: Bluetooth management interface

and 

root@bananapim2plus:~# bluetoothctl
Agent registered
[bluetooth]# show
No default controller available

where am I wrong?

Thanks

Posted
1 hour ago, cusna said:

with armbian-config  I have enabled the BT


This toggle BT when low level support is operational. Since BT is low important, not all boards has a working configuration.

Posted

Hello,

I'm not using usb adapters but the ap6212 module is built with the Banana pi M2P board.

If I install an image like UBUNTU type:

img Ubuntu  it works, all the drivers are installed.

 

I would however like to use ARMBIAN, where it is written that it also supports the
my board and supports Bluetooth, but I can not make it work.

 

Link Armbian - Orange Pi M2P

Posted

T

he only thing I discovered is that the BT-RST-N pin (n.34 of the AP6212 chip) ie PG12, always remains at 0 (low) and this is not good because it is used to turn on and the BT does not work for this.
I checked in bananapim2plus.fex is configured right:

;--------------------------------------------------------------------------------
;bluetooth configuration
;bt_used:       0- no used, 1- used
;bt_uard_id:		0- uart0, 1- uart1, 2- uart2
;bt_uart_baud:  uart baud rate, unit: bps
;bt_rst_n:      bt function enable io
;bt_wake:       host wake-up bluetooth device
;bt_host_wake:  bt device wake-up host
;bt_host_wake_invert: whether bt_host_wake use inverter between ap and module
;                     0: not used, 1: used
;--------------------------------------------------------------------------------
[bt_para]
bt_used               = 1
bt_uart_id            = 1
bt_uart_baud          = 1500000
bt_rst_n              = port:PG12<1><default><default><0> 
bt_wake               = port:PG13<1><default><default><0>
bt_host_wake          = port:PG11<0><default><default><0>
bt_host_wake_invert   = 0

why the pin to turn on the BT AP6612 module is not high (1)?

should I add something to armbianEnv.txt?

Thanks

 

Posted
23 minutes ago, cusna said:

should I add something to armbianEnv.txt?

 

If enabling would be this simple, it would already be enabled.

 

Modern kernel 4.x uses https://elinux.org/Device_Tree_Reference for describing hardware configuration. FEX is Allwinner proprietary way of describing that. Enabling Bluetooth is the same (similar) on all AP62XX powered devices. Mostly existing hacks are dirty, you need right firmware and right firmware settings, correct userland firmware loader.

 

This chip is one of the most popular ones and you can find it on many boards, but it can be attached to different UARTs ...

 

Use SEARCH function of this forum. You will be amazed what is possible to find in the archive. Perhaps not a working solution, but many insights into the problem which will help you to solving it.

Posted

Hello, 

Thanks for your answer.

I have many difficulties, not having experience.
I understand that the problem is the device tree.
From the diagram I am sure that AP6212 in the Orange PI M2 plus board
is connected to serial 1 and the BT_RST_N connected to PG12.
I did various research before writing, but I have not yet succeeded.
If you still have a little patience to make me understand:
for example, the image
https://dl.armbian.com/bananapim2plus/Debian_stretch_next.7z
all right ?
Do I just have to change the devicetree?
Or there are other things to do.
Thanks for your patience

Posted

I read this post 

trying to enable manually as described
changing BT_RST_N pin and uart.

# rfkill unblock all
# echo "0" > /sys/class/rfkill/rfkill0/state
# echo "1" > /sys/class/rfkill/rfkill0/state
# echo " " > /dev/ttyS1
# devmem2 0x1f00060 b 1
# echo 204 > /sys/class/gpio/export
# echo out > /sys/class/gpio/gpio204/direction
# echo 0 > /sys/class/gpio/gpio204/value
# echo 1 > /sys/class/gpio/gpio204/value
# hciattach /dev/ttyS1 bcm43xx 115200 flow bdaddr my macaddress
# hciconfig hci0 up

But unfortunately hciattach always generates
"Initialization time out"

in the armbianEnv.txt I hae added:

overlays=uart1

param_uart1_rtscts = 1

 

Posted

I almost solved :)
I do not understand where you can set the choice of firmware to load
(if BCM43430A1.hcd or BCM43430A0.hcd).
I need xxxA0 and it seems to always load xxxA1.
For now I solved by renaming the xxxA0 in xxxA1, but it seems to me an incorrect solution

 

Guest
This topic is now closed to further replies.
×
×
  • Create New...

Important Information

Terms of Use - Privacy Policy - Guidelines