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.

CC2340R5: as central role, how to add customer services

Part Number: CC2340R5

Tool/software:

Hi 

My customer is developing CC2340R5 as central.

they refer to basic_ble_GATT_Client_7.40.

ble_examples/examples/rtos/LP_EM_CC2340R5/ble5stack/basic_ble_GATT_client at simplelink_low_power_f3_sdk-7.40 · TexasInstruments/ble_examples · GitHub

peripheral device is using the service and characteristics below.

« Air BLE Service»:0x45, 0x4C, 0x42, 0x61, 0x68, 0x6F, 0x72, 0x69, 0x41, 0x03, 0xAB, 0x2D, 0x4D, 0x49, 0x52, 0x50

The characteristics UUIDs are as below.

« Air BLE Rx»:0x45, 0x4C, 0x42, 0x61, 0x68, 0x6F, 0x72, 0x69, 0x41, 0x32, 0xAB, 0x2D, 0x52, 0x41, 0x48, 0x43

« Air BLE Tx»:0x45, 0x4C, 0x42, 0x61, 0x68, 0x6F, 0x72, 0x69, 0x41, 0x31, 0xAB, 0x2D, 0x52, 0x41, 0x48, 0x43

they found the service by scan, but characteristics was not found.

how to found the characteristics?

also, Could you help me to create a callback function to transfer data using the service after connection?

thanks

Best regards,

 

  • Hello Robin,

    Thanks for reaching out. May I ask you how you are including this new characteristics presently? How are you modifying the gatt_table? How are you discovering the new characteristics using the basic_ble_GATT_Client_7.40 (central device)?

    We are soon going to release a training material for developing a Custom Profile. In the meantime, I can share this one with you: Bluetooth low energy Custom Profile, please consider it is not the same device being used in this tutorial as well as the example code, but it can be useful as a reference.

    BR,

    David.

  • hi David 

    we found the AirBLE Service on the central device, but we don't know what to do next.

    please help me how to include custom service and characteristics.

    also, How do I try connect on Central after scan stop?

    could you include the service and characteristics above in the basic_ble_GATT_Client_7.40 examples?

    thanks

  • Hello Robin,

    What do you mean by " include the service and characteristics above in the basic_ble_GATT_Client_7.40 examples"? I would suggest first using the Simple Link Connect App (mobile app) to connect to the peripheral and verify that the gatt table (with its characteristics) is properly discovered. Could you please share the screenshot after connecting and showing the profile?

    On how to include costume service and characteristics I would suggest to take a look at Task Implementation of a Service in the provided Lab.

    BR,

    David.

  • hi David

    We communicate with other devices because we use CC2340R5 as the central role.
    Please tell me how to communicate using the user service of the other device mentioned above.

    we found the user service UUID, but we don't know the next step.

     

    thanks

  • Hello Robin,

    May I ask how are you proceeding with the Gatt discovery? A code snipped would be helpful.

    If you know the service: After the link is established you can use GATT_DiscPrimaryServiceByUUID() API. If the service is found, then the ATT_FIND_BY_TYPE_VALUE_RSP event will be posted to the application and there we discovery all of the characteristics using GATT_DiscAllChars(). If it is desired to discover characteristic using UUID, then the GATT_DiscCharsByUUID() API should be used and the way to use it is very similar to the service API mentioned earlier.

    BR,

    David.