BT - hciattach cmd fails on wl127x

Hi,

 We are trying to make BT up on J4 dm814x board using murata com6(wl127xx) chip.

 After booting the kernel we did the following insmod operation

 insmod compat_bt.ko

insmod cfg80211.ko

insmod mac80211.ko

insmod wl12xx.ko

insmod wl12xx_sdio.ko

  

modprobe bluetooth

modprobe hci_uart

modprobe rfcomm

modprobe hidp

 

insmod gpio_en.ko

When we tried to run hciattach as follows, we got the timeout error

i.e  hciattach /dev/ttyO3 texas 115200 &

Please could somebody help us solve this issue ?

Thanks & Regards,

Rohini

8 Replies

  • Hi Rohini,

    The serial port you are using “/dev/ttyO3” is correct?

    Is the InitScript( .bts file) located at “/lib/firmware/”.

    Thanks & Regards,

    Sundeep.

    Thanks for posting on TI E2E forum. We appreciate your feedback!
    Sundeep.

    ----------------------------------------------------------------------------------------------------- 
    ** Please click the Verify Answer button on this post if it answers your question. **

    Please visit our CC256x Forum Guidelines and FAQs

    Check out our CC256x Bluetooth Main Wiki page: http://processors.wiki.ti.com/index.php/CC256x

    Don't forget to check out our wiki page for lots of useful info:  Wireless Connectivity Platforms
    -----------------------------------------------------------------------------------------------------

  • In reply to Sundeep Javvaji:

    7331.dmesg_log.txt

    Hi Sundeep,

    Please could you let us know how we could verify the right tty dev? the .bts file is present under /lib/firmwarePlease find the dmsg output file attached.

    We got timeout error when we tried hciattach from the command prompt as follows.

    root@dm814x-evm:/home/wifimod# hciattach /dev/ttyO1 texas 115200 &

    opened serial port

    calling tcgetattr

    calling cfmakeraw

    calling cfmakeraw done

    calling tcsetattr

    Set initial baudrate

    calling tcsetattr

    inside texas inside texas_init

    calling read_hci_event

    Initialization timed out.

    root@dm814x-evm:/home/wifimod#

    Any pointers would be welcome.

    Thanks and Regards,

    Rohini

  • In reply to Rohini Srinivas:

    Hi Rohini,

    The serial port associated with UARTX is referred as ttyOX.

    So depending on the UART configured for Bluetooth the /dev/tty is defined.

    Could you please provide me your board gpio_en_xxxxx.c file from path /kernel/drivers/bt_enable/gpio_en_xxxxx.c

    For example for the board AM335x the file is /kernel/drivers/bt_enable/gpio_en_am335x.c

     

    Thanks & Regards,

    Sundeep.

    Thanks for posting on TI E2E forum. We appreciate your feedback!
    Sundeep.

    ----------------------------------------------------------------------------------------------------- 
    ** Please click the Verify Answer button on this post if it answers your question. **

    Please visit our CC256x Forum Guidelines and FAQs

    Check out our CC256x Bluetooth Main Wiki page: http://processors.wiki.ti.com/index.php/CC256x

    Don't forget to check out our wiki page for lots of useful info:  Wireless Connectivity Platforms
    -----------------------------------------------------------------------------------------------------

  • In reply to Sundeep Javvaji:

    3404.gpio_en_am335x.c

     

    Hi Sundeep,

    Thank you for your inputs.For DM814x the BT communication is through UART3. Thus /dev/ttyO3 should be right.

    I have attached the file gpio_en_am335x.c

    Any pointers would be useful.

    Regards,

    Rohini

  • In reply to Rohini Srinivas:

    5732.NEW_gpio_en_am335x.c

    Hi Rohini,

    If your UART Nomenclature is UART0, UART1 and UART2. Yes it is right.

    Or If your UART Nomenclature is UART1, UART2 and UART3. Then it is ttyO2.

     

    But you are saying you are using amx335x with WL127X, in which we have clearly mentioned that BT UART is ttyO1.

    Please check the below link.

    http://processors.wiki.ti.com/index.php/AM335x_Wireless_Connectivity_Platform

     

    You are using a very old code. Could you please try it with the attached file (or) you can change the “gpio_set_value” to “gpio_direction_output” and try.

    And make sure that the BT_EN(nSHUTDOWN GPIO) is correct.

    Regards,

    Sundeep.

    Thanks for posting on TI E2E forum. We appreciate your feedback!
    Sundeep.

    ----------------------------------------------------------------------------------------------------- 
    ** Please click the Verify Answer button on this post if it answers your question. **

    Please visit our CC256x Forum Guidelines and FAQs

    Check out our CC256x Bluetooth Main Wiki page: http://processors.wiki.ti.com/index.php/CC256x

    Don't forget to check out our wiki page for lots of useful info:  Wireless Connectivity Platforms
    -----------------------------------------------------------------------------------------------------

  • In reply to Sundeep Javvaji:

    Hi Sundeep,

     Thanks for the information.

     We are trying to bring up the BT on TI J4 platform (dm814x) ezsdk package 5.04.

     The linux version is linux-2.6.37-psp04.04.00.01.

    When we try to compile the latest gpio_en_am335x.c with above kernel package we get the following platform related errors of AM33x.

     /u/karun/J4_BT/TI-ECS-build-utilites-8aaf153/bt_enable/gpio_en.c: In function 'gpio_test_init':

    /u/karun/J4_BT/TI-ECS-build-utilites-8aaf153/bt_enable/gpio_en.c:109: error: implicit declaration of function 'AM33XX_L4_WK_IO_ADDRESS'

    /u/karun/J4_BT/TI-ECS-build-utilites-8aaf153/bt_enable/gpio_en.c:109: error: 'AM33XX_SCM_BASE' undeclared (first use in this function)

    /u/karun/J4_BT/TI-ECS-build-utilites-8aaf153/bt_enable/gpio_en.c:109: error: (Each undeclared identifier is reported only once

    /u/karun/J4_BT/TI-ECS-build-utilites-8aaf153/bt_enable/gpio_en.c:109: error: for each function it appears in.)

    /u/karun/J4_BT/TI-ECS-build-utilites-8aaf153/bt_enable/gpio_en.c: In function 'gpio_test_exit':

    /u/karun/J4_BT/TI-ECS-build-utilites-8aaf153/bt_enable/gpio_en.c:121: error: 'AM33XX_SCM_BASE' undeclared (first use in this function)

     Could you please let us know your comments?

    Regards,

    Rohini

  • In reply to Rohini Srinivas:

    Hi Rohini,

    Can you please clarify if you are using amx335x or dm814x(with EZSDK Release 5.04.00.11).

    If you are using amx335x – you can try my other suggestion change the “gpio_set_value” to “gpio_direction_output” instead of changing the whole file.

    If you are using dm814x(with EZSDK Release 5.04) - As far as I understand Bluetooth is not supported in this EZSDK release. Please check the link below

    http://processors.wiki.ti.com/index.php/EZSDK_Releases_information.

    Thanks & Regards,

    Sundeep.

    Thanks for posting on TI E2E forum. We appreciate your feedback!
    Sundeep.

    ----------------------------------------------------------------------------------------------------- 
    ** Please click the Verify Answer button on this post if it answers your question. **

    Please visit our CC256x Forum Guidelines and FAQs

    Check out our CC256x Bluetooth Main Wiki page: http://processors.wiki.ti.com/index.php/CC256x

    Don't forget to check out our wiki page for lots of useful info:  Wireless Connectivity Platforms
    -----------------------------------------------------------------------------------------------------

  • In reply to Rohini Srinivas:

    Hi ,

    What changes did you make on the kernel to get wl12xx(COM6) working on dm814/ mmc0? 


    Thank you.