CC23x0r2DriverLibrary
[cpu.h] CPU
Collaboration diagram for [cpu.h] CPU:

Functions

void CPUDelay (uint32_t count)
 Provide a small non-zero delay using a simple loop counter. More...
 

Detailed Description

Introduction

The CPU API provides a set of functions performing very low-level control of the system CPU. All functions in this API are written in assembler in order to either access special registers or avoid any compiler optimizations. Each function exists in several compiler specific versions: One version for each supported compiler.

Function Documentation

§ CPUDelay()

void CPUDelay ( uint32_t  count)

Provide a small non-zero delay using a simple loop counter.

This function provides means for generating a constant length delay. It is written in assembly to keep the delay consistent across tool chains, avoiding the need to tune the delay based on the tool chain in use.

Note
It is not recommended using this function for long delays. For longer delays, consider using ROM function HapiWaitUs().
If using an RTOS, consider using RTOS provided delay functions because these will not block task scheduling and will potentially save power.
Interrupts can affect the delay if not manually disabled in advance.
The delay depends on where code resides and the path for code fetching, consider using ROM function HapiWaitUs().
Parameters
countis the number of delay loop iterations to perform. Number must be greater than zero.
See also
HapiWaitUs()
Returns
None

Referenced by I2CControllerCommand().