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.

Using two UARTs in CC2540

Other Parts Discussed in Thread: CC2540

Hi,

Is it possible to use two UARTs in the CC2540 Mini developmnet kit  using BLE Stack 1.4 or later version ?

Can you please provide some example code ?

Regards

Shafy

  • Hi,

    The driver included in the stack only supports the use of one UART at a time. Hardware wise it is possible to use both in parallel, but then you would have to create your own modified driver.

    Regards,
    Johan

     

  • Hi Johan

    Thanks for the reply.  Can i use the USB  in CC2540 in serial mode.  

    I could find HalUARTInitUSB() function in hal_uart.c.  Is this for serial mode ?

    Can you please provide some good documentation about the uart and other peripheral drivers ?

    Shafy

  • Hi Shafy,

    Yes, you ca use the USB in serial mode. This is used e.g. in the HostTestApp project. It could be a good start to look at this project for such an implementation.

    Unfortunately there are no specific documentation about the drivers. The best way would be to look at the implementation of the different peripherals and drivers in the example projects.

    Regards,
    Johan 

  • Hi Johan,

    Can I use the USB in HID keyboard mode ?

    Does the BLE stack support  USB HID Keyboard protocol ?   I could find the parameter for keyboard in the source files for HID reports, but pls let me know whether the implementation is complete ? Is there a example application for HID keyboard(using the physical USB, bit the BLE emulated keyboard)?

    Shafy

  • Hi Johan,

    When using in USB Serial mode, can we access the device like a COM port  in Windows and tty in Linux ?

    Please see my previous questions also.

    Thanks in advance

    Shafy

  • Hi,

    We have two example projects that I think could be interesting for you: 

    HIDAdvRemoteDongle is used to for an HID implementation. A CC2540 USB device will detected as an HID input on a PC. 

    When using the project HostTestApp, that are used together with e.g. the PC tool bTool, the device will CC2540 device will instead be displayed as an COM port.

    Have a look at these examples projects and see if you found what you are looking for.

    Regards,
    Johan