SWRA845 June   2026 CC2340R5 , CC2745R10-Q1

 

  1.   1
  2.   Abstract
  3. 1Links to Hardware and Software Design References
    1. 1.1 Data Sheet and User Guide
    2. 1.2 Required and Recommended Software for Environment Setup
    3. 1.3 SDK Examples
    4. 1.4 Hardware Design References
    5. 1.5 Power Calculator Table
    6. 1.6 Links to Product QDID Certificates
    7. 1.7 HSM (CC2745) Certification
  4. 2CCS 20.0-Based Debugging Methods
    1. 2.1 How to Map a Project File to the Customer's Own Board
    2. 2.2 Evaluating RAM Consumption and Checking for Stack Overflow With Map File and ROV
    3. 2.3 How to Port Your Project in CCS 12.x to CCS 20.x for Debugging
    4. 2.4 Performing Chip Erase on the CC2745
    5. 2.5 How to Debug a Project (.out) Directly in CCS 20.x Without Importing Project Code
    6. 2.6 How to Verify Whether the Chip's RF Is Working Properly
  5. 3FAQs for Development Using CC2340 and CC2745
    1. 3.1  Why Does the Program Fail to Run Correctly Although It Has Been Successfully Flashed via UniFlash or CCS
    2. 3.2  How to Change the Tx Power for Bluetooth Devices
    3. 3.3  Why Does My Program Enter iCall_abort
    4. 3.4  How to Debug a Project with MCUboot
    5. 3.5  How to Adjust the Flash Location and Size of the App in an OAD Application
    6. 3.6  How to Customize a Section in .cmd and Use it in Code
    7. 3.7  How to Use the Non-initialized Variable Section
    8. 3.8  How to Simultaneously Send Two ADV Sets With Public and RPA Addresses
    9. 3.9  What is the Difference Between E0 and E1 on the CC2745R10 Chip
    10. 3.10 How to Enable More DMA Channels to Support My Driver Requirements

How to Use the Non-initialized Variable Section

A non-initialized variable section is the memory region that is not cleared or reassigned upon system power-up or soft reset (such as an OTA upgrade), and contains data that must be preserved after a program restart.

To define and use variables in the non-initialized variable section, three steps are required:

  1. In the .cmd file mentioned above, declare the space within SECTIONS in RAM, as shown in the figure.
    .TI.noinit : > SRAM, type = NOINIT
  2. To place data in a non-initialized variable section, the application must use compiler attributes to declare it and assign it to the .TI.noinit section.

    __attribute__((noinit)) int noinit_global;
    __attribute__((noinit,location(0x100))) int noinit_location_global;
    
  3. Using this variable in your code to build your program will add the corresponding definition to Memory Allocation.

The code in the figure above is an example. A soft reset occurs every 5 seconds. noinit_global will increment continuously and will not be initialized to 0.

Note that a hardware reset (power cycle/reset pin reset) will reset this variable. If power-down hold is required, use non-volatile (NV) memory.