logo资料库

TM4C123G开发板、芯片手册.pdf

第1页 / 共278页
第2页 / 共278页
第3页 / 共278页
第4页 / 共278页
第5页 / 共278页
第6页 / 共278页
第7页 / 共278页
第8页 / 共278页
资料共278页,剩余部分请下载后查看
TM4C123GXL-LaunchPad-00
Important Notice
Revision History
Mailing Address
Table of Contents
TM4C123GXL-LaunchPad-01
Introduction
Chapter Topics
TI Processor Portfolio and Tiva C Series Roadmap
Tiva™ TM4C123G Series Overview
TM4C123GH6PM Specifics
LaunchPad Board
Lab1: Hardware and Software Set Up
Objective
Procedure
Hardware
Download and Install Code Composer Studio (
Install TivaWare™ for C Series (Complete) (
Install LM Flash Programmer (
Download and Install Workshop Lab Files (
Download Workshop Workbook (
Terminal Program (
Windows-side USB Examples (
Download and Install GIMP (
LaunchPad Board Schematic
Helpful Documents and Sites (
Kit Contents (
Initial Board Set-Up (
QuickStart Application
TM4C123GXL-LaunchPad-02
Code Composer Studio
Chapter Topics
Tiva C Series Development Tools
TI Software and Ecosystem
Code Composer Studio Functional Overview
Target Configuration and Emulators
Projects and Workspaces
Creating a New Project and Adding Files
Portable Projects
Path and Build Variables
Build Configurations
Licensing and Pricing
Lab2: Code Composer Studio
Objective
Lab 2 Procedure
Folder Structure for the Labs
Create a New CCS Project
Add Path and Build Variables
Add files to your project
Explore Build Configurations
Build, Load, Run
Perspectives
Terminate the debug session.
VARS.INI – An Easier Way to Add Variables
Using VARS.INI – Conclusion
LM Flash Programmer
Optional: Creating a bin File for the Flash Programmer
TM4C123GXL-LaunchPad-03
TivaWare™, Initialization and GPIO
Chapter Topics
TivaWare
Clocking
GPIO
Lab 3: Initialization and GPIO
Objective
Procedure
Create lab3 Project
Header Files
Main() Function
Clock Setup
SysCtlClockSet(SYSCTL_SYSDIV_5|SYSCTL_USE_PLL|SYSCTL_XTAL_16MHZ|SYSCTL_OSC_MAIN);
GPIO Configuration
The base addresses of the GPIO ports listed in the User Guide are shown below. Note that they are all within the memory map’s peripheral section shown in module 1. APB refers to the Advanced Peripheral Bus, while AHB refers to the Advanced High-Perfor...
While() Loop
Startup Code
Set the Build Options
Compile, Download and Run the Code
Examine the Tiva C Series Pin Masking Feature
TM4C123GXL-LaunchPad-04
Interrupts and the Timers
Chapter Topics
Cortex-M4 NVIC
Cortex-M4 Interrupt Handing and Vectors
General Purpose Timer Module
Lab 4: Interrupts and the Timer
Objective
Procedure
Import Lab4 Project
Header Files
Main() Function
Clock Setup
GPIO Configuration
Timer Configuration
Calculate Delay
ui32Period = (SysCtlClockGet() / 10) / 2; TimerLoadSet(TIMER0_BASE, TIMER_A, ui32Period -1);
Interrupt Enable
Timer Enable
Main Loop
Timer Interrupt Handler
Startup Code
Pre-defined Name
Compile, Download and Run The Code
Exceptions
TM4C123GXL-LaunchPad-05
ADC12
Chapter Topics
ADC12
Sample Sequencers
Lab 5: ADC12
Objective
Procedure
Import lab5 Project
Header Files
Driver Library Error Routine
Main()
Inside the while(1) Loop
Add Pre-defined Symbol
Build and Run the Code
Breakpoint
Hardware averaging
Calling APIs from ROM
Build, Download and Run Your Code
TM4C123GXL-LaunchPad-06
Hibernation Module
Chapter Topics
Low Power Modes
Lab 6: Low Power Modes
Objective
Procedure
Import lab6
Limitations
Header Files
Error Function
Main Function
Clock Setup
GPIO Configuration
Hibernate Configuration
SysCtlPeripheralEnable(SYSCTL_PERIPH_HIBERNATE); HibernateEnableExpClk(SysCtlClockGet()); HibernateGPIORetentionEnable(); SysCtlDelay(64000000); HibernateWakeSet(HIBERNATE_WAKE_PIN); GPIOPinWrite(GPIO_PORTF_BASE,GPIO_PIN_3, 0x00);
Hibernate Request
► Click the Save button to save your work. Your code should look something like the next page:
Build, Download and Run the VDD3ON (no RTC) Code
Measure the Current
Wake Up on RTC
TM4C123GXL-LaunchPad-07
USB
Chapter Topics
USB Basics
TM4C123GH6PM USB
USB Hardware and Library
Lab 7: USB
Objective
Procedure
Example Code
Import The Project
Build, Download and Run The Code
Digging Deeper
Watch the Buffers
TM4C123GXL-LaunchPad-08
Memory
Chapter Topics
Internal Memory
Flash
EEPROM
SRAM
Bit-Banding
Memory Protection Unit
Priority Levels
Lab 8: Memory and the MPU
Objective
Procedure
Import lab8
Writing to Flash
Build, Download and Run the Flash Programming Code
Reading and Writing EEPROM
Build, Download and Run the EEPROM Programming Code
Further EEPROM Information
Bit-Banding
Memory Protection Unit (MPU)
TM4C123GXL-LaunchPad-09
Floating-Point Unit
Chapter Topics
What is Floating-Point and IEEE-754?
Floating-Point Unit
CMSIS DSP Library Performance
Lab 9: FPU
Objective
Procedure
Import lab9
Browse the Code
Build, Download and Run the Code
Profiling the Code
TM4C123GXL-LaunchPad-10
BoosterPacks and grLib
Chapter Topics
LaunchPad Boards and BoosterPacks
KenTec TouchSceen TFT LCD
Graphics Library
Lab 10: Graphics Library
Objective
Procedure
Connect the KenTec Display to your LaunchPad Board
Import Project
Build, Download and Run the Demo
Writing Our Own Code
Modify pic.c
Main.c
Pointer to the Image Array
Driver Library Error Routine
Main()
Displaying the Image
Build and Run the Code
Display Text On-Screen
Build, Load and Test
Drawing Shapes
Build, Load and Test
Widgets
Build, Load and Test
TM4C123GXL-LaunchPad-11
Synchronous Serial Interface
Chapter Topics
Features and Block Diagram
Interrupts and µDMA Operation
Signal Formats
Lab 11: SPI Bus and the Olimex LED BoosterPack
Objective
Procedure
Hardware
Faces Code
Import Lab11
Build and Load
Run and Test
TM4C123GXL-LaunchPad-12
UART
UART Features and Block Diagram
Basic Operation
UART Interrupts and FIFOs
UART “stdio” Functions and Other Features
Lab 12
Objective
Procedure
Import Lab12
Build, Download, and Run the UART Example Code
Using UART Interrupts
TM4C123GXL-LaunchPad-13
µDMA
Chapter Topics
Features and Transfer Types
Block Diagram and Channel Assignment
Channel Configuration
Lab 13: µDMA
Objective
Procedure
Import Lab13
Browse the Code
Build, Download and Run the Code
Streaming Data To and From the UART using a Ping-Pong Buffer
Code Changes
Browse the Code
Build, Load and Run
Z-EK-TM4C123GXL Rev A Schematic
Getting Started with the Tiva™ TM4C123G LaunchPad Workshop Student Guide and Lab Manual Revision 1.04 June 2013 Technical Training Organization
Important Notice Important Notice Texas Instruments and its subsidiaries (TI) reserve the right to make changes to their products or to discontinue any product or service without notice, and advise customers to obtain the latest version of relevant information to verify, before placing orders, that information being relied on is current and complete. All products are sold subject to the terms and conditions of sale supplied at the time of order acknowledgment, including those pertaining to warranty, patent infringement, and limitation of liability. TI warrants performance of its semiconductor products to the specifications applicable at the time of sale in accordance with TI’s standard warranty. Testing and other quality control techniques are utilized to the extent TI deems necessary to support this warranty. Specific testing of all parameters of each device is not necessarily performed, except those mandated by government requirements. Customers are responsible for their applications using TI components. In order to minimize risks associated with the customer’s applications, adequate design and operating safeguards must be provided by the customer to minimize inherent or procedural hazards. TI assumes no liability for applications assistance or customer product design. TI does not warrant or represent that any license, either express or implied, is granted under any patent right, copyright, mask work right, or other intellectual property right of TI covering or relating to any combination, machine, or process in which such semiconductor products or services might be or are used. TI’s publication of information regarding any third party’s products or services does not constitute TI’s approval, warranty or endorsement thereof. Copyright  2013 Texas Instruments Incorporated Revision History May 2013 May 2013 May 2013 May 2013 June 2013 – Revision 1.00 Initial release – Revision 1.01 errata – Revision 1.02 errata – Revision 1.03 errata – Revision 1.04 errata Mailing Address Texas Instruments Training Technical Organization 6550 Chase Oaks Blvd Building 2 Plano, TX 75023 ii Getting Started With the Tiva C Series TM4C123G LaunchPad Workshop
Table of Contents Table of Contents Introduction to the ARM® Cortex™-M4F and Peripherals ……………… Code Composer Studio ……………………………………………………… 1-1 2-1 Hints and Tips …………………………………………………………... 2-34 Introduction to TivaWare™, Initialization and GPIO ……………………. Interrupts and the Timers ………………………………………………….. ADC12 ………………………………………………………………………... Hibernation Module ………………………………………………………… USB …………………………………………………………………………... Memory ………………………………………………………………………. Floating-Point ………………………………………………………………... BoosterPacks and Graphics Library ………………………………………. Synchronous Serial Interface ………………………………………………. UART ………………………………………………………………………… µDMA ………………………………………………………………………... 3-1 4-1 5-1 6-1 7-1 8-1 9-1 10-1 11-1 12-1 13-1 LaunchPad Board Schematics ……………………………………………… Appendix Getting Started With the Tiva C Series TM4C123G LaunchPad Workshop - iii
Table of Contents iv Getting Started With the Tiva C Series TM4C123G LaunchPad Workshop
Introduction Introduction This chapter will introduce you to the basics of the Cortex-M4F and the Tiva™ C Series peripherals. The lab will step you through setting up the hardware and software required for the rest of the workshop. Agenda Introduction to ARM® Cortex™-M4F and Peripherals Code Composer Studio Introduction to TivaWare™, Initialization and GPIO Interrupts and the Timers ADC12 Hibernation Module USB Memory Floating-Point BoosterPacks and grLib Synchronous Serial Interface UART µDMA The Wiki page for this workshop is located here: http://www.ti.com/TM4C123G-Launchpad-Workshop Portfolio ... Getting Started With the Tiva C Series TM4C123G LaunchPad Workshop - Introduction 1 - 1
Chapter Topics Chapter Topics Introduction ................................................................................................................................................1-1 Chapter Topics .........................................................................................................................................1-2 TI Processor Portfolio and Tiva C Series Roadmap ................................................................................1-3 Tiva™ TM4C123G Series Overview........................................................................................................1-4 TM4C123GH6PM Specifics .....................................................................................................................1-5 LaunchPad Board ....................................................................................................................................1-8 Lab1: Hardware and Software Set Up .....................................................................................................1-9 Objective..............................................................................................................................................1-9 Procedure ...........................................................................................................................................1-10 1 - 2 Getting Started With the Tiva C Series TM4C123G LaunchPad Workshop - Introduction
TI Processor Portfolio and Tiva C Series Roadmap TI Processor Portfolio and Tiva C Series Roadmap TI Embedded Processing Portfolio TM4C123G MCU ... Getting Started With the Tiva C Series TM4C123G LaunchPad Workshop - Introduction 1 - 3
Tiva™ TM4C123G Series Overview Tiva™ TM4C123G Series Overview Tiva™ TM4C123G Microcontroller Best-in-class power consumption As low as 370 µA/MHz 500µs wakeup from low-power modes RTC currents as low as 1.7µA Internal and external power control Core and FPU ... M4 Core and Floating-Point Unit  32-bit ARM® Cortex™-M4 core  Thumb2 16/32-bit code: 26% less memory & 25 % faster than pure 32-bit  System clock frequency up to 80 MHz  100 DMIPS @ 80MHz  Flexible clocking system  Internal precision oscillator  External main oscillator with PLL support  Internal low frequency oscillator  Real-time-clock through Hibernation module  Saturated math for signal processing  Atomic bit manipulation. Read-Modify-Write using bit-banding  Single Cycle multiply and hardware divider  Unaligned data access for more efficient memory usage  IEEE754 compliant single-precision floating-point unit  JTW and Serial Wire Debug debugger access  ETM (Embedded Trace Macrocell) available through Keil and IAR emulators Memory ... 1 - 4 Getting Started With the Tiva C Series TM4C123G LaunchPad Workshop - Introduction
分享到:
收藏