CC1350 Launchpad
project 0

Congratulations on choosing the CC1350 Wireless MCU and LaunchPad ecosystem! The CC1350 wireless microcontroller(MCU) device is part of TI’s SimpleLink MCU platform, offering a single development environment that delivers flexible hardware, software and tool options for customers developing wired and wireless applications. For more information about the SimpleLink MCU platform, visit www.ti.com/simplelink. This example will show you how to build/compile your own images for use with the BLE OAD service using Code Composer Studio.

Before starting on this tutorial you need to download and install Code Composer Studio 7.1 or later.

You will also need the CC13x0 SDK 1.30 or later installed.

We will use the rfWsnDmNode example in CCS as a basis for this tutorial. Basically any of the examples in the CC13x0 SDK 1.30 (or later) can be used to build a OAD capable image, but since the rfWsnNode and rfWsnConcentrator examples already contain code for getting back to BLE stack mode (i.e. double button press > 5s) we will for the sake of simplicity use this as a starting point.

1
Import the following projects to the workspace from the CC1350_LAUNCHXL development board in resource explorer:
  • bim_extflash_cc1350lp
  • simple_peripheral_cc1350lp_app_FlashOnly_OAD_ExtFlash
  • rfWsnDmNode_CC1350_LAUNCHXL_tirtos_ccs
2
Install the python tools

Clone or copy the OAD conversion script at ti-simplelink Github

  • Click on the folder `oad`
  • Click on the file `oad_image_tool.py`
  • Make a note of the Python version required (scroll down).
  • Copy the content to a text file, save as `oad_image_tool.py`

install `python`

  • Use version stated in `oad_image_tool.py`
  • During setup, enable feature `Add python.exe to path`

install `crcmod`

  • Download sourcefile from python.org
  • Extract the files
  • Cd into the dir and run 'python setup.py install'

install `intelhex`

  • Download from python.org
  • Extract the files
  • Cd into the dir and run 'python setup.py install'
1
Build the required BLE projects:
  • bim_extflash_cc1350lp
  • simple_peripheral_cc1350lp_app_FlashOnly_OAD_ExtFlash
2
Copy the generated hex files from
  • bim_extflash_cc1350lp/FlashOnly
  • simple_peripheral_cc1350lp_app_FlashOnly_OAD_ExtFlash/Debug
  • simple_peripheral_cc1350lp_stack_FlashROM/Debug

to the same directory as oad_image_tool.py on your PC.

3
Create a merged Bim, App and Stack:
  • cd [path_to_script]
  • python oad_image_tool.py bim_extflash_cc1350lp.hex simple_peripheral_cc1350lp_app_FlashOnly_OAD_ExtFlash.hex simple_peripheral_cc1350lp_stack_FlashROM.hex -o simple_peripheral_cc1350lp_OAD_bim-app-stack.hex -i production -t offchip
4
Switching back to BLE from the Sub1-GHz OAD firmware images requires a BLE App+Stack image to be loaded into the OAD Stack area. Create a BLE App and Stack OAD binary image:
  • cd [path_to_script]
  • python oad_image_tool.py simple_peripheral_cc1350lp_app_FlashOnly_OAD_ExtFlash.hex simple_peripheral_cc1350lp_stack_FlashROM.hex -ob simple_peripheral_cc1350lp_OAD_app-stack.bin -i stack -t offchip
1
Expand the `rfWsnDmNode` from the Resource Explorer in Code Composer Studio.
2
In Project Properties -> General, check that you are using the ARM compiler from TI.
3
In Project Properties -> ARM Compiler -> Advanced Options -> predefined symbols, add `FEATURE_OAD` define.
4
In Project Properties -> ARM Hex Utility -> check `Enable ARM Hex` Utility.
5
Remove `CC1350_LAUNCHXL_TIRTOS.cmd` from the rfWsnDmNode_CC1350_LAUNCHXL_tirtos_ccs project.
6
Include the `cc26xx_app_oad.cmd` linker command file into the rfWsnDmNode_CC1350_LAUNCHXL_tirtos_ccs project. This can be 'drag and dropped' in the workspace from simple_peripheral_cc1350lp_app_FlashOnly_OAD_ExtFlash/TOOLS to rfWsnDmNode_CC1350_LAUNCHXL_tirtos_ccs
7
Remove `release.cfg` from tirtos_builds_CC1350_LAUNCHXL_release_ccs.
8
Include the `app_ble.cmd` ccs config file in to the tirtos_builds_CC1350_LAUNCHXL_release_ccs project. This can be 'drag and dropped' in the workspace from simple_peripheral_cc1350lp_app_FlashOnly_OAD_ExtFlash/TOOLS to tirtos_builds_CC1350_LAUNCHXL_release_ccs
9
Right-click on the `ccfg.c` file in the rfWsnDmNode_CC1350_LAUNCHXL_tirtos_ccs project, then select the item `Exclude from Build`
10
Right-click on the tirtos_builds_CC1350_LAUNCHXL_release_ccs project and select Properties. Under XDCTools -> Advanced options add `OAD_IMG_E=1, NO_ROM=1` to the cfgArgs

11
Rebuild the tirtos_builds_CC1350_LAUNCHXL_release_ccs project
12
Rebuild the rfWsnDmNode_CC1350_LAUNCHXL_tirtos_ccs project to generate the intel hex file. This file is placed in the Debug folder of the project
13
Move the generated hex file from rfWsnDmNode_CC1350_LAUNCHXL_tirtos_ccs/Debug to the same directory as oad_image_tool.py on your PC.
14
Convert the rfWsnDmNode_CC1350_LAUNCHXL_tirtos_ccs.hex to the format required by the iOS OAD app
  • python oad_image_tool.py rfWsnDmNode_CC1350_LAUNCHXL_tirtos_ccs.hex -ob rfWsnDmNode_CC1350_LAUNCHXL_tirtos_ccs_oad-app.bin -i app -t offchip -m 0x1000
1
Send `simple_peripheral_cc1350lp_OAD_app-stack.bin` and `rfWsnDmNode_CC1350_LAUNCHXL_tirtos_ccs_oad.bin` to an email account that you can access from you iOS device.
2
Open the SensorTag app on the iOS device, if the CC1350LP is running the BLE FW give it a reset and you should see it in the list of devices, click on the CC135LP and open the sensor view.
3
Open the e-mail on the iOS device, `*.bin` files and click the attachments (1 by 1) and open with the SensorTag App.
4
When it switches back to the SensorTag App select FW Download then select the simple_peripheral_cc1350lp_OAD_app-stack.bin file that was in the e-mail which should now be in the list of available firmwares. The BLE Simple Peripheral OAD application needs to be OAD'ed so it is stored in external flash. This will enable the Sub1G FW to switch back to BLE for further OAD FW updates.
5
When the device reboots select FW Download again then select the rfWsnDmNode_CC1350_LAUNCHXL_tirtos_ccs_oad.bin file that was in the e-mail which should now be in the list of available firmwares.
6
The rfWsnDmNode_CC1350_LAUNCHXL_tirtos_ccs_oad App should be downloaded to the LP, once downloaded the CC1350LP will reset and run your app!
7
To get back to the BLE stack/app mode press and hold `BTN-1` and `BTN-2` for >5s until the green led blinks rapidly (note this requires the button logic from the one of the fWsnDm examples). If the BLE FW does not start you may need to reset the device manually.

To see all available resources associated with the CC1350, click on this link to filter out all the incompatible projects and collateral.

Available in resource explorer are code examples from the CC13x0 SDK, documentation, Software Developers Guide and links to wiki articles and more. Feel free to navigate the available resources to jump-start your development.

  • CCS Cloud IDE: Develop your code right in the cloud. Use this tool to import, modify and program code examples for your LaunchPad. Click CCS Project Import Icon anywhere in TI Resource Explorer to import that project into Cloud IDE. Cloud IDE will be automatically started with that project to get your started with development. my.ti.com login is required for use of Cloud IDE.
  • Booster Pack checker: Verify whether Booster Packs are compatible with your LaunchPad.