SWRA466D February   2015  – August 2021 CC1310 , CC1310 , CC1352R , CC1352R , CC2538 , CC2538 , CC2620 , CC2620 , CC2630 , CC2630 , CC2640 , CC2640 , CC2640R2F , CC2640R2F , CC2640R2F-Q1 , CC2640R2F-Q1 , CC2642R , CC2642R , CC2642R-Q1 , CC2642R-Q1 , CC2650 , CC2650 , CC2650MODA , CC2650MODA , CC2652R , CC2652R , CC2652R7 , CC2652R7 , CC2652RB , CC2652RB , CC2652RSIP , CC2652RSIP

 

  1.   Trademarks
  2. 1Introduction
  3. 2ROM Bootloader
    1. 2.1 Configuring the Bootloader
      1. 2.1.1 CC2538
      2. 2.1.2 CC26x0
    2. 2.2 CC26x2
    3. 2.3 Communication Protocol
      1. 2.3.1 ACK/NACK
    4. 2.4 Interface Configuration
      1. 2.4.1 Hardware Pins
      2. 2.4.2 UART Configuration
      3. 2.4.3 Establishing Communication
      4. 2.4.4 Status Command
  4. 3Serial Bootloader Library (SBL)
    1. 3.1 SBL Return Values
    2. 3.2 SBL API
      1. 3.2.1 Device-Specific Functions
  5. 4Example Project
    1. 4.1 Hardware Setup
      1. 4.1.1 SmartRF06EB Virtual COM Port
        1. 4.1.1.1 External Serial Interface
      2. 4.1.2 LaunchPad Virtual COM Port
      3. 4.1.3 Bootloader Backdoor
    2. 4.2 Software Setup
      1. 4.2.1 Device Type
      2. 4.2.2 Baud Rate
    3. 4.3 Program Flow
      1. 4.3.1 Enumerate COM Ports
      2. 4.3.2 Create Device
      3. 4.3.3 Connect
      4. 4.3.4 Erase Flash Range
      5. 4.3.5 Write Flash Range
      6. 4.3.6 Calculate CRC32
      7. 4.3.7 Reset
  6. 5References
  7. 6Revision History

SBL API

An overview of the SBL API is shown in Table 3-2. API functions that directly map to a bootloader command are marked with an X.

Table 3-2 SBL Functions
SBL Function NameBootloader CMDDescription
CC2538CC26x0CC26x2
CreateNANANAStatic function for creating a SBL device object.
calculateCrc32XXXCalculate CRC32 over the specified range.
connectInitialize connection with ROM bootloader
enumerateNANANAStatic function for enumerating COM ports on PC.
eraseFlashBankXXErases the entire flash. Not supported by CC2538.
eraseFlashRangeXXXErase the sectors in the specified range. Uses CMD_SECTOR_ERASE.
pingXXXSends ping command.
readDeviceIdUses CMD_MEMORY_READ to read device ID.
readFlashSizeUses CMD_MEMORY_READ to read flash size.
readMemory32XXXReads 32 bit word from device memory device memory.
readMemory8Uses CMD_MEMORY_READ to read 8 bit from device memory.
readRamSizeUses CMD_MEMORY_READ to read RAM size.
readStatusXXXReads bootloader status.
resetXXXResets device using CMD_RESET.
runXRuns the device CPU from the specified address. Not supported by CC26xx.
setCCFGXXSet CC26xx CCFG. Not supported by CC2538.
setXoscXSwitch to external oscillator. Not supported by CC26xx.
writeFlashRangeXXXWrites FLASH using CMD_DOWNLOAD and CMD_DATA_SEND.
writeMemory32XXXWrites 32-bit word to device memory using CMD_MEMORY_WRITE.
writeMemory8Implements 8-bit write to device memory using CMD_MEMORY_READ and CMD_MEMORY_WRITE.