Texas Instruments TMS320x28xx - Manuals
Texas Instruments TMS320x28xx – Manual in PDF format online.
Manuals:
Manual Texas Instruments TMS320x28xx
Summary
Contents Preface ............................................................................................................................... 9 1 Introduction ............................................................................................................. 13 1.1 Introduction ...........
Preface SPRU791D – November 2004 – Revised October 2007 Read This First This guide describes the Enhanced Pulse Width Modulator (ePWM) Module. It includes an overview of themodule and information about each of the sub-modules: • Time-Base Module • Counter Compare Module • Action Qualifier Module • D...
www.ti.com Related Documentation From Texas Instruments SPRU790— TMS320x28xx, 28xxx Enhanced Quadrature Encoder Pulse (eQEP) Reference Guide describes the eQEP module, which is used for interfacing with a linear or rotary incrementalencoder to get position, direction, and speed information from a ro...
www.ti.com Related Documentation From Texas Instruments SPRA958— Running an Application from Internal Flash Memory on the TMS320F28xx DSP covers the requirements needed to properly configure application software for execution from on-chip flashmemory. Requirements for both DSP/BIOS™ and non-DSP/BIOS...
Chapter 1 SPRU791D – November 2004 – Revised October 2007 Introduction The enhanced pulse width modulator (ePWM) peripheral is a key element in controlling many of thepower-related systems found in both commercial and industrial equipments. These systems include digitalmotor control, switch mode pow...
www.ti.com 1.1 Introduction 1.2 Submodule Overview Introduction An effective PWM peripheral must be able to generate complex pulse width waveforms with minimal CPUoverhead or intervention. It needs to be highly programmable and very flexible while being easy tounderstand and use. The ePWM unit descr...
www.ti.com PIE TZ1 to TZ6 Peripheral Frame 1 ePWM1 module ePWM2 module ePWMx module SYNCO SYNCI SYNCI SYNCO SYNCI SYNCO ADC GPIO MUX xSYNCI xSYNCO xSOC EPWMxA EPWMxB EPWM2A EPWM2B EPWM1A EPWM1B EPWM1INT EPWM1SOC EPWM2INT EPWM2SOC EPWMxINT EPWMxSOC To eCAP1 Submodule Overview Figure 1-1. Multiple ePW...
www.ti.com EPWMxINT EPWMxTZINT EPWMxSOCAEPWMxSOCB EPWMxSYNCI EPWMxSYNCO Time-base (TB) module Counter-compare (CC) module Action-qualifier (AQ) module Dead-band (DB) module PWM-chopper (PC) module Event-trigger (ET) module Trip-zone (TZ) module Peripheral bus ePWM module TZ1 to TZ6 EPWMxA EPWMxB PIE...
www.ti.com Action qualifier (AQ) Time-base (TB) Dead band (DB) Counter compare (CC) Trip zone (TZ) Event trigger and interrupt (ET) PWM chopper (PC) TZ1 to TZ6 TBPRD shadow (16) TBPRD active (16) CTR = PRD CTR = ZERO CTR = CMPA CTR = CMPB CTR_Dir TBCTL[SWFSYNC] (software forced sync) TBPHS active (1...
Chapter 2 SPRU791D – November 2004 – Revised October 2007 ePWM Submodules Seven submodules are included in every ePWM peripheral. Each of these submodules performs specifictasks that can be configured by software. Topic ...................................................................................
www.ti.com 2.1 Overview Overview Table 2-1 lists the seven key submodules together with a list of their main configuration parameters. For example, if you need to adjust or control the duty cycle of a PWM waveform, then you should see thecounter-compare submodule in Section 2.3 for relevant details....
www.ti.com Overview Table 2-1. Submodule Configuration Parameters (continued) Submodule Configuration Parameter or Option Event-trigger (ET) • Enable the ePWM events that will trigger an interrupt. • Enable ePWM events that will trigger an ADC start-of-conversion event. • Specify the rate at which e...
www.ti.com 2.2.2 Controlling and Monitoring the Time-base Submodule TBCTL[SYNCOSEL] TBPRD Period Active TBPRD Period Shadow 16 TBCTL[SWFSYNC] CTR = PRD TBPHS Phase Active Reg Counter UP/DOWN 16 Sync Out Select EPWMxSYNCO Reset Load 16 TBCTL[PHSEN] CTR = Zero CTR = CMPB Disable X EPWMxSYNCI TBCTL[PRD...
www.ti.com 2.2.3 Calculating PWM Period and Frequency Time-Base (TB) Submodule Table 2-3. Key Time-Base Signals Signal Description EPWMxSYNCI Time-base synchronization input. Input pulse used to synchronize the time-base counter with the counter of ePWM module earlier in thesynchronization chain. An...
www.ti.com 2.2.3.2 Time-Base Counter Synchronization EPWM2SYNCI ePWM2 EPWM2SYNCO EPWM1SYNCO ePWM1 EPWM1SYNCI GPIO MUX EPWM3SYNCO ePWM3 EPWM3SYNCI ePWMx EPWMxSYNCI SYNCI eCAP1 EPWMxSYNCO Time-Base (TB) Submodule A time-base synchronization scheme connects all of the ePWM modules on a device. Each ePW...
www.ti.com EPWM1SYNCO ePWM1 EPWM1SYNCI GPIO MUX SYNCI eCAP1 EPWM2SYNCI ePWM2 EPWM2SYNCO EPWM3SYNCO ePWM3 EPWM3SYNCI EPWM2SYNCI ePWM4 EPWM2SYNCO EPWM3SYNCO ePWM5 EPWM3SYNCI ePWM6 EPWMxSYNCI EPWMxSYNCO Time-Base (TB) Submodule Figure 2-6. Time-Base Counter Synchronization Scheme 3 Each ePWM module can...
www.ti.com 2.2.4 Phase Locking the Time-Base Clocks of Multiple ePWM Modules 2.2.5 Time-base Counter Modes and Timing Waveforms 0000 EPWMxSYNCI TBCTR[15:0] CTR_dir CTR = zero CNT_max CTR = PRD 0xFFFF TBPHS (value) TBPRD (value) Time-Base (TB) Submodule The TBCLKSYNC bit can be used to globally synch...
www.ti.com 0x000 0xFFFF TBCTR[15:0] TBPHS (value) TBPRD (value) EPWMxSYNCI CTR_dir CTR = zero CNT_max CTR = PRD 0x0000 0xFFFF TBCNT[15:0] UP DOWN UP DOWN UP DOWN UP TBPHS (value) TBPRD (value) EPWMxSYNCI CTR_dir CTR = zero CNT_max CTR = PRD Time-Base (TB) Submodule Figure 2-8. Time-Base Down-Count M...
www.ti.com 0x0000 0xFFFF TBCNT[15:0] UP DOWN UP DOWN UP DOWN TBPHS (value) TBPRD (value) EPWMxSYNCI CTR_dir CTR = zero CNT_max CTR = PRD 2.3 Counter-Compare (CC) Submodule CTR = CMPB CTR = CMPA CTR_Dir CTR = 0 CTR = PRD Dead Band (DB) Counter Compare (CC) Action Qualifier (AQ) EPWMxA EPWMxB CTR = CM...
www.ti.com 2.3.1 Purpose of the Counter-Compare Submodule 2.3.2 Controlling and Monitoring the Counter-Compare Submodule TBCTR[15:0] Time Base (TB) Module 16 CMPA[15:0] 16 16 16 CMPA Compare A Active Reg. CTR = CMPA CTR = CMPB Action Qualifier Module Digital comparator B CMPB[15:0] TBCTR[15:0] CTR =...
www.ti.com 2.3.3 Operational Highlights for the Counter-Compare Submodule 2.3.4 Count Mode Timing Waveforms Counter-Compare (CC) Submodule The key signals associated with the counter-compare submodule are described in Table 2-5 . Table 2-5. Counter-Compare Submodule Key Signals Signal Description of...
www.ti.com 2.4 Action-Qualifier (AQ) Submodule CTR = CMPB CTR = CMPA CTR_Dir CTR = 0 CTR = PRD Dead Band (DB) Counter Compare (CC) Action Qualifier (AQ) EPWMxA EPWMxB CTR = CMPB CTR = 0 EPWMxINT EPWMxSOCA EPWMxSOCB EPWMxA EPWMxB TZ1 to TZ6 CTR = CMPA Time-Base (TB) CTR = PRD CTR = 0 CTR_Dir EPWMxSYN...
www.ti.com Action-qualifier (AQ) Module AQCTLA[15:0] Action-qualifier control A EPWMA EPWMB TBCLK CTR = PRD CTR = Zero CTR = CMPA CTR = CMPB CTR_dir AQCTLB[15:0] Action-qualifier control B AQSFRC[15:0] Action-qualifier S/W force AQCSFRC[3:0] (shadow) continuous S/W force AQCSFRC[3:0] (active) contin...
www.ti.com 2.4.4 Waveforms for Common Configurations Action-Qualifier (AQ) Submodule Table 2-11. Behavior if CMPA/CMPB is Greater than the Period Counter Mode Compare on Up-Count Event Compare on Down-Count Event CAU/CBU CAU/CBU Up-Count Mode If CMPA/CMPB ≤ TBPRD period, then the event Never occurs....
www.ti.com TBCTR EPWMxA EPWMxB TBPRD value CA Z P CB Z P CB CA Z P Z P CA Z P CA Z P CB CB Action-Qualifier (AQ) Submodule Figure 2-21. Up, Single Edge Asymmetric Waveform, With Independent Modulation on EPWMxA and EPWMxB—Active High A PWM period = (TBPRD + 1 ) × T TBCLK B Duty modulation for EPWMxA...
www.ti.com TBCTR EPWMxA EPWMxB TBPRD value CB CA P P P P CB CA P P Action-Qualifier (AQ) Submodule Figure 2-22. Up, Single Edge Asymmetric Waveform With Independent Modulation on EPWMxA and EPWMxB—Active Low A PWM period = (TBPRD + 1 ) × T TBCLK B Duty modulation for EPWMxA is set by CMPA, and is ac...
www.ti.com TBCTR EPWMxA EPWMxB TBPRD value Z T Z T Z T Action-Qualifier (AQ) Submodule Example 2-3. Code Sample for Figure 2-22 // Initialization Time// = = = = = = = = = = = = = = = = = = = = = = = = EPwm1Regs.TBPRD = 600; // Period = 601 TBCLK counts EPwm1Regs.CMPA.half.CMPA = 350; // Compare A = ...
www.ti.com TBCTR EPWMxA EPWMxB TBPRD value CA CA CA CA CB CB CB CB CB Action-Qualifier (AQ) Submodule Figure 2-24. Up-Down-Count, Dual Edge Symmetric Waveform, With Independent Modulation on EPWMxA and EPWMxB — Active Low A PWM period = 2 x TBPRD × T TBCLK B Duty modulation for EPWMxA is set by CMPA...
www.ti.com CA CA CA CA CB CB CB CB TBCTR EPWMxA EPWMxB TBPRD value Action-Qualifier (AQ) Submodule Figure 2-25. Up-Down-Count, Dual Edge Symmetric Waveform, With Independent Modulation on EPWMxA and EPWMxB — Complementary A PWM period = 2 × TBPRD × T TBCLK B Duty modulation for EPWMxA is set by CMPA...
www.ti.com Z P Z P TBCTR EPWMxA EPWMxB CA CA CB CB Action-Qualifier (AQ) Submodule Figure 2-26. Up-Down-Count, Dual Edge Asymmetric Waveform, With Independent Modulation on EPWMxA—Active Low A PWM period = 2 × TBPRD × TBCLK B Rising edge and falling edge can be asymmetrically positioned within a PWM...
www.ti.com Dead-Band Generator (DB) Submodule action-qualifier submodule to generate the signal as shown for EPWMxA. • Mode 6: Bypass rising-edge-delay and Mode 7: Bypass falling-edge-delay Finally the last two entries in Table 2-13 show combinations where either the falling-edge-delay (FED) or risi...
www.ti.com Dead-Band Generator (DB) Submodule The dead-band submodule supports independent values for rising-edge (RED) and falling-edge (FED)delays. The amount of delay is programmed using the DBRED and DBFED registers. These are 10-bitregisters and their value represents the number of time-base cl...
www.ti.com 2.6 PWM-Chopper (PC) Submodule CTR = CMPB CTR = CMPA CTR_Dir CTR = 0 CTR = PRD Dead Band (DB) Counter Compare (CC) Action Qualifier (AQ) EPWMxB EPWMxA CTR = CMPB CTR = 0 EPWMxINT EPWMxSOCA EPWMxSOCB EPWMxA EPWMxB TZ1 to TZ6 CTR = CMPA Time-Base (TB) CTR = PRD CTR = 0 CTR_Dir EPWMxSYNCI EP...
www.ti.com 2.6.4.1 One-Shot Pulse PSCLK OSHT EPWMxA in EPWMxA out Prog. pulse width(OSHTWTH) Start OSHT pulse Sustaining pulses PWM-Chopper (PC) Submodule The width of the first pulse can be programmed to any of 16 possible pulse width values. The width orperiod of the first pulse is given by: T 1st...
www.ti.com Trip-Zone (TZ) Submodule Table 2-18. Possible Actions On a Trip Event TZCTL[TZA] EPWMxA Comment and/or and/or TZCTL[TZB] EPWMxB 0,0 High-Impedance Tripped 0,1 Force to High State Tripped 1,0 Force to Low State Tripped 1,1 No Change Do Nothing. No change is made to the output. Example 2-8....
www.ti.com 2.7.4 Generating Trip Event Interrupts Latch cyc−by-cyc mode (CBC) CTR=zero TZFRC[CBC] TZ1TZ2TZ3TZ4TZ5TZ6 Sync Clear Set Set one-shot Latch (OSHT) mode Clear TZSEL[CBC1 to CBC6] TZCLR[OST] TZSEL[OSHT1 to OSHT6] TZFRC[OSHT] Sync TZ6 TZ5 TZ4 TZ3 TZ2 TZ1 Trip logic Trip Trip CBCtrip event OS...
www.ti.com 2.8.1 Operational Overview of the Event-Trigger Submodule EPWM1INT EPWM1SOCA EPWM1SOCB EPWM1 module EPWM2SOCB EPWM2SOCA EPWM2INT EPWM2 module EPWMxSOCB EPWMxSOCA EPWMxINT EPWMx module PIE SOCB SOCA ADC Event-Trigger (ET) Submodule The following sections describe the event-trigger submodul...
www.ti.com PIE Event Trigger Module Logic CTR=Zero CTR=PRD CTR=CMPA EPWMxINTn CTR=CMPB CTR_dir Direction qualifier CTRU=CMPA ETSEL reg EPWMxSOCA /n /n /n EPWMxSOCB ADC clear count count clear count clear CTRD=CMPA CTRU=CMPB CTRD=CMPB ETPS reg ETFLG reg ETCLR reg ETFRC reg Event-Trigger (ET) Submodul...
Chapter 3 SPRU791D – November 2004 – Revised October 2007 Applications to Power Topologies An ePWM module has all the local resources necessary to operate completely as a standalone module orto operate in synchronization with other identical ePWM modules. Topic .........................................
www.ti.com 3.1 Overview of Multiple Modules CTR = 0 CTR=CMPB X EN SyncOut Phase reg EPWMxA EPWMxB SyncIn Φ =0 ° 3.2 Key Configuration Capabilities Overview of Multiple Modules Previously in this user's guide, all discussions have described the operation of a single module. Tofacilitate the understan...
www.ti.com Controlling Multiple Buck Converters With Independent Frequencies Example 3-1. Configuration for Example in Figure 3-4 //=====================================================================// (Note: code for only 3 modules shown) // Initialization Time//========================// EPWM Mo...
www.ti.com 3.4 Controlling Multiple Buck Converters With Same Frequencies CTR=zero CTR=CMPB X En Φ =0 ° SyncOut Phase reg Ext SyncIn (optional) EPWM1A EPWM1B SyncOut Phase reg CTR=CMPB CTR=zero X Φ =X En EPWM2B EPWM2A Slave Master Buck #1 Vout1 Vin1 EPWM1A Buck #2 Vin2 EPWM1B Vout2 Buck #4 Buck #3 V...
www.ti.com Controlling Multiple Buck Converters With Same Frequencies Example 3-2. Code Snippet for Configuration in Figure 3-5 //=====================================================================// Config//=====================================================================// Initialization Tim...
www.ti.com Controlling Dual 3-Phase Inverters for Motors (ACI and PMSM) Example 3-4. Code Snippet for Configuration in Figure 3-9 //=====================================================================// Configuration//=====================================================================// Initializ...
www.ti.com 3.7 Practical Applications Using Phase Control Between PWM Modules CTR=zero CTR=CMPB X En SyncOut Phase reg Ext SyncIn (optional) EPWM1A EPWM1B SyncOut Phase reg CTR=CMPB CTR=zero X En EPWM2B EPWM2A Slave Master SyncIn SyncIn 1 2 Φ =0 ° Φ =120 ° Practical Applications Using Phase Control ...
www.ti.com 0000 FFFFh TBPRD TBCTR[0-15] time CTR = PRD (SycnOut) Master Module Φ 2 Phase = 120 ° 0000 FFFFh TBPRD TBCTR[0-15] time SyncIn Slave Module TBPHS 600 600 600 600 200 200 3.8 Controlling a 3-Phase Interleaved DC/DC Converter Controlling a 3-Phase Interleaved DC/DC Converter Figure 3-12. Ti...
www.ti.com Controlling a 3-Phase Interleaved DC/DC Converter Example 3-5. Code Snippet for Configuration in Figure 3-13 //=====================================================================// Config// Initialization Time//========================// EPWM Module 1 configEPwm1Regs.TBPRD = 450; // Per...
www.ti.com 3.9 Controlling Zero Voltage Switched Full Bridge (ZVSFB) Converter CTR=zero CTR=CMPB X En SyncOut Phase reg Ext SyncIn (optional) EPWM1A EPWM1B SyncOut Phase reg CTR=CMPB CTR=zero X En EPWM2B EPWM2A Slave Master V out EPWM1A SyncIn SyncIn V DC_bus EPWM1B EPWM2A EPWM2B Φ =0 ° Φ =Var ° Var...
www.ti.com Controlling Zero Voltage Switched Full Bridge (ZVSFB) Converter Example 3-6. Code Snippet for Configuration in Figure 3-15 //=====================================================================// Config//=====================================================================// Initializati...
Chapter 4 SPRU791D – November 2004 – Revised October 2007 Registers This chapter includes the register layouts and bit description for the submodules. Topic .................................................................................................. Page 4.1 Time-Base Submodule Registers ........
www.ti.com 4.1 Time-Base Submodule Registers Time-Base Submodule Registers Figure 4-1 through Figure 4-5 and Table 4-1 through Table 4-5 provide the time-base register definitions. Figure 4-1. Time-Base Period Register (TBPRD) 15 0 TBPRD R/W-0 LEGEND: R/W = Read/Write; R = Read only; -n = value afte...
www.ti.com Time-Base Submodule Registers Figure 4-4. Time-Base Control Register (TBCTL) 15 14 13 12 10 9 8 FREE, SOFT PHSDIR CLKDIV HSPCLKDIV R/W-0 R/W-0 R/W-0 R/W-0,0,1 7 6 5 4 3 2 1 0 HSPCLKDIV SWFSYNC SYNCOSEL PRDLD PHSEN CTRMODE R/W-0,0,1 R/W-0 R/W-0 R/W-0 R/W-0 R/W-11 LEGEND: R/W = Read/Write; ...
www.ti.com 4.2 Counter-Compare Submodule Registers Counter-Compare Submodule Registers Figure 4-5. Time-Base Status Register (TBSTS) 15 8 Reserved R-0 7 3 2 1 0 Reserved CTRMAX SYNCI CTRDIR R-0 R/W1C-0 R/W1C-0 R-1 LEGEND: R/W = Read/Write; R = Read only; R/W1C = Read/Write 1 to clear; -n = value aft...
www.ti.com 4.3 Action-Qualifier Submodule Registers Action-Qualifier Submodule Registers Figure 4-8. Counter-Compare Control Register (CMPCTL) 15 10 9 8 Reserved SHDWBFULL SHDWAFULL R-0 R-0 R-0 7 6 5 4 3 2 1 0 Reserved SHDWBMODE Reserved SHDWAMODE LOADBMODE LOADAMODE R-0 R/W-0 R-0 R/W-0 R/W-0 R/W-0 ...
www.ti.com 4.4 Dead-Band Submodule Registers Dead-Band Submodule Registers Table 4-12. Action-qualifier Continuous Software Force Register (AQCSFRC) Field Descriptions Bits Name Value Description 15-4 Reserved Reserved 3-2 CSFB Continuous Software Force on Output B In immediate mode, a continuous fo...
www.ti.com 4.5 PWM-Chopper Submodule Control Register PWM-Chopper Submodule Control Register Figure 4-14. Dead-Band Generator Rising Edge Delay Register (DBRED) 15 10 9 8 Reserved DEL R-0 R/W-0 7 0 DEL R/W-0 LEGEND: R/W = Read/Write; R = Read only; -n = value after reset Table 4-14. Dead-Band Genera...
www.ti.com 4.6 Trip-Zone Submodule Control and Status Registers Trip-Zone Submodule Control and Status Registers Table 4-16. PWM-Chopper Control Register (PCCTL) Bit Descriptions (continued) Bits Name Value Description 10-8 CHPDUTY Chopping Clock Duty Cycle 000 Duty = 1/8 (12.5%) 001 Duty = 2/8 (25....
www.ti.com 4.7 Event-Trigger Submodule Registers Event-Trigger Submodule Registers Figure 4-21. Trip-Zone Clear Register (TZCLR) 15 8 Reserved R-0 7 3 2 1 0 Reserved OST CBC INT R-0 R/W-0 R/W-0 R/W-0 LEGEND: R/W = Read/Write; R = Read only; -n = value after reset Table 4-21. Trip-Zone Clear Register...
www.ti.com 4.8 Proper Interrupt Initialization Procedure Proper Interrupt Initialization Procedure When the ePWM peripheral clock is enabled it may be possible that interrupt flags may be set due tospurious events due to the ePWM registers not being properly initialized. The proper procedure forinit...
Appendix A SPRU791D – November 2004 – Revised October 2007 Revision History This document was revised to SPRU791D from SPRU791C. The scope of the revision was limited totechnical changes as shown in Table A-1 . Table A-1. Changes for Revision D Location Modifications, Additions, and Deletions Figure...
IMPORTANT NOTICE Texas Instruments Incorporated and its subsidiaries (TI) reserve the right to make corrections, modifications, enhancements,improvements, and other changes to its products and services at any time and to discontinue any product or service without notice.Customers should obtain the l...
Texas Instruments Manuals
-
Texas Instruments 60X
Manual
-
Texas Instruments TAS5508-5142K7EVM
Manual
-
Texas Instruments SLUU083A
Manual
-
Texas Instruments TSC2007EVM-PDK
Manual
-
Texas Instruments TNETE211
Manual
-
Texas Instruments TI-83 PLUS
Manual
-
Texas Instruments TPS53125EVM-599
Manual
-
Texas Instruments 47
Manual
-
Texas Instruments TI-83
Manual
-
Texas Instruments ADS5102 EVM
Manual
-
Texas Instruments TMS320F2801
Manual
-
Texas Instruments TPA6139A2 EVM
Manual
-
Texas Instruments 2000
Manual
-
Texas Instruments 3000
Manual
-
Texas Instruments UCC38500EVM
Manual
-
Texas Instruments CS-FX300MS PLUS
Manual
-
Texas Instruments SPRAA56
Manual
-
Texas Instruments TNETE100A
Manual
-
Texas Instruments TNETE110A
Manual
-
Texas Instruments TMS320DM646X DMSOC
Manual