Other Parts Discussed in Thread: WL1837,
Tool/software: Linux
Hi,
I am able to bring up WiFi on dra744 interfacing with wl1837 (NF3108).
I am using processor SDK.
For Bluetooth, I did following changes,
1. On dts file (configure the UART3 and BT_EN pin)
---------------------------------------------------
&uart3 {
pinctrl-names = "default";
pinctrl-0 = <
0x248 (PIN_INPUT | MUX_MODE0) /* uart3_Rx */
0x24c (PIN_OUTPUT | MUX_MODE0) /* uart3_Tx */
0x338 (PIN_INPUT | MUX_MODE1) /* uart3_CTS */
0x3cc (PIN_OUTPUT | MUX_MODE1) /* uart3_RTS */
>;
status = "okay";
fsl,uart-has-rtscts;
gpio = <&gpio5 4 0>; /* BT Enable : BT_EN */
startup-delay-us = <70000>;
enable-active-high;
};
2. After boot up, run the following script to create a port :
---------------------------------------------------------------------------
echo <bt_en> /sys/class/gpio/export
echo out > /sys/class/gpio/gpio<bt_en>/direction
echo 0 > /sys/class/gpio/gpio<bt_en>/value
echo 1 > /sys/class/gpio/gpio<bt_en>/value
gpio="nshutdown_gpio=16"
tty="tty=/dev/ttyS2"
flow="flow_cntrl=1"
baud_rate="baud_rate=3000000"
mkdir /home/root/tibt
echo $gpio > /home/root/tibt/config
echo $tty >> /home/root/tibt/config
echo $flow >> /home/root/tibt/config
echo $baud_rate >> /home/root/tibt/config
3. Attach the ttyS2
---------------------
hciattach /dev/ttyS2 any 3000000
got the following logs,
[ 197.406076] Bluetooth: HCI UART driver ver 2.3
[ 197.410722] Bluetooth: HCI UART protocol H4 registered
[ 197.416376] Bluetooth: HCI UART protocol BCSP registered
[ 197.421791] Bluetooth: HCI UART protocol LL registered
[ 197.427077] Bluetooth: HCI UART protocol Three-wire (H5) registered
[ 197.555125] Bluetooth: BNEP (Ethernet Emulation) ver 1.3
[ 197.560650] Bluetooth: BNEP filters: protocol multicast
[ 197.566320] Bluetooth: BNEP socket layer initialized
[ 199.463449] Bluetooth: hci0 command 0x1003 tx timeout
[ 201.463452] Bluetooth: hci0 command 0x1001 tx timeout
[ 203.463447] Bluetooth: hci0 command 0x1009 tx timeout
root@dra7xx-evm:~/uart# hciconfig -a
hci0: Type: BR/EDR Bus: UART
BD Address: 00:00:00:00:00:00 ACL MTU: 0:0 SCO MTU: 0:0
DOWN
RX bytes:0 acl:0 sco:0 events:0 errors:0
TX bytes:12 acl:0 sco:0 commands:3 errors:0
When i run the following command getting error,
root@dra7xx-evm:~/uart# hcitool scan
Device is not available: No such device
root@dra7xx-evm:~/uart# hcitool lescan
Set scan parameters failed: File descriptor in bad state
I have checked the BT_EN pin with scope and its got getting enabled.
I have enabled BT_EN pin manually.
Please help us with where I did wrong.
Thanks,
Lal