EasyManua.ls Logo

Texas Instruments TMS320 User Manual

Texas Instruments TMS320
288 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Page #81 background image
Instrumentation APIs
Instrumentation 3-19
The LOG and STS APIs are also used internally by DSP/BIOS to collect
information about program execution. These internal calls in DSP/BIOS
routines provide implicit instrumentation support. As a result, even
applications that do not contain any explicit calls to the DSP/BIOS
instrumentation APIs can be monitored and analyzed using the DSP/BIOS
Analysis Tools. For example, the execution of a software interrupt is recorded
in a LOG object called LOG_system.
In addition, worst-case ready-to-completion times for software interrupts and
overall CPU load are accumulated in STS objects. See section 3.5.4.2,
Control of Implicit Instrumentation, page 3-27, for more information about
what implicit instrumentation can be collected.
3.5.2 Event Log Manager (LOG Module)
This module manages LOG objects, which capture events in real time while
the target program executes.
User-defined logs contain any information your program stores in them using
the LOG_event and LOG_printf operations. You can view messages in these
logs in real time with the CCSv4 Printf Logs RTA tool. To access this tool,
choose Tools > RTA > Printf Logs from the CCStudio menu bar.
A log can be either fixed or circular. This distinction is important in
applications that enable and disable logging programmatically (using the
TRC module operations as described in section 3.4.4, Trace Manager (TRC
Module), page 3-13).
Fixed. The log stores the first messages it receives and stops accepting
messages when its message buffer is full. As a result, a fixed log stores
the first events that occur since the log was enabled.
Circular. The log automatically overwrites earlier messages when its
buffer is full. As a result, a circular log stores the last events that occur.
You configure LOG objects statically and assign properties such as the length
and location of the message buffer.
You specify the length of each message buffer in words. Individual messages
use four words of storage in the log’s buffer. The first word holds a sequence
number. The remaining three words of the message structure hold event-
dependent codes and data values supplied as parameters to operations such
as LOG_event, which appends new events to a LOG object.
As shown in Figure 3-1, LOG buffers are read from the target and stored in a
much larger buffer on the host. Records are marked empty as they are copied
up to the host.

Table of Contents

Other manuals for Texas Instruments TMS320

Question and Answer IconNeed help?

Do you have a question about the Texas Instruments TMS320 and is the answer not in the manual?

Texas Instruments TMS320 Specifications

General IconGeneral
BrandTexas Instruments
ModelTMS320
CategoryComputer Hardware
LanguageEnglish

Summary

IMPORTANT NOTICE

Read This First

About This Manual

Describes the DSP/BIOS v5.40, its purpose, and companion documents.

Notational Conventions

Explains the document's typographical and symbolic conventions for clarity.

Chapter 1 About DSP/BIOS

DSP/BIOS Features and Benefits

Details the advantages of DSP/BIOS, including reduced code size and improved performance.

DSP/BIOS Components

Overviews the DSP/BIOS architecture including Configuration Tool and Analysis Tools.

Naming Conventions

Defines naming rules for modules, objects, operations, and data types in DSP/BIOS.

For More Information

Points to additional resources for further information on DSP/BIOS and related topics.

Chapter 2 Program Generation

Creating and Building a CCSv4 Project for DSP/BIOS Applications

Guides through the process of creating and building DSP/BIOS projects in CCSv4 IDE.

Converting CCSv3.3 Projects to CCSv4 Projects

Provides instructions for migrating existing CCSv3.3 DSP/BIOS projects to CCSv4.

Configuring DSP/BIOS Applications Statically

Explains how to configure DSP/BIOS objects and properties statically for optimal performance.

Creating DSP/BIOS Objects Dynamically

Details how to create and delete DSP/BIOS objects dynamically at runtime for flexibility.

Files Used to Create DSP/BIOS Programs

Lists and describes the various files involved in creating a DSP/BIOS application.

Using Makefiles to Build Applications

Explains how to build DSP/BIOS executables using makefiles as an alternative to CCS projects.

Using DSP/BIOS with the Run-Time Support Library

Discusses the integration and usage of DSP/BIOS with the C run-time support library.

DSP/BIOS Startup Sequence

Describes the step-by-step process of DSP/BIOS application startup and initialization.

Using C++ with DSP/BIOS

Addresses issues and considerations for developing C++ applications with DSP/BIOS.

User Functions Called by DSP/BIOS

Outlines conventions for user functions called by DSP/BIOS objects to ensure proper operation.

Calling DSP/BIOS APIs from Main

Guides on which DSP/BIOS APIs can be safely called from the main routine during initialization.

Chapter 3 Instrumentation

An Overview of Real-Time Analysis

Introduces real-time analysis concepts and its importance in system operation.

Real-Time Analysis Tools in CCStudio v4.x

Describes the Real-Time Analysis (RTA) tools available within CCStudio for debugging.

Runtime Object Viewer (ROV)

Explains the ROV tool for inspecting application state information at stop points.

Instrumentation Performance

Discusses the impact of instrumentation on application performance and optimization techniques.

Instrumentation APIs

Details the LOG, STS, and HST API modules for gathering and controlling instrumentation data.

Implicit DSP/BIOS Instrumentation

Explains how DSP/BIOS automatically provides instrumentation for analysis tools like CPU load.

Instrumentation for Field Testing

Discusses using DSP/BIOS instrumentation for production systems and field diagnostics.

Real-Time Data Exchange

Covers RTDX for real-time, continuous visibility into DSP application operation.

Chapter 4 Thread Scheduling

Overview of Thread Scheduling

Introduces threads, their types, priorities, and interaction within DSP/BIOS applications.

Hardware Interrupts

Details how hardware interrupts handle critical processing and manage hardware interactions.

Software Interrupts

Explains software interrupts (SWI) for handling tasks with less severe real-time deadlines.

Tasks

Describes DSP/BIOS task objects (threads) managed by the TSK module for dynamic scheduling.

The Idle Loop

Explains the idle loop as the background thread for low-priority, non-critical tasks.

Power Management

Covers the DSP/BIOS Power Manager (PWRM) module for reducing application power consumption.

Semaphores

Details semaphores for intertask synchronization and communication based on resource availability.

Mailboxes

Explains mailboxes for structured sending and receiving of variable length messages.

Timers, Interrupts, and the System Clock

Discusses on-device timers, system clock, and timing methods in DSP/BIOS.

Periodic Function Manager (PRD) and the System Clock

Covers scheduling periodic functions based on I/O availability or programmed events using PRD.

Chapter 5 Memory and Low-level Functions

Memory Management

Details the Memory Section Manager (MEM module) for managing named memory segments and allocation.

System Services

Describes the SYS module for basic system services like halting execution and error handling.

Queues

Explains the QUE module for managing lists of queue elements, often used for FIFO lists.

Chapter 6 Input/Output Methods

I/O Overview

Introduces application-level I/O handling via streams, pipes, message queues, and host channels.

Comparing Pipes and Streams

Compares the pipe and stream models for data transfer supported by DSP/BIOS.

Comparing Driver Models

Details the IOM and SIO/DEV device driver models for communicating with DSP peripherals.

Data Pipe Manager (PIP Module)

Explains the PIP module for managing block I/O, including writer/reader ends and data notification.

Message Queues

Covers the MSGQ module for structured sending and receiving of variable length messages, especially for multi-processor systems.

Host Channel Manager (HST Module)

Describes the HST module for streaming data between the target and host files via SIO streams.

I/O Performance Issues

Discusses performance considerations for I/O operations, including HST data transfer.

Chapter 7 Streaming I/O and Device Drivers

Overview of Streaming I/O and Device Drivers

Introduces device drivers using the DEV_Fxns model and the SIO module for streaming I/O.

Creating and Deleting Streams

Explains how to create and delete streams statically in configuration or dynamically at runtime.

Stream I/O—Reading and Writing Streams

Details the standard and Issue/Reclaim models for streaming data read/write operations.

Stackable Devices

Covers the SIO module's capabilities for creating virtual I/O devices by stacking drivers.

Controlling Streams

Explains how to control streams using SIO_ctrl, SIO_idle, and SIO_flush for device communication.

Selecting Among Multiple Streams

Describes SIO_select for waiting on I/O operations across multiple streams without blocking.

Streaming Data to Multiple Clients

Discusses efficient multi-cast data transmission to multiple clients using SIO streams.

Streaming Data Between Target and Host

Covers configuring host channel objects (HST) for streaming data between target and host files.

Device Driver Template

Presents an example device driver template (Dxx) with C code and pseudocode for operations.

Streaming DEV Structures

Details the DEV_Fxns and DEV_Frame structures used by SIO and device drivers for buffer management.

Device Driver Initialization

Explains the Dxx_init function for performing hardware initialization and static driver setup.

Opening Devices

Guides on opening Dxx devices using SIO_create and Dxx_open, including parameter handling.

Real-Time I/O

Describes the DEV_STANDARD and DEV_ISSUERECLAIM models for real-time I/O operations.

Closing Devices

Explains how to close devices using SIO_delete, which calls Dxx_idle and Dxx_close.

Device Control

Details the SIO_ctrl function for performing control operations on a device via Dxx_ctrl.

Device Ready

Explains Dxx_ready called by SIO_select to determine if a device is ready for I/O operations.

Types of Devices

Differentiates between terminating and stackable devices and their implementations.

Related product manuals