This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

[CC2564B] QCA9558 + CC2564B platform: Bluetooth: hci0 command tx timeout or Bluetooth: Unknown HCI packet type

Other Parts Discussed in Thread: CC2564, CC2564MODNEM

Hi all,


I have stuck in those problem for awhile and really need some advice or hint. Any suggestion would be appreciated!

Here is my status. I got a QCA9558 board and using HS-UART interface connected to CC2564B. The tty driver has been

successfully porting so the UART interface seems to be fine. But in some situation like l2ping or doing blueZ stuff, the

error message start to print from kernel like following:


$ l2ping CC:FA:00:15:FD:76
Ping: CC:FA:00:15:FD:76 from 6C:EC:EB:4C:15:9E (data size 44) ..[  701.490000] Bluetooth: Unknown HCI packet type f0
.
^C0 sent, 0 received, 0% loss
root@EWS1025:~# [  711.830000] Bluetooth: hci0 command tx timeout

And I'm pretty sure the BTS script has succesfully loaded because the CC2564 can be control by hcitool cmd like those:

$ hciconfig hci0 up
$ hcitool -i hci0 cmd 0x4 0x9
< HCI Command: ogf 0x04, ocf 0x0009, plen 0
> HCI Event: 0x0e plen 10
  01 09 10 00 9E 15 4C EB EC 6C
$ hciconfig
hci0:    Type: BR/EDR  Bus: UART
    BD Address: 6C:EC:EB:4C:15:9E  ACL MTU: 1021:4  SCO MTU: 180:4
    UP RUNNING
    RX bytes:1154 acl:0 sco:0 events:60 errors:0
    TX bytes:645 acl:0 sco:0 commands:60 errors:0

Then, I have tried using MSP-EXP430 + CC2564MODNEM with bypass firmware to testing on my board via USB port again. The result is
different from previous. The l2ping works normal without any error message form kernel. It seems the only difference is tty driver between

the CC2564MODNEM and CC2564B.

So is there anything I should be done in my HS-UART tty driver to fix the issue?

Thanks.

BR,

George Lin

  • Hi George,

    Yes, from the error message it does look like the UART driver is dropping bytes causing the BlueZ stack to fail parsing the data.

    If you can send me the logger logs, I can take a look and confirm if the firmware downloaded successfully and if there's any issue on the device side (doesn't look like that).

    Regards,
    Gigi Joseph.
  • Hi Gigi,

    Sorry for the late reply. I have another BTS script problem related to the problem.

    Our FAE gave me a BTS script and if I don't do any modification that will cause BlueZ initialization failure.

    So, I trace BlueZ and found the cmd opcode 0x5b01 and 0x3601 is the root cuase.

    I am doubt about what is 0x5b01 and 0x3601 stand for and it is necessary for me if I want to develop my product.

    Link is the BTS script. And the fail initialization log is as following

    BTS:

    https://www.dropbox.com/s/eyidmcka7r9x87m/TIInit_6.7.16.bts?dl=0

    $ mknod /dev/ttyATH0 c 4 65

    #Load bts script and setup CC2564

    $ hciattach /dev/ttyATH0 texas 115200 flow

    Found a Texas Instruments' chip!

    Firmware file : /lib/firmware/ti-connectivity/TIInit_6.7.16.bts

    Loaded BTS script version 1

    texas: changing baud rate to 115200, flow control to 1

    TI init command failed.

    Can't initialize device: Input/output error

  • Hi Gigi,

    This is the log of question #1 for your reference.

    $ mknod /dev/ttyATH0 c 4 65
    $ hciattach /dev/ttyATH0 texas 115200 flow
    Found a Texas Instruments' chip!
    Firmware file : /lib/firmware/ti-connectivity/TIInit_6.7.16.bts
    Loaded BTS script version 1
    texas: changing baud rate to 115200, flow control to 1
    Device setup complete
    root@(none):/# hciconfig -a hci0 piscan
    Can't set scan mode on hci0: Network is down (127)
    root@(none):/# hciconfig hci0 up
    root@(none):/# hciconfig -a hci0 piscan
    root@(none):/# hciconfig -a hci0 sspmode off
    root@(none):/# l2ping CC:FA:00:15:FD:76
    Ping: CC:FA:00:15:FD:76 from 6C:EC:EB:4C:15:BD (data size 44) ...
    0 bytes from CC:FA:00:15:FD:76 id 0 time 33.90ms
    0 bytes from CC:FA:00:15:FD:76 id 1 time 37.33ms
    0 bytes from CC:FA:00:15:FD:76 id 2 time 35.99ms
    0 bytes from CC:FA:00:15:FD:76 id 3 time 36.01ms
    0 bytes from CC:FA:00:15:FD:76 id 4 time 36.01ms
    0 bytes from CC:FA:00:15:FD:76 id 5 time 36.01ms
    0 bytes from CC:FA:00:15:FD:76 id 6 time 42.26ms
    0 bytes from CC:FA:00:15:FD:76 id 7 time 37.26ms
    0 bytes from CC:FA:00:15:FD:76 id 8 time 36.01ms
    0 bytes from CC:FA:00:15:FD:76 id 9 time 36.01ms
    ^C10 sent, 10 received, 0% loss
    root@(none):/# hcitool -i hci0 cmd 0x4 0x9
    < HCI Command: ogf 0x04, ocf 0x0009, plen 0
    > HCI Event: 0x0e plen 10
    01 09 10 00 BD 15 4C EB EC 6C
    root@(none):/# l2ping CC:FA:00:15:FD:76
    Ping: CC:FA:00:15:FD:76 from 6C:EC:EB:4C:15:BD (data size 44) ...
    no response from CC:FA:00:15:FD:76: id 0
    0 bytes from CC:FA:00:15:FD:76 id 1 time 13.51ms
    0 bytes from CC:FA:00:15:FD:76 id 2 time 35.55ms
    ^C3 sent, 2 received, 33% loss
    root@(none):/# l2ping CC:FA:00:15:FD:76
    Ping: CC:FA:00:15:FD:76 from 6C:EC:EB:4C:15:BD (data size 44) ...
    0 bytes from CC:FA:00:15:FD:76 id 0 time 62.22ms
    0 bytes from CC:FA:00:15:FD:76 id 1 time 36.09ms
    0 bytes from CC:FA:00:15:FD:76 id 2 time 45.92ms
    ^C3 sent, 3 received, 0% loss
    root@(none):/# l2ping CC:FA:00:15:FD:76
    Ping: CC:FA:00:15:FD:76 from 6C:EC:EB:4C:15:BD (data size 44) ...
    0 bytes from CC:FA:00:15:FD:76 id 0 time 43.17ms
    0 bytes from CC:FA:00:15:FD:76 id 1 time 35.94ms
    0 bytes from CC:FA:00:15:FD:76 id 2 time 59.74ms
    ^C3 sent, 3 received, 0% loss
    root@(none):/# hcitool -i hci0 cmd 0x4 0x9
    < HCI Command: ogf 0x04, ocf 0x0009, plen 0
    > HCI Event: 0x0e plen 10
    01 09 10 00 BD 15 4C EB EC 6C
    root@(none):/# hcitool -i hci0 cmd 0x4 0x9
    < HCI Command: ogf 0x04, ocf 0x0009, plen 0
    > HCI Event: 0x0e plen 10
    01 09 10 00 BD 15 4C EB EC 6C
    root@(none):/# hcitool -i hci0 cmd 0x4 0x9
    < HCI Command: ogf 0x04, ocf 0x0009, plen 0
    > HCI Event: 0x0e plen 10
    01 09 10 00 BD 15 4C EB EC 6C
    root@(none):/# hcitool -i hci0 cmd 0x4 0x9
    < HCI Command: ogf 0x04, ocf 0x0009, plen 0
    > HCI Event: 0x0e plen 10
    01 09 10 00 BD 15 4C EB EC 6C
    root@(none):/# hcitool -i hci0 cmd 0x4 0x9
    < HCI Command: ogf 0x04, ocf 0x0009, plen 0
    > HCI Event: 0x0e plen 10
    01 09 10 00 BD 15 4C EB EC 6C
    root@(none):/# l2ping CC:FA:00:15:FD:76
    [ 172.120000] Bluetooth: Unknown HCI packet type 0f
    [ 172.130000] Bluetooth: unknown link type 255
    [ 172.130000] Bluetooth: Unknown HCI packet type 20
    [ 172.140000] Bluetooth: Unknown HCI packet type 0a
    [ 172.140000] Bluetooth: Unknown HCI packet type 00
    [ 172.150000] Bluetooth: Unknown HCI packet type 06
    [ 172.150000] Bluetooth: Unknown HCI packet type 00
    [ 172.150000] Bluetooth: Unknown HCI packet type 01
    [ 172.160000] Bluetooth: Unknown HCI packet type 00
    [ 172.160000] Bluetooth: Unknown HCI packet type 0a
    [ 173.120000] Bluetooth: hci0 command 0x041b tx timeout
    [ 174.120000] Bluetooth: hci0 command 0x0429 tx timeout
    0 sent, 0 received, 0% loss
  • Hi,

    (1) dropbox is blocked in my office. Can you attach the problematic bts file (you can rename it to txt or something)?
    (2) I was actually looking for the logger logs (processors.wiki.ti.com/index.php/CC256x_Logger_User_Guide). Can you please share that?

    Regards,
    Gigi Joseph.
  • Hi Gigi,


    The BTS is as attached.

    4034.TIInit_6.7.16.txt
    BTSBR#--------------------------------------------------------------------------------8# Description : Orca L PG 2.0 ROM Initialization Script#"# Compatibility: Orca, 7.0.16 ROM#)# Last Updated: 16-Feb-2016  11:49:45.18## Version     : TI_P7_16.33####V# Notes       : Use this script on Orca L PG 2.0, 7.0.16 ROM device only (FW v7.0.16)R#--------------------------------------------------------------------------------B################################################################### START of CC256x Add-OnB################################################################### Change UART baudrate6���6��B################################################################### END of CC256x Add-OnB#################################################################7��7���@a�G!���Gh� &0�](&�8�8*��$�4�)� &�F7J�DG)� ��)� �F1J�DGH�DC`,��� �0�[^(	���� �0�[,� DC�`$A !"�FJ�DG�a@0��	�M&�{(�(|9x�B�H.�0h�����	�"�FJ�DG){�"�FJ�DG(�����:b��(56.���D`H30����F��89z�E{��Ex�$�F�H�DG�M(h�I	���	1�F�J�DG(��Hx(��Hx(�.`�F�H�DG�M(h!I��	1�F�J�DG(L�.`�Hx�H�C�)����4c��"!�H "\*�	\)�A)�	!Aw�H!�F�J�DG �F�I�DG%h�F�I�DG(Ё|
    �|C
    }C
    A}C�ix�"BC�H�\@�JZ�H@]�KV{ ��F�N�D0G5-��x�0��L~4�x(� �(��i(	� �F�H�DG �p�H�0(b0����i����I@
    З8QЌ8E�8<�"8+�8%���! �]8!$�F�J�DG}!�AC����.d��H`-A��-?�8)�F�J�DG�H!�F�J�DG(��H�I	h`	� �I��8!�F�I�DG8�"#�F�K�DG�8!�F�I�DG�8!�F�I�DG�H�00b��$�F�H�DG�F�H�DG��p��i}D!@(&�8�(8+�(x((�; �C!IW�B"�hqp�(x(��N0$�F�I�DG�p�1
    "�F�K�DG(�F�I�DGp�WHx(� �F�H�D����(e�Gp�p�fi "�OM$�h84�� }0�]
    (/� ix0$�F�J�DG%�h�B"�w=(x(�y(��M,pM �F�J�DG (pp��=(x(
    �� y0�]0$#%�F�M�D(G�H�I bp�p�,i��#��B2ݴHx`�0AC�B)��&1]�	%��I�B �� ](�(�0](��!	])�)�(
    �p�� ]!"�F�J�DG 0U�I� �@(bp�����"f��FGv\aJap�iԎ��B��!�\@!@��1C�,YI�1	x	�B�+	��!�\)�)��I�JQbp�9zE,$�jXa0��I�J2 #$�F�M�D(G�H�@
    �$�Hp0��F�Fa��I�J]2 #$�F�L�D G�P���ُ�iKx@�0CC$fK�Bۈ�B�!	@��B��B܈������g���F �x Y��?�$����%�F�I�DG !�F�J�DGH<&��!�F
    J�DG(�p`�H!�FJ�DG(�8pCI`�F�I�DG���F�bQ*AgPk�lOba�j�%Eo�o}^�m�n���Eih|(�(|�I(�
    �*
    �(� � � (t� �h|
    (�(|(��O����h�&8$�F�I�DG�F�I�DG(�z
    )���Ij1�b7>��h|(
    �(|�I(��(� � ���`�/	YQ�i}da�����..������iQx�ip�!;�H3�;s�#��#�Ix
    C2p6x(�%(� %0p60
    !$�F�J�DG�F�H�DG����Hx@@C!�C		0�F�J�DG0�����i�#��#�Ix
    C2p6x(�%(� %0p60
    !$�F�J�DG�F�H�DG����Hx@@C!�C		0�F�J�DG}� 8��H�I	�b��y'(�Py(�# Pq���Fˣ�0��i!�% �/"�'�(#�`z!�F�I�DG(�0�!x� HC�J\(�vH�8x(��H@\(
    � !�F�I�DG�I�Hx0����
    j�@(b0��E�q���pU1>��q��0�i�J�h�B$��Hx� ��HB*�"Bw�Hx�pYH�8x�(��H!"�F�J�DG$�M,��F�H�DG,��F�H�DG0��!"�F�J�DG�I���/e*�Da���H���L"��I�B9��I	x)5�a���J��B�"�C�'-�"�C�&�Jx�F�Jx�F"��J�B�vF6����k�6^CgF>A-�+�x��+�x��x+�vB�Jx�Kp�a�&��JhsC!�`��Hx1�IB�B�.�@BPCMA=�o�HxPC
    ��IB�B��(��Hx(��H!$�F�J�DG(��g0�F�I�DG���F\O[�?Fa1O�*�O����i�i8��I@>��I@(/�%8Q��H�(M�0$�F�I�D�����k�G� 0�])�!�U�!1�])т]*�*�)
    р](�(�0�F�I�DG$�0�F�I�DG�: �](�8!�FKI�DG��Hx(�� &0�]0!#$�F�N�D0G8�F@I�DG�I_ @(b��F�a�4�𵅰�i����H&��I@^��M�Hx(Y�$�F�H�DG(RѦF�H�DG(LѦF�H�DG(F�(x(CѨx(@������l�� �F�I�DG:��!jF$�F�K�DG�!"�F�K�DG%�h-�Hx�B"� @hC�I �iF�F�J�DG(��hF��F�J�DG(�аx(����I:"�F�K�DG�H�08b���FP�٣�LH� �F�H�DG�I`
    H�D���F{�"JV���P��`aQ*PTahNaOaRa��,$�����m��5i�'�i)RЊ�PRzZ�+�Cz�#z���F9 @]�L%(�*2�
    (�*%�*#�: @] (�+�*/�$(-�x](�(!�F�I�DG(!�F�I�DG�� m0@"�F�J�DG�4�(aF$#%�F�M�D(G�(aF"$#%�F�M�D(G�44b�MaLaQaSaPa�bx�&�$�FxH�DGwM�miF�FvJ�DG!�p�m������n�2�FrK�DGrM ��(i@�(�&�.ЦFmH�DG>(i@�(�ѦFiH�DGx�Pk����hba𵇰�`Hh$�FWH�DG]N00�]mF(q�]hq�!��Y�FXJ�DG�!��Y�FTJ�DGW!	�Y�FQJ�DG">�Y�FNJ�DG�FIH�DG (p�JI"��FIL�D G���5���BE���;Hh%�F2H�����o��DG$8N028�Q0*8�Q0"8�Q� ��Q08�QY �Q08�Q �!�F/J�DG� ��QW �Q� ��Q ��Q>�U�F H�DG�"I9"�F#K�DG����Q�3�3���*_3O���>%Gv\a�t���	����GT�Y�Y$!��&�P��**�&�����p����%@��KP�I
    P�F��J��B�@i@0,!"�F�J�DG�H+0����Ei$� @](7��&p](
    �(�(!�F�I�DG� @]('�l�%�� DUw]tU(!�F�I�DGwU�&p](��*�(#�F�K�DG(�l���B�$�!� AUtU(�aAC��a�I�9	x�	�.�1$�F�J�DG��Hx� C]: �F�L�D G�H�0��
    {�����q��H*��i)�c0�F�IC9�F�y
    )�
    !�H�B�e0�F[0�Fj�{�{C�HR0��H�B�-0�F)0�F��I�@��H�8@�/'?�M/�$,�&�d !�F�I�DGp6����.�Ѩ�@@� h�/��H(�,�$�d !�F�I�DG`$����,�Ѩ�h��H�040��j�Jh�����J+����DhD`�aH������r���H�0�p�hh(��N5 � h!�F�I�DG (
    ��Hx(	��P!ACqH�0H�`�8`� �I` �F�H�DGh`�He0p��H�0�F�@i!�F�I�DG�H50�Ai	|)�!�J�!�`�HS0�F�hCh
    x*ѻJx*�"�"JpCa�H	0�F��i�I	x)	�$p0!"�F�J�DG�$p0!"�F�J�DGp0
    !$�F�J�DG�I�����s��F�J�DG�H]0��Hx�H*�]0�F("�`��F�I	x)�!�Jp#!�`�H'0�F�~}C�L
    � �Ip �F�H�DG y0� q0��iJx�`Ix)�!�`�H90�F�F��{���Eh�h$�� �F�H�DG<�xix	�N)���,�(��4!ACH08`0!0�,��!�H
    #$�F�L�D G0%0��F������L�����t���!�F�I�DG(��H���H�0n0���fbO���i!!),�0%�F�I�DG(�'�F�I�DGx�!AC�HG\8�F�I�DG��8�F�I�DG�F�I�DG60�Q�F�J�DG�i``�H�0���H0�F�E�!�I
    :2x	x�A`�H�0�F��������U����%��I�H��B�&�(!�F�J�DG.�����u��O$<v�F�H�DG=r�O�miF�F�J�DG!�p�Fp�m�*�F�K�DG�H;0���F�Î��I�H��B� !�F�J�DG �`�HW0��HHa�E�V�)�&���(Da�"1O]��*����ij�0�(�$s�1h-$uJ, ��>#�[]x�BР\�B�'�'�'Hh�0%�F�I�DG�����v�0h(�1�F|J�DG0�(I�J!�\(D�/B��!�9T>�%LtH/�!�)� 0`p`�!�@1"�FkJ�DG  ��/ѡ�)� 0`p`�@1"�FbJ�DG ��0�80��x@@C�p0�(	�J!�\(�/��!�9T4�D`QHQ0���F�]��dam)"/�����i$l`� @`CGI �1"�FDJ�����w��DG(�o`4BHx�B��AHG0�����0�Eihz�(
    �$�F:I�DG�!\(�hz�F6I�DG6H�00���Yp��h�aEh� @]2N(�$�F.H�DG(
    ЦF,H�DG(Ѽ DU0�0p�0�p�'He0�F�F߇$������*ُ��v�v�*9�y���y�)��T�YY�`a������x��D� M"��3O��43]'��3������hF��Z�����hF��������hF��������hF��������hF��P�����hF�������hF��������hF��������hF��������hF��C�����hF��������hF��������hF��@�����hF��=�����hF��&�����hF��S�����hF��~�����hF�����������x{����A���pQs�r�ris=s�s�s�s7sia
    t5t�t�wYtr)r�u	vxMx�tcuqumv�wq�q��������,#:�:d��(~��T�R'|�����.�Ȑ�"(�Yr�n�d�"E��������� ������������f�������`N"2p#spG �p! �p%(\I9$�FYO�D8G�x�x(WI�FUN�D0G(TI1�FTJ�DG(�!��FPJ�DG�FOH�DGOK!h*�"�@C*��"*@GM�R!30 (��? DIp�FDH�DGBI`� BI�<#BHp AIp�"AHpAHpAHpAHpAHp(#Cp#�p >Kp>H%s#�s
    #Cs� ;K`>HZ3`'8Kp9K������8N3�p9J�O0p	 !!�"6K�F6N�D0G8N068!�F3J�DG �F2I�DG0)�F.J�DG0)�F.J�DG-N��F-I�DG0�F*I�DG�F)H�DG8�F)I�DG&I`'H`'H���F�O{��e�S�{���XaGvJaQaRaSaNaOaPa1�� da`a��bO$�>1��������Î6����X�b�y�bbap�CM�$�F?H�DG�B�� !��F;J�DG��F8H�DG�B����p�8I8J`$5HpDHp:!#�%p3M
    `%Uq2MM`%p1M�`q1L�`$�%%p/M
    a%�t.MMa%�q�,N�a&�w+L�a	$�p*Lb
    $�w)LLb$\w(L�b$�q'J�b
    "Zu&J
    c"p&JJc"Bp%J�c"�s$J��������c8"p#J
    d"q"HHd #I�#I�!IJ�K!	 Jу I!J�Ipp�Ńe�<N�OpbpRUyAy_yiyKy�y�y�y}ysyyy#y�R�x�x-y7yy�#TDaFa$��P�����N�p�,L��(� �(�*H!%�F,J�DG(� �F%I�DG0$J� �F$J�DG��(��H@00bp����!1���B,� %�FI�DG�L h0 `+'�NH�2h��	�FJ�DG(��0` h(
    � �FI�DGH8\�F
    I�DG  `���JM2�Wk��	�y�b�bHI9z����y{���
    �	�����d��	�X`�	�	�`�	�5v�1!TaW
    
    	
    �v�
    �����
    ��<�_���������������8��8�B################################################################### START of CC2564 Adds-OnB#################################################################"## Enable fast clock XTAL support�����������## Enable eHCILL	+�P��+�
    �	����d��B################################################################### END of CC2564 Adds-OnB#################################################################R#--------------------------------------------------------------------------------.# Description:   BLE FW Initialization Script## Compatibility: BL6450B#*# Last Updated:  19-Oct-2014  13:57:11.15## Version:       2.0#R#--------------------------------------------------------------------------------#LE Enable[��[�# Disable Cortex Sleep�����2# Cortex Reset (hold in reset while loading IMEM)	���	�######################### Patch Start########################�
    �K��G�5G���Y�U cP0���a�]�sXpGF:�R$ъx*�*�:В*�	:Љ�@���0C��K�	�@���0C��C���@���0C��;�pG��######################### Patch End#########################release Cortex Reset	���	�# Enable Cortex Sleep�����#RESET BLE[��[������

    For question 2, please wait me get the logger tools first.

  • Hi George,

    Please try with the attached modified bts file and see if it helps.

    Regards,
    Gigi Joseph.

    4034.TIInit_6.7.16.bts

  • Hi Gigi,

    I test the new BTS. The result is fail. The log is the same as previous post:

    $ hciattach /dev/ttyATH0 texas 115200 flow

    Found a Texas Instruments' chip!

    Firmware file : /lib/firmware/ti-connectivity/TIInit_6.7.16.bts

    Loaded BTS script version 1

    texas: changing baud rate to 115200, flow control to 1

    TI init command failed.

    Can't initialize device: Input/output error

  • Hi George,

    Thanks for the update - as discussed, please share the logger logs for further analysis.

    Regards,
    Gigi Joseph.