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.

CC2642R: Need to unpair the device every time

Part Number: CC2642R
Other Parts Discussed in Thread: SYSCONFIG

Hi all,

I am doing some work on cc2642 with latest SDK 5.10. I am using example codes from SDK (BIM, Persistent, Simple peripheral OAD) and creating super hex from these examples  to flash the device.After flashing the device,it is discoverable and i can connect to but the problem is every time i need to unpair the device first then again pair and then connect which is not right according to my application. Why this is happening and how to resolve it??? Any help on this will be appreciated.

Thanks.

  • Hello,

    I have assigned an expert to comment. In the meantime, I recommend looking at the SLA OAD lab. The lab covers how to set up and work with OAD. The lab also provides a detailed description of how OAD works as well.

    Regards,

    Jan

  • Hey Bipin,

    Can you outline the steps you are taking? It is not uncommon for user's to need to unpair the device from there phone in the initial steps, but this shouldn't be required each time.

  • Hi Ammar,

    I am using SREC tool to create super.hex out of 2 hex(bim app and persistent app)and bin of simple peripheral onchip OAD.after flashing the device with super.hex when i try to connect to deviceit just cant connect to device.need to unpair the device first.then again pairing connection needs to performed.then only device gets connected.

  • Hey Bipin,

    Are you performing this test using a launchpad? What device are you using as your central?

    Can you provide sniffer logs so we can see the reason for the failed connection attempt? If you use a launchpad as the central (with host_test flashed and BTOOL as the OAD target), you might find the disconnect or pair fail reason in those logs.

    I have tested the out of box examples with an Android/iOS device and did not have any trouble with the initial connection. I used the Simple Starter app, and in fact, the phones did not store the bond information so I could not "unpair".

  • Hey Bipin,

    To follow up, please see this comment in our User's Guide. Here's a link to the "Setting up the BLE OAD Environment" section where you will find the comment that pertains to your question: https://dev.ti.com/tirex/explore/content/simplelink_cc13x2_26x2_sdk_5_10_00_48/docs/ble5stack/ble_user_guide/html/ble-stack-oad/setting-up-environment.html

    Under OAD Target Setup, see step 6.

    The default address mode for the simple_peripheral_oad_onchip example is set to Resolvable Private Address with Public Identity Address (ADDRMODE_RP_WITH_PUBLIC_ID). In the next section Performing a BLE OAD, the OAD distributor (Btool + HostTest) will reset the OAD target (simple_peripheral_oad_onchip) by writing a command to the OAD Reset Service (OAD Reset Service (0xFFD0)) to make the OAD target reboot into the OAD persistent App which will handle the OAD transfer. The persistent app use public address mode (ADDRMODE_PUBLIC). In this case BTool will automatically try to re-connect to the previous random address which does not exist anymore. To make te OAD procedure easier with BTool you can change the default address mode for simple_peripheral_oad_onchip to public mode. Open simple_peripheral_oad_onchip.syscfg (double-click on file in CCS), navigate in the GUI to RF STACKS -> BLE -> General Configuration, change the default address mode to Public Address and rebuild the project. The default address mode is set in the SysConfig generated file ti_ble_config.h.

  • Hi Ammar,

    I have done all the setting said by you already.Yes  i am using Launchpad as central device. I am using "Ti_oad_example" android app to perform OAD.From above application i am downloading desired binary file in launch pad and its working fine. Only problem is before connecting to device,i need to unpair the device first.Following are the steps i am following

    1)creating super.hex with 3 files from example (BIM,Persistent app,Simple peripheral onchip oad app)using srec tool.

    2)Flashing the super.hex in launchpad.

    3)From mobile application,writing 0x01 to OAD reset service so that device can enter in persistent app.

    4)from "Ti_oad_example" app ,downloading New binary to device.

    all these working fine. all settings are same as you mentioned above. but when connecting to device every time, it gets disconnected every time until i unpair it and again pair it.

    i hope this clears everything from my side.

  • Hey Bipin,

    The TI_oad_example mobile app is no longer supported. We make the source code for the app available to assist in mobile app development. but unfortunately, as I am not an expert in Android app development, I cannot assist with any issues with the app.

    I recommend trying the TI SimpleStarter App instead.