• Join
  • Sign In with my.TI Login
Texas Instruments
  • Products
  • Applications
  • Tools & Software
  • Support & Community
  • Sample & Buy
  • About TI
Sample & Purchase Cart Sample & Purchase Cart
  • Search
  • Advanced
TI E2E™ Community
  • Support Forums
  • Blogs
  • Groups
  • Videos
  • 简体中文
  • More ...
TI Home » TI E2E Community » Support Forums » Low Power RF & Wireless Connectivity » Low Power RF Bluetooth® Low Energy & ANT Forum » USING BTOOL (OR MORE?) TO SERVE AS BLE PERIPHERAL
Share
Low Power RF & Wireless Connectivity
  • Forums
  • Announcements
  • Files
  • E2E Wiki
Options
  • Subscribe via RSS

USING BTOOL (OR MORE?) TO SERVE AS BLE PERIPHERAL

USING BTOOL (OR MORE?) TO SERVE AS BLE PERIPHERAL

This question is answered
Michael Powell
Posted by Michael Powell
on Aug 07 2012 15:36 PM
Prodigy130 points

I've been tasked with developing a BLE app for the iPhone 4S. A colleague (who lives and works about an hour away) will be using the TI CC2540 kit to develop the peripherals with which the iPhone will interact. I'd like to be able to use BTool and the CC2540 USBDongle to serve as a test peripheral, just to validate that the app under development can do the most elementary things. I have an old Windows XP system, bought the Dongle (and a CC Debugger to reflash it)  and have installed what I think is all the necessary support, though not without a struggle (being a tyro here). At this point, BTool sees the Dongle, but I'm unclear as to how to get it to (1) tell the Dongle to be a slave and (2) advertise something (Generic Access would be fine).

Some stale advice on this general subject seems to be out of date, for instance referencing hex files other than cc2540_usbdongle_hosttestrelease_all.hex, which seemed to be the only really plausible candidate (assuming that cc2540minidkdemoslave.hex isn't suitable) when I used the CC Debugger to reflash the Dongle. In it (the older advice) mention was made of ways to use BTool to tell the Dongle to be a slave, but the ways mentioned don't seem to be applicable now.

If anyone at TI aspires to be a true benefactor to mankind (or at least to a subset of its geek subset), my recommendation would be to compose a Windows program (runnable on XP and up) which would, like BTool, use the CC2540 USBDongle, and, in addition, would automatically put it into slave mode, and then would use it to advertise a BLE Service, the hex string for which would be enterable (in the full standard form xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx). It would not be required to actually provide any Characteristics, only advertise the Service (since Core Bluetooth uses that to filter out candidates when it scans). However, it could usefully provide some simple Services, with Characteristics as described at https://developer.bluetooth.org/gatt/services/Pages/ServicesHome.aspx, and I'd recommend Generic Access, Device Information, Battery Service and Tx Power.

Making a case for such a tool, I offer the following: My colleague who is developing for the peripheral with the TI kit does not have as warm a feeling communicating ONLY with a master developed by TI, as he would were he to see communication with something else entirely, no easy task in itself. However, with Mountain Lion and a late-model Mac Mini, there is hope that he can now do so. My predicament isn't the mirror image of his, since I don't have anything at all with which to communicate, but my need for a warm feeling equally strong.

iPhone 4S slave mode advertise service CC2540 USBDongle Windows Utility
Report Abuse
  • Reply
You have posted to a forum that requires a moderator to approve posts before they are publicly available.
All Replies
  • Joakim Lindh
    Posted by Joakim Lindh
    on Aug 08 2012 01:46 AM
    Verified Answer
    Verified by Michael Powell
    Genius13370 points

    Hi Michael,

    You will find the steps you are looking for in this post: http://e2e.ti.com/support/low_power_rf/f/538/p/187762/732079.aspx#732079. Essentially you need to issue three commands from the Adv. commands tab of BTool:

    • GAP_DeviceInit, set profileRole to Peripheral and hit Send Command
    • GAP_UpdateAdvertisingData, set adType toGAPADVERT_ADVERTISEMENT_DATA and set dataLen to 3 and hit Send Command.
    • GAP_MakeDiscoverable, make sure that you see the available options for it (no need to make changes) and hit Send Command.

    I hope that work things out for ya.

    Best Regards

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Michael Powell
    Posted by Michael Powell
    on Aug 08 2012 15:26 PM
    Prodigy130 points

    Hi Nick,

    Thanks!

    It did the trick. As evidence, I'll offer the image below (if I can get it in).

    At some point, I'll try to put a reply on this thread that describes how an idiot (and I feel no shame about it) managed to get to the point where (without buying a Wahoo Heart Monitor for $80, but, instead, only spending $100 on the TI Dongle and CC Debugger) he managed to get his iPhone 4S to see something BLE.

    Warm Regards,

    Mike

    iPhone 4S slave mode CC2540 USBDongle Advertise
    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
TI E2E™ Community
  • Support Forums
  • Blogs
  • Videos
  • Groups
  • Site Support & Feedback
  • Settings
TI E2E™ Community Groups
  • TI University Program
  • Make the Switch
  • Microcontroller Projects
  • Motor Drive & Control
Other Communities
  • Deyisupport
  • Designsomething.org
  • beagleboard.org
  • TI on Element 14
  • TI on TechXchangeSM
Other Technical & Support Resources
  • WEBENCH® Design Center
  • Product Information Centers
  • Technical Documents
  • TI Design Network
  • TI Technical Articles
  • TI Training

All content and materials on this site are provided "as is". TI and its respective suppliers and providers of content make no representations about the suitability of these materials for any purpose and disclaim all warranties and conditions with regard to these materials, including but not limited to all implied warranties and conditions of merchantability, fitness for a particular purpose, title and non-infringement of any third party intellectual property right. TI and its respective suppliers and providers of content make no representations about the suitability of these materials for any purpose and disclaim all warranties and conditions with respect to these materials. No license, either express or implied, by estoppel or otherwise, is granted by TI. Use of the information on this site may require a license from a third party, or a license from TI.

Content on this site may contain or be subject to specific guidelines or limitations on use. All postings and use of the content on this site are subject to the Terms of Use of the site; third parties using this content agree to abide by any limitations or guidelines and to comply with the Terms of Use of this site. TI, its suppliers and providers of content reserve the right to make corrections, deletions, modifications, enhancements, improvements and other changes to the content and materials, its products, programs and services at any time or to move or discontinue any content, products, programs, or services without notice.

Follow Us Texas Instruments on Facebook Texas Instruments on Twitter Texas Instruments on LinkedIn Texas Instruments on Google+
TI Worldwide | Contact Us | my.TI Login | Site Map | Corporate Citizenship | mobile m.ti.com (Mobile Version)

TI is a global semiconductor design and manufacturing company. Innovate with 100,000+ analog ICs and
embedded processors, along with software, tools and the industry’s largest sales/support staff.

© Copyright 1995-2013 Texas Instruments Incorporated. All rights reserved.
Trademarks | Privacy Policy | Terms of Use