MPC5676RRM
MPC5676RRM
MPC5676RRM
Reference Manual
Devices Supported:
MPC5676R
MPC5676RRM
Rev 5
9/2012
How to Reach Us: Information in this document is provided solely to enable system and software
implementers to use Freescale products. There are no express or implied copyright
Home Page:
freescale.com licenses granted hereunder to design or fabricate any integrated circuits based on the
Freescale, the Freescale logo, AltiVec, C-5, CodeTest, CodeWarrior, ColdFire, C-Ware,
Energy Efficient Solutions logo, Kinetis, mobileGT, PowerQUICC, Processor Expert,
QorIQ, Qorivva, StarCore, Symphony, and VortiQa are trademarks of Freescale
Semiconductor, Inc., Reg. U.S. Pat. & Tm. Off. Airfast, BeeKit, BeeStack, ColdFire+,
CoreNet, Flexis, MagniV, MXC, Platform in a Package, QorIQ Qonverge, QUICC
Engine, Ready Play, SafeAssure, SMARTMOS, TurboLink, Vybrid, and Xtrinsic are
trademarks of Freescale Semiconductor, Inc. All other product or service names are
the property of their respective owners. The Power Architecture and Power.org word
marks and the Power and Power.org logos and related marks are trademarks and
service marks licensed by Power.org.
© 2012 Freescale Semiconductor, Inc.
Chapter 2
Signal Descriptions
2.1 Pin Function Selection . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-1
2.1.1 Pad Configuration Register (PCR) PA Definition . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-1
2.1.2 LVDS Signal Selection . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-1
2.2 External Signal Descriptions, Pin Multiplexing, and Attributes . . . . . . . . . . . . . . . . . . . . . . . . . 2-3
2.3 Detailed Signal Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-54
2.3.1 eTPU Signals . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-54
2.3.2 IRQ Signals . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-55
2.3.3 eMIOS Signals . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-56
2.3.4 eQADC Signals . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-57
2.3.5 FlexRay Signals . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-58
2.3.6 FlexCAN Signals . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-58
2.3.7 eSCI Signals . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-58
2.3.8 DSPI Signals . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-59
2.3.9 EBI Signals . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-61
2.3.10 Reset, Configuration and Clock Signals . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-62
2.3.11 JTAG and Nexus Signals . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-63
2.3.12 PMC and Power/Voltage Signals . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-64
Chapter 3
System Integration Units (SIU, SIU_B)
3.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-1
3.1.1 Block Diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-2
3.1.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-3
3.1.3 Modes of Operation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-3
3.2 Memory Map and Register Definition . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-4
3.2.1 Register Descriptions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-7
3.3 SIU_B . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-98
3.4 Functional Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-99
3.4.1 External Interrupts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-99
3.4.2 GPIO Operation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-102
Chapter 4
System Information Module
4.1 SIM Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4-1
4.1.1 SIM Constants . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4-1
Chapter 5
Resets
5.1 Reset Sources and Configuration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-1
5.2 Reset Vector . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-3
5.3 Reset Pins . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-3
5.3.1 RESET . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-3
5.3.2 RSTOUT . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-3
5.4 Reset Source Descriptions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-4
5.4.1 Power-on Reset (POR) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-7
5.4.2 External Reset . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-7
5.4.3 Loss of Lock . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-7
5.4.4 Loss of Clock . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-8
5.4.5 Core Watchdog Timer/Debug Reset . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-8
5.4.6 Software Watchdog Timer Reset . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-8
5.4.7 Dual Core Reset . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-9
5.4.8 JTAG Reset . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-9
5.4.9 Software System Reset . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-9
5.4.10 Software External Reset . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-9
5.5 Reset Registers in the SIU . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-10
5.6 Reset Configuration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-10
5.6.1 Reset Configuration Half Word (RCHW) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-10
5.6.2 Reset Configuration Timing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-12
5.6.3 WKPCFG operation during reset . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-13
5.6.4 BOOTCFG operation during reset . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-13
5.6.5 PLLCFG operation during reset . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-13
Chapter 6
Boot Assist Module (BAM)
6.1 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6-1
6.2 Features . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6-1
6.3 Modes of Operation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6-1
6.3.1 Normal Mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6-1
6.3.2 Debug Mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6-1
6.3.3 Internal Boot Mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6-2
6.3.4 Serial Boot Mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6-2
6.3.5 Development Bus Boot Mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6-2
6.4 Memory Map . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6-2
Chapter 7
Clocking
7.1 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-1
7.2 Clock Distribution . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-1
7.3 Architecture . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-1
7.4 Internal Clocking Requirements . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-3
7.4.1 Operating Frequencies . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-3
7.4.2 16MHz Internal RC Oscillator (IRC) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-3
7.4.3 External Oscillator (XOSC) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-3
7.4.4 Default Clock Configuration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-4
7.4.5 Clock Configuration Selection . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-4
7.4.6 Halt Clock Gating . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-4
7.4.7 Serial Boot Clocking . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-4
7.4.8 FlexRay Clocking . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-5
7.4.9 FlexCAN Clocking . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-5
7.4.10 MCKO . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-5
7.4.11 D_CLKOUT/ENGCLK . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-5
Chapter 8
Frequency Modulated Phase-Locked Loop (FMPLL)
8.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8-1
8.1.1 Block Diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8-1
8.1.2 Features . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8-2
8.1.3 Modes of Operation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8-2
8.2 External Signal Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8-2
8.3 Memory Map and Registers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8-2
8.3.1 Module Memory Map . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8-3
8.3.2 Register Descriptions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8-3
8.4 Functional Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8-12
8.4.1 General . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8-12
8.4.2 PLL Off Mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8-12
8.4.3 Normal Mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8-12
8.5 Resets . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8-20
8.5.1 Clock Mode Selection . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8-20
8.5.2 PLL Loss-of-Lock Reset . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8-21
Chapter 9
Power Management Controller (PMC)
9.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-1
9.1.1 Features . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-1
9.1.2 Block Diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-3
9.1.3 PMC Operation Modes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-3
9.2 External Signals Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-4
9.2.1 Signals Information . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-4
9.3 Signals Details . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-4
9.3.1 VDDREG . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-4
9.3.2 VDD . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-5
9.3.3 VDDSYN . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-5
9.3.4 VSS . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-5
9.3.5 REGCTL . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-5
9.3.6 REGSEL . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-5
9.3.7 VDD33 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-5
9.4 Memory Map/Register Definition . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-6
9.4.1 Configuration Register (PMC_MCR) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-6
9.4.2 Trimming Register (PMC_TRIMR) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-8
9.4.3 Status Register (PMC_SR) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-12
9.5 Functional Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-14
9.5.1 PMC Internal 1.2V Voltage Regulator Selection . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-15
9.5.2 PMC Bandgap . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-16
9.5.3 VDDREG LVD . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-16
9.5.4 3.3V Internal Voltage Regulator . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-16
9.5.5 3.3V VDDSYN LVD . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-17
9.5.6 1.2V Voltage Regulator Controller . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-18
9.5.7 1.2V VDD LVD . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-19
9.5.8 Trimming . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-20
9.5.9 Interrupts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-20
9.5.10 PMC Power-on Reset . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-20
9.5.11 ADC Test Mux . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-22
9.6 Initialization . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-23
9.7 Application Information . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-23
9.7.1 Regulator Example . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-23
9.7.2 Hardware Design Recommendations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-24
Chapter 11
AMBA Crossbar Switch (XBAR)
11.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11-1
11.1.1 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11-1
11.1.2 Block Diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11-2
11.1.3 Features . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11-3
11.1.4 Modes of Operation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11-3
11.2 Memory Map and Register Definition . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11-3
11.2.1 Register Descriptions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11-4
11.3 Functional Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11-9
11.3.1 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11-9
11.3.2 General Operation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11-9
11.3.3 Master Ports . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11-10
11.3.4 Slave Ports . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11-10
11.3.5 Priority Assignment . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11-10
11.3.6 Arbitration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11-10
Chapter 12
Cyclic Redundancy Checker (CRC) Unit
12.1 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12-1
12.2 Features . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12-1
12.2.1 Access and Performance . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12-1
12.3 Calculating a CRC Checksum . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12-2
12.3.1 Configuring the Context . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12-3
12.3.2 Initializing the Context Seed Value . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12-4
12.3.3 Writing the Data Stream to the Context Input . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12-4
12.3.4 Reading the Checksum . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12-5
12.4 Register Descriptions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12-5
12.4.1 CRC Configuration Register (CRC_CFG) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12-6
12.4.2 CRC Input Register (CRC_INP) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12-7
12.4.3 CRC Current Status Register (CRC_CSTAT) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12-7
12.4.4 CRC Output Register (CRC_OUTP) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12-8
12.5 Use cases and limitations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12-9
12.5.1 Checksums for Configuration Registers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12-9
12.5.2 Calculations on Incoming/Outgoing Protocol Frames . . . . . . . . . . . . . . . . . . . . . . . . . 12-9
Chapter 13
Debug
13.1 IEEE 1149.1 Test Access Port Controller (JTAGC) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13-1
13.1.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13-1
Chapter 14
Decimation Filter
14.1 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-1
14.1.1 Features . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-3
14.1.2 Modes of Operation Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-4
14.2 Memory Map and Register Definition . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-5
14.2.1 Decimation Filter Memory Map . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-5
14.2.2 Decimation Filter Register Descriptions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-7
14.3 Functional Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-25
14.3.1 Decimation Filter Input . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-25
14.3.2 Decimation Filter Output . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-26
14.3.3 Bypass Operation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-27
14.3.4 Filter Prefill Control . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-27
14.3.5 Timestamp Data Transmission . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-28
14.3.6 Flush Command . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-28
14.3.7 Soft Reset Command . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-29
14.3.8 Freeze Mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-29
14.3.9 Filter Implementation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-29
14.3.10Rounding . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-30
14.3.11Saturation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-31
14.3.12Interrupts and DMA Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-31
14.3.13Integrator . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-34
Chapter 15
Deserial Serial Peripheral Interface (DSPI)
15.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-1
15.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-2
15.3 Features . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-2
15.4 DSPI configurations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-4
15.4.1 SPI configuration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-4
15.4.2 DSI configuration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-4
15.4.3 CSI configuration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-5
15.5 DSPI frequency support . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-6
15.6 Modes of operation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-6
15.6.1 Master mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-6
15.6.2 Slave mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-6
15.6.3 Module Disable mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-6
15.6.4 Debug mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-7
15.7 External signal description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-7
15.7.1 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-7
15.7.2 Detailed signal description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-7
15.8 Memory map and register definition . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-9
15.8.1 Memory map . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-9
15.8.2 Register descriptions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-11
15.9 Functional description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-41
15.9.1 Start and stop of DSPI transfers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-42
15.9.2 Serial peripheral interface (SPI) configuration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-43
15.9.3 Deserial serial interface (DSI) configuration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-45
15.9.4 Combined serial interface (CSI) configuration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-53
15.9.5 DSPI baud rate and clock delay generation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-54
15.9.6 Transfer formats . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-57
15.9.7 Continuous serial communications clock . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-66
15.9.8 Timed serial bus (TSB) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-67
15.9.9 Parity generation and check . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-71
15.9.10Interrupts/DMA requests . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-72
15.9.11Buffered SPI operation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-73
15.9.12Continuous peripheral chip select . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-74
15.9.13Peripheral chip select expansion and deglitching . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-74
15.9.14DMA and interrupt conditions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-75
15.9.15Modified SPI transfer format . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-76
Chapter 16
Development Trigger Semaphore (DTS)
16.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16-1
16.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16-1
16.3 DTS device connections . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16-3
16.3.1 DTS register access . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16-4
16.4 Memory map . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16-5
16.5 Register descriptions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16-5
16.5.1 DTS Enable Register (DTS_ENABLE) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16-5
16.5.2 DTS Startup Register (DTS_STARTUP) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16-6
16.5.3 DTS Semaphore Register (DTS_SEMAPHORE) . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16-7
16.6 Example application . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16-8
Chapter 17
Enhanced Direct Memory Access Controller (eDMA)
17.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17-1
17.1.1 Block Diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17-2
17.1.2 Features . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17-2
17.1.3 Modes of Operation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17-3
17.2 External Signal Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17-3
17.3 Memory Map and Registers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17-4
17.3.1 Module Memory Map . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17-4
17.3.2 Register Descriptions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17-9
17.4 Functional Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17-36
17.4.1 eDMA Basic Data Flow . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17-38
17.5 Initialization / Application Information . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17-40
17.5.1 eDMA Initialization . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17-40
17.5.2 DMA Programming Errors . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17-43
17.5.3 DMA Request Assignments . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17-44
17.5.4 DMA Arbitration Mode Considerations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17-48
17.5.5 DMA Transfer . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17-49
17.5.6 TCD Status . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17-52
17.5.7 Channel Linking . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17-54
Chapter 18
Enhanced Modular Input/Output Subsystem (eMIOS200)
18.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18-1
18.1.1 Block Diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18-2
18.1.2 Features . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18-3
18.1.3 Modes of Operation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18-3
18.1.4 eMIOS200 Channel Configurations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18-4
18.2 External Signal Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18-5
18.2.1 eMIOS[n] . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18-5
18.2.2 Output Disable Input — eMIOS200 Output Disable Input Signal . . . . . . . . . . . . . . . 18-5
18.3 Memory Map and Register Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18-6
18.3.1 Memory Map . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18-6
18.3.2 Register Descriptions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18-8
18.4 Functional Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18-20
18.4.1 Unified Channel (UC) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18-20
18.4.2 IP Bus Interface Unit (BIU) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18-61
18.4.3 STAC Client Submodule . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18-61
18.4.4 Global Clock Prescaler Submodule (GCP) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18-63
18.5 Reset . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18-63
18.6 Interrupts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18-63
18.7 Initialization/Application Information . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18-63
18.7.1 Considerations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18-63
18.7.2 Application Information . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18-64
18.7.3 Time Base Generation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18-64
18.7.4 Coherent Accesses . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18-66
Chapter 19
Enhanced Queued Analog-to-Digital Converter (eQADC)
19.1 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19-1
19.1.1 Analog to Digital Conversion Sub-system . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19-1
19.2 Block Diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19-3
19.2.1 Features . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19-5
19.3 Modes of Operation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19-6
19.3.1 Normal Mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19-6
19.3.2 Streaming Mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19-6
19.3.3 Debug Mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19-6
19.3.4 Stop Mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19-7
19.4 External Signal Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19-8
19.4.1 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19-8
19.4.2 Detailed Signal Descriptions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19-10
19.5 Pin Mapping to Channel Mapping . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19-12
19.6 Memory Map/Register Definition . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19-14
Chapter 20
Enhanced Serial Communications Interface (eSCI)
20.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-1
20.1.1 Bibliography . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-1
20.1.2 Acronyms and Abbreviations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-1
20.1.3 Glossary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-1
20.1.4 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-3
20.1.5 Features . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-3
20.1.6 Modes of Operation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-4
20.2 External Signal Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-5
20.2.1 Detailed Signal Descriptions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-5
20.3 Memory Map and Register Definition . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-5
20.3.1 Memory Map . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-5
20.3.2 Register Descriptions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-7
20.4 Functional Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-21
20.4.1 Module Control . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-21
20.4.2 Frame Formats . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-21
20.4.3 Baud Rate and Clock Generation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-25
20.4.4 Baud Rate Tolerance . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-26
20.4.5 SCI Mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-28
20.4.6 LIN Mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-42
20.4.7 Interrupts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-52
20.5 Application Information . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-53
Chapter 21
Enhanced Time Processing Unit (eTPU)
21.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21-1
21.1.1 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21-2
21.1.2 Features . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21-8
21.1.3 Modes of Operation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21-12
21.2 External Signal Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21-13
21.2.1 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21-13
21.2.2 Detailed Signal Descriptions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21-13
21.2.3 Memory Map/Register Definition . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21-15
21.2.4 Memory Map . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21-15
21.2.5 System Configuration Registers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21-22
21.2.6 Time Base Registers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21-31
21.2.7 Engine Related Registers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21-37
21.2.8 Memory Error Support Registers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21-40
21.2.9 Channel Registers Layout . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21-58
21.2.10Global Channel Registers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21-59
21.2.11Channel Configuration and Control Registers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21-67
21.3 Functional Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21-72
21.3.1 Watchdog . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21-72
21.3.2 Host Interface . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21-73
21.3.3 Scheduler . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21-80
21.3.4 Parameter Sharing and Coherency . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21-87
21.3.5 Time Bases . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21-92
21.3.6 Safety Features . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21-99
21.3.7 Performance Monitoring Features . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21-105
21.4 Initialization/Application Information . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21-106
21.4.1 Multiple Parameter Coherency Methods . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21-106
21.4.2 Estimating Worst Case Latency . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21-106
21.4.3 Memory Error Service Procedures . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21-122
21.4.4 MISC Algorithm . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21-124
Chapter 22
Error Correction Status Module (ECSM)
22.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 22-1
22.1.1 Features . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 22-1
22.2 Memory Map and Registers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 22-2
22.2.1 Module Memory Map . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 22-2
22.2.2 Register Descriptions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 22-3
Chapter 24
Flash Memory Array and Control
24.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24-1
24.1.1 Block Diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24-3
24.1.2 Features . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24-5
24.1.3 Modes of Operation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24-5
24.2 Memory Map and Registers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24-6
24.2.1 Module Memory Map . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24-6
24.2.2 Register Descriptions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24-9
24.3 Functional Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24-32
24.3.1 Flash User Mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24-32
24.3.2 Flash Read and Write . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24-32
24.3.3 Read While Write (RWW) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24-32
24.3.4 Flash Programming . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24-33
24.3.5 Flash Erase . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24-36
24.3.6 Flash Shadow Block . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24-39
24.3.7 Flash Reset . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24-40
Chapter 25
FlexCAN Module
25.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25-1
Chapter 26
FlexRay Module (FlexRay)
26.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26-1
26.1.1 Reference . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26-1
26.1.2 Glossary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26-1
26.1.3 Color Coding . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26-2
26.1.4 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26-2
26.1.5 Features . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26-4
26.1.6 Modes of Operation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26-5
26.2 External Signal Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26-6
26.2.1 Detailed Signal Descriptions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26-6
26.3 Controller Host Interface Clocking . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26-7
26.4 Protocol Engine Clocking . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26-7
26.4.1 Oscillator Clocking . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26-7
26.4.2 PLL Clocking . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26-8
26.5 Memory Map and Register Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26-8
26.5.1 Memory Map . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26-8
26.5.2 Register Descriptions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26-11
Chapter 27
Interrupts and Interrupt Controller (INTC)
27.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27-1
27.1.1 Block Diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27-2
27.1.2 Interrupt Controller Features . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27-3
27.1.3 Modes of Operation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27-3
27.2 External Signal Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27-7
27.3 Memory Map and Registers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27-7
27.3.1 INTC Memory Map . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27-7
27.3.2 Register Descriptions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27-8
Chapter 28
Memory Protection Unit (MPU)
28.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28-1
28.1.1 Block Diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28-2
28.1.2 Features . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28-3
28.2 Memory Map and Registers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28-4
28.2.1 Module Memory Map . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28-4
28.2.2 Register Descriptions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28-6
28.3 Functional Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28-14
28.3.1 Access Evaluation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28-14
28.3.2 AHB Error Terminations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28-15
28.4 Initialization Information . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28-16
28.5 Application Information . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28-16
Chapter 29
Periodic Interrupt Timer (PIT_RTI)
29.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29-1
29.1.1 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29-1
29.1.2 Block Diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29-2
29.1.3 Features . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29-2
29.2 Signal Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29-3
29.3 Memory Map and Register Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29-3
29.3.1 Memory Map . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29-3
29.3.2 Register Descriptions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29-4
29.4 Functional Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29-7
29.4.1 General . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29-7
29.4.2 Interrupts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29-9
29.5 Initialization and Application Information . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29-9
Chapter 30
Peripheral Bridge (PBRIDGE)
30.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 30-1
30.1.1 Terminology . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 30-1
30.1.2 Block Diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 30-1
30.1.3 Features . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 30-2
30.1.4 Modes of Operation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 30-2
30.2 External Signal Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 30-2
30.3 Memory Map and Registers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 30-2
30.4 Functional Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 30-2
30.4.1 Read Cycles . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 30-2
30.4.2 Write Cycles . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 30-3
Chapter 31
Self-Test Control Unit (STCU)
31.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31-1
31.1.1 Glossary and Acronyms . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31-1
31.1.2 Features . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31-1
31.1.3 Modes of Operation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31-2
31.1.4 Block Diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31-2
31.2 External Signal Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31-3
31.3 STCU Memory Map . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31-3
31.3.1 Memory Map & Register Descriptions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31-3
31.3.2 STCU Control Register (STCU_CTRL) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31-4
31.3.3 STCU Enable Register (STCU_ENABLE) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31-7
31.3.4 STCU Status Register (STCU_STAT) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31-8
31.3.5 STCU WATCHDOG TIMER (STCU_WDGT) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31-10
31.3.6 STCU UNLOCK KEY (STCU_KEY) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31-11
31.3.7 Logical BIST Control Register (STCU_LBIST_CTRL) . . . . . . . . . . . . . . . . . . . . . . 31-11
31.3.8 LBIST Pattern Counter Start Register (STCU_LBIST_PC_START) . . . . . . . . . . . . 31-14
31.3.9 LBIST Pattern End Counter Register (STCU_LBIST_PC_END) . . . . . . . . . . . . . . 31-14
31.3.10LBIST Pseudo-Random Number (STCU_LBIST_PRPGH) . . . . . . . . . . . . . . . . . . . 31-15
31.3.11LBIST Pseudo-Random Number (STCU_LBIST_PRPGL) . . . . . . . . . . . . . . . . . . . 31-15
31.3.12LBIST ENABLE REGISTER (STCU_LBIST_ENABLE) . . . . . . . . . . . . . . . . . . . . 31-16
31.3.13LBIST STATUS Register (STCU_LBIST_STATUS) . . . . . . . . . . . . . . . . . . . . . . . . 31-17
31.3.14STCU Interrupt Enable/Status Register (STCU_INTERRUPT) . . . . . . . . . . . . . . . . 31-18
31.3.15STCU Current Watchdog Timer (STCU_CURRENT_WDGT) . . . . . . . . . . . . . . . . 31-19
31.3.16LBIST 0 MISRH Register (STCU_LBIST_MISRH0) . . . . . . . . . . . . . . . . . . . . . . . 31-19
31.3.17LBIST 0 MISRL Register (STCU_LBIST_MISRL0) . . . . . . . . . . . . . . . . . . . . . . . . 31-20
31.3.18LBIST 1 MISRH Register (STCU_LBIST_MISRH1) . . . . . . . . . . . . . . . . . . . . . . . 31-21
31.3.19LBIST 1 MISRL Register (STCU_LBIST_MISRL1) . . . . . . . . . . . . . . . . . . . . . . . . 31-21
Chapter 32
Semaphores
32.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 32-1
32.1.1 Block Diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 32-2
32.1.2 Features . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 32-3
32.1.3 Modes of Operation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 32-3
32.2 Signal Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 32-3
32.3 Memory Map and Registers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 32-3
32.3.1 Module Memory Map . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 32-4
32.3.2 Register Descriptions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 32-5
32.4 Functional Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 32-12
32.4.1 Semaphore Usage . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 32-13
32.5 Initialization Information . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 32-14
32.6 Application Information . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 32-14
32.7 DMA Requests . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 32-15
32.8 Interrupt Requests . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 32-15
Chapter 33
Software Watchdog Timers (SWT_A, SWT_B)
33.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 33-1
33.1.1 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 33-1
33.1.2 Features . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 33-1
33.1.3 Modes of Operation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 33-2
33.2 External Signal Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 33-2
33.3 Memory Map and Register Definition . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 33-2
33.3.1 Memory Map . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 33-2
33.3.2 Register Descriptions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 33-3
33.4 Functional Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 33-9
Chapter 35
System RAM (SRAM)
35.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 35-1
35.2 Features . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 35-1
35.3 Modes of Operation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 35-1
35.3.1 Normal (Functional) Mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 35-1
35.3.2 Standby Mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 35-1
35.4 Block Diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 35-1
35.5 External Signal Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 35-2
35.5.1 Register Memory Map . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 35-2
35.6 Functional Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 35-2
35.7 SRAM ECC Mechanism . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 35-2
35.7.1 Access Timing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 35-3
35.7.2 Reset Effects on SRAM Accesses . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 35-3
35.8 Initialization and Application Information . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 35-4
35.8.1 Example Code . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 35-4
Chapter 36
System Timer Module (STM)
36.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 36-1
36.1.1 Modes of Operation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 36-1
36.2 External Signal Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 36-1
36.3 Memory Map and Register Definition . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 36-1
36.3.1 Memory Map . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 36-1
36.3.2 Register Descriptions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 36-2
36.4 Functional Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 36-5
Chapter 37
Temperature Sensor
37.1 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 37-1
37.2 Detailed Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 37-1
37.3 Temperature formula . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 37-3
37.3.1 TLOW and THIGH . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 37-3
37.3.2 TTSENS_CODE(TLOW) and TTSENS_CODE(THIGH) . . . . . . . . . . . . . . . . . . . . . . . . . . . . 37-3
37.3.3 VBG_CODE(TLOW) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 37-4
37.3.4 Temperature sensor voltage (VTENS(T)) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 37-4
37.3.5 Bandgap reference voltage (VBG_CODE(T)) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 37-4
37.3.6 Registers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 37-4
1.1 Features
This section compares the MPC5676R to the MPC5500 and MPC5600 family of devices, shows a block
diagram of the device, and describes the features of the MPC5676R.
MMU Entries 32 32 32 32 64 32
MMU Tool Control No No No No No Yes
MPU No No No No Yes Yes
Semaphores No No No No No 16
CRC Channels No No No No No 3
Software Watchdog No No No No 1 2
Timer
Core Nexus Class 3+ 3+ 3+ 3+ 3+ 3+
SRAM 64KB 64KB 64KB 128KB 256KB 384KB
(32K Standby) (32K Standby) (32K Standby) (32K Standby) (32K Standby) (48K Standby)
Flash 2MB 2MB 2MB 3MB 4MB 6MB
Flash fetch 2 x 256 bit 2 x 256 bit 2 x 256 bit 2 x 256 bit 4 x 256 bit 4 x 256 bit
accelerator
External bus 32 bit 32 bit 32 bit 32 bit Yes2 Yes2
Calibration bus No 16 bit 16 bit 16 bit 16 bit non-mux 16 bit, 32 bit
16, 32 bit muxed3 muxed3
DMA channels 64 32 32 64 64 + 32 64 + 64
DMA Nexus Class 3 3 3 3 3 3
Serial Interface (eSCI) 2 2 2 2 3 3
FlexCAN 3 3 5 4 4 4
SPI 4 3 3 4 4 5
Microsecond bus No No No No Yes Yes
downlink
FlexRay No No Yes No Yes Yes
Ethernet No No Yes Yes No No
System Timers No No No No 1 RTI 1 RTI
4 PIT 4 PIT
4 AutoSAR 4 AutoSAR
eMIOS channels 24 24 24 24 32 32
eTPU channels 64 32 32 64 64 96
eTPU Version 2 x eTPU 1 x eTPU 1 x eTPU 2 x eTPU 2 x eTPU2 3 x eTPU2
eTPU Code memory 16KB 12KB 12KB 12KB 24KB 24KB + 12KB
eTPU Data memory 3KB 2.5KB 2.5KB 3KB 6KB 6KB + 3KB
Interrupt controller 308 sources 210 sources 210 sources 308 sources 448 sources 500 sources
ADC Input Pins 40 40 40 40 64 64
ADC Input diagnostics No No No No Yes Yes
ADC Resolution 12 bit 12 bit 12 bit 12 bit 12 bit 12 bit
ADC Quantity 2 2 2 2 4 4
ADC variable gain No No No No Yes Yes
amp.
Temp. sensor No No No No Yes Yes
Decimation filters No No No No 8 12
Protected Port Output No No No No No 4
Self Test Controller No No No No No Yes
Dev Tool Semaphores No No No No No 32
PLL FM FM FM FM FM FM
Integrated linear 1.5V 1.5V 1.5V 1.5V 3.3V, 1.2V 3.3V, 1.2V
voltage regulator
Integrated switch No No No No 1.2V 1.2V
mode voltage
regulator
External Power 5V, 3.3V 5V, 3.3V 5V, 3.3V 5V, 3.3V 5V4 5V4
Supplies
Low Power Modes No No No No Stop Mode Stop Mode
Slow Mode Slow Mode
1
There are 2 cores on the MPC5676R. Both cores have identical features.
2
External Bus Interface (EBI) is not available on 416 PBGA
3 Cal bus is combined with EBI
4 External 3.3V may be needed for external 3.3V pins.
Crossbar Switch
MPU
FlexCAN
FlexCAN
FlexCAN
FlexCAN
6KB 3KB eQADC eQADC
DSPI
DSPI
DSPI
DSPI
DSPI
SIUB
eSCI
eSCI
eSCI
ADC
ADC
ADC
ADC
32 32 32 32
Channel Channel 24KB Channel 12KB Channel
Code Code
RAM RAM PPO AMux
LEGEND
ADC – Analog to Digital Convertor I-Cache – Instruction Cache
AMux – Analog Pin Multiplexer IRC – Internal RC Oscillator
D-Cache – Data Cache JTAG – Joint Test Action Group controller
DECFILT– Decimation Filter MMU – Memory Management Unit
DSPI – Deserial/Serial Peripheral Interface MPU – Memory Protection Unit
EBI – External Bus Interface PPO – Protected Port Output
eDMA2 – Enhanced Direct Memory Access controller version 2 S/B – Stand-by
eMIOS – Enhanced Modular I/O System SIUA – System Integration Unit A
eQADC – Enhanced Queued Analog to Digital Converter SIUB – System Integration Unit B
eSCI – Enhanced Serial Communications Interface SPE – Signal Processing Engine
eTPU2 – Enhanced Time Processing Unit version 2 SRAM – Static RAM
FlexCAN– Flexible Controller Area Network controller STCU – Self Test Control Unit
FMPLL – Frequency Modulated Phase Lock Loop clock generator VLE – Variable Length instruction Encoding
1.6 Packages
The MPC5676R is offered in the following package types:
• 416-ball PBGA, 1 mm ball pitch, 27 mm 27 mm outline (no EBI)
• 516-ball PBGA, 1 mm ball pitch, 27 mm 27 mm outline (includes EBI)
Block Address
Block Address
Block Address
Block Address
000 GPIO
Pins that do not require selection of a function by modifying the PA field have a hard-wired value
corresponding to the appropriate function available at the pin. All PA values might not be used. A
definition of which values are used is provided in the SIU_PCRn settings table (Table 3-22). The “Primary
Function” name is retained from previous MPC5xxx designs and indicates the name used on the ball map.
The name “GPIO” is also retained for clarity. The remaining function names are new and have been chosen
for simplicity and clarity.
Table 2-2 is an example of the options for PA on two balls, where “true” and “complement” LVDS outputs
are multiplexed with SCK_C and SINC.
Table 2-2. LVDS example
Additionally, when LVDS signals are enabled on balls, their PCR SRC[1:0] bits control the differential
signal output swing increase and decrease, as defined in Table 2-3.
Table 2-3. Differential Signal Output when LVDS is Enabled
Current
Differential Voltage Across
SRC1 SRC0 flowing in the
‘true’ and ‘complement’
driver
0 0 normal default
This section summarizes the external signal functions, their static electrical characteristics, and pad configuration settings for this
device. The signal properties and their electrical characteristics are set in the System Integration Unit (SIU) Pad Configuration (PCR)
registers. See the MPC5676R Microcontroller Data Sheet for ball-map figures.
Table 2-4. Signal Properties and Muxing Summary
GPIO/PCR1
Package
Pad Type5
Direction
Voltage6
State State
P/A/G3
Location
Signal Name2 Function4 Function Summary during after
RESET7 RESET8
416
516
MPC5676R Microcontroller Reference Manual, Rev 5
eTPU_A
Signal Descriptions
GPIO117
A1 ETPUA15 eTPU A channel (output only) O
A2 — — —
G GPIO117 GPIO I/O
2-3
Table 2-4. Signal Properties and Muxing Summary (continued)
Freescale Semiconductor
GPIO/PCR1
Package
Pad Type5
Direction
Voltage6
State State
P/A/G3
2 4 Location
Signal Name Function Function Summary during after
RESET7 RESET8
416
516
118 ETPUA4_ETPUA16_ P ETPUA4 eTPU A channel I/O MH VDDEH1 —/WKPCFG —/WKPCFG K2 J4
GPIO118
A1 ETPUA16 eTPU A channel (output only) O
A2 — — —
G GPIO118 GPIO I/O
GPIO119
A1 ETPUA17 eTPU A channel (output only) O
A2 — — —
G GPIO119 GPIO I/O
Signal Descriptions
G GPIO123 GPIO I/O
2-4
Table 2-4. Signal Properties and Muxing Summary (continued)
Freescale Semiconductor
GPIO/PCR1
Package
Pad Type5
Direction
Voltage6
State State
P/A/G3
2 4 Location
Signal Name Function Function Summary during after
RESET7 RESET8
416
516
124 ETPUA10_ETPUA22_ P ETPUA10 eTPU A channel I/O MH VDDEH1 —/WKPCFG —/WKPCFG J4 K6
GPIO124
A1 ETPUA22 eTPU A channel (output only) O
A2 — — —
G GPIO124 GPIO I/O
GPIO125
A1 ETPUA23 eTPU A channel (output only) O
A2 — — —
G GPIO125 GPIO I/O
Signal Descriptions
G GPIO129 GPIO I/O
2-5
Table 2-4. Signal Properties and Muxing Summary (continued)
Freescale Semiconductor
GPIO/PCR1
Package
Pad Type5
Direction
Voltage6
State State
P/A/G3
2 4 Location
Signal Name Function Function Summary during after
RESET7 RESET8
416
516
130 ETPUA16_PCSD1_ P ETPUA16 eTPU A channel I/O MH VDDEH1 —/WKPCFG —/WKPCFG G2 H6
GPIO130
A1 PCSD1 DSPI D peripheral chip select O
A2 — — —
G GPIO130 GPIO I/O
GPIO131
A1 PCSD2 DSPI D peripheral chip select O
A2 — — —
G GPIO131 GPIO I/O
Signal Descriptions
G GPIO135 GPIO I/O
2-6
Table 2-4. Signal Properties and Muxing Summary (continued)
Freescale Semiconductor
GPIO/PCR1
Package
Pad Type5
Direction
Voltage6
State State
P/A/G3
2 4 Location
Signal Name Function Function Summary during after
RESET7 RESET8
416
516
136 ETPUA22_IRQ10_ P ETPUA22 eTPU A channel I/O MH VDDEH1 —/WKPCFG —/WKPCFG F4 F4
GPIO136
A1 IRQ10 External interrupt request I
A2 — — —
G GPIO136 GPIO I/O
GPIO137
A1 IRQ11 External interrupt request I
A2 — — —
G GPIO137 GPIO I/O
Signal Descriptions
G GPIO141 GPIO I/O
2-7
Table 2-4. Signal Properties and Muxing Summary (continued)
Freescale Semiconductor
GPIO/PCR1
Package
Pad Type5
Direction
Voltage6
State State
P/A/G3
2 4 Location
Signal Name Function Function Summary during after
RESET7 RESET8
416
516
142 ETPUA28_PCSC1_ P ETPUA28 eTPU A channel I/O MH VDDEH1 —/WKPCFG —/WKPCFG D2 D2
GPIO142
A1 PCSC1 DSPI C peripheral chip select O
A2 — — —
G GPIO142 GPIO I/O
GPIO143
A1 PCSC2 DSPI C peripheral chip select O
A2 — — —
G GPIO143 GPIO I/O
eTPU_B
146 TCRCLKB_IRQ6_ P TCRCLKB eTPU B TCR clock I MH VDDEH6 —/Up —/Up T23 V25
GPIO146
A1 IRQ6 External interrupt request I
A2 — — —
G GPIO146 GPIO I/O
147 ETPUB0_ETPUB16_ P ETPUB0 eTPU B channel I/O MH VDDEH6 —/WKPCFG —/WKPCFG T24 V26
GPIO147
Signal Descriptions
A1 ETPUB16 eTPU B channel (output only) O
A2 — — —
G GPIO147 GPIO I/O
2-8
Table 2-4. Signal Properties and Muxing Summary (continued)
Freescale Semiconductor
GPIO/PCR1
Package
Pad Type5
Direction
Voltage6
State State
P/A/G3
2 4 Location
Signal Name Function Function Summary during after
RESET7 RESET8
416
516
148 ETPUB1_ETPUB17_ P ETPUB1 eTPU B channel I/O MH VDDEH6 —/WKPCFG —/WKPCFG T25 U22
GPIO148
A1 ETPUB17 eTPU B channel (output only) O
A2 — — —
G GPIO148 GPIO I/O
149 ETPUB2_ETPUB18_ P ETPUB2 eTPU B channel I/O MH VDDEH6 —/WKPCFG —/WKPCFG T26 U23
MPC5676R Microcontroller Reference Manual, Rev 5
GPIO149
A1 ETPUB18 eTPU B channel (output only) O
A2 — — —
G GPIO149 GPIO I/O
150 ETPUB3_ETPUB19_ P ETPUB3 eTPU B channel I/O MH VDDEH6 —/WKPCFG —/WKPCFG R23 T22
GPIO150
A1 ETPUB19 eTPU B channel (output only) O
A2 — — —
G GPIO150 GPIO I/O
151 ETPUB4_ETPUB20_ P ETPUB4 eTPU B channel I/O MH VDDEH6 —/WKPCFG —/WKPCFG R24 U24
GPIO151
A1 ETPUB20 eTPU B channel (output only) O
A2 — — —
G GPIO151 GPIO I/O
152 ETPUB5_ETPUB21_ P ETPUB5 eTPU B channel I/O MH VDDEH6 —/WKPCFG —/WKPCFG R25 U25
GPIO152
A1 ETPUB21 eTPU B channel (output only) O
A2 — — —
G GPIO152 GPIO I/O
153 ETPUB6_ETPUB22_ P ETPUB6 eTPU B channel I/O MH VDDEH6 —/WKPCFG —/WKPCFG R26 U26
GPIO153
A1 ETPUB22 eTPU B channel (output only) O
A2 — — —
Signal Descriptions
G GPIO153 GPIO I/O
2-9
Table 2-4. Signal Properties and Muxing Summary (continued)
Freescale Semiconductor
GPIO/PCR1
Package
Pad Type5
Direction
Voltage6
State State
P/A/G3
2 4 Location
Signal Name Function Function Summary during after
RESET7 RESET8
416
516
154 ETPUB7_ETPUB23_ P ETPUB7 eTPU B channel I/O MH VDDEH6 —/WKPCFG —/WKPCFG P23 T23
GPIO154
A1 ETPUB23 eTPU B channel (output only) O
A2 — — —
G GPIO154 GPIO I/O
155 ETPUB8_ETPUB24_ P ETPUB8 eTPU B channel I/O MH VDDEH6 —/WKPCFG —/WKPCFG P24 T24
MPC5676R Microcontroller Reference Manual, Rev 5
GPIO155
A1 ETPUB24 eTPU B channel (output only) O
A2 — — —
G GPIO155 GPIO I/O
156 ETPUB9_ETPUB25_ P ETPUB9 eTPU B channel I/O MH VDDEH6 —/WKPCFG —/WKPCFG P25 R22
GPIO156
A1 ETPUB25 eTPU B channel (output only) O
A2 — — —
G GPIO156 GPIO I/O
157 ETPUB10_ETPUB26_ P ETPUB10 eTPU B channel I/O MH VDDEH6 —/WKPCFG —/WKPCFG P26 T25
GPIO157
A1 ETPUB26 eTPU B channel (output only) O
A2 — — —
G GPIO157 GPIO I/O
158 ETPUB11_ETPUB27_ P ETPUB11 eTPU B channel I/O MH VDDEH6 —/WKPCFG —/WKPCFG N24 T26
GPIO158
A1 ETPUB27 eTPU B channel (output only) O
A2 — — —
G GPIO158 GPIO I/O
159 ETPUB12_ETPUB28_ P ETPUB12 eTPU B channel I/O MH VDDEH6 —/WKPCFG —/WKPCFG N25 R23
GPIO159
A1 ETPUB28 eTPU B channel (output only) O
A2 — — —
Signal Descriptions
G GPIO159 GPIO I/O
2-10
Table 2-4. Signal Properties and Muxing Summary (continued)
Freescale Semiconductor
GPIO/PCR1
Package
Pad Type5
Direction
Voltage6
State State
P/A/G3
2 4 Location
Signal Name Function Function Summary during after
RESET7 RESET8
416
516
160 ETPUB13_ETPUB29_ P ETPUB13 eTPU B channel I/O MH VDDEH6 —/WKPCFG —/WKPCFG N26 P22
GPIO160
A1 ETPUB29 eTPU B channel (output only) O
A2 — — —
G GPIO160 GPIO I/O
161 ETPUB14_ETPUB30_ P ETPUB14 eTPU B channel I/O MH VDDEH6 —/WKPCFG —/WKPCFG M25 R24
MPC5676R Microcontroller Reference Manual, Rev 5
GPIO161
A1 ETPUB30 eTPU B channel (output only) O
A2 — — —
G GPIO161 GPIO I/O
162 ETPUB15_ETPUB31_ P ETPUB15 eTPU B channel I/O MH VDDEH6 —/WKPCFG —/WKPCFG M24 R25
GPIO162
A1 ETPUB31 eTPU B channel (output only) O
A2 — — —
G GPIO162 GPIO I/O
163 ETPUB16_PCSA1_ P ETPUB16 eTPU B channel I/O MH VDDEH6 —/WKPCFG —/WKPCFG U26 V24
GPIO163
A1 PCSA1 DSPI A peripheral chip select O
A2 — — —
G GPIO163 GPIO I/O
164 ETPUB17_PCSA2_ P ETPUB17 eTPU B channel I/O MH VDDEH6 —/WKPCFG —/WKPCFG U25 T21
GPIO164
A1 PCSA2 DSPI A peripheral chip select O
A2 — — —
G GPIO164 GPIO I/O
165 ETPUB18_PCSA3_ P ETPUB18 eTPU B channel I/O MH VDDEH6 —/WKPCFG —/WKPCFG U24 W26
GPIO165
A1 PCSA3 DSPI A peripheral chip select O
A2 — — —
Signal Descriptions
G GPIO165 GPIO I/O
2-11
Table 2-4. Signal Properties and Muxing Summary (continued)
Freescale Semiconductor
GPIO/PCR1
Package
Pad Type5
Direction
Voltage6
State State
P/A/G3
2 4 Location
Signal Name Function Function Summary during after
RESET7 RESET8
416
516
166 ETPUB19_PCSA4_ P ETPUB19 eTPU B channel I/O MH VDDEH6 —/WKPCFG —/WKPCFG U23 W25
GPIO166
A1 PCSA4 DSPI A peripheral chip select O
A2 — — —
G GPIO166 GPIO I/O
167 ETPUB20_ P ETPUB20 eTPU B channel I/O MH VDDEH6 —/WKPCFG —/WKPCFG V26 W24
MPC5676R Microcontroller Reference Manual, Rev 5
GPIO167
A1 — — —
A2 — — —
G GPIO167 GPIO I/O
168 ETPUB21_ P ETPUB21 eTPU B channel I/O MH VDDEH6 —/WKPCFG —/WKPCFG V25 V22
GPIO168
A1 — — —
A2 — — —
G GPIO168 GPIO I/O
169 ETPUB22_ P ETPUB22 eTPU B channel I/O MH VDDEH6 —/WKPCFG —/WKPCFG V24 V23
GPIO169
A1 — — —
A2 — — —
G GPIO169 GPIO I/O
170 ETPUB23_ P ETPUB23 eTPU B channel I/O MH VDDEH6 —/WKPCFG —/WKPCFG W26 U21
GPIO170
A1 — — —
A2 — — —
G GPIO170 GPIO I/O
171 ETPUB24_ P ETPUB24 eTPU B channel I/O MH VDDEH6 —/WKPCFG —/WKPCFG W25 Y25
GPIO171
A1 — — —
A2 — — —
Signal Descriptions
G GPIO171 GPIO I/O
2-12
Table 2-4. Signal Properties and Muxing Summary (continued)
Freescale Semiconductor
GPIO/PCR1
Package
Pad Type5
Direction
Voltage6
State State
P/A/G3
2 4 Location
Signal Name Function Function Summary during after
RESET7 RESET8
416
516
172 ETPUB25_ P ETPUB25 eTPU B channel I/O MH VDDEH6 —/WKPCFG —/WKPCFG W24 W21
GPIO172
A1 — — —
A2 — — —
G GPIO172 GPIO I/O
173 ETPUB26_ P ETPUB26 eTPU B channel I/O MH VDDEH6 —/WKPCFG —/WKPCFG V23 Y23
MPC5676R Microcontroller Reference Manual, Rev 5
GPIO173
A1 — — —
A2 — — —
G GPIO173 GPIO I/O
174 ETPUB27_ P ETPUB27 eTPU B channel I/O MH VDDEH6 —/WKPCFG —/WKPCFG Y25 Y24
GPIO174
A1 — — —
A2 — — —
G GPIO174 GPIO I/O
175 ETPUB28_ P ETPUB28 eTPU B channel I/O MH VDDEH6 —/WKPCFG —/WKPCFG Y24 AA24
GPIO175
A1 — — —
A2 — — —
G GPIO175 GPIO I/O
176 ETPUB29_ P ETPUB29 eTPU B channel I/O MH VDDEH6 —/WKPCFG —/WKPCFG Y23 W22
GPIO176
A1 — — —
A2 — — —
G GPIO176 GPIO I/O
177 ETPUB30_ P ETPUB30 eTPU B channel I/O MH VDDEH6 —/WKPCFG —/WKPCFG AA24 AB24
GPIO177
A1 — — —
A2 — — —
Signal Descriptions
G GPIO177 GPIO I/O
2-13
Table 2-4. Signal Properties and Muxing Summary (continued)
Freescale Semiconductor
GPIO/PCR1
Package
Pad Type5
Direction
Voltage6
State State
P/A/G3
2 4 Location
Signal Name Function Function Summary during after
RESET7 RESET8
416
516
178 ETPUB31_ P ETPUB31 eTPU B channel I/O MH VDDEH6 —/WKPCFG —/WKPCFG AB24 Y22
GPIO178
A1 — — —
A2 — — —
G GPIO178 GPIO I/O
MPC5676R Microcontroller Reference Manual, Rev 5
eTPU_C
440 TCRCLKC_ P TCRCLKC eTPU C TCR clock I MH VDDEH7 —/Up —/Up B26 F22
GPIO440
A1 — — —
A2 — — —
G GPIO440 GPIO I/O
441 ETPUC0_ P ETPUC0 eTPU C channel I/O MH VDDEH7 —/WKPCFG —/WKPCFG C25 C25
GPIO441
A1 — — —
A2 — — —
G GPIO441 GPIO I/O
442 ETPUC1_ P ETPUC1 eTPU C channel I/O MH VDDEH7 —/WKPCFG —/WKPCFG C26 C26
GPIO442
A1 — — —
A2 — — —
G GPIO442 GPIO I/O
443 ETPUC2_ P ETPUC2 eTPU C channel I/O MH VDDEH7 —/WKPCFG —/WKPCFG D25 D25
GPIO443
A1 — — —
A2 — — —
G GPIO443 GPIO I/O
444 ETPUC3_ P ETPUC3 eTPU C channel I/O MH VDDEH7 —/WKPCFG —/WKPCFG D26 D26
GPIO444
Signal Descriptions
A1 — — —
A2 — — —
G GPIO444 GPIO I/O
2-14
Table 2-4. Signal Properties and Muxing Summary (continued)
Freescale Semiconductor
GPIO/PCR1
Package
Pad Type5
Direction
Voltage6
State State
P/A/G3
2 4 Location
Signal Name Function Function Summary during after
RESET7 RESET8
416
516
445 ETPUC4_ P ETPUC4 eTPU C channel I/O MH VDDEH7 —/WKPCFG —/WKPCFG E24 E24
PCSE1_GPIO445
A1 DSPI E peripheral chip select
A2 — — —
G GPIO445 GPIO I/O
446 ETPUC5_ P ETPUC5 eTPU C channel I/O MH VDDEH7 —/WKPCFG —/WKPCFG E25 E25
MPC5676R Microcontroller Reference Manual, Rev 5
PCSE2_GPIO446
A1 DSPI E peripheral chip select
A2 — — —
G GPIO446 GPIO I/O
447 ETPUC6_ P ETPUC6 eTPU C channel I/O MH VDDEH7 —/WKPCFG —/WKPCFG E26 E26
PCSE3_GPIO447
A1 DSPI E peripheral chip select
A2 — — —
G GPIO447 GPIO I/O
448 ETPUC7_ P ETPUC7 eTPU C channel I/O MH VDDEH7 —/WKPCFG —/WKPCFG F23 F23
PCSE4_GPIO448
A1 DSPI E peripheral chip select
A2 — — —
G GPIO448 GPIO I/O
449 ETPUC8_ P ETPUC8 eTPU C channel I/O MH VDDEH7 —/WKPCFG —/WKPCFG F24 F24
PCSE5_GPIO449
A1 DSPI E peripheral chip select
A2 — — —
G GPIO449 GPIO I/O
450 ETPUC9_IRQ0_ P ETPUC9 eTPU C channel I/O MH VDDEH7 —/WKPCFG —/WKPCFG F25 F25
GPIO450
A1 IRQ0 External interrupt request I
A2 — — —
Signal Descriptions
G GPIO450 GPIO I/O
2-15
Table 2-4. Signal Properties and Muxing Summary (continued)
Freescale Semiconductor
GPIO/PCR1
Package
Pad Type5
Direction
Voltage6
State State
P/A/G3
2 4 Location
Signal Name Function Function Summary during after
RESET7 RESET8
416
516
451 ETPUC10__IRQ1_ P ETPUC10 eTPU C channel I/O MH VDDEH7 —/WKPCFG —/WKPCFG F26 F26
GPIO451
A1 IRQ1 External interrupt request I
A2 — — —
G GPIO451 GPIO I/O
452 ETPUC11_IRQ2_ P ETPUC11 eTPU C channel I/O MH VDDEH7 —/WKPCFG —/WKPCFG G23 G22
MPC5676R Microcontroller Reference Manual, Rev 5
GPIO452
A1 IRQ2 External interrupt request I
A2 — — —
G GPIO452 GPIO I/O
453 ETPUC12_IRQ3_ P ETPUC12 eTPU C channel I/O MH VDDEH7 —/WKPCFG —/WKPCFG G24 G23
GPIO453
A1 IRQ3 External interrupt request I
A2 — — —
G GPIO453 GPIO I/O
454 ETPUC13_3_IRQ4_ P ETPUC13 eTPU C channel I/O MH VDDEH7 —/WKPCFG —/WKPCFG G25 G24
GPIO454
A1 IRQ4 External interrupt request I
A2 — — —
G GPIO454 GPIO I/O
455 ETPUC14_4_IRQ5_ P ETPUC14 eTPU C channel I/O MH VDDEH7 —/WKPCFG —/WKPCFG G26 G25
GPIO455
A1 IRQ5 External interrupt request I
A2 — — —
G GPIO455 GPIO I/O
456 ETPUC15__ P ETPUC15 eTPU C channel I/O MH VDDEH7 —/WKPCFG —/WKPCFG H23 G26
GPIO456
A1 — — —
A2 — — —
Signal Descriptions
G GPIO456 GPIO I/O
2-16
Table 2-4. Signal Properties and Muxing Summary (continued)
Freescale Semiconductor
GPIO/PCR1
Package
Pad Type5
Direction
Voltage6
State State
P/A/G3
2 4 Location
Signal Name Function Function Summary during after
RESET7 RESET8
416
516
457 ETPUC16_FR_A_TX_ P ETPUC16 eTPU C channel I/O MH VDDEH7 —/WKPCFG —/WKPCFG H24 H22
GPIO457
A1 FR_A_TX FlexRay A transfer O
A2 — — —
G GPIO457 GPIO I/O
458 ETPUC17_FR_A_RX_ P ETPUC17 eTPU C channel I/O MH VDDEH7 —/WKPCFG —/WKPCFG H25 H23
MPC5676R Microcontroller Reference Manual, Rev 5
GPIO458
A1 FR_A_RX FlexRay A receive I
A2 — — —
G GPIO458 GPIO I/O
459 ETPUC18_FR_A_TX_EN_ P ETPUC18 eTPU C channel I/O MH VDDEH7 —/WKPCFG —/WKPCFG H26 H24
GPIO459
A1 FR_A_TX_EN FlexRay A transfer enable O
A2 — — —
G GPIO459 GPIO I/O
460 ETPUC19_TXDA_ P ETPUC19 eTPU C channel I/O MH VDDEH7 —/WKPCFG —/WKPCFG J23 H21
GPIO460
A1 TXDA eSCI A transmit O
A2 — — —
G GPIO460 GPIO I/O
461 ETPUC20_RXDA _ P ETPUC20 eTPU C channel I/O MH VDDEH7 —/WKPCFG —/WKPCFG J24 H25
GPIO461
A1 RXDA eSCI A receive I
A2 — — —
G GPIO461 GPIO I/O
462 ETPUC21_TXDB_ P ETPUC21 eTPU C channel I/O MH VDDEH7 —/WKPCFG —/WKPCFG J25 H26
GPIO462
A1 TXDB eSCI B transmit O
A2 — — —
Signal Descriptions
G GPIO462 GPIO I/O
2-17
Table 2-4. Signal Properties and Muxing Summary (continued)
Freescale Semiconductor
GPIO/PCR1
Package
Pad Type5
Direction
Voltage6
State State
P/A/G3
2 4 Location
Signal Name Function Function Summary during after
RESET7 RESET8
416
516
463 ETPUC22_RXDB_ P ETPUC22 eTPU C channel I/O MH VDDEH7 —/WKPCFG —/WKPCFG J26 J22
GPIO463
A1 RXDB eSCI B receive I
A2 — — —
G GPIO463 GPIO I/O
464 ETPUC23_PCSD5_ P ETPUC23 eTPU C channel I/O MH VDDEH7 —/WKPCFG —/WKPCFG K23 J23
MPC5676R Microcontroller Reference Manual, Rev 5
GPIO464
A1 PCSD5 DSPI D peripheral chip select O
A2 MAA0 ADC A Mux Address 0 O
A3 MAB0 ADC B Mux Address 0 O
G GPIO464 GPIO I/O
465 ETPUC24_PCSD4_ P ETPUC24 eTPU C channel I/O MH VDDEH7 —/WKPCFG —/WKPCFG K24 J24
GPIO465
A1 PCSD4 DSPI D peripheral chip select O
A2 MAA1 ADC A Mux Address 1 O
A4 MAB1 ADC B Mux Address 1 O
G GPIO465 GPIO I/O
466 ETPUC25_PCSD3_ P ETPUC25 eTPU C channel I/O MH VDDEH7 —/WKPCFG —/WKPCFG K25 K21
GPIO466
A1 PCSD3 DSPI D peripheral chip select O
A2 MAA2 ADC A Mux Address 2 O
A3 MAB2 ADC B Mux Address 2 O
G GPIO466 GPIO I/O
467 ETPUC26_PCSD2_ P ETPUC26 eTPU C channel I/O MH VDDEH7 —/WKPCFG —/WKPCFG K26 J25
GPIO467
A1 PCSD2 DSPI D peripheral chip select O
A2 — — —
G GPIO467 GPIO I/O
Signal Descriptions
468 ETPUC27_PCSD1_ P ETPUC27 eTPU C channel I/O MH VDDEH7 —/WKPCFG —/WKPCFG L23 J26
GPIO468
A1 PCSD1 DSPI D peripheral chip select O
A2 — — —
2-18
GPIO/PCR1
Package
Pad Type5
Direction
Voltage6
State State
P/A/G3
2 4 Location
Signal Name Function Function Summary during after
RESET7 RESET8
416
516
469 ETPUC28_PCSD0_ P ETPUC28 eTPU C channel I/O MH VDDEH7 —/WKPCFG —/WKPCFG L24 K22
GPIO469
A1 PCSD0 DSPI D peripheral chip select O
A2 — — —
G GPIO469 GPIO I/O
470 ETPUC29_SCKD_ P ETPUC29 eTPU C channel I/O MH VDDEH7 —/WKPCFG —/WKPCFG L25 K23
MPC5676R Microcontroller Reference Manual, Rev 5
GPIO470
A1 SCKD DSPI D clock I/O
A2 — — —
G GPIO470 GPIO I/O
471 ETPUC30_SOUTD_ P ETPUC30 eTPU C channel I/O MH VDDEH7 —/WKPCFG —/WKPCFG L26 K24
GPIO471
A1 SOUTD DSPI D data output O
A2 — — —
G GPIO471 GPIO I/O
472 ETPUC31_SIND_ P ETPUC31 eTPU C channel I/O MH VDDEH7 —/WKPCFG —/WKPCFG M23 K25
GPIO472
A1 SIND DSPI D data input I
A2 — — —
G GPIO472 GPIO I/O
eMIOS
179 EMIOS0_ETPUA0_ P EMIOS0 eMIOS channel I/O MH VDDEH4 —/WKPCFG —/WKPCFG AE10 AC13
GPIO179
A1 ETPUA0 eTPU A channel O
A2 — — —
G GPIO179 GPIO I/O
180 EMIOS1_ETPUA1_ P EMIOS1 eMIOS channel I/O MH VDDEH4 —/WKPCFG —/WKPCFG AF10 AB13
GPIO180
Signal Descriptions
A1 ETPUA1 eTPU A channel O
A2 — — —
G GPIO180 GPIO I/O
2-19
Table 2-4. Signal Properties and Muxing Summary (continued)
Freescale Semiconductor
GPIO/PCR1
Package
Pad Type5
Direction
Voltage6
State State
P/A/G3
2 4 Location
Signal Name Function Function Summary during after
RESET7 RESET8
416
516
181 EMIOS2_ETPUA2_ P EMIOS2 eMIOS channel I/O MH VDDEH4 —/WKPCFG —/WKPCFG AD11 AD13
GPIO181
A1 ETPUA2 eTPU A channel O
A2 — — —
G GPIO181 GPIO I/O
182 EMIOS3_ETPUA3_ P EMIOS3 eMIOS channel I/O MH VDDEH4 —/WKPCFG —/WKPCFG AE11 AE13
MPC5676R Microcontroller Reference Manual, Rev 5
GPIO182
A1 ETPUA3 eTPU A channel O
A2 — — —
G GPIO182 GPIO I/O
183 EMIOS4_ETPUA4_ P EMIOS4 eMIOS channel I/O MH VDDEH4 —/WKPCFG —/WKPCFG AF11 AF13
GPIO183
A1 ETPUA4 eTPU A channel O
A2 — — —
G GPIO183 GPIO I/O
184 EMIOS5_ETPUA5_ P EMIOS5 eMIOS channel I/O MH VDDEH4 —/WKPCFG —/WKPCFG AD12 AF14
GPIO184
A1 ETPUA5 eTPU A channel O
A2 — — —
G GPIO184 GPIO I/O
185 EMIOS6_ETPUA6_ P EMIOS6 eMIOS channel I/O MH VDDEH4 —/WKPCFG —/WKPCFG AE12 AE14
GPIO185
A1 ETPUA6 eTPU A channel O
A2 — — —
G GPIO185 GPIO I/O
186 EMIOS7_ETPUA7_ P EMIOS7 eMIOS channel I/O MH VDDEH4 —/WKPCFG —/WKPCFG AF12 AD14
GPIO186
A1 ETPUA7 eTPU A channel O
A2 — — —
Signal Descriptions
G GPIO186 GPIO I/O
2-20
Table 2-4. Signal Properties and Muxing Summary (continued)
Freescale Semiconductor
GPIO/PCR1
Package
Pad Type5
Direction
Voltage6
State State
P/A/G3
2 4 Location
Signal Name Function Function Summary during after
RESET7 RESET8
416
516
187 EMIOS8_ETPUA8_ P EMIOS8 eMIOS channel I/O MH VDDEH4 —/WKPCFG —/WKPCFG AC13 AC14
GPIO187
A1 ETPUA8 eTPU A channel O
A2 — — —
G GPIO187 GPIO I/O
188 EMIOS9_ETPUA9_ P EMIOS9 eMIOS channel I/O MH VDDEH4 —/WKPCFG —/WKPCFG AD13 AF15
MPC5676R Microcontroller Reference Manual, Rev 5
GPIO188
A1 ETPUA9 eTPU A channel O
A2 — — —
G GPIO188 GPIO I/O
189 EMIOS10_SCKD_ P EMIOS10 eMIOS channel I/O MH VDDEH4 —/WKPCFG —/WKPCFG AE13 AE15
GPIO189
A1 SCKD DSPI D clock O
A2 — — —
G GPIO189 GPIO I/O
190 EMIOS11_SIND_ P EMIOS11 eMIOS channel I/O MH VDDEH4 —/WKPCFG —/WKPCFG AF13 AB14
GPIO190
A1 SIND DSPI D data input I
A2 — — —
G GPIO190 GPIO I/O
191 EMIOS12_SOUTC_ P EMIOS12 eMIOS channel O MH VDDEH4 —/WKPCFG —/WKPCFG AF14 AD15
GPIO191
A1 SOUTC DSPI C data output O
A2 — — —
G GPIO191 GPIO I/O
192 EMIOS13_SOUTD_ P EMIOS13 eMIOS channel O MH VDDEH4 —/WKPCFG —/WKPCFG AE14 AC15
GPIO192
A1 SOUTD DSPI D data output O
A2 — — —
Signal Descriptions
G GPIO192 GPIO I/O
2-21
Table 2-4. Signal Properties and Muxing Summary (continued)
Freescale Semiconductor
GPIO/PCR1
Package
Pad Type5
Direction
Voltage6
State State
P/A/G3
2 4 Location
Signal Name Function Function Summary during after
RESET7 RESET8
416
516
193 EMIOS14_IRQ0_ P EMIOS14 eMIOS channel O MH VDDEH4 —/WKPCFG —/WKPCFG AC14 AF17
GPIO193
A1 IRQ0 External interrupt request I
A2 CNTXD FlexCAN D transmit O
G GPIO193 GPIO I/O
194 EMIOS15_IRQ1_ P EMIOS15 eMIOS channel O MH VDDEH4 —/WKPCFG —/WKPCFG AD14 AE16
MPC5676R Microcontroller Reference Manual, Rev 5
GPIO194
A1 IRQ1 External interrupt request I
A2 CNRXD FlexCAN D receive I
G GPIO194 GPIO I/O
195 EMIOS16_ETPUB0_ P EMIOS16 eMIOS channel I/O MH VDDEH4 —/WKPCFG —/WKPCFG AF15 AD16
GPIO195
A1 ETPUB0 eTPU B channel O
A2 FR_DBG[3] FlexRay debug O
G GPIO195 GPIO I/O
196 EMIOS17_ETPUB1_ P EMIOS17 eMIOS channel I/O MH VDDEH4 —/WKPCFG —/WKPCFG AE15 AB15
GPIO196
A1 ETPUB1 eTPU B channel O
A2 FR_DBG[2] FlexRay debug O
G GPIO196 GPIO I/O
197 EMIOS18_ETPUB2_ P EMIOS18 eMIOS channel I/O MH VDDEH4 —/WKPCFG —/WKPCFG AC15 AD17
GPIO197
A1 ETPUB2 eTPU B channel O
A2 FR_DBG[1] FlexRay debug O
G GPIO197 GPIO I/O
198 EMIOS19_ETPUB3_ P EMIOS19 eMIOS channel I/O MH VDDEH4 —/WKPCFG —/WKPCFG AD15 AB16
GPIO198
A1 ETPUB3 eTPU B channel O
A2 FR_DBG[0] FlexRay debug O
Signal Descriptions
G GPIO198 GPIO I/O
2-22
Table 2-4. Signal Properties and Muxing Summary (continued)
Freescale Semiconductor
GPIO/PCR1
Package
Pad Type5
Direction
Voltage6
State State
P/A/G3
2 4 Location
Signal Name Function Function Summary during after
RESET7 RESET8
416
516
199 EMIOS20_ETPUB4_ P EMIOS20 eMIOS channel I/O MH VDDEH4 —/WKPCFG —/WKPCFG AF16 AF16
GPIO199
A1 ETPUB4 eTPU B channel O
A2 — — —
G GPIO199 GPIO I/O
200 EMIOS21_ETPUB5_ P EMIOS21 eMIOS channel I/O MH VDDEH4 —/WKPCFG —/WKPCFG AE16 AE17
MPC5676R Microcontroller Reference Manual, Rev 5
GPIO200
A1 ETPUB5 eTPU B channel O
A2 — — —
G GPIO200 GPIO I/O
201 EMIOS22_ETPUB6_ P EMIOS22 eMIOS channel I/O MH VDDEH4 —/WKPCFG —/WKPCFG AC16 AC16
GPIO201
A1 ETPUB6 eTPU B channel O
A2 — — —
G GPIO201 GPIO I/O
202 EMIOS23_ETPUB7_ P EMIOS23 eMIOS channel I/O MH VDDEH4 —/WKPCFG —/WKPCFG AD16 AA16
GPIO202
A1 ETPUB7 eTPU B channel O
A2 — — —
G GPIO202 GPIO I/O
203 EMIOS24_PCSB0_ P EMIOS24 eMIOS channel I/O MH VDDEH4 —/WKPCFG —/WKPCFG AF17 AC17
GPIO203
A1 PCSB0 DSPI B peripheral chip select I/O
A2 — — —
G GPIO203 GPIO I/O
204 EMIOS25_PCSB1_ P EMIOS25 eMIOS channel I/O MH VDDEH4 —/WKPCFG —/WKPCFG AE17 AF18
GPIO204
A1 PCSB1 DSPI B peripheral chip select O
A2 — — —
Signal Descriptions
G GPIO204 GPIO I/O
2-23
Table 2-4. Signal Properties and Muxing Summary (continued)
Freescale Semiconductor
GPIO/PCR1
Package
Pad Type5
Direction
Voltage6
State State
P/A/G3
2 4 Location
Signal Name Function Function Summary during after
RESET7 RESET8
416
516
432 EMIOS26_PCSB2_ P EMIOS26 eMIOS channel I/O MH VDDEH4 —/WKPCFG —/WKPCFG AD17 AE18
GPIO432
A1 PCSB2 DSPI B peripheral chip select O
A2 — — —
G GPIO432 GPIO I/O
433 EMIOS27_PCSB3_ P EMIOS27 eMIOS channel I/O MH VDDEH4 —/WKPCFG —/WKPCFG AC17 AD18
MPC5676R Microcontroller Reference Manual, Rev 5
GPIO433
A1 PCSB3 DSPI B peripheral chip select O
A2 — — —
G GPIO433 GPIO I/O
434 EMIOS28_PCSC0_ P EMIOS28 eMIOS channel I/O MH VDDEH4 —/WKPCFG —/WKPCFG AF18 AC18
GPIO434
A1 PCSC0 DSPI C peripheral chip select I/O
A2 — — —
G GPIO434 GPIO I/O
435 EMIOS29_PCSC1_ P EMIOS29 eMIOS channel I/O MH VDDEH4 —/WKPCFG —/WKPCFG AE18 AB17
GPIO435
A1 PCSC1 DSPI C peripheral chip select O
A2 — — —
G GPIO435 GPIO I/O
436 EMIOS30_PCSC2_ P EMIOS30 eMIOS channel I/O MH VDDEH4 —/WKPCFG —/WKPCFG AD18 AF19
GPIO436
A1 PCSC2 DSPI C peripheral chip select O
A2 — — —
G GPIO436 GPIO I/O
437 EMIOS31_PCSC5_ P EMIOS31 eMIOS channel I/O MH VDDEH4 —/WKPCFG —/WKPCFG AC18 AA17
GPIO437
A1 PCSC5 DSPI C peripheral chip select O
A2 — — —
Signal Descriptions
G GPIO437 GPIO I/O
eQADC
— ANA0 P ANA09 eQADC A shared analog input I AE/up- VDDA_A1 ANA0 ANA0 A4 A4
2-24
down
Table 2-4. Signal Properties and Muxing Summary (continued)
Freescale Semiconductor
GPIO/PCR1
Package
Pad Type5
Direction
Voltage6
State State
P/A/G3
2 4 Location
Signal Name Function Function Summary during after
RESET7 RESET8
416
516
— ANA1 P ANA19 eQADC A shared analog input I AE/up- VDDA_A1 ANA1 ANA1 B5 B5
down
— ANA2 P ANA29 eQADC A shared analog input I AE/up- VDDA_A1 ANA2 ANA2 C5 C5
down
— ANA3 P ANA39 eQADC A shared analog input I AE/up- VDDA_A1 ANA3 ANA3 D6 D6
down
MPC5676R Microcontroller Reference Manual, Rev 5
— ANA4 P ANA49 eQADC A shared analog input I AE/up- VDDA_A1 ANA4 ANA4 A5 A5
down
— ANA5 P ANA59 eQADC A shared analog input I AE/up- VDDA_A1 ANA5 ANA5 B6 B6
down
— ANA6 P ANA69 eQADC A shared analog input I AE/up- VDDA_A1 ANA6 ANA6 C6 C6
down
— ANA7 P ANA79 eQADC A shared analog input I AE/up- VDDA_A1 ANA7 ANA7 D7 C7
down
— ANA18 P ANA18 eQADC A analog input I AE VDDA_A1 ANA18 ANA18 D10 D10
Signal Descriptions
— ANA19 P ANA19 eQADC A analog input I AE VDDA_A1 ANA19 ANA19 C10 C10
— ANA20 P ANA20 eQADC A analog input I AE VDDA_A1 ANA20 ANA20 D11 D11
— ANA21 P ANA21 eQADC A analog input I AE VDDA_A1 ANA21 ANA21 C11 C11
— ANA22 P ANA22 eQADC A analog input I AE VDDA_A1 ANA22 ANA22 D12 C12
2-25
Table 2-4. Signal Properties and Muxing Summary (continued)
Freescale Semiconductor
GPIO/PCR1
Package
Pad Type5
Direction
Voltage6
State State
P/A/G3
2 4 Location
Signal Name Function Function Summary during after
RESET7 RESET8
416
516
— ANA23 P ANA23 eQADC A analog input I AE VDDA_A1 ANA23 ANA23 C12 D12
— AN24 P AN24 eQADC analog input I AE VDDA_A0 AN24 AN24 B12 B12
— AN25 P AN25 eQADC analog input I AE VDDA_A0 AN25 AN25 D13 C13
— AN26 P AN26 eQADC analog input I AE VDDA_A0 AN26 AN26 C13 D13
— AN27 P AN27 eQADC analog input I AE VDDA_A0 AN27 AN27 B13 B13
MPC5676R Microcontroller Reference Manual, Rev 5
— AN28 P AN28 eQADC analog input I AE VDDA_A0 AN28 AN28 A13 A13
— AN29 P AN29 eQADC analog input I AE VDDA_A0 AN29 AN29 B14 A14
— AN30 P AN30 eQADC analog input I AE VDDA_B1 AN30 AN30 C14 B14
— AN31 P AN31 eQADC analog input I AE VDDA_B1 AN31 AN31 D14 C14
— AN32 P AN32 eQADC analog input I AE VDDA_B1 AN32 AN32 A14 B15
— AN33 P AN33 eQADC analog input I AE VDDA_B0 AN33 AN33 B15 D14
— AN34 P AN34 eQADC analog input I AE VDDA_B0 AN34 AN34 C15 C15
— AN35 P AN35 eQADC analog input I AE VDDA_B0 AN35 AN35 D15 D15
— AN36 P AN36 eQADC analog input I AE VDDA_B1 AN36 AN36 A15 A15
— AN37 P AN37 eQADC analog input I AE VDDA_B0 AN37 AN37 C16 C17
— AN38 P AN38 eQADC analog input I AE VDDA_B0 AN38 AN38 C17 D16
— AN39 P AN39 eQADC analog input I AE VDDA_B0 AN39 AN39 D16 C16
— ANB0 P ANB0 eQADC B shared analog input I AE/up- VDDA_B0 ANB0 ANB0 C18 C18
down
— ANB1 P ANB1 eQADC B shared analog input I AE/up- VDDA_B0 ANB1 ANB1 D17 D17
down
— ANB2 P ANB2 eQADC B shared analog input I AE/up- VDDA_B0 ANB2 ANB2 D18 D18
down
— ANB3 P ANB3 eQADC B shared analog input I AE/up- VDDA_B0 ANB3 ANB3 D19 D19
Signal Descriptions
down
— ANB4 P ANB4 eQADC B shared analog input I AE/up- VDDA_B0 ANB4 ANB4 C19 B19
down
— ANB5 P ANB5 eQADC B shared analog input I AE/up- VDDA_B0 ANB5 ANB5 C20 A20
2-26
down
Table 2-4. Signal Properties and Muxing Summary (continued)
Freescale Semiconductor
GPIO/PCR1
Package
Pad Type5
Direction
Voltage6
State State
P/A/G3
2 4 Location
Signal Name Function Function Summary during after
RESET7 RESET8
416
516
— ANB6 P ANB6 eQADC B shared analog input I AE/up- VDDA_B0 ANB6 ANB6 B19 C20
down
— ANB7 P ANB7 eQADC B shared analog input I AE/up- VDDA_B0 ANB7 ANB7 A20 C19
down
— ANB8 P ANB8 eQADC B analog input I AE VDDA_B0 ANB8 ANB8 B20 B20
MPC5676R Microcontroller Reference Manual, Rev 5
— ANB9 P ANB9 eQADC B analog input I AE VDDA_B0 ANB9 ANB9 D20 A21
— ANB10 P ANB10 eQADC B analog input I AE VDDA_B0 ANB10 ANB10 B21 B21
— ANB11 P ANB11 eQADC B analog input I AE VDDA_B0 ANB11 ANB11 A21 C21
— ANB12 P ANB12 eQADC B analog input I AE VDDA_B0 ANB12 ANB12 C21 A22
— ANB13 P ANB13 eQADC B analog input I AE VDDA_B0 ANB13 ANB13 D21 B22
— ANB14 P ANB14 eQADC B analog input I AE VDDA_B0 ANB14 ANB14 A22 D20
— ANB15 P ANB15 eQADC B analog input I AE VDDA_B0 ANB15 ANB15 B22 C22
— ANB16 P ANB16 eQADC B analog input I AE VDDA_B0 ANB16 ANB16 C22 D21
— ANB17 P ANB17 eQADC B analog input I AE VDDA_B0 ANB17 ANB17 A23 D22
— ANB18 P ANB18 eQADC B analog input I AE VDDA_B0 ANB18 ANB18 B23 A23
— ANB19 P ANB19 eQADC B analog input I AE VDDA_B0 ANB19 ANB19 C23 B23
— ANB20 P ANB20 eQADC B analog input I AE VDDA_B0 ANB20 ANB20 D22 C23
— ANB21 P ANB21 eQADC B analog input I AE VDDA_B0 ANB21 ANB21 A24 A24
— ANB22 P ANB22 eQADC B analog input I AE VDDA_B0 ANB22 ANB22 B24 B24
— ANB23 P ANB23 eQADC B analog input I AE VDDA_B0 ANB23 ANB23 A25 E20
— VRH_A P VRH_A ADC A Voltage reference high I VDDINT VRH_A VRH_A VRH_A A12 A12
— VRL_A P VRL_A ADC A Voltage reference low I VSSINT VRL_A VRL_A VRL_A A11 A11
— VRH_B P VRH_B ADC B Voltage reference high I VDDINT VRH_B VRH_B VRH_B A19 A19
Signal Descriptions
— VRL_B P VRL_B ADC B Voltage reference low I VSSINT VRL_B VRL_B VRL_B A18 A18
— REFBYPCB P REFBYPCB ADC B Reference bypass capacitor I AE VDDA_B0 REFBYPCB REFBYPCB B18 B18
— REFBYPCA P REFBYPCA ADC A Reference bypass capacitor I AE VDDA_A1 REFBYPCA REFBYPCA B11 B11
— VDDA_A0 P VDDA_A Internal logic supply input I VDDE VDDA_A0 VDDA_A0 VDDA_A0 A9 A9
2-27
Table 2-4. Signal Properties and Muxing Summary (continued)
Freescale Semiconductor
GPIO/PCR1
Package
Pad Type5
Direction
Voltage6
State State
P/A/G3
2 4 Location
Signal Name Function Function Summary during after
RESET7 RESET8
416
516
— VDDA_A1 P VDDA_A Internal logic supply input I VDDE VDDA_A1 VDDA_A1 VDDA_A1 B9 B9
— REFBYPCA1 P REFBYPCA1 ADC A Reference bypass capacitor I AE VDDA_A1 REFBYPCA1 REFBYPCA1 A10 A10
— VDDA_B0 P VDDA_B Internal logic supply input I VDDE VDDA_B0 VDDA_B0 VDDA_B0 A16 A16
— VDDA_B1 P VDDA_B Internal logic supply input I VDDE VDDA_B1 VDDA_B1 VDDA_B1 B16 B16
MPC5676R Microcontroller Reference Manual, Rev 5
— REFBYPCB1 P REFBYPCB1 ADC B Reference bypass capacitor I AE VDDA_B0 REFBYPCB1 REFBYPCB1 A17 A17
FlexRay
248 FR_A_TX_ P FR_A_TX FlexRay A transfer O FS VDDE2 —/Up —/Up AD4 AD4
GPIO248 (–/– for Rev.1 (–/– for Rev.1
A1 — — —
of the device) of the device)
A2 — — —
G GPIO248 GPIO I/O
249 FR_A_RX_ P FR_A_RX FlexRay A receive I FS VDDE2 —/Up —/Up AE3 AE3
GPIO249 (–/– for Rev.1 (–/– for Rev.1
A1 — — — of the device) of the device)
A2 — — —
G GPIO249 GPIO I/O
250 FR_A_TX_EN_ P FR_A_TX_EN FlexRay A transfer enable O FS VDDE2 —/Up —/Up AF3 AF3
GPIO250 (–/– for Rev.1 (–/– for Rev.1
A1 — — —
of the device) of the device)
A2 — — —
G GPIO250 GPIO I/O
251 FR_B_TX_ P FR_B_TX FlexRay B transfer O FS VDDE2 —/Up —/Up AD5 AD5
GPIO251 (–/– for Rev.1 (–/– for Rev.1
A1 — — —
of the device) of the device)
Signal Descriptions
A2 — — —
G GPIO251 GPIO I/O
2-28
Table 2-4. Signal Properties and Muxing Summary (continued)
Freescale Semiconductor
GPIO/PCR1
Package
Pad Type5
Direction
Voltage6
State State
P/A/G3
2 4 Location
Signal Name Function Function Summary during after
RESET7 RESET8
416
516
252 FR_B_RX_ P FR_B_RX FlexRay B receive I FS VDDE2 —/Up —/Up AE4 AE4
GPIO252 (–/– for Rev.1 (–/– for Rev.1
A1 — — —
of the device) of the device)
A2 — — —
G GPIO252 GPIO I/O
253 FR_B_TX_EN_ P FR_B_TX_EN FlexRay B transfer enable O FS VDDE2 —/Up —/Up AF4 AF4
MPC5676R Microcontroller Reference Manual, Rev 5
FlexCAN
Signal Descriptions
A1 PCSC4 DSPI C peripheral chip select O
A2 — — —
G GPIO86 GPIO I/O
2-29
Table 2-4. Signal Properties and Muxing Summary (continued)
Freescale Semiconductor
GPIO/PCR1
Package
Pad Type5
Direction
Voltage6
State State
P/A/G3
2 4 Location
Signal Name Function Function Summary during after
RESET7 RESET8
416
516
87 CNTXC_PCSD3_ P CNTXC FlexCAN C transmit O MH VDDEH4 —/Up —/Up AF20 AF20
GPIO87
A1 PCSD3 DSPI D peripheral chip select O
A2 — — —
G GPIO87 GPIO I/O
GPIO88
A1 PCSD4 DSPI D peripheral chip select O
A2 — — —
G GPIO88 GPIO I/O
246 CNTXD_ P CNTXD FlexCAN D transmit O MH VDDEH4 —/Up —/Up AD20 AD20
GPIO246
A1 — — —
A2 — — —
G GPIO246 GPIO I/O
247 CNRXD_ P CNRXD FlexCAN D receive I MH VDDEH4 —/Up —/Up AC20 AC20
GPIO247
A1 — — —
A2 — — —
G GPIO247 GPIO I/O
eSCI
Signal Descriptions
A1 — — —
A2 — — —
G GPIO90 GPIO I
2-30
Table 2-4. Signal Properties and Muxing Summary (continued)
Freescale Semiconductor
GPIO/PCR1
Package
Pad Type5
Direction
Voltage6
State State
P/A/G3
2 4 Location
Signal Name Function Function Summary during after
RESET7 RESET8
416
516
91 TXDB_PCSD1_ P TXDB eSCI B transmit O MH VDDEH1 —/Up —/Up P1 K1
GPIO91
A1 PCSD1 DSPI D peripheral chip select O
A2 — — —
G GPIO91 GPIO I/O
GPIO92
A1 PCSD5 DSPI D peripheral chip select O
A2 — — —
G GPIO92 GPIO I/O
244 TXDC_ETRIG0_ P TXDC eSCI C transmit O MH VDDEH4 —/Up —/Up AF23 AF23
GPIO244
A1 ETRIG0 eQADC trigger input I
A2 — — —
G GPIO244 GPIO I/O
245 RXDC_ P RXDC eSCI C receive I MH VDDEH5 —/Up —/Up AD22 AD22
GPIO245
A1 — — —
A2 — — —
G GPIO245 GPIO I/O
DSPI
93 SCKA_PCSC1_ P SCKA DSPI A clock I/O MH VDDEH3 —/Up —/Up AD8 AB8
GPIO93
A1 PCSC1 DSPI C peripheral chip select O
A2 — — —
G GPIO93 GPIO I/O
94 SINA_PCSC2_ P SINA DSPI A data input I MH VDDEH3 —/Up —/Up AF7 AE7
GPIO94
Signal Descriptions
A1 PCSC2 DSPI C peripheral chip select O
A2 — — —
G GPIO94 GPIO I/O
2-31
Table 2-4. Signal Properties and Muxing Summary (continued)
Freescale Semiconductor
GPIO/PCR1
Package
Pad Type5
Direction
Voltage6
State State
P/A/G3
2 4 Location
Signal Name Function Function Summary during after
RESET7 RESET8
416
516
95 SOUTA_PCSC5_ P SOUTA DSPI A data output O MH VDDEH3 —/Up —/Up AD7 AC7
GPIO95
A1 PCSC5 DSPI C peripheral chip select O
A2 — — —
G GPIO95 GPIO I/O
96 PCSA0_PCSD2_ P PCSA0 DSPI A peripheral chip select I/O MH VDDEH3 —/Up —/Up AE6 AD6
MPC5676R Microcontroller Reference Manual, Rev 5
GPIO96
A1 PCSD2 DSPI D peripheral chip select O
A2 — — —
G GPIO96 GPIO I/O
97 PCSA1_ P PCSA1 DSPI A peripheral chip select O MH VDDEH3 —/Up —/Up AC6 AC6
PCSE0_GPIO97
A1 DSPI E peripheral chip select
A2 — — —
G GPIO97 GPIO I/O
98 PCSA2_ P PCSA2 DSPI A peripheral chip select O MH VDDEH3 —/Up —/Up AC7 AF6
SOUTE_GPIO98
A1 DSPI E data output
A2 — — —
G GPIO98 GPIO I/O
99 PCSA3_ P PCSA3 DSPI A peripheral chip select O MH VDDEH3 —/Up —/Up AE7 AD7
SINE_GPIO99
A1 DSPI E data input
A2 — — —
G GPIO99 GPIO I/O
100 PCSA4_ P PCSA4 DSPI A peripheral chip select O MH VDDEH3 —/Up —/Up AE5 AE5
SCKE_GPIO100
A1 DSPI E clock
A2 — — —
Signal Descriptions
G GPIO100 GPIO I/O
2-32
Table 2-4. Signal Properties and Muxing Summary (continued)
Freescale Semiconductor
GPIO/PCR1
Package
Pad Type5
Direction
Voltage6
State State
P/A/G3
2 4 Location
Signal Name Function Function Summary during after
RESET7 RESET8
416
516
101 PCSA5_ETRIG1_ P PCSA5 DSPI A peripheral chip select O MH VDDEH3 —/Up —/Up AD6 AA8
GPIO101
A1 ETRIG1 eQADC trigger input I
A2 — — —
G GPIO101 GPIO I/O
102 SCKB_ P SCKB DSPI B clock I/O MH VDDEH3 —/Up —/Up AE8 AC8
MPC5676R Microcontroller Reference Manual, Rev 5
GPIO102
A1 — — —
A2 — — —
G GPIO102 GPIO I/O
103 SINB_ P SINB DSPI B data input I MH VDDEH3 —/Up —/Up AE9 AB9
GPIO103
A1 — — —
A2 — — —
G GPIO103 GPIO I/O
104 SOUTB_ P SOUTB DSPI B data output O MH VDDEH3 —/Up —/Up AF9 AA10
GPIO104
A1 — — —
A2 — — —
G GPIO104 GPIO I/O
105 PCSB0_PCSD2_ P PCSB0 DSPI B peripheral chip select I/O MH VDDEH3 —/Up —/Up AD9 AF8
GPIO105
A1 PCSD2 DSPI D peripheral chip select O
A2 — — —
G GPIO105 GPIO I/O
106 PCSB1_PCSD0_ P PCSB1 DSPI B peripheral chip select O MH VDDEH3 —/Up —/Up AC9 AE8
GPIO106
A1 PCSD0 DSPI D peripheral chip select I/O
A2 — — —
Signal Descriptions
G GPIO106 GPIO I/O
2-33
Table 2-4. Signal Properties and Muxing Summary (continued)
Freescale Semiconductor
GPIO/PCR1
Package
Pad Type5
Direction
Voltage6
State State
P/A/G3
2 4 Location
Signal Name Function Function Summary during after
RESET7 RESET8
416
516
107 PCSB2_SOUTC_ P PCSB2 DSPI B peripheral chip select O MH VDDEH3 —/Up —/Up AF8 AD8
GPIO107
A1 SOUTC DSPI C data output O
A2 — — —
G GPIO107 GPIO I/O
108 PCSB3_SINC_ P PCSB3 DSPI B peripheral chip select O MH VDDEH3 —/Up —/Up AD10 AC9
MPC5676R Microcontroller Reference Manual, Rev 5
GPIO108
A1 SINC DSPI C data input I
A2 — — —
G GPIO108 GPIO I/O
109 PCSB4_SCKC_ P PCSB4 DSPI B peripheral chip select O MH VDDEH3 —/Up —/Up AC8 AF7
GPIO109
A1 SCKC DSPI C clock I/O
A2 — — —
G GPIO109 GPIO I/O
110 PCSB5_PCSC0_ P PCSB5 DSPI B peripheral chip select O MH VDDEH3 —/Up —/Up AF6 AE6
GPIO110
A1 PCSC0 DSPI C peripheral chip select I/O
A2 — — —
G GPIO110 GPIO I/O
235 SCKC_SCK_C_LVDSP_ P SCKC DSPI C clock I/O MH+ VDDEH4 —/Up —/Up AD21 AD21
GPIO235 LVDS
A1 SCK_C_LVDSP LVDS+ downstream signal positive O
output clock
A2 — — —
G GPIO235 GPIO I/O
236 SINC_SCK_C_LVDSM_ P SINC DSPI C data input I MH+ VDDEH4 —/Up —/Up AE22 AE22
GPIO236 LVDS
A1 SCK_C_LVDSM LVDS– downstream signal negative O
Signal Descriptions
output clock
A2 — — —
G GPIO236 GPIO I/O
2-34
Table 2-4. Signal Properties and Muxing Summary (continued)
Freescale Semiconductor
GPIO/PCR1
Package
Pad Type5
Direction
Voltage6
State State
P/A/G3
2 4 Location
Signal Name Function Function Summary during after
RESET7 RESET8
416
516
237 SOUTC_SOUT_C_LVDSP_ P SOUTC DSPI C data output O MH+ VDDEH4 —/Up —/Up AF21 AF21
GPIO237 LVDS
A1 SOUT_C_LVDSP LVDS+ downstream signal positive O
output data
A2 — — —
G GPIO237 GPIO I/O
MPC5676R Microcontroller Reference Manual, Rev 5
238 PCSC0_SOUT_C_LVDSM_ P PCSC0 DSPI C peripheral chip select I/O MH+ VDDEH4 —/Up —/Up AE21 AE21
GPIO238 LVDS
A1 SOUT_C_LVDSM LVDS– downstream signal negative O
output data
A2 — — —
G GPIO238 GPIO I/O
239 PCSC1_ P PCSC1 DSPI C peripheral chip select O MH VDDEH4 —/Up —/Up AC22 AC22
GPIO239
A1 — — —
A2 — — —
G GPIO239 GPIO I/O
240 PCSC2_GPIO240 P PCSC2 DSPI C peripheral chip select O MH VDDEH5 —/Up —/Up AE23 AE23
A1 — — —
A2 — — —
G GPIO240 GPIO I/O
241 PCSC3_GPIO241 P PCSC3 DSPI C peripheral chip select O MH VDDEH5 —/Up —/Up AD23 AD23
A1 — — —
A2 — — —
G GPIO241 GPIO I/O
242 PCSC4_GPIO242 P PCSC4 DSPI C peripheral chip select O MH VDDEH5 —/Up —/Up AF24 AF24
Signal Descriptions
A1 — — —
A2 — — —
G GPIO242 GPIO I/O
2-35
Table 2-4. Signal Properties and Muxing Summary (continued)
Freescale Semiconductor
GPIO/PCR1
Package
Pad Type5
Direction
Voltage6
State State
P/A/G3
2 4 Location
Signal Name Function Function Summary during after
RESET7 RESET8
416
516
243 PCSC5_GPIO243 P PCSC5 DSPI C peripheral chip select O MH VDDEH5 —/Up —/Up AE24 AE24
A1 — — —
A2 — — —
G GPIO243 GPIO I/O
MPC5676R Microcontroller Reference Manual, Rev 5
EBI
256 D_CS0_ P D_CS0 EBI chip select 0 O F VDDE9 —/Up —/Up — AD9
GPIO256
A1 — — —
A2 — — —
G GPIO256 GPIO I/O
Signal Descriptions
A1 — — —
A2 — — —
G GPIO260 GPIO I/O
2-36
Table 2-4. Signal Properties and Muxing Summary (continued)
Freescale Semiconductor
GPIO/PCR1
Package
Pad Type5
Direction
Voltage6
State State
P/A/G3
2 4 Location
Signal Name Function Function Summary during after
RESET7 RESET8
416
516
261 D_ADD14_ P D_ADD14 EBI address bus O F VDDE8 —/Up —/Up — R3
GPIO261
A1 — — —
A2 — — —
G GPIO261 GPIO I/O
GPIO262
A1 — — —
A2 — — —
G GPIO262 GPIO I/O
Signal Descriptions
G GPIO266 GPIO I/O
2-37
Table 2-4. Signal Properties and Muxing Summary (continued)
Freescale Semiconductor
GPIO/PCR1
Package
Pad Type5
Direction
Voltage6
State State
P/A/G3
2 4 Location
Signal Name Function Function Summary during after
RESET7 RESET8
416
516
267 D_ADD20_D_ADD_DAT20_ P D_ADD20 EBI address bus O F VDDE8 —/Up —/Up — T4
GPIO267
A1 D_ADD_DAT20 Address and data in mux mode. I/O
A2 — — —
G GPIO267 GPIO I/O
268 D_ADD21_D_ADD_DAT21_ P D_ADD21 EBI address bus O F VDDE9 —/Up —/Up — AB11
MPC5676R Microcontroller Reference Manual, Rev 5
GPIO268
A1 D_ADD_DAT21 Address and data in mux mode. I/O
A2 — — —
G GPIO268 GPIO I/O
269 D_ADD22_D_ADD_DAT22_ P D_ADD22 EBI address bus O F VDDE9 —/Up —/Up — AD10
GPIO269
A1 D_ADD_DAT22 Address and data in mux mode. I/O
A2 — — —
G GPIO269 GPIO I/O
270 D_ADD23_D_ADD_DAT23_ P D_ADD23 EBI address bus O F VDDE9 —/Up —/Up — AE10
GPIO270
A1 D_ADD_DAT23 Address and data in mux mode. I/O
A2 — — —
G GPIO270 GPIO I/O
271 D_ADD24_D_ADD_DAT24_ P D_ADD24 EBI address bus O F VDDE9 —/Up —/Up — AF10
GPIO271
A1 D_ADD_DAT24 Address and data in mux mode. I/O
A2 — — —
G GPIO271 GPIO I/O
272 D_ADD25_D_ADD_DAT25_ P D_ADD25 EBI address bus O F VDDE9 —/Up —/Up — AD11
GPIO272
A1 D_ADD_DAT25 Address and data in mux mode. I/O
A2 — — —
Signal Descriptions
G GPIO272 GPIO I/O
2-38
Table 2-4. Signal Properties and Muxing Summary (continued)
Freescale Semiconductor
GPIO/PCR1
Package
Pad Type5
Direction
Voltage6
State State
P/A/G3
2 4 Location
Signal Name Function Function Summary during after
RESET7 RESET8
416
516
273 D_ADD26_D_ADD_DAT26_ P D_ADD26 EBI address bus O F VDDE9 —/Up —/Up — AE11
GPIO273
A1 D_ADD_DAT26 Address and data in mux mode. I/O
A2 — — —
G GPIO273 GPIO I/O
274 D_ADD27_D_ADD_DAT27_ P D_ADD27 EBI address bus O F VDDE9 —/Up —/Up — AF11
MPC5676R Microcontroller Reference Manual, Rev 5
GPIO274
A1 D_ADD_DAT27 Address and data in mux mode. I/O
A2 — — —
G GPIO274 GPIO I/O
275 D_ADD28_D_ADD_DAT28_ P D_ADD28 EBI address bus O F VDDE9 —/Up —/Up — AD12
GPIO275
A1 D_ADD_DAT28 Address and data in mux mode. I/O
A2 — — —
G GPIO275 GPIO I/O
276 D_ADD29_D_ADD_DAT29_ P D_ADD29 EBI address bus O F VDDE9 —/Up —/Up — AB12
GPIO276
A1 D_ADD_DAT29 Address and data in mux mode. I/O
A2 — — —
G GPIO276 GPIO I/O
277 D_ADD30_D_ADD_DAT30_ P D_ADD30 EBI address bus O F VDDE9 —/Up —/Up — AE12
GPIO277
A1 D_ADD_DAT30 Address and data in mux mode. I/O
A2 — — —
G GPIO277 GPIO I/O
278 D_ADD_DAT0_ P D_ADD_DAT0 EBI data only in non-mux mode. I/O F VDDE10 —/Up —/Up — P25
GPIO278 Address and data in mux mode.
A1 — — —
Signal Descriptions
A2 — — —
G GPIO278 GPIO I/O
2-39
Table 2-4. Signal Properties and Muxing Summary (continued)
Freescale Semiconductor
GPIO/PCR1
Package
Pad Type5
Direction
Voltage6
State State
P/A/G3
2 4 Location
Signal Name Function Function Summary during after
RESET7 RESET8
416
516
279 D_ADD_DAT1_ P D_ADD_DAT1 EBI data only in non-mux mode. I/O F VDDE10 —/Up —/Up — P26
GPIO279 Address and data in mux mode.
A1 — — —
A2 — — —
G GPIO279 GPIO I/O
MPC5676R Microcontroller Reference Manual, Rev 5
280 D_ADD_DAT2_ P D_ADD_DAT2 EBI data only in non-mux mode. I/O F VDDE10 —/Up —/Up — N24
GPIO280 Address and data in mux mode.
A1 — — —
A2 — — —
G GPIO280 GPIO I/O
281 D_ADD_DAT3_ P D_ADD_DAT3 EBI data only in non-mux mode. I/O F VDDE10 —/Up —/Up — N25
GPIO281 Address and data in mux mode.
A1 — — —
A2 — — —
G GPIO281 GPIO I/O
282 D_ADD_DAT4_ P D_ADD_DAT4 EBI data only in non-mux mode. I/O F VDDE10 —/Up —/Up — N26
GPIO282 Address and data in mux mode.
A1 — — —
A2 — — —
G GPIO282 GPIO I/O
283 D_ADD_DAT5_ P D_ADD_DAT5 EBI data only in non-mux mode. I/O F VDDE10 —/Up —/Up — M25
GPIO283 Address and data in mux mode.
A1 — — —
A2 — — —
Signal Descriptions
G GPIO283 GPIO I/O
2-40
Table 2-4. Signal Properties and Muxing Summary (continued)
Freescale Semiconductor
GPIO/PCR1
Package
Pad Type5
Direction
Voltage6
State State
P/A/G3
2 4 Location
Signal Name Function Function Summary during after
RESET7 RESET8
416
516
284 D_ADD_DAT6_ P D_ADD_DAT6 EBI data only in non-mux mode. I/O F VDDE10 —/Up —/Up — N22
GPIO284 Address and data in mux mode.
A1 — — —
A2 — — —
G GPIO284 GPIO I/O
MPC5676R Microcontroller Reference Manual, Rev 5
285 D_ADD_DAT7_ P D_ADD_DAT7 EBI data only in non-mux mode. I/O F VDDE10 —/Up —/Up — M24
GPIO285 Address and data in mux mode.
A1 — — —
A2 — — —
G GPIO285 GPIO I/O
286 D_ADD_DAT8_ P D_ADD_DAT8 EBI data only in non-mux mode. I/O F VDDE10 —/Up —/Up — M23
GPIO286 Address and data in mux mode.
A1 — — —
A2 — — —
G GPIO286 GPIO I/O
287 D_ADD_DAT9_ P D_ADD_DAT9 EBI data only in non-mux mode. I/O F VDDE10 —/Up —/Up — M22
GPIO287 Address and data in mux mode.
A1 — — —
A2 — — —
G GPIO287 GPIO I/O
288 D_ADD_DAT10_ P D_ADD_DAT10 EBI data only in non-mux mode. I/O F VDDE10 —/Up —/Up — L26
GPIO288 Address and data in mux mode.
A1 — — —
A2 — — —
Signal Descriptions
G GPIO288 GPIO I/O
2-41
Table 2-4. Signal Properties and Muxing Summary (continued)
Freescale Semiconductor
GPIO/PCR1
Package
Pad Type5
Direction
Voltage6
State State
P/A/G3
2 4 Location
Signal Name Function Function Summary during after
RESET7 RESET8
416
516
289 D_ADD_DAT11_ P D_ADD_DAT11 EBI data only in non-mux mode. I/O F VDDE10 —/Up —/Up — L25
GPIO289 Address and data in mux mode.
A1 — — —
A2 — — —
G GPIO289 GPIO I/O
MPC5676R Microcontroller Reference Manual, Rev 5
290 D_ADD_DAT12_ P D_ADD_DAT12 EBI data only in non-mux mode. I/O F VDDE10 —/Up —/Up — L24
GPIO290 Address and data in mux mode.
A1 — — —
A2 — — —
G GPIO290 GPIO I/O
291 D_ADD_DAT13 P D_ADD_DAT13 EBI data only in non-mux mode. I/O F VDDE10 —/Up —/Up — L23
_GPIO291 Address and data in mux mode.
A1 — — —
A2 — — —
G GPIO291 GPIO I/O
292 D_ADD_DAT14_GPIO292 P D_ADD_DAT14 EBI data only in non-mux mode. I/O F VDDE10 —/Up —/Up — L22
Address and data in mux mode.
A1 — — —
A2 — — —
G GPIO292 GPIO I/O
293 D_ADD_DAT15_GPIO293 P D_ADD_DAT15 EBI data only in non-mux mode. I/O F VDDE10 —/Up —/Up — K26
Address and data in mux mode.
A1 — — —
A2 — — —
Signal Descriptions
G GPIO293 GPIO I/O
2-42
Table 2-4. Signal Properties and Muxing Summary (continued)
Freescale Semiconductor
GPIO/PCR1
Package
Pad Type5
Direction
Voltage6
State State
P/A/G3
2 4 Location
Signal Name Function Function Summary during after
RESET7 RESET8
416
516
294 D_RD_WR_GPIO294 P D_RD_WR EBI read/write O F VDDE10 —/Up —/Up — R26
A1 — — —
A2 — — —
G GPIO294 GPIO I/O
A1 — — —
A2 — — —
G GPIO295 GPIO I/O
297 D_OE_GPIO297 P D_OE EBI output enable O F VDDE10 —/Up —/Up — P23
A1 — — —
A2 — — —
G GPIO297 GPIO I/O
298 D_TS_GPIO298 P D_TS EBI transfer start O F VDDE9 —/Up —/Up — AE9
A1 — — —
A2 — — —
G GPIO298 GPIO I/O
299 D_ALE_GPIO299 P D_ALE EBI Address Latch Enable O F VDDE10 —/Up —/Up — P24
A1 — — —
A2 — — —
Signal Descriptions
G GPIO299 GPIO I/O
2-43
Table 2-4. Signal Properties and Muxing Summary (continued)
Freescale Semiconductor
GPIO/PCR1
Package
Pad Type5
Direction
Voltage6
State State
P/A/G3
2 4 Location
Signal Name Function Function Summary during after
RESET7 RESET8
416
516
300 D_TA_GPIO300 P D_TA EBI transfer acknowledge I/O F VDDE9 —/Up —/Up — AF9
A1 — — —
A2 — — —
G GPIO300 GPIO I/O
301 D_CS1_GPIO301 P D_CS1 EBI chip select O F VDDE9 —/Up —/Up — AB10
MPC5676R Microcontroller Reference Manual, Rev 5
A1 — — —
A2 — — —
G GPIO301 GPIO I/O
302 D_BDIP_GPIO302 P D_BDIP EBI burst data in progress O F VDDE8 —/Up —/Up — M2
A1 — — —
A2 — — —
G GPIO302 GPIO I/O
Signal Descriptions
G GPIO305 GPIO I/O
2-44
Table 2-4. Signal Properties and Muxing Summary (continued)
Freescale Semiconductor
GPIO/PCR1
Package
Pad Type5
Direction
Voltage6
State State
P/A/G3
2 4 Location
Signal Name Function Function Summary during after
RESET7 RESET8
416
516
306 D_ADD10_GPIO306 P D_ADD10 EBI address bus O F VDDE8 —/Up —/Up — P2
A1 — — —
A2 — — —
G GPIO306 GPIO I/O
A1 — — —
A2 — — —
G GPIO307 GPIO I/O
A2 — — —
Signal Descriptions
G GPIO213 GPIO I
2-45
Table 2-4. Signal Properties and Muxing Summary (continued)
Freescale Semiconductor
GPIO/PCR1
Package
Pad Type5
Direction
Voltage6
State State
P/A/G3
2 4 Location
Signal Name Function Function Summary during after
RESET7 RESET8
416
516
208 PLLCFG0_IRQ4_ P PLLCFG0 FMPLL mode configuration input I MH VDDEH1 PLLCFG/Up —/Up R3 M3
GPIO208
A1 IRQ4 External interrupt request I
A2 — — —
G GPIO208 GPIO I/O
209 PLLCFG1_IRQ5_GPIO209 P PLLCFG1 FMPLL mode configuration input I MH VDDEH1 PLLCFG/Up —/Up P2 L1
MPC5676R Microcontroller Reference Manual, Rev 5
— XTAL P XTAL Crystal oscillator output O AE VDD33 XTAL XTAL AC26 AC26
— EXTAL P EXTAL Crystal oscillator input I AE VDD33 EXTAL EXTAL AB26 AB26
229 D_CLKOUT P D_CLKOUT EBI system clock output O F VDDE9 CLKOUT/ CLKOUT/ — AF12
Enabled Enabled
214 ENGCLK P ENGCLK EBI engineering clock output O F VDDE2 ENGCLK/ ENGCLK/ AD1 AD1
Note: EXTCLK (External clock input) Enabled Enabled
selected through SIU register)
227 EVTO –12 EVTO Nexus event out O F VDDE2 ABS/Up EVTO/HI U1 V2
(the BAM uses this pin to
select if auto baud rate is on
or off)
219 MCKO –12 MCKO Nexus message clock out O F VDDE2 O/Low Disabled13 T2 U4
Signal Descriptions
220 MDO0_GPIO220 – 12
MDO014 Nexus message data out O F VDDE2 See Note15 See Note15 U3 V3
A1 — — —
A2 — — —
G GPIO220 GPIO I/O
2-46
Table 2-4. Signal Properties and Muxing Summary (continued)
Freescale Semiconductor
GPIO/PCR1
Package
Pad Type5
Direction
Voltage6
State State
P/A/G3
2 4 Location
Signal Name Function Function Summary during after
RESET7 RESET8
416
516
221 MDO1_GPIO221 –12 MDO114 Nexus message data out O F VDDE2 O/Low —/Down U4 W6
A1 — — —
A2 — — —
G GPIO221 GPIO I/O
222 MDO2_GPIO222 – 12
MDO214 Nexus message data out O F VDDE2 O/Low —/Down V1 V4
MPC5676R Microcontroller Reference Manual, Rev 5
A1 — — —
A2 — — —
G GPIO222 GPIO I/O
223 MDO3_GPIO223 – 12
MDO314 Nexus message data out O F VDDE2 O/Low —/Down V2 V5
A1 — — —
A2 — — —
G GPIO223 GPIO I/O
75 MDO4_GPIO75 –12 MDO414 Nexus message data out O F VDDE2 O/Low —/Down V3 W1
A1 — — —
A2 — — —
G GPIO75 GPIO I/O
76 MDO5_GPIO76 – 12
MDO514 Nexus message data out O F VDDE2 O/Low —/Down V4 W2
A1 — — —
A2 — — —
G GPIO76 GPIO I/O
77 MDO6_GPIO77 – 12
MDO614 Nexus message data out O F VDDE2 O/Low —/Down W1 W3
A1 — — —
A2 — — —
Signal Descriptions
G GPIO77 GPIO I/O
2-47
Table 2-4. Signal Properties and Muxing Summary (continued)
Freescale Semiconductor
GPIO/PCR1
Package
Pad Type5
Direction
Voltage6
State State
P/A/G3
2 4 Location
Signal Name Function Function Summary during after
RESET7 RESET8
416
516
78 MDO7_GPIO78 –12 MDO714 Nexus message data out O F VDDE2 O/Low —/Down W2 Y1
A1 — — —
A2 — — —
G GPIO78 GPIO I/O
79 MDO8_GPIO79 – 12
MDO814 Nexus message data out O F VDDE2 O/Low —/Down W3 W5
MPC5676R Microcontroller Reference Manual, Rev 5
A1 — — —
A2 — — —
G GPIO79 GPIO I/O
80 MDO9_GPIO80 – 12
MDO914 Nexus message data out O F VDDE2 O/Low —/Down Y1 Y2
A1 — — —
A2 — — —
G GPIO80 GPIO I/O
81 MDO10_GPIO81 –12 MDO1014 Nexus message data out O F VDDE2 O/Low —/Down Y2 Y3
A1 — — —
A2 — — —
G GPIO81 GPIO I/O
82 MDO11_GPIO82 – 12
MDO1114 Nexus message data out O F VDDE2 O/Low —/Down Y3 Y4
A1 — — —
A2 — — —
G GPIO82 GPIO I/O
231 MDO12_GPIO231 – 12
MDO1214 Nexus message data out O F VDDE2 O/Low —/Down AA1 Y5
A1 — — —
A2 — — —
Signal Descriptions
G GPIO231 GPIO I/O
2-48
Table 2-4. Signal Properties and Muxing Summary (continued)
Freescale Semiconductor
GPIO/PCR1
Package
Pad Type5
Direction
Voltage6
State State
P/A/G3
2 4 Location
Signal Name Function Function Summary during after
RESET7 RESET8
416
516
232 MDO13_GPIO232 –12 MDO1314 Nexus message data out O F VDDE2 O/Low —/Down AA2 AA1
A1 — — —
A2 — — —
G GPIO232 GPIO I/O
233 MDO14_GPIO233 – 12
MDO1414 Nexus message data out O F VDDE2 O/Low —/Down AA3 AA2
MPC5676R Microcontroller Reference Manual, Rev 5
A1 — — —
A2 — — —
G GPIO233 GPIO I/O
234 MDO15_GPIO234 – 12
MDO1514 Nexus message data out O F VDDE2 O/Low —/Down Y4 AA3
A1 — — —
A2 — — —
G GPIO234 GPIO I/O
224 MSEO0 –12 MSEO014 Nexus message start/end out O F VDDE2 O/Low MSEO/HI U2 U6
225 MSEO1 – 12
MSEO114 Nexus message start/end out O F VDDE2 O/Low MSEO/HI T3 U5
12
226 RDY – RDY Nexus ready output O F VDDE2 O/Low RDY/HI R4 U3
— TCK –12 TCK JTAG test clock input I F VDDE2 TCK/Down TCK/Down AB2 AB2
12
— TDI – TDI JTAG test data input I F VDDE2 TDI/Up TDI/Up AC2 AC2
12
228 TDO – TDO JTAG test data output O F VDDE2 TDO/Up TDO/Up AB1 AB1
12
— TMS – TMS JTAG test mode select input I F VDDE2 TMS/Up TMS/Up AB3 AB3
— JCOMP –12 JCOMP JTAG TAP controller enable I F VDDE2 JCOMP/Down JCOMP/Down R1 U2
— TEST — TEST Test mode select (not for customer I F VDDEH1 TEST/Down TEST/Down B4 B4
use)
— VDDSYN — VDDSYN Clock synthesizer power input I/O VDDE VDDSYN VDDSYN VDDSYN AD26 AD26
Signal Descriptions
— VSSSYN — VSSSYN Clock synthesizer ground input I VSSE VDDSYN VSSSYN VSSSYN AA26 AA26
— VSTBY — VSTBY SRAM standby power input I VHV VDDEH1 VSTBY VSTBY M4 M4
— REGSEL — REGSEL Selects regulator mode I AE VDDREG REGSEL REGSEL W23 W23
(Linear/Switch mode)
2-49
Table 2-4. Signal Properties and Muxing Summary (continued)
Freescale Semiconductor
GPIO/PCR1
Package
Pad Type5
Direction
Voltage6
State State
P/A/G3
2 4 Location
Signal Name Function Function Summary during after
RESET7 RESET8
416
516
— REGCTL — REGCTL Regulator controller output to O AE VDDREG REGCTL REGCTL Y26 Y26
base/gate of power transistor
— VSSFL — VSSFL Tie to VSS I VSS VDDREG VSSFL VSSFL AB25 AB25
— VDDREG — VDDREG Source voltage for on-chip regulators I VDDINT VDDREG VDDREG VDDREG AA25 AA25
and Low voltage detect circuits
MPC5676R Microcontroller Reference Manual, Rev 5
1
The GPIO number is the same as the corresponding pad configuration register (SIU_PCRn) number in pins that have GPIO functionality. For pins that do not
have GPIO functionality, this number is the PCR number.
2
The primary signal name is used as the pin label on the BGA map for identification purposes. However, the primary signal function is not available on all devices
and is indicated by a dash in the following table columns: Signal Functions, P/F/G, and I/O Type.
3
P/A/G stands for Primary/Alternate/GPIO . This column indicates which function on a pin is Primary, Alternate 1, Alternate 2, (Alternate n) and GPIO.
4 Each line in the Function column corresponds to a separate signal function on the pin. For all device I/O pins, the primary, alternate, or GPIO signal functions
are designated in the PA field of the SIU_PCRn registers except where explicitly noted.
5 MH = High voltage, medium speed
F = Fast speed
FS = Fast speed with slew
AE = Analog with ESD protection circuitry (up/down = pull up and pull down circuits included in the pad)
VHV = Very high voltage
6 VDDE (fast I/O) and VDDEH (slow I/O) power supply inputs are grouped into segments. Each segment of VDDEH pins can connect to a separate 3.3–5.0 V
(+5%/–10%) power supply input. Each segment of VDDE pins can connect to a separate 1.8–3.3 V (±10%) power supply.
7 All pins are sampled after the internal POR is negated. The terminology used in this column is: O – output, I – input, Up – weak pull up enabled, Down – weak
pulldown enabled, Low – output driven low, High – output driven high, ABS — Auto Baud Select (during Reset or until JCOMP assertion). A dash on the left side
of the slash denotes that both the input and output buffers for the pin are off. A dash on the right side of the slash denotes that there is no weak pull up/down
enabled on the pin. The signal name to the left or right of the slash indicates the pin is enabled.
8 The Function After Reset of a GPI function is general purpose input. A dash on the left side of the slash denotes that both the input and output buffers for the pin
are off. A dash on the right side of the slash denotes that there is no weak pull up/down enabled on the pin.
9 During and just after POR negates, internal pull resistors can be enabled, resulting in as much as 4 mA of current draw. The pull resistors are disabled when the
and MCKO are also dependent on trace (RPM or FPM) being enabled.
Signal Descriptions
12 The Nexus pins don’t have a “primary” function as they are not configured by the SIU. The pins are selected by asserting JCOMP and configuring the NPC. SIU
Signal Descriptions
2-51
Table 2-5 lists the pin locations of the power and ground signals on the 416 TEPBGA package.
Freescale Semiconductor
VDD33
M1 AA4 AA23
VDDE2
MPC5676R Microcontroller Reference Manual, Rev 5
N10 P10 P11 R10 R11 T1 T10 T11 T12 U10 U11 U12 W4 AC1 AC5 AF2
VDDEH6 VDDEH7
N23 AC25 D24 E23 M26
VSS
A1 A26 B2 B25 C3 C24 D4 D23 K10 K11 K12 K13 K14 K15 K16 K17 L10 L11
L12 L13 L14 L15 L16 L17 M10 M11 M12 M13 M14 M15 M16 M17 N11 N12 N13 N14
N15 N16 N17 P12 P13 P14 P15 P16 P17 R12 R13 R14 R15 R16 R17 T13 T14 T15
T16 T17 U13 U14 U15 U16 U17 AC4 AC23 AD3 AD24 AE2 AE25 AF1 AF26
Signal Descriptions
2-52
Signal Descriptions
Table 2-6 lists the pin locations of the power and ground signals on the 516 TEPBGA package.
Table 2-6. 516-pin Power Supply Locations
VDD
A2 B3 C4 D5 E6 N4 AB4 AB23 AC3 AC12 AC24 AD2 AD25 AE1 AE26
VDD33 VDDE10
M1 P6 L21 AA4 AA11 AA14 AA23 F16 F17 F19 F21 N21 P21 AA22
VDDE2
N10 P10 P11 R10 R11 T1 T10 T11 T12 U10 U11 U12 W4 AC1 AC5 AF2
VDDE8 VDDE9
F6 F8 F10 F11 N6 AA5 AA13 AB6 AB7 AB18 AB19 AB20 AB21
VDDEH6 VDDEH7
N23 AC25 D24 E23 M26
VSS
A25 B2 B25 B26 C3 C24 D4 D23 E5 E7 E8 E9 E10 E11 E12 E13 E14 E15
E16 E17 E18 E19 E21 E22 F5 F13 F14 K10 K11 K12 K13 K14 K15 K16 K17 L10
L11 L12 L13 L14 L15 L16 L17 M10 M11 M12 M13 M14 M15 M16 M17 N11 N12 N13
N14 N15 N16 N17 P12 P13 P14 P15 P16 P17 R12 R13 R14 R15 R16 R17 T13 T14
T15 T16 T17 U13 U14 U15 U16 U17 AA6 AA21 AB5 AB22 AC4 AC23 AD3 AD24 AE2 AE25
Pad configuration
•••
Power-on RESET
Reset
reset
controller RSTOUT
detection
IRQ[0]
•
External •
IRQ/ IRQ[15]
edge • •
• •
detects • •
SIU BOOTCFG[0]
registers
Pad BOOTCFG[1]
Interface/ WKPCFG
Reset
Pad
configuration
Ring GPIO[n]
PLLCFG[0]
GPIO
• • PLLCFG[1]
• •
• •
PLLCFG[2]
•••
NOTE
The power-on reset detection module, pad interface/pad ring module, and
peripheral I/O channels shown shaded in Figure 3-1 are external to the SIU.
3.1.2 Overview
The system integration units are accessed through the system bus crossbar switch (XBAR) and the
peripheral bridge A (PBRIDGE_A). Table 3-1 lists the features that are configured:
:
Feature Description
System reset operations Monitors internal and external reset sources, and drives the RSTOUT signal
• Power-on reset support
• Reset status register providing last reset source to software
• Glitch detection on reset input
• Software controlled reset assertion
Pad configuration registers Enables the configuration and initialization of the I/O pin electrical characteristics using
software to select the following:
• Active function from the set of multiplexed functions
• Pullup and pulldown characteristics of the pin
• Slew rate for slow and medium pads
• Open drain mode for output pins
• Hysteresis for input pins
• Drive strength of bus signals for fast pads
General-purpose I/O (GPIO) Provides uniform and discrete I/O control of MCU general-purpose I/O pins, where each
GPIO signal has an input register and an output register.
Internal peripheral multiplexing Provides flexibility to customize signal/pin assignments for application development that
allows:
• Serial and parallel chaining of DSPIs
• Flexible selection of eQADC trigger inputs
• Assignment of interrupt requests (IRQs) between external pins and DSPI
TLB Entry Selector Allows an external tool to non-intrusively change the TLB entry that is used by the cores to
access memory.
Protected Port Output Allows up to four GPIO pins to be reserved by any one of the two cores.
Normal In normal mode, the SIU provides the register interface and logic that controls the device and
system configuration, the reset controller, and GPIO. The SIU continues operation with no
changes in stop mode.
SIU_BASE + (0x0600–0x07FF) SIU_GPDO0 – SIU_GPDO511 GPIO pin data output registers 0–511 8
SIU_BASE + (0x0800–0x08FF) SIU_GPDI0 – 255 GPIO input data registers 0–255 (Legacy 8
support only, new implementation at
SIU_BASE + 0x0E00)
SIU_BASE + (0x0900–0x0903) Reserved — —
SIU_BASE + (0x0904–0x0907) SIU_EIISR (sometimes referred External IRQ input select register 32
to as ISEL1)
SIU_BASE+0x0D20– Reserved — —
SIU_BASE+0x0D3F
SIU_BASE+0x0D4C Reserved — —
SIU_BASE+0x0D5C Reserved — —
SIU_BASE+0x0D6C Reserved — —
SIU_BASE+0x0D7C– Reserved — —
SIU_BASE+0x0DFF
Table 3-4 is the address map for the SIU_B registers. All register addresses shown are an offset of the
SIU_B base address.
Table 3-4. SIU_B Memory Map
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R PARTNUM
MPC5676R part 0 1 0 1 0 1 1 0 0 1 1 1 0 1 1 0
number
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
W
Default reset 416= 0b0110 0 0 0 0 0b0000 0b0000
values 516=0b1110
Field Description
0–15 MCU part number. Read-only, mask-programmed part identification number of the MCU.
PARTNUM MPC5676R reads 0x5676.
16–19 Package settings. PKG selects the pin package for the device.
PKG 0110 Select the 416 package
1110 Select the 516 package
All other settings are reserved.
20–23 Reserved
24–27 Major revision number of MCU mask. Read-only, mask programmed mask number of the
MASKNUM_MAJOR MCU. Reads 0x0 for the initial mask set of the device, and changes sequentially for each
[0:3] mask set.
28–31 Minor revision number of MCU mask. Read-only, mask programmed mask number of the
MASKNUM_MINOR MCU. Reads 0x0 for the initial mask set of the device, and changes sequentially for each
[0:3] mask set.
• Loss-of-clock Lower 2
• Loss-of-lock
• Core Watchdog or Debug
• Platform Watchdog
The WKPCFG bit retains the latest value of the WKPCFG signal before reset. The BOOTCFG field retains
the latest values of the BOOTCFG[0:1] signals before reset.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
SWTRS0
SWTRS1
STCURS
WDRS0
WDRS1
CPURS
R
PORS
SSRS
LCRS
LLRS
ERS
SERF
0
0
W
Reset 1 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R WKP
0 0 0 0 0 0 0 0 0 0 0 ABR BOOTCFG
CFG 2 RGF
W
Reset 1 U2 0 0 0 0 0 0 0 0 0 0 0 U U3 0
1
The reset status register receives the reset values during power-on reset.
2
The reset value of the WKPCFG bit is the value on the WKPCFG pin at the time of the last reset.
3 The reset value of the BOOTCFG bits is the value on the BOOTCFG[0:1] pins at he time of the last reset.
The following table lists and describes the fields of the reset status register:
Table 3-7. SIU_RSR Bit Field Descriptions
Field Description
Field Description
Except for a POR request or writing a 1 to the software external reset flag (SERF) bit, all reset requests,
regardless of priority are not serviced until the current reset completes.
In the following cases, more than one reset bit is set in the reset status register (SIU_RSR):
Table 3-8. Causes That Set Multiple Reset Status Bits
Case 1
Condition • POR request negates and the device remains in the reset
• External reset requested
• POR and external reset status bits are set
Reason POR request started the reset sequence, but an external reset request was received before the POR reset
sequence ended.
Case 2
Reason The SERF flag bit is cleared by writing a 1 (write 1 to clear) to the bit location or when another reset source
is asserted.
Case 3
Reason More than one reset request occurred on the same clock cycle with no reset request by a higher-priority
reset source, therefore the status bits for all the requesting resets are set. Refer to Table 3-6.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 SER 0 0 0 0 0 0 0 0 0 0 0 0 0 0
W see
SSR1
note2
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
W
Reset 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
1
The SSR bit always reads 0. A write of 0 to this bit has no effect.
2 Write 1 to the SER bit to generate a software external reset. A write of 0 to this bit has no effect. When the reset completes,
the SER bit is cleared to 0.
The following table describes the fields in the system reset control register:
Table 3-9. SIU_SRCR Bit Field Descriptions
Field Description
1 Software external reset. Used to generate a software external reset. Writing a 1 to this bit asserts RSTOUT for 2400
SER clocks, and the internal reset is not asserted. The bit automatically clears when the software external reset completes
or any other reset source is asserted. After a software external reset has been initiated, RSTOUT negates if this bit
is cleared before the 2400 clock period expires.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R NMI0 NMI1 0 0 0 0 0 0 0 0 0 0 0 0 0 0
W w1c w1c
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R EIF15 EIF14 EIF13 EIF12 EIF11 EIF10 EIF9 EIF8 EIF7 EIF6 EIF5 EIF4 EIF3 EIF2 EIF1 EIF0
W w1c w1c w1c w1c w1c w1c w1c w1c w1c w1c w1c w1c w1c w1c w1c w1c
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
The following table describes the fields in the external interrupt status register:
Table 3-10. SIU_EISR Bit Field Descriptions
Field Description
0 Non-Maskable Interrupt Flag. This bit is set when core 0 receives an interrupt from the NMI input pin.
NMI0 0 No core 0 interrupt has occurred on the NMI input
1 A core 0 interrupt has occurred on the NMI input
1 Non-Maskable Interrupt Flag. This bit is set when core 1 receives an interrupt from the NMI input pin.
NMI1 0 No core 1 interrupt has occurred on the NMI input
1 A core 1 interrupt has occurred on the NMI input
2–15 Reserved
16–31 External interrupt request flag n. This bit is set when an edge-triggered event occurs on the corresponding IRQ[n]
EIFn input. Cleared by writing a 1.
0 No edge-triggered event has occurred on the corresponding IRQ[n] input.
1 An edge-triggered event has occurred on the corresponding IRQ[n] input.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R EIRE EIRE EIRE EIRE EIRE EIRE EIRE EIRE EIRE EIRE EIRE EIRE EIRE EIRE EIRE EIRE
15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
The following table describes the fields in the DMA interrupt request enable register:
Table 3-11. SIU_DIRER Bit Field Descriptions
Field Description
NMISEL8 Non Maskable Interrupt / Critical Interrupt Selection (from external pin). SIU generates two specific sources
of interrupt to core 0, one of them is defined as critical interrupt and the other is defined as non maskable
interrupt (NMI). The NMISEL bit selects which signal receives the IRQ from the pin.
0 NMI is enabled (IVOR1 core 0 exception)
1 Critical interrupt is enabled (IVOR0 core 0 exception)
Note: NMISEL8 is a write once bit.
NMISEL9 Non Maskable Interrupt / Critical Interrupt Selection (from external pin). SIU generates two specific sources
of interrupt to core 1, one of them is defined as critical interrupt and the other is defined as non maskable
interrupt (NMI). The NMISEL bit selects which signal receives the IRQ from the pin.
0 NMI is enabled (IVOR1 core 1 exception)
1 Critical interrupt is enabled (IVOR0 core 1 exception)
Note: NMISEL9 is a write once bit.
NMISEL0 Non Maskable Interrupt / Critical Interrupt Selection (from the watchdog timer, SWT0). SIU generates two
specific sources of interrupt to core 0, one of them is defined as a critical interrupt and the other is defined as
a non maskable interrupt (NMI).
0 NMI is enabled (IVOR1 core 0 exception)
1 Critical interrupt is enabled (IVOR0 core 0 exception)
Note: NMISEL0 is a write once bit.
NMISEL1 Non Maskable Interrupt / Critical Interrupt Selection (from the watchdog timer, SWT1). SIU generates two
specific sources of interrupt to core 1, one of them is defined as a critical interrupt and the other is defined as
a non maskable interrupt (NMI).
0 NMI is enabled (IVOR1 core 1 exception)
1 Critical interrupt is enabled (IVOR0 core 1 exception)
Note: NMISEL1 is a write once bit.
EIREn External interrupt request enable n. Enables the assertion of the interrupt request from the SIU to the interrupt
controller when an edge-triggered event occurs on the IRQ[n] pin.
0 External interrupt request is disabled.
1 External interrupt request is enabled.
Note: EIRE[0:3] can optionally enable DMA requests instead of IRQs.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Field Description
0–27 Reserved
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R OVF OVF OVF OVF OVF OVF OVF OVF OVF OVF OVF OVF OVF OVF OVF OVF
W 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
The following table describes the fields in the overrun status register:
Table 3-13. SIU_OSR Bit Field Descriptions
Field Description
0–15 Reserved
16–31 Overrun flag n. This bit is set when an overrun occurs on IRQ[n]. Bit 31 (OVF0) is the overrun flag for IRQ[0]; bit 16
OVFn (OVF15) is overrun flag for IRQ[15].
0 No overrun occurred.
1 An overrun occurred.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R ORE ORE ORE ORE ORE ORE ORE ORE ORE ORE ORE ORE ORE ORE ORE ORE
W 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
The following table describes the fields in the overrun request enable register:
Table 3-14. SIU_ORER Bit Field Descriptions
Field Function
0–15 Reserved
16–31 Overrun request enable n. Enables the overrun request when an overrun occurs on the IRQ[n] pin. Bit 31 (ORE0) is
OREn the enable overrun flag for IRQ[0]; bit 16 (ORE15) is overrun flag for IRQ[15].
0 Overrun request is disabled.
1 Overrun request is enabled.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R IREE_ 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
W NMI8
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
The following table describes the fields in the IRQ rising-edge event enable register:
Table 3-15. SIU_IREER Bit Field Descriptions
Field Function
IREE_ IRQ rising-edge event enable for NMI from external NMI pin.
NMI8 0 Rising-edge event is disabled.
1 Rising-edge event is enabled.
IREEn IRQ rising-edge event enable n. Enables rising-edge-triggered events on the corresponding IRQ[n] pin.
0 Rising-edge event is disabled.
1 Rising-edge event is enabled.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R IFEE_ 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
W NMI8
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R IFEE IFEE IFEE IFEE IFEE IFEE IFEE IFEE IFEE IFEE IFEE IFEE IFEE IFEE IFEE IFEE
W 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
The following table describes the fields in the IRQ falling-edge event enable register:
Table 3-16. SIU_IFEER Bit Field Descriptions
Field Function
IFEE_ IRQ falling-edge event enable for NMI from external NMI pin.
NMI8 0 Falling-edge event is disabled.
1 Falling-edge event is enabled.
IFEEn IRQ falling-edge event enable n. Enables falling-edge-triggered events on the corresponding IRQ[n] pin.
0 Falling-edge event is disabled.
1 Falling-edge event is enabled.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R 0 0 0 0 0 0 0 0 0 0 0 0
DFL
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
The following table describes the field in the IRQ digital filter register:
Table 3-17. SIU_IDFR Bit Field Descriptions
Field Function
0–27 Reserved
28–31 Digital filter length. Defines the digital filter period on the IRQ[n] inputs according to the following equation:
DFL
DFL
Filter Period = SystemClockPeriod 2 + 1 S ystemClockPeriod
For a 100 MHz system clock, this gives a range of 20 ns to 328 µs. The minimum time of three clocks accounts for
synchronization of the IRQ input pins with the system clock.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R IFI_ 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
W NMI
Reset U U U U U U U U U U U U U U U U
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R
IFI15 IFI14 IFI13 IFI12 IFI11 IFI10 IFI9 IFI8 IFI7 IFI6 IFI5 IFI4 IFI3 IFI2 IFI1 IFI0
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Field Function
0–31 Filtered Input n—set/cleared for the corresponding filtered IRQ pin.
IFIn 0 A logic one has passed through the IRQ digital filter for the corresponding IRQ pin.
1 A logic zero has passed through the IRQ digital filter for the corresponding IRQ pin.
Address: SIU_BASE + offset (see SIU_PCRn Settings table) Access: User read/write
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 0
PA OBE IBE DSC ODE HYS SRC WPE WPS
W
Reset See SIU_PCRn Settings table for reset values
Figure 3-14. Pad Configuration Register (SIU_PCRn)
The following table describes the fields in the pad configuration control registers:
Table 3-19. SIU_PCR Bit Field Descriptions
Field Description
0–2 Reserved
3–5 Pin assignment. Selects the function of a multiplexed pad. A separate port enable output signal from the
PA SIU is asserted for each value of this register. The size of the field can be from 1 to 3 bits, depending on
[0:2] the amount of multiplexing on the pad.
PA Pin Function 1
0 0 0 GPIO
0 0 1 Primary function
0 1 0 Alternate 1
0 1 1 Alternate 2
1 0 0 Alternate 3
1 0 1 Invalid value
1 1 0 Invalid value
1 1 1 Invalid value
1
For any SIU_PCR that does not comply
with these rules, the PA definition is given
explicitly with the SIU_PCR definition.
6 Output buffer enable. Enables the pad as an output and drives the output buffer enable signal.
OBE 0 Disable output buffer for the pad.
1 Enable output buffer for the pad is enabled.
7 Input buffer enable. Enables the pad as an input and drives the input buffer enable signal.
IBE 0 Disable input buffer for the pad.
1 Enable input buffer for the pad is enabled.
8–9 Drive strength control. Controls the pad drive strength. Drive strength control pertains to pins with the fast
DSC I/O pad type.
[0:1] 00 10 pF drive strength
01 20 pF drive strength
10 30 pF drive strength
11 50 pF drive strength
10 Open drain output enable. Controls output driver configuration for the pads. Either open drain or push/pull
ODE driver configurations can be selected. This feature applies to output pins only.
0 Disable open drain for the pad (push/pull driver enabled).
1 Enable open drain for the pad.
Field Description
12–13 Slew rate control. Controls slew rate for the pad. Slew rate control pertains to pins with slow or medium
SRC I/O pad types, and the output signals are driven according to the value of this field. Actual slew rate
[0:1] depends on the pad type and load. Refer to the electrical specifications for this information.
00 Minimum slew rate
01 Medium slew rate
10 Invalid value
11 Maximum slew rate
14 Weak pullup/down enable. Controls whether the weak pullup/down devices are enabled/disabled for the
WPE pad. Pullup/down devices are enabled by default.
0 Disable weak pull device for the pad.
1 Enable weak pull device for the pad.
15 Weak pullup/down select. Controls whether weak pullup or weak pulldown devices are used for the pad
WPS when weak pullup/down devices are enabled. The WKPCFG pin determines whether pullup or pulldown
devices are enabled during reset. The WPS bit determines whether weak pullup or pulldown devices are
used after reset, or for pads in which the WKPCFG pin does not determine the reset weak pullup/down
state.
0 Pulldown is enabled for the pad.
1 Pullup is enabled for the pad.
There are a number of input signals on the device that have multiple external pins as input sources. Only
one input source can be active at any time for these pins. To achieve this, there is a predefined priority for
the PCR registers controlling these pins, which is used to mux the input sources and allow only one active
input. The multiple source inputs with PCR priority is given in Table 3-20.
PCR number
Function
highest lowest
priority priority
TXDA 89 83 460
RXDA 90 84 461
TXDB 91 462 —
RXDB 92 463 —
The symbols in the SIU_PCRn bit fields in table on the following pages represent the reset state of the bits.
The meaning of each symbol is given in Table 3-21.
Table 3-21. SIU_PCRn Bit Field Symbols
Symbol Meaning
SIU_PCRn[3:15]
(SIU_PCRn[0:2] = Reserved, should be cleared)
PCRn
Address Primary
GPIO A2 A3 A4 3 4 5 6 7 8 9 10 11 12 13 14 15
Offset Function
DSC1
DSC0
SRC1
SRC0
WPE
WPS
ODE
OBE
HYS
PA2
PA1
PA0
IBE
75 0x00D6 GPIO75 MDO4 — — — — — — 0 0 1 1 0 0 — — 1 0
76 0x00D8 GPIO76 MDO5 — — — — — — 0 0 1 1 0 0 — — 1 0
77 0x00DA GPIO77 MDO6 — — — — — — 0 0 1 1 0 0 — — 1 0
MPC5676R Microcontroller Reference Manual, Rev 5
SIU_PCRn[3:15]
(SIU_PCRn[0:2] = Reserved, should be cleared)
PCRn
Address Primary
GPIO A2 A3 A4 3 4 5 6 7 8 9 10 11 12 13 14 15
Offset Function
DSC1
DSC0
SRC1
SRC0
WPE
WPS
ODE
OBE
HYS
PA2
PA1
PA0
IBE
97 0x0102 GPIO97 PCSA1 PCSE0 — — — 0 0 0 0 — — 0 0 0 0 1 1
98 0x0104 GPIO98 PCSA2 SOUTE — — — 0 0 0 0 — — 0 0 0 0 1 1
99 0x0106 GPIO99 PCSA3 SINE — — — 0 0 0 0 — — 0 0 0 0 1 1
MPC5676R Microcontroller Reference Manual, Rev 5
SIU_PCRn[3:15]
(SIU_PCRn[0:2] = Reserved, should be cleared)
PCRn
Address Primary
GPIO A2 A3 A4 3 4 5 6 7 8 9 10 11 12 13 14 15
Offset Function
DSC1
DSC0
SRC1
SRC0
WPE
WPS
ODE
OBE
HYS
PA2
PA1
PA0
IBE
122 0x0134 GPIO122 ETPUA8 ETPUA20 — — — 0 0 0 0 — — 0 0 0 0 1 U
123 0x0136 GPIO123 ETPUA9 ETPUA21 — — — 0 0 0 0 — — 0 0 0 0 1 U
124 0x0138 GPIO124 ETPUA10 ETPUA22 — — — 0 0 0 0 — — 0 0 0 0 1 U
MPC5676R Microcontroller Reference Manual, Rev 5
SIU_PCRn[3:15]
(SIU_PCRn[0:2] = Reserved, should be cleared)
PCRn
Address Primary
GPIO A2 A3 A4 3 4 5 6 7 8 9 10 11 12 13 14 15
Offset Function
DSC1
DSC0
SRC1
SRC0
WPE
WPS
ODE
OBE
HYS
PA2
PA1
PA0
IBE
145 0x0162 GPIO145 ETPUA31 PCSC4 — — — 0 0 0 0 — — 0 0 0 0 1 U
146 0x0164 GPIO146 TCRCLKB IRQ6 — — — 0 0 0 0 — — 0 0 0 0 1 1
147 0x0166 GPIO147 ETPUB0 ETPUB16 — — — 0 0 0 0 — — 0 0 0 0 1 U
MPC5676R Microcontroller Reference Manual, Rev 5
SIU_PCRn[3:15]
(SIU_PCRn[0:2] = Reserved, should be cleared)
PCRn
Address Primary
GPIO A2 A3 A4 3 4 5 6 7 8 9 10 11 12 13 14 15
Offset Function
DSC1
DSC0
SRC1
SRC0
WPE
WPS
ODE
OBE
HYS
PA2
PA1
PA0
IBE
168 0x0190 GPIO168 ETPUB21 — — — — — 0 0 0 — — 0 0 0 0 1 U
169 0x0192 GPIO169 ETPUB22 — — — — — 0 0 0 — — 0 0 0 0 1 U
170 0x0194 GPIO170 ETPUB23 — — — — — 0 0 0 — — 0 0 0 0 1 U
MPC5676R Microcontroller Reference Manual, Rev 5
SIU_PCRn[3:15]
(SIU_PCRn[0:2] = Reserved, should be cleared)
PCRn
Address Primary
GPIO A2 A3 A4 3 4 5 6 7 8 9 10 11 12 13 14 15
Offset Function
DSC1
DSC0
SRC1
SRC0
WPE
WPS
ODE
OBE
HYS
PA2
PA1
PA0
IBE
191 0x01BE GPIO191 EMIOS12 SOUTC — — — 0 0 0 0 — — 0 0 0 0 1 U
192 0x01C0 GPIO192 EMIOS13 SOUTD — — — 0 0 0 0 — — 0 0 0 0 1 U
193 0x01C2 GPIO193 EMIOS14 IRQ0 CNTXD — — 0 0 0 0 — — 0 0 0 0 1 U
MPC5676R Microcontroller Reference Manual, Rev 5
SIU_PCRn[3:15]
(SIU_PCRn[0:2] = Reserved, should be cleared)
PCRn
Address Primary
GPIO A2 A3 A4 3 4 5 6 7 8 9 10 11 12 13 14 15
Offset Function
DSC1
DSC0
SRC1
SRC0
WPE
WPS
ODE
OBE
HYS
PA2
PA1
PA0
IBE
222 0x01FC GPIO222 MDO2 — — — — — — 0 0 1 1 0 0 — — 1 0
223 0x01FE GPIO223 MDO3 — — — — — — 0 0 1 1 0 0 — — 1 0
224 0x0200 — MSEO0 — — — — — — — — 1 1 — — — — — —
MPC5676R Microcontroller Reference Manual, Rev 5
SIU_PCRn[3:15]
(SIU_PCRn[0:2] = Reserved, should be cleared)
PCRn
Address Primary
GPIO A2 A3 A4 3 4 5 6 7 8 9 10 11 12 13 14 15
Offset Function
DSC1
DSC0
SRC1
SRC0
WPE
WPS
ODE
OBE
HYS
PA2
PA1
PA0
IBE
244 0x0228 GPIO244 TXDC ETRIG0 — — — 0 0 0 0 — — 0 0 0 0 1 1
245 0x022A GPIO245 RXDC — — — — — 0 0 0 — — 0 0 0 0 1 1
246 0x022C GPIO246 CNTXD — — — — — 0 0 0 — — 0 0 0 0 1 1
MPC5676R Microcontroller Reference Manual, Rev 5
SIU_PCRn[3:15]
(SIU_PCRn[0:2] = Reserved, should be cleared)
PCRn
Address Primary
GPIO A2 A3 A4 3 4 5 6 7 8 9 10 11 12 13 14 15
Offset Function
DSC1
DSC0
SRC1
SRC0
WPE
WPS
ODE
OBE
HYS
PA2
PA1
PA0
IBE
269 0x025A GPIO269 D_ADD22 D_ADD_DAT22 — — — 0 0 0 0 1 1 0 0 — — 1 1
270 0x025C GPIO270 D_ADD23 D_ADD_DAT23 — — — 0 0 0 0 1 1 0 0 — — 1 1
271 0x025E GPIO271 D_ADD24 D_ADD_DAT24 — — — 0 0 0 0 1 1 0 0 — — 1 1
MPC5676R Microcontroller Reference Manual, Rev 5
SIU_PCRn[3:15]
(SIU_PCRn[0:2] = Reserved, should be cleared)
PCRn
Address Primary
GPIO A2 A3 A4 3 4 5 6 7 8 9 10 11 12 13 14 15
Offset Function
DSC1
DSC0
SRC1
SRC0
WPE
WPS
ODE
OBE
HYS
PA2
PA1
PA0
IBE
292 0x0288 GPIO292 D_ADD_DAT14 — — — — — 0 0 0 1 1 0 0 — — 1 1
293 0x028A GPIO293 D_ADD_DAT15 — — — — — 0 0 0 1 1 0 0 — — 1 1
294 0x028C GPIO294 D_RD_WR — — — — — 0 0 0 1 1 0 0 — — 1 1
MPC5676R Microcontroller Reference Manual, Rev 5
SIU_PCRn[3:15]
(SIU_PCRn[0:2] = Reserved, should be cleared)
PCRn
Address Primary
GPIO A2 A3 A4 3 4 5 6 7 8 9 10 11 12 13 14 15
Offset Function
DSC1
DSC0
SRC1
SRC0
WPE
WPS
ODE
OBE
HYS
PA2
PA1
PA0
IBE
441 0x03B2 GPIO441 ETPUC0 — — — — — 0 0 0 — — 0 0 0 0 1 U
442 0x03B4 GPIO442 ETPUC1 — — — — — 0 0 0 — — 0 0 0 0 1 U
443 0x03B6 GPIO443 ETPUC2 — — — — — 0 0 0 — — 0 0 0 0 1 U
MPC5676R Microcontroller Reference Manual, Rev 5
SIU_PCRn[3:15]
(SIU_PCRn[0:2] = Reserved, should be cleared)
PCRn
Address Primary
GPIO A2 A3 A4 3 4 5 6 7 8 9 10 11 12 13 14 15
Offset Function
DSC1
DSC0
SRC1
SRC0
WPE
WPS
ODE
OBE
HYS
PA2
PA1
PA0
IBE
464 0x03E0 GPIO464 ETPUC23 PCSD5 MAA0 MAB0 0 0 0 0 0 — — 0 0 0 0 1 U
465 0x03E2 GPIO465 ETPUC24 PCSD4 MAA1 MAB1 0 0 0 0 0 — — 0 0 0 0 1 U
466 0x03E4 GPIO466 ETPUC25 PCSD3 MAA2 MAB2 0 0 0 0 0 — — 0 0 0 0 1 U
MPC5676R Microcontroller Reference Manual, Rev 5
0 1 2 3 4 5 6 7
R 0 0 0 0 0 0 0 0
W PDOn
Reset 0 0 0 0 0 0 0 0
Figure 3-15. General Purpose Data Output (GPDO) Registers 0–512 (SIU_GPDOn)
Name Description
PDOn Pin data out. Stores the data to drive out the external GPIO. If the register is read,
it returns the value written.
0 A logic 0 is driven on the external GPIO pin when the pin is configured as an
output.
1 A logic 1 is driven on the external GPIO pin when the pin is configured as an
output.
0 1 2 3 4 5 6 7
R 0 0 0 0 0 0 0 PDIn
Reset 0 0 0 0 0 0 0 0
Figure 3-16. General Purpose Data Input (GPDI) Registers 0–255 (SIU_GPDIn)
Name Description
PDIn Pin data in. This bit reflects the input state on the external GPIO pin for the register.
If PCRn[IBE] = 1, then:
0 Signal on pin is a logic 0.
1 Signal on pin is a logic 1.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R
ESEL15 ESEL14 ESEL13 ESEL12 ESEL11 ESEL10 ESEL9 ESEL8
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R
ESEL7 ESEL6 ESEL5 ESEL4 ESEL3 ESEL2 ESEL1 ESEL0
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
The following table describes the external IRQ input select fields:
Table 3-25. SIU_EIISR Bit Field Descriptions
0–1 ESEL15 External IRQ input select 15. Specifies the input for IRQ[15].
[0:1] 00 IRQ[15]
01 PCSB[15]
10 PCSC[0]
11 PCSD[1] serialized input (ETPUA[20])
2–3 ESEL14 External IRQ input select 14. Specifies the input for IRQ[14].
[0:1] 00 IRQ[14]
01 PCSB[14]
10 PCSC[15]
11 PCSD[0] serialized input (ETPUA[21])
4–5 ESEL13 External IRQ input select 13. Specifies the input for IRQ[13].
[0:1] 00 IRQ[13]
01 PCSB[13]
10 PCSC[14]
11 PCSD[15] serialized input (ETPUA[24])
6–7 ESEL12 External IRQ input select 12. Specifies the input for IRQ[12].
[0:1] 00 IRQ[12] pin
01 PCSB[12]
10 PCSC[13]
11 PCSD[14] serialized input (ETPUA[25])
8–9 ESEL11 External IRQ input select 11. Specifies the input for IRQ[11].
[0:1] 00 IRQ[11]
01 PCSB[11]
10 PCSC[12]
11 PCSD[13] serialized input (ETPUA[26])
10–11 ESEL10 External IRQ input select 10. Specifies the input for IRQ10].
[0:1] 00 IRQ[10]
01 PCSB[10]
10 PCSC[11]
11 PCSD[12] serialized input (ETPUA[27])
12–13 ESEL9 External IRQ input select 9. Specifies the input for IRQ[9].
[0:1] 00 IRQ[9]
01 PCSB[9]
10 PCSC[10]
11 PCSD[11] serialized input (ETPUA[28])
14–15 ESEL8 External IRQ input select 8. Specifies the input for IRQ[8].
[0:1] 00 IRQ[8]
01 PCSB[8]
10 PCSC[9]
11 PCSD[10] serialized input (ETPUA[29])
16–17 ESEL7 External IRQ input select 7. Specifies the input for IRQ[7].
[0:1] 00 IRQ[7]
01 PCSB[7]
10 PCSC[8]
11 PCSD[9] serialized input (EMIOS[12])
20–21 ESEL5 External IRQ input select 5. Specifies the input for IRQ[5].
[0:1] 00 IRQ[5]
01 PCSB[5]
10 PCSC[6]
11 PCSD[7] serialized input (EMIOS[10])
22–23 ESEL4 External IRQ input select 4. Specifies the input for IRQ[4].
[0:1] 00 IRQ[4]
01 PCSB[4]
10 PCSC[5]
11 PCSD[6] serialized input (EMIOS[11])
24–25 ESEL3 External IRQ input select 3. Specifies the input for IRQ[3].
[0:1] 00 IRQ[3]
01 PCSB[3]
10 PCSC[4]
11 PCSD[5] serialized input (ETPUA[16])
26–27 ESEL2 External IRQ input select 2. Specifies the input for IRQ[2].
[0:1] 00 IRQ[2]
01 PCSB[2]
10 PCSC[3]
11 PCSD[4] serialized input (ETPUA[17])
28–29 ESEL1 External IRQ input select 1. Specifies the input for IRQ[1].
[0:1] 00 IRQ[1]
01 PCSB[1] input (EMIOS[10])
10 PCSC[2]
11 EMIOS[15]
30–31 ESEL0 External IRQ input select 0. Specifies the input for IRQ[0].
[0:1] 00 IRQ[0]
01 PCSB[0] input (EMIOS[11])
10 PCSC[1]
11 EMIOS[14]
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R
SINSELA SSSELA SCKSELA TRIGSELA SINSELB SSSELB SCKSELB TRIGSELB
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R
SINSELC SSSELC SCKSELC TRIGSELC SINSELD SSSELD SCKSELD TRIGSELD
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0–1 SINSELA DSPI A data input select. Specifies the source of the DSPI A data input.
[0:1] 00 SINA_PCSC[2]_GPIO[94] pin
01 SOUTB
10 SOUTC
11 SOUTD
2–3 SSSELA DSPI A slave select input select. Specifies the source of the DSPI A slave select
[0:1] input.
00 PCSA[0]_PCSD[2]_GPIO[96] pin
01 PCSB[0] (master)
10 PCSC[0] (master)
11 PCSD[0] (master)
4–5 SCKSELA DSPI A clock input select. Specifies the source of the DSPI A clock input.
[0:1] 00 SCKA_PCSC[1]_GPIO[93] pin
01 SCKB (master)
10 SCKC (master)
11 SCKD (master)
6–7 TRIGSELA DSPI A trigger input select. Specifies the source of the DSPI A trigger input.
[0:1] 00 No Trigger
01 PCSB[4]
10 PCSC[4]
11 PCSD[4]
8–9 SINSELB DSPI B data input select. Specifies the source of DSPI B data input.
[0:1] 00 SINB_GPIO[103] pin
01 SOUTA
10 SOUTC
11 SOUTD
10–11 SSSELB DSPI B slave select input select. Specifies the source of the DSPI B slave select
[0:1] input.
00 PCSB[0]_PCSD[2]_GPIO[105] pin
01 PCSA[0] (master)
10 PCSC[0] (master)
11 PCSD[0] (master)
12–13 SCKSELB DSPI B clock input select. Specifies the source of the DSPI B clock input.
[0:1] 00 SCKB_GPIO[102] pin
01 SCKA (master)
10 SCKC (master)
11 SCKD (master)
14–15 TRIGSELB DSPI B trigger input select. Specifies the source of the DSPI B trigger input for
[0:1] master or slave mode.
00 Invalid value
01 PCSA[4]
10 PCSC[4]
11 PCSD[4]
16–17 SINSELC DSPI C data input select. Specifies the source of the DSPI C data input.
[0:1] 00 PCSB[3]_SINC_GPIO[108] pin
01 SOUTA
10 SOUTB
11 SOUTD
18–19 SSSELC DSPI C slave select input select. Specifies the source of the DSPI C slave select
[0:1] input.
00 PCSB[5]_PCSC[0]_GPIO[110] pin
01 PCSA[0] (master)
10 PCSB[0] (master)
11 PCSD[0] (master)
20–21 SCKSELC DSPI C clock input select. Specifies the source of the DSPI C clock input when in
[0:1] slave mode.
00 PCSB[4]_SCKC_GPIO[109] pin
01 SCKA (master)
10 SCKB (master)
11 SCKD (master)
22–23 TRIGSELC DSPI C trigger input select. Specifies the source of the DSPI C trigger input for
[0:1] master or slave mode.
00 Invalid value
01 PCSA[4]
10 PCSB[4]
11 PCSD[4]
24–25 SINSELD DSPI D data input select. Specifies the source of the DSPI D data input.
[0:1] 00 PCSA[3]_GPIO[99] pin
01 SOUTA
10 SOUTB
11 SOUTC
26–27 SSSELD DSPI D slave select input select. Specifies the source of the DSPI D slave select
[0:1] input.
00 PCSB[1]_PCSD[0]_GPIO[106] pin
01 PCSA0 (master)
10 PCSB0 (master)
11 PCSC0 (master)
28–29 SCKSELD DSPI D clock input select. Specifies the source of the DSPI D clock input in slave
[0:1] mode.
00 PCSA[2]_SCKD_GPIO[98] pin
01 Invalid value
10 SCKB (master)
11 SCKC (master)
30–31 TRIGSELD DSPI D trigger input select. Specifies the source of the DSPI D trigger input for
[0:1] master or slave mode.
00 Invalid value
01 PCSA4
10 PCSB4
11 PCSC4
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0
cTSEL5_0 cTSEL4_0
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R 0 0
cTSEL3_0 cTSEL2_0
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
SIU_ISEL5: eTRIG_A[1:0]
Address: SIU_BASE + 0x0914 Access: Read / write
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0
cTSEL1_0 cTSEL0_0
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
SIU_ISEL6: eTRIG_B[5:2]
Address: SIU_BASE + 0x0918 Access: Read / write
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0
cTSEL5_1 cTSEL4_1
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R 0 0
cTSEL3_1 cTSEL2_1
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
SIU_ISEL7: eTRIG_B[1:0]
Address: SIU_BASE + 0x091C Access: Read / write
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0
cTSEL1_1 cTSEL0_1
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
eQADC_A Trigger
cTSEL0_0
Inputs
eQADC_A Trigger
cTSEL1_0
Inputs
eQADC_A Trigger
cTSEL2_0
Inputs
eQADC_A Trigger
cTSEL3_0
Inputs
eQADC_A Trigger
cTSEL4_0
Inputs
eQADC_A Trigger
cTSEL5_0
Inputs
eQADC_B Trigger
cTSEL0_1
Inputs
eQADC_B Trigger
cTSEL1_1
Inputs
eQADC_B Trigger
cTSEL2_1
Inputs
eQADC_B Trigger
cTSEL3_1
Inputs
eQADC_B Trigger
cTSEL4_1
Inputs
eQADC_B Trigger
cTSEL5_1
Inputs
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 0 0 0 0 0 0 0 0 0 eTPU 0 0 0 eTPU
W A29 A28
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
eTPUA29 input select. Specifies the source of the eTPUA29 channel input.
11 eTPUA29 0 DSPI_B Serialized input 8
1 eTPUA29 channel input pad
eTPUA28 input select. Specifies the source of the eTPUA28 channel input.
15 eTPUA28 0 DSPI_B Serialized input 9
1 eTPUA28 channel input pad
eTPUA27 input select. Specifies the source of the eTPUA27 channel input.
19 eTPUA27 0 DSPI_B Serialized input 10
1 eTPUA27 channel input pad
eTPUA26 input select. Specifies the source of the eTPUA26 channel input.
23 eTPUA26 0 DSPI_B Serialized input 11
1 eTPUA26 channel input pad
eTPUA25 input select. Specifies the source of the eTPUA25 channel input.
27 eTPUA25 0 DSPI_B Serialized input 12
1 eTPUA25 channel input pad
eTPUA24 input select. Specifies the source of the eTPUA24 channel input.
31 eTPUA24 0 DSPI_B Serialized input 13
1 eTPUA24 channel input pad
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 0 0 0 0 0 0 0 0 0
eTSEL0ADV_A
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R 0 0 0 0 0 0 0 0 0 0 0
eTSEL0ADV_B
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
This register selects the source of the control signals for the integrators of decimation filters A to D. Each
ZSELx field of this register may be programmed to route a single eTPU channel simultaneously to the
Zero, Integrate and Read control inputs of one integrator. Each HSELx field may be programmed to route
a single eTPU channel to the Halt control input of one integrator. Refer to Table 3-42 for details of the
source selection codes. See Chapter 14, “Decimation Filter,” for details on the Zero, Integrate, Read and
Halt control configuration and functionality.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R
HSELD ZSELD HSELC ZSELC
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R
HSELB ZSELB HSELA ZSELA
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R
HSELH ZSELH HSELG ZSELG
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R
HSELF ZSELF HSELE ZSELE
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R
HSELL ZSELL HSELK ZSELK
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R
HSELJ ZSELJ HSELI ZSELI
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R
TRIG_SRCH TRIG_SRCG TRIG_SRCF TRIG_SRCE
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R
TRIG_SRCD TRIG_SRCC TRIG_SRCB TRIG_SRCA
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 3-23. Decimation Filter A - H Triggered Output Source Select Register (SIU_DECFIL4)
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R
TRIG_SRCL TRIG_SRCK TRIG_SRCJ TRIG_SRCI
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 3-24. Decimation Filter I - LTriggered Output Source Select Register (SIU_DECFIL5)
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 0 0 0 0 0 0 0 0 0 0 0 0 MATCH DISNEX
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 X1
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
TEST
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
1
When system RESET negates, the value in this bit depends on the censorship control word and the boot
configuration bits.
0–13 — Reserved
14 MATCH Compare register match. Holds the value of the match input signal to the SIU. The
match input is asserted if the values in SIU_CBRH and SIU_CBRL are the same as
the public password stored in flash, 0xFEED_FACE_CAFE_BEEF. The MATCH bit is
reset by the internal reset condition.
0 Match input signal is negated
1 Match input signal is asserted
15 DISNEX Disable Nexus. Holds the value of the Nexus disable input signal to the SIU. When
system reset negates, the value in this bit depends on the censorship control word and
the boot configuration bits.
0 Nexus disable input signal is negated.
1 Nexus disable input signal is asserted.
16–30 — Reserved
31 TEST Test mode enable. Allows reads or writes to undocumented registers used only for
production tests. Since these production test registers are undocumented, estimating
the impact of errant accesses to them is impossible. Do not change this bit from its
negated state at reset.
0 Undocumented production test registers cannot be read or written.
1 Undocumented production test registers can be read or written.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R 0 0 0 0
ENGDIV ECSS EBTS EBDF
W
Reset 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 1
0–15 — Reserved
16–23 ENGDIV Engineering clock division factor. Specifies the frequency ratio between fperiph (also
[0:7] referred to as fplatf on this device) and ENGCLK. The ENGCLK frequency is divided from
fplatf according to the following equation:
f periph
Engineering clock frequency = -------------------------------
-
ENGDIV 2
Setting ENGDIV to 0 makes the ENGCLK frequency equal to the fperiph clock frequency.
Note: Maximum ENGCLK frequency is limited by the pad performance. Refer to the
Electrical Specifications in the Data Sheet document for this device. Synchronization
between ENGCLK and D_CLKOUT cannot be guaranteed when ENGDIV is 0.
28 EBTS External bus tap select. Changes the phase relationship between the system clock and
D_CLKOUT. Changing the phase relationship so that D_CLKOUT is advanced in relation
to the system clock increases the output hold time of the external bus signals to a non-zero
value. It also increases the output delay times, increases the input hold times to non-zero
values, and decreases the input setup times. Refer to the Electrical Specifications for how
the EBTS bit affects the external bus timing.
0 External bus signals have zero output hold times.
1 External bus signals have non-zero output hold times.
Note: Do not change EBTS while an external bus transaction is in process.
29 — Reserved
30–31 EBDF External bus division factor. Specifies the frequency ratio between the system clock and
[0:1] the external clock, D_CLKOUT. Do not change EBDF during an external bus access or
while an access is pending. The D_CLKOUT frequency is divided from the system clock
frequency according to the descriptions below. When operating in full mode (1:1), set the
divider to 0b01 (divide-by-2).
00 Divide by 1
01 Divide by 2
10 Divide by 3
11 Divide by 4
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R
CMPBH
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R
CMPBH
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R
CMPBL
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R
CMPBL
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
SIU_BASE+0x9A0
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R
LCK
W
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R SYS- BY- SYS-
IPCLKDIV
W CLKSEL PASS CLKDIV
RESET: 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0
= Unimplemented or Reserved
Figure 3-30. System Clock Register (SIU_SYSDIV)
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R
HLT
W
RESET 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 3-32. Halt Register (SIU_HLT)
Field Description
0-31 Halt Selects
HLT The HLT bits halt specific modules. Each bit corresponds to a separate module as
mapped below:
0 Core 01
1 Core 11
2 rsvd
3 rsvd
4 eTPU_C
5 eTPU_A, eTPU_B
6 NPC
7 EBI
8 eQADCs: eQADC_A and eQADC_B
9 rsvd
10 eMIOS_A
11 DECFILT (decimation filters)
12 rsvd
13 PIT
14 rsvd
15 rsvd
16FlexCAN_D
17 FlexCAN_C
18 FlexCAN_B
19 FlexCAN_A
20 DSPI_D
21 DSPI_C
22 DSPI_B
23 DSPI_A
24 DSPI_E
25 rsvd
26 rsvd
27 rsvd
28 rsvd
29 eSCI_C
30 eSCI_B
31 eSCI_A
1
Stops the core clocks but only after the core executes a WAIT instruction. The interrupt
controller and SWT0 and SWT1 clocks are never stopped.
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R HLTACK
W
RESET 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 3-33. Halt Acknowledge Register (SIU_HLTACK)
Field Description
HLTACK Halt Acknowledge
The HLTACK bits acknowledge halt for specific modules. Each bit corresponds to a
separate module as mapped below:
0 Core 0
1 Core 1
2 rsvd
3 rsvd
4 eTPU_C
5 eTPU_A, eTPU_B
6 NPC
7 EBI
8 eQADCs: eQADC_A and eQADC_B
9 rsvd
10 eMIOS_A
11 DECFILT (decimation filters)
12 rsvd
13 PIT
14 rsvd
15 rsvd
16 FlexCAN_D
17 FlexCAN_C
18FlexCAN_B
19 FlexCAN_A
20 DSPI_D
21 DSPI_C
22 DSPI_B
23 DSPI_A
24 DSPI_E
25 rsvd
26 rsvd
27 rsvd
28 rsvd
29 eSCI_C
30 eSCI_B
31 eSCI_A
RST
W RSTVEC L
E
Reset 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 0 0
Figure 3-34. Reset Vector Register for Core 0 (SIU_RSTVEC0)
Field Description
0-29 Core 0 Reset Vector. The RSTVEC value determines the initial program counter for core 0 upon exiting reset.
RSTVEC On POR, the value contained in the register defaults to 0xFFFF_FFFC, so that core 0 fetches BookE code
from the BAM starting at address 0xFFFF_FFFC. User code may change this value to select a different fetch
address on exit from a user initiated reset of this core.
Core 1 MMU TLB entry 0 effective and real page number (EPN/RPN) is automatically loaded with
RSTVEC[0:21] when reset is released and the TLB entry size is set to 4KB. In the e200z759 Core Reference
Manual the reset vector is referred to as “p_rstbase[0-21]”.
30 Controls the assertion of RESET to core 0. Writing 1 to this bit causes core 0 to enter reset, provided core 0
RST halt bit is also set. Reads of this bit indicate whether the core is being held in reset.
0 core 0 not in reset
1 core 0 reset requested
31 VLE Select. The VLE bit selects whether the core executes VLE or Book E code at the reset vector address.
VLE 0 Book E
1 VLE
RST
W RSTVEC L
E
Reset 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 0
Figure 3-35. Reset Vector Register for Core 1 (SIU_RSTVEC1)
Field Description
0-29 Core 1 Reset Vector. The RSTVEC value determines the initial program counter for core 1 upon exiting reset.
RSTVEC On POR, the value contained in the register defaults to 0xFFFF_FFFC, so that core 1 fetches BookE code
from the BAM starting at address 0xFFFF_FFFC. User code may change this value to select a different fetch
address on exit from a user initiated reset of this core.
Core 1 MMU TLB entry 0 effective and real page number (EPN/RPN) is automatically loaded with
RSTVEC[0:21] when reset is released and the TLB entry size is set to 4KB. In the e200z759 Core Reference
Manual the reset vector is referred to as “p_rstbase[0-21]”.
30 Controls the assertion of RESET to core1. Writing 1 to this bit causes core1 to enter reset, provided core1
RST halt bit is also set. Reads of this bit indicate if the core is being held in reset.
0 core 1 not in reset
1 core 1 reset requested
31 VLE Select. The VLE bit selects whether the core executes VLE or Book E code at the reset vector address.
VLE 0 Book E
1 VLE
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
EXT_PID_SYNC
R
EXT_PID_EN
EXT_PID6
EXT_PID7
Reserved
Reset 0 0 - - - - - - - - - - - - - - - - - - - - - - - - - - - - 0 0
Field Description
2-29 Must be written with 0s for future compatibility. Writes have no effect.
Reserved
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
EXT_PID_SYNC
R
EXT_PID_EN
EXT_PID6
EXT_PID7
Reserved
Reset 0 0 - - - - - - - - - - - - - - - - - - - - - - - - - - - - 0 0
Field Description
2-29 Must be written with 0s for future compatibility. Writes have no effect.
Reserved
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R PGPDO PGPDO PGPDO PGPDO PGPDO PGPDO PGPDO PGPDO PGPDO PGPDO PGPDO PGPDO PGPDO PGPDO PGPDO PGPDO
W 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 3-38. Parallel GPIO Pin Data Output Register (SIU_PGPDO0 - SIU_PGPDO15)
Field Description
PGPDOx Pin Data Out. Stores the data to be driven out on the external GPIO pin controlled by this register.
0 Logic low value is driven on the data out signal for the corresponding GPOI pin when the pin is configured
as an output.
1 Logic high value is driven on the data out signal for the corresponding GPOI pin when the pin is
configured as an output.
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R PGPDI PGPDI PGPDI PGPDI PGPDI PGPDI PGPDI PGPDI PGPDI PGPDI PGPDI PGPDI PGPDI PGPDI PGPDI PGPDI
W 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 3-39. Parallel GPIO Pin Data Input Register (SIU_PGPDI0 - SIU_PGPDI15)
Field Description
PGPDIx Pin Data In. Stores the value of the pad-interface signals (data in) corresponding to the external GPIO pin
associated with the register.
0 The value of the pad-interface signals (data in) for the corresponding GPIO pin is logic low.
1 The value of the pad-interface signals (data in) for the corresponding GPIO pin is logic high.
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R DAT DAT DAT DAT DAT DAT DAT DAT DAT DAT DAT DAT DAT DAT DAT DAT
A A A A A A A A A A A A A A A A
W
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 3-40. Masked Parallel GPIO Pin Data Output Register (SIU_MPGPDO0 - SIU_MPGPDO31)
Field Description
MASKx Pin Data Out. Controls the write access to the corresponding GPDO.
0 Previous value defined by GPDO is maintain.
1 Corresponding GPDO is written with value defined by DATA field.
DATAx Pin Data Out. Stores the data to be driven out on the external GPIO pin controlled by this register.
0 Logic low value is driven on the pad interface data out signal for the corresponding GPIO pin when the
pin is configured as an output.
1 Logic high value is driven on the pad interface data out signal for the corresponding GPIO pin when the
pin is configured as an output.
eTPUB
0
1
2
3
4
15
30
31
eMIOS
0
1
2
3
4
15
30
31
Enable
SIU_DSPIAL[MASK17]
Serial
SIU_DSPIAL[DATA17]
GPO A
Function
&
Channel
Selection
Address Use
SIU_BASE + 0x0D00 -SIU_BASE + 0x0D03 DSPIA GP Mask-Output High Register
SIU_BASE + 0x0D04 -SIU_BASE + 0x0D07 DSPIA GP Mask-Output Low Register
SIU_BASE + 0x0D08 -SIU_BASE + 0x0D0B DSPIB GP Mask-Output High Register
SIU_BASE + 0x0D0C -SIU_BASE + 0x0D0F DSPIB GP Mask-Output Low Register
SIU_BASE + 0x0D10 -SIU_BASE + 0x0D13 DSPIC GP Mask-Output High Register
SIU_BASE + 0x0D14 -SIU_BASE + 0x0D17 DSPIC GP Mask-Output Low Register
SIU_BASE + 0x0D18 -SIU_BASE + 0x0D1B DSPID GP Mask-Output High Register
SIU_BASE + 0x0D1C -SIU_BASE + 0x0D1F DSPID GP Mask-Output Low Register
SIU_BASE + 0x0D20 -SIU_BASE + 0x0D3F Reserved
SIU_BASE + 0x0D40 -SIU_BASE + 0x0D43 DSPIA eTPUB Select Register
SIU_BASE + 0x0D44 -SIU_BASE + 0x0D47 DSPIA eMIOS Select Register
SIU_BASE + 0x0D48 -SIU_BASE + 0x0D4B DSPIA GPO Select Register
SIU_BASE + 0x0D4C -SIU_BASE + 0x0D4F Reserved
SIU_BASE + 0x0D50 -SIU_BASE + 0x0D53 DSPIB eTPUA Select Register
SIU_BASE + 0x0D54 -SIU_BASE + 0x0D57 DSPIB eMIOS Select Register
SIU_BASE + 0x0D58 -SIU_BASE + 0x0D5B DSPIB GPO Select Register
SIU_BASE + 0x0D5C -SIU_BASE + 0x0D5F Reserved
SIU_BASE + 0x0D60 -SIU_BASE + 0x0D63 DSPIC eTPUA Select Register
SIU_BASE + 0x0D64 -SIU_BASE + 0x0D67 DSPIC eMIOS Select Register
SIU_BASE + 0x0D68 -SIU_BASE + 0x0D6B DSPIC GPO Select Register
SIU_BASE + 0x0D6C -SIU_BASE + 0x0D6F Reserved
SIU_BASE + 0x0D70 -SIU_BASE + 0x0D73 DSPID eTPUB Select Register
SIU_BASE + 0x0D74 -SIU_BASE + 0x0D77 DSPID eMIOS Select Register
SIU_BASE + 0x0D78 -SIU_BASE + 0x0D7B DSPID GPO Select Register
SIU_BASE + 0x0D7C -SIU_BASE + 0x0D7F Reserved
SIU_BASE + 0x0D80 -SIU_BASE + 0x0DC0 Reserved
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R DAT DAT DAT DAT DAT DAT DAT DAT DAT DAT DAT DAT DAT DAT DAT DAT
A A A A A A A A A A A A A A A A
W
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 3-41. Masked Serial GPO Register for DSPI - DSPI_A/B/C/D GPO Mask Output High Register
(SIU_DSPIAH/SIU_DSPIBH/SIU_DSPICH/SIU_DSPIDH)
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R DAT DAT DAT DAT DAT DAT DAT DAT DAT DAT DAT DAT DAT DAT DAT DAT
A A A A A A A A A A A A A A A A
W
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 3-42. Masked Serial GPO Register for DSPI - DSPI_A/B/C/D GPO Mask Output Low Register
(SIU_DSPIAL/SIU_DSPIBL/SIU_DSPICL/SIU_DSPIDL)
Field Description
MASKx Pin Data Out. Controls the write access to the corresponding GPO for DSPI.
0 Previous value defined by GPDO is maintain.
1 Corresponding GPO is written with value defined by DATA field.
DATAx Pin Data Out. Stores the data to be driven out on the external GPIO pin controlled by this register.
0 Logic low value is driven on the pad interface data out signal for the corresponding GPO for DSPI when
this output is selected in the DSPI serialization module.
1 Logic high value is driven on the pad interface data out signal for the corresponding GPO for DSPI when
this output is selected in the DSPI serialization module.
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R ETPUB ETPUB ETPUB ETPUB ETPUB ETPUB ETPUB ETPUB ETPUB ETPUB ETPUB ETPUB ETPUB ETPUB ETPUB ETPUB
W 31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 3-43. eTPU_B Select Register for DSPI_A (SIU_ETPUBA)
Field Description
ETPUBx ETPUB channel select
0 This bit in the DSPI_A serialized output frame will not use the respective ETPUB channel
1 This bit in the DSPI_A serialized output frame will use the respective ETPUB channel
SIU_BASE + 0xD44
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS
W 7 6 5 4 3 2 1 0 8 9 10 11 12 13 14 15
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS
W 16 17 18 19 20 21 22 23 0 1 2 3 4 5 6 7
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 3-44. eMIOS Select Register for DSPI_A (SIU_EMIOSA)
Field Description
EMIOSx EMIOS channel select
0 This bit in the DSPI_A serialized output frame will not use the respective EMIOS channel
1 This bit in the DSPI_A serialized output frame will use the respective EMIOS channel
SIU_BASE + 0xD48
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R DSPI DSPI DSPI DSPI DSPI DSPI DSPI DSPI DSPI DSPI DSPI DSPI DSPI DSPI DSPI DSPI
AH AH AH AH AH AH AH AH AH AH AH AH AH AH AH AH
W 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R DSPI DSPI DSPI DSPI DSPI DSPI DSPI DSPI DSPI DSPI DSPI DSPI DSPI DSPI DSPI DSPI
AL AL AL AL AL AL AL AL AL AL AL AL AL AL AL AL
W 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 3-45. SIU_DSPIAH/L Select Register for DSPI_A (SIU_DSPIAHLA)
Field Description
DSPIAH/Lx DSPI_A Data Register bit
0 The corresponding serial GPO A output (from the SIU_DSPIAH/L register) is disabled
1 The corresponding serial GPO A output (from the SIU_DSPIAH/L register) is enabled
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R ETPUA ETPUA ETPUA ETPUA ETPUA ETPUA ETPUA ETPUA ETPUA ETPUA ETPUA ETPUA ETPUA ETPUA ETPUA ETPUA
W 12 13 14 15 0 1 2 3 4 5 6 7 8 9 10 11
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 3-46. eTPU_A Select Register for DSPI_B (SIU_ETPUAB)
Field Description
ETPUAx ETPUA channel select
0 This bit in the DSPI_B serialized output frame will not use the respective ETPUA channel
1 This bit in the DSPI_B serialized output frame will use the respective ETPUA channel
SIU_BASE + 0xD54
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS
W 11 10 9 8 6 5 4 3 2 1 0 23 15 14 13 12
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS
W 23 15 14 13 12 11 10 9 8 6 5 4 3 2 1 0
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 3-47. eMIOS Select Register for DSPI_B (SIU_EMIOSB)
Field Description
EMIOSx EMIOS channel select
0 This bit in the DSPI_B serialized output frame will not use the respective EMIOS channel
1 This bit in the DSPI_B serialized output frame will use the respective EMIOS channel
SIU_BASE + 0xD58
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R DSPI DSPI DSPI DSPI DSPI DSPI DSPI DSPI DSPI DSPI DSPI DSPI DSPI DSPI DSPI DSPI
BH BH BH BH BH BH BH BH BH BH BH BH BH BH BH BH
W 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R DSPI DSPI DSPI DSPI DSPI DSPI DSPI DSPI DSPI DSPI DSPI DSPI DSPI DSPI DSPI DSPI
BL BL BL BL BL BL BL BL BL BL BL BL BL BL BL BL
W 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 3-48. SIU_DSPIBH/L Select Register for DSPI_B (SIU_DSPIBHLB)
Field Description
DSPIBH/Lx DSPI_B Data Register bit
0 The corresponding serial GPO B output (from the SIU_DSPIBH/L register) is disabled
1 The corresponding serial GPO B output (from the SIU_DSPIBH/L register) is enabled
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R ETPUA ETPUA ETPUA ETPUA ETPUA ETPUA ETPUA ETPUA ETPUA ETPUA ETPUA ETPUA ETPUA ETPUA ETPUA ETPUA
W 23 22 21 20 19 18 17 16 29 28 27 26 25 24 31 30
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 3-49. eTPU_A Select Register for DSPI_C (SIU_ETPUAC)
Field Description
ETPUAx ETPUA channel select
0 This bit in the DSPI_C serialized output frame will not use the respective ETPUA channel
1 This bit in the DSPI_C serialized output frame will use the respective ETPUA channel
SIU_BASE + 0xD64
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS
W 12 13 14 15 23 0 1 2 3 4 5 6 8 9 10 11
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS EMIOS
W 23 22 21 20 19 18 17 16 29 28 27 26 25 24 31 30
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 3-50. eMIOS Select Register for DSPI_C (SIU_EMIOSC)
Field Description
EMIOSx EMIOS channel select
0 This bit in the DSPI_C serialized output frame will not use the respective EMIOS channel
1 This bit in the DSPI_C serialized output frame will use the respective EMIOS channel
SIU_BASE + 0xD68
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R DSPI DSPI DSPI DSPI DSPI DSPI DSPI DSPI DSPI DSPI DSPI DSPI DSPI DSPI DSPI DSPI
CH CH CH CH CH CH CH CH CH CH CH CH CH CH CH CH
W 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R DSPI DSPI DSPI DSPI DSPI DSPI DSPI DSPI DSPI DSPI DSPI DSPI DSPI DSPI DSPI DSPI
CL CL CL CL CL CL CL CL CL CL CL CL CL CL CL CL
W 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 3-51. SIU_DSPICH/L Select Register for DSPI_C (SIU_DSPICHLC)
Field Description
DSPICH/Lx DSPI_C Data Register bit
0 The corresponding serial GPO C output (from the SIU_DSPICH/L register) is disabled
1 The corresponding serial GPO C output (from the SIU_DSPICH/L register) is enabled
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
W
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 3-52. eTPU_B Select Register for DSPI_D (SIU_ETPUBD)
Field Description
ETPUBx ETPUB channel select
0 This bit in the DSPI_D serialized output frame will not use the respective ETPUB channel
1 This bit in the DSPI_D serialized output frame will use the respective ETPUB channel
SIU_BASE + 0xD74
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 0 0 0 0 EMIOS EMIOS EMIOS EMIOS 0 0 0 0 0 0
W 11 10 13 12
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
W
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 3-53. eMIOS Select Register for DSPI_D (SIU_EMIOSD)
Field Description
EMIOSx EMIOS channel select
0 This bit in the DSPI_D serialized output frame will not use the respective EMIOS channel
1 This bit in the DSPI_D serialized output frame will use the respective EMIOS channel
SIU_BASE + 0xD78
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
W
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
W
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 3-54. DSPIDH/L Select Register for DSPI_D (SIU_DSPIDHLD)
Address Offset
Number
from SIU_BASE
0x0E00 - 0x0E4A Reserved
0x0E4B - 0x0E6E GPIO Pin Data Input Registers 75 - 110
0x0E6F - 0x0E70 Reserved
0x0E71 - 0x0ECC GPIO Pin Data Input Registers 113- 204
The GPDIx_x registers are read-only registers that allow reading of the input state of an external GPIO pin.
Each byte of a register represents the input state of a single external GPIO pin. The first 256 GPDIx_x
registers corresponds to the same GPDI inputs described in Section 3.2.1.15, “GPIO Pin Data Input
Registers 0–255 (SIU_GPDIn)”.
SIU_BASE+0x0E00
0 1 2 3 4 5 6 7
R 0 0 0 0 0 0 0
PDI0
W
RESET: 0 0 0 0 0 0 0 U
Figure 3-55. GPIO Pin Data In Register 0 (SIU_GPDI0)
SIU_BASE+0xFFC
0 1 2 3 4 5 6 7
R 0 0 0 0 0 0 0 PDI
W 511
RESET: 0 0 0 0 0 0 0 U
Figure 3-56. GPIO Pin Data In Register 511 (SIU_GPDI511)
Field Description
PDIx This bit reflects the input state on the external GPIO pin for the register. If PCRn[IBE] = 1, then:
0 Signal on pin is a logic 0
1 Signal on pin is a logic 1
3.3 SIU_B
SIU_B contains a set of mirrored PCR configuration, GPO and GPI data registers for GPIO[240:243]
balls. By default after reset, the mirrored registers are disabled and provide no function. The disabled
state is indicated by PA[2:0] = 0b111 in the mirrored PCR register, as shown in Table 3-74. When a mir-
rored PCR is enabled by writing a different value to its PA[2:0], it has priority over the equivalent
“non-mirrored” register, and controls the ball function and characteristics defined by the implemented bit
fields of the mirrored PCR, and the mirrored GPO (Table 3-75) and GPI (Table 3-76) data registers con-
trol and reflect the logic level. When the mirrored registers are enabled, writes to the non mirrored regis-
ters have no effect.
PCR240M 0x220 1 1 1 0 0 - - 0 0 0 0 1 1
PCR241M 0x222 1 1 1 0 0 - - 0 0 0 0 1 1
PCR242M 0x224 1 1 1 0 0 - - 0 0 0 0 1 1
PCR243M 0x226 1 1 1 0 0 - - 0 0 0 0 1 1
• IRQ flag bit is set in the external interrupt status register (SIU_EISR)
• Enable bit is cleared in the DMA/Interrupt request enable register (SIU_DIRER)
• Select bit is cleared in the DMA/Interrupt select register (SIU_DIRSR)
The NMI pin function or platform SWT can generate either an NMI or a critical interrupt. When
WKPCFG_NMI_GPIO213 is enabled as NMI, the pin will override the PCR configuration after reset.
SIU_DIRER selects between critical and non maskable interrupt use, SIU_EISR reports status of NMI and
SIU_IFEER selects edge sensitivity of NMI input
Refer to the following sections for more information:
Section 3.2.1.5, “DMA/Interrupt Request Enable Register (SIU_DIRER)”
Section 3.2.1.6, “DMA/Interrupt Request Select Register (SIU_DIRSR)”
3.4.1.0.3 Overruns
An overrun IRQ exists for each overrun flag bit in the overrun status register (SIU_OSR).
An overrun IRQ asserts when all of the following occur:
• Enable bit is set in the IRQ rising- and/or falling-edge event registers (SIU_IREER, SIU_IFEER)
• IRQ flag bit is set in the external interrupt status register (SIU_EISR)
• Bit is set in the overrun request enable and overrun status registers (SIU_ORER, SIU_OSR)
• Rising- or falling-edge event triggers an interrupt request
The SIU outputs one overrun IRQ bit that is the logical OR of all of the IRQ overrun bits.
Refer to the following sections for more information:
Section 3.2.1.4, “External Interrupt Status Register (SIU_EISR)”
Section 3.2.1.7, “Overrun Status Register (SIU_OSR)”
Section 3.2.1.8, “Overrun Request Enable Register (SIU_ORER)”
DMA
request
SIU
SIU_EISR SIU_DISR DMA
0
DMA/
1 Interrupt
interrupt
EIRQ pins 2 request
select
or 3
internal IMUX
• • 4
source • •
• • • •
• •
• •
15 Interrupt
SIU_OSR • controller
•
0 Interrupt
1 • request
•
• •
• •
• • Overrun
15 request
SIU
An example of the multiplexing of an eQADC (EQADC_A) external trigger input is given below.
Extended trigger selection
SIU_ISEL5[cTSEL0_0[2:6]]
TXDC_ETRIG[0]_GPIO[244]
ETRIG[0]
ETPUA[30] output channel
EMIOS[10] output channel
SIU_ISEL5[cTSEL0_0[0:1]]
SIU_ISEL4-7 always provides one of four choices based on the most-significant two bits of each cTSEL
field. When those bits are 0b00, the extended trigger selection is chosen and the remaining bits in cTSEL
select among a longer list of trigger sources.
SOUTB
SCKA
SINA
SS SCK IN
Offset from
0:15 16:31
0xFFFE_C000
0x08
Reserved
0x0C
0x20 Reserved
0x24
0x28
0x2C
0x30
0x34
0x38
0x3C
Package Pins1
Clock Mode
PLLCFG[0] PLLCFG[1]
1 1 Reserved
1 The PLLCFG[2] pin configures the crystal oscillator range:
PLLCFG[2] = 0, for 8 MHz to 20 MHz
PLLCFG[2] = 1, for 40 MHz
After reset, the device system clock source is derived from an internal RC oscillator (IRC) that is trimmed
to a nominal 16MHz. The system clock operates at half the IRC nominal frequency. The PLL is not the
source of the system clock until user software selects the PLL output instead of the default IRC oscillator
by updating the SIU_SYSDIV[SYSCLKSEL] bits described in Section 3.2.1.29, or if the boot mode
automatically reverts to, or is user-configured for the FlexCAN/eSCI serial boot option listed in Table 5-1.
In serial boot mode, the Boot Assist Module (BAM) switches the system clock source to the PLL to
provide a stable baud rate. Refer to the BAM Chapter for detailed information on boot modes.
The Reset Status Register (SIU_RSR) gives the source or sources of the last reset and indicates whether a
glitch has occurred on the RESET pin. The SIU_RSR register is updated for all reset sources except JTAG
reset.
All reset sources initiate execution of the BAM program with the exception of the Software External Reset
and the JTAG reset. In internal or external boot mode, the BAM attempts to read from memory and decode
the contents of a user defined reset configuration half word (RCHW) which serves several basic functions:
• System reset (including watchdog reset) resets the entire chip, including both cores
• CPU0 exits reset, while CPU1 is still held in reset
• CPU0 utilizes BAM (to determine boot block or serial boot)
• CPU0 performs normal chip initialization. As part of this initialization, CPU0 writes to CPU1 reset
vector register
• CPU0 enables CPU1 & CPU1 watchdog
5.3.1 RESET
The RESET pin is an active low input. The RESET pin must be asserted by an external device during a
power-on or whenever an external reset is required. The internal reset signal asserts only if the RESET pin
asserts for 10 clock cycles. Assertion of the RESET pin while the reset state machine is already processing
a reset causes the reset cycle to start over. The RESET pin has a glitch detector which detects spikes greater
than 2 clocks in duration that fall below the switch point of its input buffer. The switch point lies between
the maximum VIL and minimum VIH specifications for the RESET pin. Figure 5-1 and Figure 5-2 show
logic flows of the reset state machine on assertion of RESET.
5.3.2 RSTOUT
The RSTOUT pin is an active low output that uses a push/pull configuration. The RSTOUT pin is driven
low by the MCU for all internal and external reset sources.
The RSTOUT pin is asserted for a number of clock cycles that depends on the reset source, as shown in
Table 5-3, plus 4 cycles for sampling of the configuration pins. The RSTOUT pin can also be asserted by
a write to the SER bit of the System Reset Control Register (SIU_SRCR); however no system reset occurs
under this circumstance. The duration of RSTOUT assertion caused by setting the SER bit depends on
whether the clock source is the IRC or not, as given in Table 5-3.
Table 5-3. Clock Cycles for Different Reset Sources
F
RESET
Asserted?
Wait 2
Clock Cycles
F
RESET
Asserted?
Set Latch,
Wait 8 Clock
Cycles
F
RESET
Set RGF Bit
Asserted?
Valid RESET
Assert Internal
Assert
Reset and
RSTOUT Start RSTOUT
Counter = 0
Apply
PLLCFG
WKPCFG
pins Valid
RESET T
or POR
Detected?
RESET
F
Negated? F
Increment Counter
T
F Counter
Counter = 0
= N* ?
T
Valid
Update Reset Status Register
RESET T
Negate RSTOUT
or POR Start
Detected?
Latch
BOOTCFG, PLLCFG, WKPCFG
F Values in registers
Increment Counter T
Update Reset Status Register
Counter = N* ?
Negate Internal Reset and RSTOUT
NOTES:
* The clock count is dependent on the clock and reset sources (refer to Section 5.3.2, “RSTOUT”).
Refer to Section 8.4.3.1, “PLL Lock Detection,” in the FMPLL chapter for more information on loss of
lock.
the RSTOUT clock cycles expire, and remains set until cleared by software or another reset besides the
Software External Reset occurs.
For a Software External Reset, the e200z7 core will continue to execute instructions, timers that are
enabled will continue to operate, and interrupt requests will continue to be processed. It is the
responsibility of the application to ensure devices connected to RSTOUT are not accessed during a
Software External Reset, and to determine how to manage MCU resources when using the Software
External Reset.
Table 5-4. RCHW Location for Internal and External Boot Modes
External 0x0000_0000
Internal 0x0002_0000
0x0003_0000
0x0000_0000
0x0000_4000
0x0001_0000
0x0001_C000
BOOT_BLOCK_ADDRESS + 0x0000_0000
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
SWT WTE PS0 VLE 0 1 0 1 1 0 1 0
Boot Identifier = 0x5A
The following table describes the fields in the reset configuration half word.
Table 5-5. RCHW Bit Field Descriptions
Field Description
0–3 Reserved. These bit values are ignored when the halfword is read. Program to 0 for future compatibility.
SWT Software watchdog timer enable. This bit determines if the software watchdog timer for core 0 is enabled after
passing control to the user application code.
0 Disable software watchdog timer
1 Software watchdog timer maintains its default state of enabled after reset. The timeout period is 392400
clock cycles of the IRC oscillator.
WTE Core 0 watchdog timer enable. This bit determines if the core watchdog timer is enabled.after passing control
to the user application code.
0 Disable core watchdog timer
1 Enable core watchdog timer after reset. The BAM programs the timeout period to 2.5*218 cycles of core 0
clock1.
PS0 Port size. Used for external memory boot modes only. Defines the data width of the external memory selected
by CAL_CS0. After reset, the BAM sets the 16-bit port size to support fetching the RCHW from either 16- or
32-bit external memories. Then the BAM reconfigures the port size, depending on this bit.
0 32-bit CAL_CS0 port size
1 16-bit CAL_CS0 port size
Note: Do not clear this bit if the device only has a 16-bit data bus.
Field Description
VLE VLE Code Indicator. This bit configures the MMU entries 1-3 coded as Classic Book E instructions or as VLE
instructions.
0 User code executes as classic Book E code
1 User code executes as Freescale VLE code
Refer to the BAM chapter for details of how the RCHW is used to configure the boot sequence of the
MPC5676R.
VDD
Pins start to
POR drive/sample when
POR negates
RESET
N1 clocks
Internal
Reset
(4 clock cycles)
RSTOUT
User drives
config pins relative
to RSTOUT
PLLCFG,
WKPCFG,
BOOTCFG, PLLCFG are ignored PLLCFG and WKPCFG BOOTCFG are
and WKPCFG is treated as ‘1’ are applied, but not latched. latched.
during POR assertion. BOOTCFG are ignored.
NOTE:
1. The clock count is dependent on the clock and reset sources (refer to Section 5.3.2, “RSTOUT”).
Chapter 6
Boot Assist Module (BAM)
6.1 Overview
The Boot Assist Module (BAM) is a 4-KB block of read-only memory, containing the boot program code
for the MCU. The BAM program supports the following boot modes:
• Boot from internal flash
• Serial boot via SCI or CAN interface with optional baud-rate detection
• Boot from a memory connected to the MCU development bus (EBI1) with multiplexed or separate
address and data lines
On a dual-core MCU like the MPC5676R only Core0 is enabled out of reset, therefore the BAM program
is executed by Core0 just after the MCU resets. Depending on the boot mode, the program initializes the
appropriate minimum MCU resources to start user application code.
6.2 Features
• Initial MCU core MMU setup with minimum address translation for all internal MCU resources
• MMU configuration to boot user application, compiled as Classic PowerPC Book E code or as
Freescale VLE code
• Passes control to user application code in the internal flash or external memory device
• Automatic switch to Serial Boot mode if internal or external flash is blank or invalid
• Serial boot by loading user program via CAN bus or eSCI to the internal SRAM
— User programmable 64 bit password protection
— Optional automatic detection of the host SCI or CAN speed
• Boot from an external memory device, connected to the EBI
— Option to boot from 16 bit memory device with separate data and address lines
— Option to boot from 32/16 bit memory device with multiplexed data and address lines
• Controls MCU core Watchdog Timer and/or the Software Watchdog Timer (SWT)
Address Description
0xFFFF_C000 – 0xFFFF_EFFF BAM program mirrored
0xFFFF_F000 – 0xFFFF_FFFF BAM program
0xFFFF_FFFC MCU reset vector
0xFFFF_FFF8 BAM last executed instruction
Reset
Config. MMU N N
BOOTCFG BOOTCFG
for internal
boot = 01 = 10
Y Y
Found N
RCHW? Check RCHW
N Found
Parse RCHW RCHW?
and execute
RCHW options
Y
The MMU regions are mapped with logical addresses the same as physical addresses except for the
external bus interface (EBI). The logical EBI address space is mapped to physical address space of the
internal flash memory. This allows code, written to run from external memory, to execute from internal
flash.
After the MMU configuration, the BAM program starts the boot sequence depending on the
SIU_RSR[BOOTCFG] value, as shown in Table 6-3.
Depending on the values stored in the censorship word and serial boot control word in the shadow row of
the internal flash memory, the internal flash memory can be enabled or disabled, the Nexus port can be
enabled or disabled, the password received in the serial boot mode is compared with the fixed public
password or compared to a user programmable password in the internal flash memory.
The censorship word is a 32 bit word of data stored in the shadow row of internal flash memory. This
memory location is read by hardware as part of the boot process and is used in conjunction with the
BOOTCFG pins to enable and disable the internal flash memory and the Nexus interface. The censorship
word consists of two fields: censorship control and serial boot control. The censorship word is
programmed during manufacturing to be 0x55AA_55AA. This results in a device that is not censored and
uses a flash-based password for serial boot mode.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
Binary value 0 1 0 1 0 1 0 1 1 0 1 0 1 0 1 0
Hex value 5 5 A A
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
Binary value 0 1 0 1 0 1 0 1 1 0 1 0 1 0 1 0
Hex value 5 5 A A
Serial boot control field–default value reads a password from internal flash.
The BAM program uses SIU_CCR[DISNEX], which reflects the Nexus module state, to determine if the
serial password received in serial boot mode should be compared to:
• Public password (0xFEED_FACE_CAFE_BEEF) if DISNEX is cleared
• Flash password (64-bit value, stored in the shadow block of internal flash at address
0x00FF_FDD8) if DISNEX is set
NOTE
Regardless of the boot mode used, program a valid serial password. This
allows you to rescue the device using serial boot mode if the flash content
is corrupted.
Flash Password@ 0x00FF_FDD8 – 0x00FF_FDDF
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
1 1 1 1 1 1 1 0 1 1 1 0 1 1 0 1
Serial Boot Password (0x00FF_FDD8) - 0xFEED (Factory Default)
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
1 1 1 1 1 0 1 0 1 1 0 0 1 1 1 0
Serial Boot Password (0x00FF_FDDA) - 0xFACE (Factory Default)
32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47
1 1 0 0 1 0 1 0 1 1 1 1 1 1 1 0
Serial Boot Password (0x00FF_FDDC) - 0xCAFE (Factory Default)
48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63
1 0 1 1 1 1 1 0 1 1 1 0 1 1 1 1
Serial Boot Password (0x00FF_FDDE) - 0xBEEF (Factory Default)
Figure 6-3. Serial Boot Flash Password
Field Description
0–3 Reserved. These bit values are ignored when the halfword is read. Program to 0 for future compatibility.
SWT Software watchdog timer enable. This bit determines if the software watchdog timer is enabled after passing
control to the user application code.
0 Disable software watchdog timer
1 Enable software watchdog timer after reset. The timeout period is 392400 cycles of the Internal RC
Oscillator.
WTE MCU core watchdog timer enable. This bit determines if the core software watchdog timer is enabled.after
passing control to the user application code.
0 Disable core software watchdog timer
1 Enable core watchdog timer after reset. The timeout period is 2.5*218 cycles of the CPU clock1.
PS0 Port size. Defines the width of the data bus connected to the memory on D_CS0. After system reset, the BAM
changes D_CS0 to a 16-bit port to fetch the RCHW from either 16- or 32-bit external memories. Then the BAM
reconfigures the EBI as a 16- or 32-bit port, depending on this bit.
0 32-bit D_CS0 port size
1 16-bit D_CS0 port size
Note: Used in development bus boot modes only (i.e. 496- and 516-pin packages). Do not clear this bit if the
device only has a 16-bit data bus.
VLE VLE Code Indicator. This bit configures the MMU entries 1-3 coded as Classic Book E instructions or as
Freescale VLE instructions.
0 User code executes as classic Book E code
1 User code executes as Freescale VLE code
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
A16 A17 A18 A19 A20 A21 A22 A23 A24 A25 A26 A27 A28 A29 A30 A31
Figure 6-5. Application Start Address Register
Priority Address
0 0x0002_0000
1 0x0003_0000
2 0x0000_0000
3 0x0000_4000
4 0x0001_0000
5 0x0001_C000
3. If a valid RCHW is not found, the BAM program switches to serial boot mode
4. If the BAM program finds a valid RCHW:
— BOOT_BLOCK_ADDRESS is the address (from Table 6-5) of the valid RCHW
— The BAM program fetches the application start address from
BOOT_BLOCK_ADDRESS + 0x4
— The BAM branches to this start address (shown in Figure 6-5)
— The MMU TLB entries 1,2,3 are programmed with VLE attribute if the RCHW[VLE] = 1
— The watchdog timers are programmed as shown in
Core WD SWT
Table 6-7. CAN/eSCI Pins Configuration for CAN/eSCI Fixed Baud Rate Boot Modes
Serial Boot Mode after a valid Serial Boot Mode after a valid
Reset Initial Serial Boot Mode
Pins CAN message received eSCI message received
Function
Function Pad Configuration Function Pad Configuration Function Pad Configuration
CNTX_A GPIO CNTX_A Push/Pull output, with CNTX_A Push/Pull output, GPIO —
medium slew rate with medium slew
rate
Table 6-7. CAN/eSCI Pins Configuration for CAN/eSCI Fixed Baud Rate Boot Modes
CNRX_A GPIO CNRX_A Input with pull-up and CNRX_A Input with pull-up GPIO —
hysteresis and hysteresis
TXD_A GPIO GPIO — GPIO — TXD_A Push/Pull output, with
medium slew rate
RXD_A GPIO RXD_A Input with pull-up and GPIO — RXD_A Input with pull-up and
hysteresis hysteresis
The BAM configures the communication modules for reception with fixed baud rates as shown in the
Table 6-8 and then waits for data reception. The watchdog timers are configured as shown in Table 6-9.
Core WD SWT
If a message containing 8 bytes with ID 0x11 is received by the CAN controller first, the BAM program:
• Transitions to serial CAN boot mode
• Disables the eSCI
• Configures RXD_A to its reset state
• Transitions to the CAN serial download protocol routine
If a byte from eSCI is received first, the BAM program:
• Transitions to the Serial SCI Boot sub-mode
• Disables CAN_A module
• Configures CAN_A’s pins to their reset state
• Transitions to the SCI serial download protocol routine
NRZ Signal
The BAM program ignores CAN errors and all received messages are assumed to be good. Received
messages are transmitted back. The host processor must compare the MCU transmissions with the sent
data and restart the process if an error is detected.
When the CAN is used for serial download, the data is packed into standard CAN messages in the
following manner:
• A message with 0x11 ID and 8-byte length to send the password. The MCU transmits back the
same data, but with ID of 0x1.
• A message with 0x12 ID and 8-byte length to send the start address, length, and the VLE mode bit.
The MCU transmits back the same data, but with ID of 0x2.
• Messages with 0x13 ID are used to send the downloaded data. The MCU transmits back the same
data with ID of 0x3.
When the SCI is used for serial download, the data must be sent on a byte-by-byte basis. The MCU
transmits back the received bytes.
Since the MCU starts up with the system clock derived from the Internal RC Oscillator (IRC), it does not
wait for the crystal oscillator to stabilize or the PLL to lock before finishing the reset sequence and
negating the RTSTOUT pin. Therefore, the BAM program starts executing with the IRC clock, but it needs
to switch to the PLL clock in case of serial boot. Before switching to the PLL clock, the BAM program
waits for the PLL lock flag to be asserted, which is an indication that the crystal oscillator has settled and
the PLL has locked. As a consequence, the external device that will upload the serial code needs to wait
enough time after RSTOUT negates to allow the crystal oscillator to stabilize and the PLL to lock. The
exact time depends on the crystal used, but is typically less than 10 ms. On the other hand, the code must
be uploaded before the SWT timeout expires. The SWT timeout is 21 seconds.
NOTE
Serial boot is only possible if the PLLCFG pins have been configured to
enable the PLL working in normal mode.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
START_ADDRESS[0:15]
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
START_ADDRESS[16:31]
32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47
VLE CODE_LENGTH[0:14]
48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63
CODE_LENGTH[15:30]
Figure 6-7. Start Address, VLE Bit and Download Size in Bytes
– START_ADDRESS defines where the received data is stored and where the MCU branches
after the download is finished. The two least significant bits of the start address are ignored
by the BAM program, thus the loaded code should be 32-bit word aligned.
– CODE_LENGTH defines how many data bytes to be loaded.
– VLE instructs the MCU to program MMU entries 1–3 with VLE attribute. If it is 1, the
downloaded code must be compiled to VLE instructions, if it is 0 the code contains classic
Power Book E architecture instructions.
3. Download data.
Each byte of data received is stored in the MCU memory, starting at the START_ADDRESS
specified in the previous step. The data increments through memory until the number of bytes
stored matches CODE_LENGTH specified in the previous step.
The BAM program buffers incoming data, collecting up to eight bytes. The buffered data is written
to the RAM with 64-bit writes to prevent ECC errors, which may happen if the MCU RAM is
protected by 64-bit ECC code.
Once the buffered data is written to the RAM the BAM program refreshes the SWT.
NOTE
Only system RAM supports 64-bit writes; therefore, attempting to
download data to other RAM apart from system RAM causes errors.
If the start address of the downloaded data is not on an 8-byte boundary, the
BAM writes 0x0 to the memory locations from the proceeding 8-byte
boundary to the start address (maximum 4 bytes). The BAM also writes 0x0
to all memory locations from the last byte of data downloaded to the
following 8 byte boundary (maximum 7 bytes). An additional 8 zero bytes
are written to prevent possible ECC errors that may be caused by the CPU
pre-fetching.
BAM writes additional two zero double words to the system RAM after
loaded code to prevent possible ECC errors, which could happen due the
CPU speculatively pre-fetches data after last loaded instruction, where the
RAM can be not initialized. The last loaded code address must not exceed
0x4003_FFF0 (the upper allowed RAM address by MMU settings minus
two zero double words, written by BAM at the end of code download).
TB content divided by 288. (Measured over 9 bits with 16 system clocks per bit and the core frequency is
two times higher than system frequency).
Maximum and minimum speeds of the serial communication modules are defined by the MCU system
frequency and shown in the Table 6-11.
Fsys =
Fxtall Max Baud rate for CAN Min CAN Baud rate Max Baud rate for SCI Min Baud rate for SCI
1.5*Fxtal
(MHz) (Fsys/9)2(bps) (Fsys/25/256) bps (Fsys/160)(bps) (Fsys/160/213)(bps)
(MHz)
8 12 1M 1875 75K 9.2
12 18 2812.5 112.5K 13.7
16 24 3750 150K 18.3
20 30 4687.5 187.5K 22.9
40
1
When the MCU operates with the PLL in normal mode with crystal oscillator as a reference clock source.
2
Limited by 1Mbps by CAN standard
6.5.6.1 EBI Configuration for Separate Address and Data Development Bus
Boot Mode
The BAM program sets up EBI related registers as shown in the Table 6-13.
Table 6-13. Development Bus/EBI Register Settings for Separate Address Data lines mode
RCHW[PS0] must be programmed to “1”, since the development bus does not support 32-bit port size in
that sub-mode.
6.5.6.2 EBI Configuration for multiplexed Address and Data Development Bus
Boot Mode
The BAM program sets up EBI related registers as shown in the Table 6-14.
If the boot memory device is 32 bit wide, the RCHW must be programmed in two first half-words of the
memory because when the MCU tries to read RCHW, the EBI is configured to use data lines 16–31 for
16-bit port accesses.
Compare
Nexus Client
TAP Controller
JTAG Port Controller
CENSOR_CTRL Register
Debug/Calibration Tool
Access
The steps to enable the debug port on a censored device are as follows:
1. Hold the device in system reset state using a debugger or other tool.
2. While the device is being held in system reset state, shift the 64-bit password into the
CENSOR_CTRL register via the JTAG port using the JTAG ENABLE_CENSOR_CTRL
instruction. The JTAG serial password is compared against the serial boot flash password from the
flash shadow block.
3. If there is a match, the Nexus client TAP controller enters normal operation mode and the DISNEX
flag in the SIU_CCR register is negated, indicating Nexus is enabled. Upon negation of reset, the
debug / calibration tool is able to access the device via NEXUS port and JTAG. If the JTAG serial
password does not match the serial boot flash password or the serial boot flash password is an
illegal password then the debug / calibration tool is not able to access the device. After the debug
port is enabled, the tool can access the censored device and can erase and reprogram the shadow
flash block in order to uncensor the device.
NOTE
If the shadow flash block is erased without reprogramming a new valid
password before a reset, it will contain an illegal password and the debug
port will be inaccessible.
4. Subsequent resets will clear the JTAG censor password register and the Nexus client TAP
controller will be held in reset again. Therefore, the tool must resend the JTAG serial password, as
described above, in order to enable the Nexus client TAP controller again.
7.1 Overview
This SoC contains the following clock related modules:
• External Oscillator (XOSC)
• Internal RC Oscillator (IRC)
• FM PLL
• System Clock Divider
• FlexCAN Clock Selector
• FlexRay Clock Selector
• Nexus MCKO Divider
7.3 Architecture
Figure 7-1 shows the clock distribution paths for all on-chip modules.
Clocking
SIU_ECCR[ECSS] SIU_ECCR[ENGDIV]
DIV ENGCLK
DIV CLKOUT
SIU_ECCR[EBDF]
PLLCFG[0:2]
pll_osc_enable
pllbi_rmode
CLK Core1
ESYNCR1[CLKCFG[0]] Gate
en
System Platform,
EXTAL div2 CLK Flash, &
Oscillator Clock Gate
XTAL Peripherals
Divider
Digital Analog
PLL
16MHz
IRC Dual eTPU
CLK
Gate (A&B)
SIU_SYSDIV[SYSCLKSEL[0:1]]
FFL SIU_SYSDIV[SYSCLKDIV[0:1]
Flash
Test Row SIU_SYSDIV[IPGCLKDIV[0:1]]
Freescale Semiconductor
SIU_HLT[HLT[0:31]]
CLK
Gate FlexCANs
FlexRay
7.4.2.1 Overview
The benefits of providing and booting the device from the IRC are:
• Fast start up (IRC starts up in tens of IRC clock cycles).
• The IRC is very reliable (extremely low PPM failure rate).
• Removes historical issues seen with the PLL trying to lock during power up transients. The PLL
will be enabled by the user, after reset, and after the supplies are within specified regulation.
• The IRC can provide a limp mode clock in the event of a crystal oscillator failure.
7.4.4.1 IRC
The device starts up from reset with the 16MHz internal RC oscillator (IRC) enabled and driving the
system clock.
7.4.4.2 XOSC
The external oscillator (XOSC) is enabled or disabled based on PLLCFG encodings to support the BAM
serial boot mode.
7.4.4.3 PLL
In order to support BAM serial boot mode, all PLLCFG pins, connections and configurations are effective
from reset.
7.4.10 MCKO
MCKO is an output clock from the Nexus Port Controller (NPC) to the development tools used for the
timing of MSEO and MDO pin functions. MCKO is derived from the system clock, and its frequency is
determined by the value of the MCKO_DIV field in the port configuration register (PCR) located in the
NPC.
7.4.11 D_CLKOUT/ENGCLK
D_CLKOUT is the device system clock output designed for, but not restricted to, use with the EBI.
ENGCLK is a 50% duty cycle output clock derived from the device system clock or the oscillator
frequency. ENGCLK maximum frequency is the system clock or oscillator frequency divided by two.
ENGCLK is not synchronous to CLKOUT.
8.1.2 Features
The FMPLL has these major features (refer to MPC5676R Microcontroller Data Sheet for performance
data and restrictions):
• Input clock frequency range: 8 MHz to 40 MHz (EXTAL)
• Programmable frequency multiplication factor settings which specify VCO frequencies of
192 MHz – 600 MHz
• PLL Off mode (low-power mode)
• Register programmable output clock divider (ERFD)
• Programmable frequency modulation
— Modulation applied as a triangle waveform
— Peak-to-peak register programmable modulation depths
— Register programmable modulation rates of Fextal/80, Fextal/40, and Fextal/20 (modulation rate
must be between 400 kHz and 1 MHz).
• Lock detect circuitry provides a signal indicating the FMPLL has acquired lock and continuously
monitors the FMPLL output for any loss of lock
• Loss-of-clock circuitry monitors input reference and FMPLL output clocks with programmable
ability to select a backup clock source as well as generate a reset or interrupt in the event of a failure
Offset from
FMPLL_BASE_ADDR Register Bits Access Reset Value Section/Page
(0xC3F8_0000)
0x0000 Reserved
0x0004 SYNSR—FMPLL synthesizer status register 32 R/W —1 8.3.2.1/8-3
0x0008 ESYNCR1—FMPLL enhanced synthesizer 32 R/W 0x8001_0053 8.3.2.2/8-6
control register 1
0x000C ESYNCR2—FMPLL enhanced synthesizer 32 R/W 0x0000_0005 8.3.2.3/8-8
control register 2
0x0010–0x001C Reserved
0x20 SYNFMCR—FMPLL synthesizer FM control 32 R/W —1 8.3.2.4/8-11
register
1
See specific register description.
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R PLL PLL 1
0 0 0 0 0 0 LOLF LOC MODE LOCKS LOCK LOCF U U1
SEL REF
W w1c w1c
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 8-2. FMPLL Synthesizer Status Register (SYNSR)
1 These bits may read 0 or 1, depending on current state of the PLL, however they do not provide any useful user information.
Field Description
0–21 Reserved
22 Loss- of-Lock Flag. This bit provides the interrupt request flag. To clear the flag, write a 1 to the bit. Writing 0 has
LOLF no effect. The LOLF is not set in response to the following conditions:
• Loss of lock due to a system reset, or
• Loss of lock due to changing any of the following: Multiplication Factor Divider (ESYNCR1_EMFD),
Pre-Divider (ESYNCR1_EPREDIV), or Modulation Depth (EYSNCR2_EDEPTH) prior to the LOLF being set
and cleared (for example, in response to an unexpected loss of lock condition).
If the flag is set due to a system failure, writing the ESYNCR1[EMFD] bits or enabling FM does not clear the flag.
Assert reset to clear the flag. If lock is reacquired, the bit remains set until either a write 1 or reset is asserted.
0 Interrupt service not requested.
1 Interrupt service requested.
23 Loss-Of-Clock Status. The LOC bit is an indication of whether a loss-of-clock condition is present when operating
LOC in normal PLL mode. If LOC = 0, the system clocks are operating normally. If LOC = 1, the system clocks have
failed due to a reference failure or a PLL failure. If the read of the LOC bit and the loss-of-clock condition occur
simultaneously, the bit does not reflect the current loss-of-clock condition. If a loss-of-clock condition occurs that
sets this bit and the clocks later return to normal, this bit is cleared. LOC is always zero in PLL Off mode.
0 Clocks are operating normally.
1 Clocks are not operating normally.
24 Clock Mode. The state of this bit, along with PLLSEL and PLLREF, indicates which clock mode the PLL is
MODE operating in (see Table 8-13). The value of ESYNCR1[CLKCFG2] is reflected in this location.
0 PLL Off mode.
1 PLL clock mode.
25 PLL Mode Select. The state of this bit, along with MODE and PLLREF, indicates which mode the PLL operates
PLLSEL in. This bit is cleared in PLL Off mode. The value of ESYNCR1[CLKCFG1] is reflected in this location.
0 PLL Off mode.
1 Normal PLL mode.
26 PLL Clock Reference Source. The state of this bit, along with MODE and PLLSEL, indicates which reference
PLLREF source has been chosen for normal PLL mode. This bit is cleared in PLL Off mode. The value of
ESYNCR1[CLKCFG0] is reflected in this location.
0 External clock reference chosen
1 Crystal clock reference chosen
Note: The PLL controls the oscillator.
Field Description
27 Sticky PLL Lock Status Bit. The LOCKS bit is a sticky indication of PLL lock status. LOCKS is set by the lock
LOCKS detect circuitry when the PLL acquires lock after: 1) a system reset, or 2) a write to the ESYNCR1 which modifies
the ESYNCR1[EMFD] bits, or 3) frequency modulation is enabled. Whenever the PLL loses lock, LOCKS is
cleared. LOCKS remains cleared after the PLL re-locks, until one of the three conditions occurs. Furthermore,
if the LOCKS bit is read when the PLL simultaneously loses lock, the bit does not reflect the current loss-of-lock
condition.
If operating in PLL Off mode, LOCKS remains cleared after reset.
0 PLL has lost lock since last system reset, a write to ESYNCR1 to modify the ESYNCR1[EMFD] and
ESYNCR1[EPREDIV] bit fields, or frequency modulation enabled
1 PLL has not lost lock since last system reset, a write to ESYNCR1 to modify the ESYNCR1[EMFD] and
ESYNCR1[EPREDIV] bit fields, or frequency modulation enabled
28 PLL Lock Status Bit. The LOCK bit indicates whether the PLL has acquired lock. Refer to MPC5676R
LOCK Microcontroller Data Sheet for tolerances. If the LOCK bit is read when the PLL simultaneously loses lock or
acquires lock, the bit does not reflect the current condition of the PLL.
If operating in PLL Off mode, LOCK remains cleared after reset.
0 PLL is unlocked
1 PLL is locked
29 Loss-of-Clock Flag. This bit provides the interrupt request flag. To clear the flag, write a 1 to the bit. Writing 0
LOCF has no effect. Asserting reset clears the flag. If clocks return to normal after the flag has been set, the bit remains
set until cleared by either writing 1 or asserting reset. A loss-of-clock condition can only be detected if
LOCEN = 1.
0 Interrupt service not requested.
1 Interrupt service requested.
30–31 Reserved
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R 0 0 0 0 0 0 0 0
EMFD
W 03
Reset 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0
1
Reset value determined by PLLCFG pins during reset.
2
Resets to value of PLLCFG[2] (0 if PLLCFG[2]=0; 1 if PLLCFG[2]= 1)
3 Do not set this bit to 1.
Field Description
0 Reserved.
Note: This bit is set to 1 on reset and always reads as 1. Writes to this bit have no effect.
1–3 Clock Configuration. The CLKCFG[2:0] bits are writable versions of the MODE, PLLSEL, and PLLREF bits
CLKCFG[2:0] in the SYNSR. These change the clock mode, after reset has negated, via software. CLKCFG[2:0] map
directly to MODE, PLLSEL, and PLLREF to control the system clock mode.
Note: CLKCFG = 0b101 (or any reserved/invalid value) can produce an unpredictable clock output.
Note: The ESYNCR2[LOLRE] and ESYNCR2[LOCRE] should be set to 0 before changing the PLL mode,
so that a reset is not immediately generated when CLKCFG is written.
4–11 Reserved
12–15 Enhanced Pre-Divider. The EPREDIV bits control the value of the divider on the input clock. The output of
EPREDIV the pre-divider circuit generates the reference clock to the PLL analog loop. The decimal equivalent of the
EPREDIV binary number is substituted into the equation from Table 8-8.
Note: Setting EPREDIV to any of the invalid states in Table 8-4 causes the PLL to produce an unpredictable
output clock. The output frequency of the divider must equal fpllref (see the MPC5676R Microcontroller
Data Sheet).
When the EPREDIV bits are changed, the PLL immediately loses lock. Do not change the EPREDIV bits
during FM operation. Before changing EPREDIV, FM must be disabled and then reconfigured after the PLL
re-locks to the new EPREDIV value. To prevent an immediate reset, clear the LOLRE bit before writing the
EPREDIV bits. In PLL Off mode, the EPREDIV bits have no effect.
Field Description
16–23 Reserved.
Note: Do not set this bit to 1.
24–31 Enhanced Multiplication Factor Divider. The EMFD bits control the value of the divider in the PLL feedback
EMFD loop. The value specified by the EMFD bits establish the multiplication factor applied to the reference
frequency. The decimal equivalent of the EMFD binary number is substituted into the equation from
Table 8-10 for Fsys to determine the equivalent multiplication factor. The range of settings is
32 EMFD 132.
Note: EMFD values less than 32 and greater than 132 are invalid and cause the PLL to produce an
unpredictable clock output. The VCO frequency must be within the fVCO specification (see the
MPC5676R Microcontroller Data Sheet).
When the EMFD bits are changed, the PLL loses lock. Do not change the EMFD bits during FM operation.
Before changing EMFD, FM must be disabled and then reconfigured after the PLL re-locks to the new EMFD
value.To prevent an immediate reset, clear the LOLRE bit before writing the EMFD bits.
In PLL Off mode, the EMFD bits have no effect.
Table 8-5 shows the available divide ratios.
0000 1
0001 2 (default if PLLCFG[2]=0)
0010 3
0011 4 (default if PLLCFG[2]=1)
0100 5
0101 6
0110 Invalid
0111 8
1000 Invalid
1001 10
1010–1111 Invalid
0000_0000–0001_1111 Invalid
0010_0000 48 (default for MPC5676R)
0010_0001 49
0010_0010 50
0010_0011 51
0010_0100 52
0010_0101 53
. .
. .
0101_0011 99
. .
. .
1000_0100 132
1000_0101–1111_1111 Invalid
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R CLK 0 0 0 0 0 0
W CFG EDEPTH ERFD
_DIS
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 1
Figure 8-4. FMPLL Enhanced Synthesizer Control Register 2 (ESYNCR2)
Field Description
0–7 Reserved
8 Loss-of-Clock Enable. The LOCEN bit determines whether the loss-of-clock function is operational along
LOCEN with backup clock modes, and interrupt and reset functions. See Section 8.4.3.2, “Loss-of-Clock Detection,”
for more information.
In PLL Off mode, this bit has no effect.
LOCEN does not affect the loss-of-lock circuitry.
0 Loss-of-clock disabled.
1 Loss-of-clock enabled.
9 Loss-of-Lock Reset Enable. The LOLRE bit determines how the integration module handles a loss-of-lock
LOLRE indication. See Section 8.4.3.1, “PLL Lock Detection,” for more information.
When operating in normal PLL mode, the PLL must be locked before setting the LOLRE bit. Otherwise reset
is immediately asserted.
The LOLRE bit has no effect in PLL Off mode.
0 Assert reset on loss of lock is disabled.
1 Assert reset on loss of lock.
Field Description
10 Loss-of-Clock Reset Enable. The LOCRE bit determines how the integration module handles a loss-of-clock
LOCRE condition when LOCEN is equal to 1. LOCRE has no effect when LOCEN is equal to 0.
If the LOCF bit in the SYNSR indicates a loss-of-clock condition, setting the LOCRE bit causes an immediate
reset.
The LOCRE bit has no effect in PLL Off mode.
0 Assert reset on loss of clock is disabled.
1 Assert reset on loss of clock.
11 Loss-of-Lock Interrupt Request. The LOLIRQ bit determines how the integration module handles a
LOLIRQ loss-of-lock indication. See Section 8.6.1, “Loss-of-Lock Interrupt Request,” for more information.
When operating in normal mode, the PLL must be locked before setting the LOLIRQ bit. Otherwise an
interrupt is immediately requested.
The LOLIRQ bit has no effect in PLL Off mode.
0 Request interrupt is disabled.
1 Request interrupt.
12 Loss- of-Clock Interrupt Request. The LOCIRQ bit determines how the integration module handles a loss-
LOCIRQ of-clock condition when LOCEN = 1. LOCIRQ has no effect when LOCEN = 0.
If the LOCF bit in the SYNSR indicates a loss-of-clock condition, setting (or having previously set) the
LOCIRQ bit causes an interrupt request.
The LOCIRQ bit has no effect in PLL Off mode.
0 Request interrupt on loss of clock is disabled.
1 Request interrupt on loss of clock.
13 Reserved
14–15 Enhanced Modulation Rate. The ERATE bits control the rate of frequency modulation applied to the system
ERATE1 frequency. Table 8-7 shows the allowable modulation rates.
16 The CLKCFG_DIS bit is used to disable the ability to change the PLL mode using the CLKCFG bits. This
CLKCFG_DIS protects the system from errant software writes and/or bit flips on the CLKCFG[2:0] bits that could change
the PLL clock mode.
Note: If the PLL is configured for PLL Off mode when the CLKCFG_DIS bit is set, the PLL will automatically
enter normal mode. For this reason, it is advisable to set the PLL for the desired mode (normal mode
with crystal reference or normal mode with external reference) before setting the CLKCFG_DIS bit to
protect from inadvertent mode changes.
0 Writes to CLKCFG[2:0] enabled.
1 Writes to CLKCFG[2:0] disabled.
17–20 Reserved
21–23 Enhanced Modulation Depth. The EDEPTH bit field controls the frequency modulation depth, and in
EDEPTH conjunction with the SYNFMCR[FMDAC_EN] bit enables frequency modulation. The EDEPTH bit must be
set to a non-zero value for FM operation. The sequence for enabling and configuring FM operation is
described in Section 8.4.3.4.2, “Programming System Clock Frequency With Frequency Modulation””. This
program sequence must be followed exactly to insure proper operation of the FM.
24–25 Reserved
Field Description
26–31 Enhanced Reduced Frequency Divider. The ERFD bits control a divider at the output of the PLL. The value
ERFD specified by the ERFD bits establish the divisor applied to the PLL frequency. The ERFD divides the output
clock by the quantity (ERFD + 1). Even-numbered ERFD settings, which would result in odd divide ratios, are
not allowed.
The decimal equivalent of the ERFD binary number is substituted into the equation from Table 8-10.
Note: The ERFD divides the output clock by the quantity (ERFD + 1). Even numbered ERFD settings, which
would result in odd divide ratios, are invalid and cause the PLL to produce an unpredictable output
clock. The PLL output clock must be within the fPLL specification (see the MPC5676R Microcontroller
Data Sheet).
Changing the ERFD bits does not affect the PLL, hence, no re-lock delay is incurred. Resulting changes in
clock frequency are synchronized to the next falling edge of the current system clock. These bits should be
written only when the lock bit (LOCK) is set, to avoid surpassing the allowable system operating frequency.
In PLL Off mode, the ERFD bits have no effect.
The available output divider ratios are given in Table 8-8.
1
ERATE and EDEPTH must be enabled simultaneously to avoid unintentional assertion of the LOLF. Program the desired
modulation rate and depth to the ERATE and EDEPTH bit fields simultaneously with a single 32 bit write to the ESYNCR2
register.
00 Fmod = Fextal/80
01 Fmod = Fextal/40
10 Fmod = Fextal/20
11 Invalid
00_0000 Divide-by-1
00_0001 Divide-by-2
00_0010 Invalid
00_0011 Divide-by-4
00_0100 Invalid
00_0101 Divide-by-6
00_0110 Invalid
00_0111 Divide-by-8
(default value for MPC5676R)
. .
. .
. .
11_1100 Invalid
11_1101 Divide-by-62
11_1110 Invalid
11_1111 Divide-by-64
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 8-5. FMPLL Synthesizer FM Control Register (SYNFMCR)
Field Description
0 Reserved
1 Frequency Modulation Register Enable. When this bit is set, the FMDAC_CTL field is enabled and the FM
FMDAC_EN depth can be controlled directly by the value in FMDAC_CTL. The ESYNCR2[EDEPTH] field must also be
set to a non-zero value to enable FM.
0 FMDAC_CTL disabled.
1 FMDAC_CTL enabled. DAC is controlled by the value in FMDAC_CTL.
2–10 Reserved
11–15 Digital-to-Analog Converter Control. This bit-field value is written to the DAC to control the FM depth by
FMDAC_CTL percentage during FM operation.
00100 – 1%
01000 – 2%
01100 – 3%
10000 – 4%
These values have been shown in characterization data to produce the specified FM percentage within the
device specification. However, the user may program intermediate values to trim the FM percentage for a
specific application if desired. Do not program FMDAC_CTL to any value that will cause the system
frequency to exceed the maximum specification.
16–0 Reserved
8.4.1 General
The system clock source is determined during reset as shown in Table 8-13. The value of the PLLCFG[0:1]
pins are latched during reset. If PLLCFG[0:1] are changed during a reset other than power-on reset, the
internal clocks may glitch as the clock source is changed between PLL Off mode and PLL clock mode or
from one PLL clock mode to another. Whenever PLLCFG[0:1] are changed in reset to a value other than
what it was before the reset, an immediate loss of lock condition is declared. This only applies if the PLL
was running in a locked state prior to the assertion of reset and change of PLLCFG[0:1].
Table 8-10 shows the PLL clock to input clock frequency relationships for the available clock modes.
frequency modulation enabled. The post-divider is capable of reducing the PLL clock frequency without
forcing a re-lock. The PLL reference can be a crystal oscillator reference or an external clock reference.
This clock is divided by the pre-divider circuit to create the PLL reference clock.
Count N
reference cycles, Lock detected
and compare Relax lock
number of feedback criteria.
cycles elapsed.
After the PLL acquires lock after reset, the LOCK and LOCKS status bits are set. If the EPREDIV or
EMFD are changed, or if an unexpected loss-of-lock condition occurs, the LOCK and LOCKS status bits
are negated. While the PLL is in an unlocked condition, the system clocks continue to be sourced from the
PLL as the PLL attempts to re-lock. Consequently, during the re-locking process, the system clock
frequency is not well defined and may exceed the maximum system frequency violating the system clock
timing specifications. Because of this condition, use of the loss-of-lock reset function is recommended.
After the PLL has re-locked, the LOCK bit is set. The LOCKS bit remains cleared if the loss of lock was
unexpected. The LOCKS bit is set to one when the loss of lock was caused by changing the EPREDIV or
EMFD fields.
caused by a reference clock failure or a PLL failure. If the reference fails, the PLL goes out of lock and
into self-clocked mode (SCM) (see Table 8-11). The PLL remains in SCM until the next reset. When the
PLL is operating in SCM, the PLL runs open loop at a default VCO frequency. The RFD will set to
divide-by-6 to ensure the clock presented to the system is well below the maximum allowable frequency
for the device. If the loss-of-clock condition is due to a PLL failure (i.e., loss of feedback clock), the PLL
reference becomes the system clock source until the next reset, even if the PLL regains itself and re-locks.
Note: The LOC circuit monitors the inputs to the PFD: reference and feedback clocks (see Figure 8-1).
A special loss-of-clock condition occurs when both the reference and the PLL fail. The failures may be
simultaneous or the PLL may fail first. In either case, the reference clock failure takes priority and the PLL
attempts to operate in SCM. If successful, the PLL remains in SCM until the next reset. During SCM,
modulation is always disabled. If the PLL cannot operate in SCM, the system remains static until the next
reset. Both the reference and the PLL must be functioning properly to exit reset.
UP and DOWN signals for a very short duration during each reference clock cycle. These short pulses
force the PLL to continually update and prevent a frequency drift phenomena referred to as
“dead-banding.” Dead-band describes the minimum amount of phase error between the reference and
feedback clocks that a phase detector cannot correct.
8.4.3.3.3 VCO
The voltage into the VCO controls the frequency of its output. The frequency-to-voltage relationship
(VCO gain) is positive.
8.4.3.3.4 EMFD
The MFD divides down the output of the VCO and feeds it back to the PFD. The PFD controls the VCO
frequency (via the charge pump and loop filter) such that the reference and feedback clocks have the same
frequency and phase. Thus, the input to the MFD, which is also the output of the VCO, is at a frequency
that is the reference frequency multiplied by the same amount the MFD divides by. For example, if the
MFD divides the VCO frequency by 48, then the PLL is frequency locked when the VCO frequency is 48
times the reference frequency. The presence of the MFD in the loop allows the PLL to perform frequency
multiplication, or synthesis.
2. Write a value of ERFD = ERFD (from step 1) + 2 to the ERFD field of the ESYNCR2. Not
increasing the ERFD when changing the EPREDIV or EMFD could subject the device to clock
frequencies beyond the range specified for the device due to the PLL’s unlocked state.
3. If frequency modulation is currently enabled, disable it by writing 00 to the EDEPTH field of the
ESYNCR2.
4. If programming the EPREDIV and/or EMFD, write the value(s) determined in step 1 to the
appropriate field(s) in the ESYNCR1.
5. Monitor the synthesizer lock bit (LOCK) in the synthesizer status register (SYNSR). When the
PLL achieves lock, write the ERFD value determined in step 1 to the ERFD field of the ESYNCR2.
This changes the system clocks frequency to the desired frequency. If frequency modulation is
desired, leave ERFD programmed to ERFD + 2 until after completing the steps in
Section 8.4.3.4.2, “Programming System Clock Frequency With Frequency Modulation.”
6. If frequency modulation was enabled initially, it can be re-enabled following the steps listed in
Section 8.4.3.4.2, “Programming System Clock Frequency With Frequency Modulation.”
During startup, current transients on the VDD supply are related to the system frequency. A technique can
be used to reduce these current transients when the system frequency is changed from its default value to
your desired frequency.
Follow the above procedure for step 1. In step 2, rather than set ERFD to ERFD (from step 1) + 2, set this
to a value which will produce a low system frequency (close to the default system frequency), e.g.
ERFD = ERFD (from step 1) + 4. Once set, follow steps 3 and 4 as above. In step 5, wait for the LOCK
bit to set, then set the EFRD bit to ERFD (from step 2) – 2. Wait for a small duration of time for the current
to stabilize, then repeat this procedure until the ERFD value is equal to the value determined in step 1.
Using this technique you should observe the system frequency increasing in steps to the desired system
frequency. This results in the VDD current increasing to its equivalent final value in smaller current steps
which, therefore, produce smaller current transients, making it easier for the power supply to handle.
Fmax
Fm
Fm
Fmin
1
t = ----------------
F mod
2. Write the SYNFMCR[FMDAC_EN] bit to logical 1 (to enable FMDAC_CTL) and the
SYNFMCR[FMDAC_CTL] bit field to the appropriate value shown in Table 8-12.
Table 8-12. FMDAC_CTL settings for FM Configuration
Peak-to-Peak FM depth
FMDAC_CTL
(EDEPTH)
3. Program the desired modulation rate into the ERATE field of the ESYNCR2 register and set the
EDEPTH field to a non-zero value. The absolute value in the EDEPTH field is non-critical as this
value is not used for actual FM depth, however EDEPTH must be non-zero to enable FM. Make
sure not to change ERFD from step 2 when setting ERATE and EDEPTH as they share the same
register space.
4. Wait for the PLL to lock. When the PLL achieves lock, write the desired ERFD value. Make sure
not to modify ERATE/EDEPTH as they share the same register space.
The frequency modulation system is dependent on several factors, including the accuracies of the
VDDSYN/VSSSYN voltage, of the crystal oscillator frequency, and of the manufacturing variation.
For example, if a 5% accurate supply voltage is used, then a 5% modulation depth error results. If the
crystal oscillator frequency is skewed from the nominal operating frequency, the resulting modulation
frequency is proportionally skewed. Finally, the error due to the manufacturing and environment variation
alone can cause the frequency modulation depth error to be greater than 20%.
8.5 Resets
This section describes the reset operation of the PLL, including power-on reset and normal resets. The
reset values of registers and signals are provided in other sections.
not be able to lock due to an (E)MFD and crystal frequency combination that attempts to force the VCO
outside of its operating range
CAUTION
When running in an unlocked state, the clocks generated by the PLL are not
guaranteed stable and may exceed the maximum specified operating
frequency of the device. The RFD should always be used as described in
Section 8.4.3.3.5, “Programming System Clock Frequency,” to insulate the
system from any potential frequency overshoot of the PLL clocks.
8.6 Interrupts
This section describes the interrupt requests that the PLL can generate.
9.1.1 Features
The PMC contains the following features (see Section 9.1.1.1, “Features of the Analog Portion of
PMC_SMPS”, and Section 9.1.1.2, “Features of the Digital Portion of PMC_SMPS”, for detailed analog
and digital features of this device):
• Compatible for both 5V and 3.3V operations.
• A Switched Mode Power Supply (SMPS) Buck regulator and a Low Drop Out (LDO) linear
regulator, sharing the same control pin (REGSEL).
• SMPS regulator is selected when the REGSEL pin is connected to VDDREG. A 5V nominal
supply voltage is recommended to operate and defines the LVD level to 5V.
• LDO regulator is selected when the REGSEL pin is connected to VSS. A 3V nominal supply
voltage is recommended to operate and defines the VDDREG LVD level to 3V.
• High precision Low Voltage Detector (LVD) monitor for PMC supply voltage VDDREG, VDD
core voltage supply, and VDDSYN.
• A low voltage band gap generates the reference voltages and currents for voltage regulators and
LVDs.
• A Power On Reset (POR) monitor is used to check main regulator supply VDDREG and core
supply VDD and guarantees proper system function even at very low voltage supply levels.
• No power sequencing constraint required.
• An independent internal regulator generates 1.2V supply voltage for the low voltage digital portion
of the PMC.
• A 5V to 3.3V LDO regulator is enabled when the PMC is in SMPS5V mode and when the PMC is
in LDO mode with nominal supply voltage of 5V (LDO5V mode). The LDO 5V to 3V is disabled
when VDDREG is 3.3V nominal and in this case VDDREG and VDDSYN must be connected
together (LDO3V mode).
• A loose precision temperature sensor detects over-temperature conditions in the PMC and adjacent
area. Its low accuracy requires that temperature is checked with the included precision temperature
sensor before taking any corrective action.
• Direct measurement of PMC internal voltages is available at predefined ADC channels.
PMC
Logic/Registers ADC
Power Architecture™
LDO3V 3.3V Voltage Supply, When external pin REGSEL is connected to VSS -it has a weak internal resistive pull
LDO regulator enabled down- and regulator supply voltage is 3.3V nominal, the Linear 1.2V VRC is enabled
and the internal 3.3V regulator is disabled with tri-stated output. VDDSYN must be
connected to VDDREG. An external ballast transistor is expected on REGCTL as
described in 1.2V LDO regulator section. VDDREG LVD selected to 3V nominal.
LDO5V 5V Voltage Supply, LDO When external pin REGSEL is connected to VSS -it has a weak internal resistive pull
regulator enabled down- and regulator supply voltage is 5V nominal, the Linear 1.2V VRC is enabled,
as the internal 3.3V regulator. An external ballast transistor is expected on REGCTL
as described in 1.2V LDO regulator section. An external decoupling capacitor is
expected on VDDSYN (details in the 3.3V regulator section). VDDREG LVD selected
to 3V nominal.
SMPS5V 5V Voltage Supply, When external pin REGSEL is connected to VDDREG and regulator supply voltage
SMPS regulator enabled is 5V nominal, the Switched Mode VRC is enabled, and the internal 3.3V regulator
is enabled. An external MOS - Schottky device is expected on REGCTL as
described in SMPS regulator section. A decoupling capacitor must be used on
VDDSYN (details in the 3.3V regulator section). VDDREG LVD selected to 5V
nominal.
9.3.1 VDDREG
Positive analog power supply for PMC and voltage regulators. It can be nominal 5V or nominal 3.3V. It
supplies internal regulators and LVDs.
Voltage range VDDR for 5V operation and VDD33 for 3V operation can be found in the MPC5676R
Microcontroller Data Sheet.
Requires a decoupling cap of 5 – 20 uF between VDDREG and VSS as close as possible to the pins to
minimize board parasitcs.
9.3.2 VDD
Positive digital power supply for core voltage. Nominal value is 1.2V, voltage range is VDD12.
Decoupling capacitance configuration depends on selected regulator (LDO or SMPS). More details
available in the correspondent regulator description and in Section 9.7.2, “Hardware Design
Recommendations”.
9.3.3 VDDSYN
Positive 3.3V regulator output - power supply, voltage range VDD33, usually tied flash. Internal regulator
is ON in SMPS5V mode or in LDO5V mode. The 3.3V regulator is OFF in LDO3V mode with VDDREG
in the 3.3V range. When enabled, the VDDSYN regulator can source up to 80 mA keeping the regulation
in the 3.3V range. See the MPC5676R Microcontroller Data Sheet for more details. Sense voltage is taken
at VDD33, hence it is recommended to short VDDSYN and VDD33 with low impedance short track.
When the internal regulator is disabled the pin has a weak 35 k pull down resistor and VDDSYN must
be connected to VDDREG. Requires an external capacitor of 200 nF - 4 uF (depending on the application),
on the pad or as closest as possible with negative connection to VSS.
9.3.4 VSS
Negative digital power supply.
PMC substrate connection.
9.3.5 REGCTL
VRC 1.2V output that connects to the base of ballast NPN in LDO3V or LDO5V mode, or to the gate of
the n-MOS in SMPS5V mode.
9.3.6 REGSEL
Analog input that selects 1.2 VRC operation. It can be connected only to VDDREG or VSS.
When connected to VDDREG it enables the SMPS regulator, and requires a nominal supply voltage of 5V.
Else the LDO regulator is enabled and both 3.3V and 5V operation are allowed. A weak 200k pull down
resistor keeps the default level at 0V when pin is floating.
9.3.7 VDD33
Sense point for LVD and regulator feedback of the 3.3V VDDSYN analog supply.
Input that produces 3.3V regulator reference and LVD 3.3V reference.
Must be shorted to VDDSYN with low impedance connection.
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 9-2. Configuration and Status Register (PMC_MCR)
Field Description
0 Reset-pin-supply low-voltage reset enable. This bit defines whether an LVD assertion on the supply of the I/O
LVRER segment that contains the reset pin will generate system reset or not.
0 Disabled. LVD assertion on the supply of the I/O segment that contains the reset pin does not cause system reset.
1 Enabled. LVD assertion on the supply of the I/O segment that contains the reset pin causes system reset.
1 VDDEH low-voltage reset enable. This bit defines whether an LVD assertion on any monitored VDDEH supply will
LVREH generate system reset or not.
0 Disabled. LVD assertion on any monitored VDDEH supply does not cause system reset.
1 Enabled. LVD assertion on any monitored VDDEH supply causes system reset.
Field Description
2 VDDREG low-voltage reset enable. This bit defines whether an LVD assertion on the VDDREG supply of the voltage
LVRE50 regulator will generate system reset or not.
0 Disabled. LVD assertion on the VDDREG supply of the voltage regulator does not cause system reset.
1 Enabled. LVD assertion on the VDDREG supply of the voltage regulator causes system reset.
3 VDDSYN low-voltage reset enable. This bit defines whether an LVD assertion on the VDDSYN supply will generate
LVRE33 system reset or not.
0 Disabled. LVD assertion on the VDDSYN supply does not cause system reset.
1 Enabled. LVD assertion on the VDDSYN supply causes system reset.
4 Core-voltage-supply VDD low-voltage reset enable. This bit defines whether an LVD assertion on the core voltage
LVREC VDD supply will generate system reset or not.
0 Disabled. LVD assertion on the core voltage supply does not cause system reset.
1 Enabled. LVD assertion on the core voltage supply causes system reset.
5 VDDA low-voltage reset enable. This bit defines whether an LVD assertion on the analog power input VDDA1 will
LVREA generate system reset or not.
0 Disabled. LVD assertion on the analog power input VDDA1 does not cause system reset.
1 Enabled. LVD assertion on the analog power input VDDA1 causes system reset.
6–7 Reserved
8 Reset-pin-supply low-voltage interrupt enable. This bit enables the generation of the low-voltage interrupt request
LVIER when the supply of the I/O segment that contains the reset pin falls below the corresponding LVD threshold. The
low-voltage interrupt is independent from low-voltage reset. If both, interrupt and reset, are enabled, then reset and
interrupt will be generated, but reset will then clear the interrupt.
0 Disabled. Low-voltage interrupt request is disabled.
1 Enabled. Low-voltage interrupt request is enabled.
9 VDDEH low-voltage interrupt enable. This bit enables the generation of the low-voltage interrupt request when any
LVIEH monitored VDDEH supply falls below the corresponding LVD threshold. The low-voltage interrupt is independent
from low-voltage reset. If both, interrupt and reset, are enabled, then reset and interrupt will be generated, but reset
will then clear the interrupt.
0 Disabled. Low-voltage interrupt request is disabled.
1 Enabled. Low-voltage interrupt request is enabled.
10 VDDREG low-voltage interrupt enable. This bit enables the generation of the low-voltage interrupt request when the
LVIE50 VDDREG supply of the voltage regulator falls below the corresponding LVD threshold. The low-voltage interrupt is
independent from low-voltage reset. If both, interrupt and reset, are enabled, then reset and interrupt will be
generated, but reset will then clear the interrupt.
0 Disabled. Low-voltage interrupt request is disabled.
1 Enabled. Low-voltage interrupt request is enabled.
11 VDDSYN low-voltage interrupt enable. This bit enables the generation of the low-voltage interrupt request when the
LVIE33 VDDSYN power supply gets below the corresponding LVD threshold. The low-voltage interrupt is independent from
low-voltage reset. If both, interrupt and reset, are enabled, then reset and interrupt will be generated, but reset will
then clear the interrupt.
0 Disabled. Low-voltage interrupt request is disabled.
1 Enabled. Low-voltage interrupt request is enabled.
12 Core-voltage-supply low-voltage VDD interrupt enable. This bit enables the generation of the low-voltage interrupt
LVIEC request when the core voltage supply gets below the corresponding LVD threshold. The low-voltage interrupt is
independent from low-voltage reset. If both, interrupt and reset, are enabled, then reset and interrupt will be
generated, but reset will then clear the interrupt.
0 Disabled. Low-voltage interrupt request is disabled.
1 Enabled. Low-voltage interrupt request is enabled.
Field Description
13 VDDA low-voltage interrupt enable. This bit enables the generation of the low-voltage interrupt request when the
LVIEA analog power input VDDA1 falls below the corresponding LVD threshold. The low-voltage interrupt is independent
from low-voltage reset. If both, interrupt and reset, are enabled, then reset and interrupt will be generated, but reset
will then clear the interrupt.
0 Disabled. Low-voltage interrupt request is disabled.
1 Enabled. Low-voltage interrupt request is enabled.
14 Reserved
15 Trimming lock. This is a set-only bit that comes out of reset negated, and can be asserted one time after reset to lock
TLK the trimming register. Once asserted, it cannot be negated anymore. When TLK is asserted, the Trimming Register
becomes read-only and cannot be changed until the next reset.
0 Trimming register can be written.
1 Trimming register is read-only.
16–31 Reserved
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R
VDD33TRIM LVD33TRIM VDDCTRIM LVDCTRIM
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 0
Figure 9-3. Trimming Register (PMC_TRIMR)
Field Description
0–7 Reserved
Field Description
8–11 LVD VDDA trimming. This field is used to fine tune the voltage threshold of the VDDA1 rising LVD, used
LVDATRIM to monitor the analog power input VDDA1. See the MPC5676R Microcontroller Data Sheet for
details.0111LVDA 140 mV.
0110 LVDA 120 mV
0101 LVDA 100 mV
0100 LVDA 80 mV
0011 LVDA 60 mV
0010 LVDA 40 mV
0001 LVDA 20 mV
0000 Nominal, start-up and default value LVDA
1111 LVDA 20 mV
1110 LVDA 40 mV
1101 LVDA 60 mV
1100 LVDA 80 mV
1011 LVDA 100 mV
1010 LVDA 120 mV
1001 LVDA 140 mV
1000LVDA 160 mV
12–15 Description:
LVDREGTRIM This field is used to fine tune the voltage threshold of LvdReg the rising LVD, used to monitor the
VDDREG supply - rising edge. See the MPC5676R Microcontroller Data Sheet for details.
Bit Values: 0111 LvdReg 7 LVDSTEPREG
0110 LvdReg 6 LVDSTEPREG
0101 LvdReg 5 LVDSTEPREG
0100 LvdReg 4 LVDSTEPREG
0011 LvdReg 3 LVDSTEPREG
0010 LvdReg 2 LVDSTEPREG
0001 LvdReg 1 LVDSTEPREG
0000 Nominal, start-up and default value LvdReg
1111 LvdReg 1 LVDSTEPREG
1110 LvdReg 2 LVDSTEPREG
1101 LvdReg 3 LVDSTEPREG
1100 LvdReg 4 LVDSTEPREG
1011 LvdReg 5 LVDSTEPREG
1010 LvdReg 6 LVDSTEPREG
1001 LvdReg 7 LVDSTEPREG
1000 LvdReg 8 LVDSTEPREG
Field Description
16–19 Description:
VDD33TRIM This field is used to fine tune VDD33 the output voltage of the 3.3V regulator, the VDDSYN supply. See
the MPC5676R Microcontroller Data Sheet for details.
Bit Values:
0111 VDD33 7 STEPV33
0110 VDD33 6 STEPV33
0101 VDD33 5 STEPV33
0100 VDD33 4 STEPV33
0011 VDD33 3 STEPV33
0010 VDD33 2 STEPV33
0001 VDD33 1 STEPV33
0000 Nominal, start-up and default value VDD33
1111 VDD33 STEPV33
1110 VDD33 2 STEPV33
1101 VDD33 3 STEPV33
1100 VDD33 4 STEPV33
1011 VDD33 5 STEPV33
1010 VDD33 6 STEPV33
1001 VDD33 7 STEPV33
1000 VDD33 8 STEPV33
20–23 Description:
LVD33TRIM LVD 3.3V trimming. This field is used to fine tune the rising voltage threshold of the VDDSYN supply,
which can be internally regulated by the 3.3V regulator in LDO5V and SMPS5V modes or can be
provided externally in LDO3V mode. See the MPC5676R Microcontroller Data Sheet for details.
Bit Values
0111 LVD33 7 LVDSTEP33
0110 LVD33 6 LVDSTEP33
0101 LVD33 5 LVDSTEP33
0100 LVD33 4 LVDSTEP33
0011 LVD33 3 LVDSTEP33
0010 LVD33 2 LVDSTEP33
0001 LVD33 1 LVDSTEP33
0000 Nominal, start-up and default value of LVD33
1111 LVD33 1 LVDSTEP33
1101 LVD33 2 LVDSTEP33
1110 LVD33 3 LVDSTEP33
1100 LVD33 4 LVDSTEP33
1011 LVD33 5 LVDSTEP33
1001 LVD33 6 LVDSTEP33
1010 LVD33 7 LVDSTEP33
1000 LVD33 8 LVDSTEP33
Field Description
24–27 Description:
VDDCTRIM This field is used to fine tune VDD12OUT the output voltage of the 1.2V regulator, correspondent to the
VDD supply. See the MPC5676R Microcontroller Data Sheet for details.
Bit Values
0111 VDD12OUT 7 STEPV12
0110 VDD12OUT 6 STEPV12
0101 VDD12OUT 5 STEPV12
0100 VDD12OUT 4 STEPV12
0011 VDD12OUT 3 STEPV12
0010 VDD12OUT 2 STEPV12
0001 VDD12OUT 1 STEPV12
0000 Nominal, start-up and default value of VDD12OUT
1111 VDD12OUT 1 STEPV12
1110 VDD12OUT 2 STEPV12
1101 VDD12OUT 3 STEPV12
1100 VDD12OUT 4 STEPV12 Program VDD12OUT to this code when using Internal LDO generator
1011 VDD12OUT 5 STEPV12
1010 VDD12OUT 6 STEPV12
1001 VDD12OUT 7 STEPV12
1000 VDD12OUT 8 STEPV12
28–31 Description:
LVDCTRIM LVD 1.2V trimming. This field is used to fine tune the rising voltage threshold of the VDD supply. See the
MPC5676R Microcontroller Data Sheet for details.
Bit Values
0111 LVD12 13 LVDSTEP12
0110 LVD12 12 LVDSTEP12 Default LVD12 value to be programmed immediately after reset if core
voltage internal regulator is used
0101 LVD12 11 LVDSTEP12
0100 LVD12 10 LVDSTEP12
0011 LVD12 9 LVDSTEP12
0010 LVD12 8 LVDSTEP12
0001 LVD12 7 LVDSTEP12
0000 LVD12 6 LVDSTEP12 Default value before reset
1111 LVD12 5 LVDSTEP12
1101 LVD12 4 LVDSTEP12
1110 LVD12 3 LVDSTEP12
1100 LVD12 2 LVDSTEP12
1011 LVD12 1 LVDSTEP12
1010 LVD12 Default value at reset
1001 LVD12 1 LVDSTEP12
1000 LVD12 2 LVDSTEP12
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R LVFC LVFC LVF LVF
LVFCR LVFCH LVFCC LVFCA 0 0 LVFR LVFH LVFC LVFA 0 0
50 33 50 33
W w1c w1c w1c w1c w1c w1c
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 9-4. Status Register (PMC_SR)
1
This bit is not defined.
2
Reset value depends on whether RAM standby regulator switch reported a brownout condition.
Field Description
0–4 Reserved
5 Standby-RAM-supply low-voltage flag. This read-only bit indicates that a brownout condition was reported
LVFSTBY by the RAM standby regulator switch. Software can clear this bit by writing ‘1’ to the LVFCSTBY bit.
0 No occurrence.
1 LVD occurrence, or brownout, reported by the RAM standby regulator switch.
6 Bandgap ready. This read-only bit gets asserted when the PMC bandgap circuit has finished its startup
BGRDY procedure during power-up. The PMC LVDs are disabled (output negated) while BGRDY is negated.
0 Bandgap not ready. PMC LVDs disabled.
1 Bandgap ready. PMC LVDs enabled.
7 This bit is not defined.
U
8–12 Reserved
13 Standby-RAM-supply LVF clear. This write-only bit is used to clear the low-voltage flag reported by the RAM
LVFCSTBY standby regulator switch. Writing 1 to this bit informs the RAM standby regulator switch to clear LVFSTBY.
Writing 0 has no effect. Reading this bit always returns 0.
0 No effect.
1 Clears LVFSTBY.
14–15 Reserved
16 Reset-pin-supply LVF clear. This write-only bit is used to clear the low-voltage flag associated with the supply
LVFCR of the I/O segment that contains the reset pin. Writing 1 to this bit clears LVFR. Writing 0 has no effect.
Reading this bit always returns 0.
0 No effect.
1 Clears LVFR.
Field Description
17 VDDEH LVF clear. This write-only bit is used to clear the low-voltage flag associated with the monitored
LVFCH VDDEH supplies. Writing 1 to this bit clears LVFH. Writing 0 has no effect. Reading this bit always return 0.
0 No effect.
1 Clears LVFH.
18 VDDREG LVF clear. This write-only bit is used to clear the low-voltage flag associated with the VDDREG
LVFC50 voltage regulator supply. Writing 1 to this bit clears LVF50. Writing 0 has no effect. Reading this bit always
returns 0.
0 No effect.
1 Clears LVF50.
19 VDDSYN LVF clear. This write-only bit is used to clear the low-voltage flag associated with the VDDSYN 3.3
LVFC33 V supply. Writing 1 to this bit clears LVF33. Writing 0 has no effect. Reading this bit always returns 0.
0 No effect.
1 Clears LVF33.
20 Core-voltage-supply LVF clear. This write-only bit is used to clear the low-voltage flag associated with the
LVFCC core voltage supply. Writing 1 to this bit clears LVFC. Writing 0 has no effect. Reading this bit always returns
0.
0 No effect.
1 Clears LVFC.
21 VDDA LVF clear. This write-only bit is used to clear the low-voltage flag associated with the analog power
LVFCA input VDDA1. Writing 1 to this bit clears LVFA. Writing 0 has no effect. Reading this bit always return 0.
0 No effect.
1 Clears LVFA.
22–23 Reserved
24 Reset-pin-supply low-voltage flag. This read-only bit is the low-voltage flag associated with the supply of the
LVFR I/O segment that contains the reset pin. It is asserted when the supply falls below the corresponding LVD
threshold, and can be cleared by the CPU by writing 1 to the LVFCR bit. If the LVIER bit is also asserted, a
low-voltage interrupt is sent to the CPU. If LVRER is also asserted, a system reset will be generated, which
will clear LVFR and negate the interrupt request.
0 No occurrence.
1 LVD occurrence detected on the supply of the I/O segment that contains the reset pin.
25 VDDEH low-voltage flag. This read-only bit is the low-voltage flag associated with the monitored VDDEH
LVFH supplies. It is asserted when any monitored VDDEH supply falls below its corresponding LVD threshold, and
can be cleared by the CPU by writing 1 to the LVFCH bit. If the LVIEH bit is also asserted, a low-voltage
interrupt is sent to the CPU. If LVREH is also asserted, a system reset will be generated, which will clear
LVFH and negate the interrupt request.
0 No occurrence.
1 LVD occurrence detected on a monitored VDDEH supply.
26 VDDREG low-voltage flag. This read-only bit is the low-voltage flag associated with the VDDREG supply of
LVF50 the voltage regulator. It can be cleared by the CPU by writing 1 to the LVFC50 bit. If the LVIE5 bit is also
asserted, a low-voltage interrupt is sent to the CPU. If LVRE50 is also asserted, a system reset will be
generated, which will clear LVF50 and negate the interrupt request.
0 No occurrence.
1 LVD occurrence detected on the VDDREG supply of the voltage regulator.
Field Description
27 VDDSYN low-voltage flag. This read-only bit is the low-voltage flag associated with the VDDSYN 3.3 V
LVF33 supply. It is asserted when the 3.3 V supply falls below the corresponding LVD threshold, and can be cleared
by the CPU by writing 1 to the LVFC33 bit. If the LVIE33 bit is also asserted, a low-voltage interrupt is sent
to the CPU. If LVRE33 is also asserted, a system reset will be generated, which will clear LVF33 and negate
the interrupt request.
0 No occurrence.
1 LVD occurrence detected on the 3.3V supply.
28 Core-voltage-supply low-voltage flag. This read-only bit is the low-voltage flag associated with the core
LVFC voltage supply. It is asserted when the core voltage supply falls below the corresponding LVD threshold, and
can be cleared by the CPU by writing 1 to the LVFCC bit. If the LVIEC bit is also asserted, a low-voltage
interrupt is sent to the CPU. If LVREC is also asserted, a system reset will be generated, which will clear
LVFC and negate the interrupt request.
0 No occurrence.
1 LVD occurrence detected on the core voltage supply.
29 VDDA low-voltage flag. This read-only bit is the low-voltage flag associated with the analog power input
LVFA VDDA1. It is asserted when the VDDA1 supply falls below its corresponding LVD threshold, and can be
cleared by the CPU by writing 1 to the LVFCA bit. If the LVIEA bit is also asserted, a low-voltage interrupt is
sent to the CPU. If LVREA is also asserted, a system reset will be generated, which will clear LVFA and
negate the interrupt request.
0 No occurrence.
1 LVD occurrence detected on the VDDA1 supply.
30–31 Reserved
expected in absolute LVD trip points and voltage regulator output, so the system shall come up correctly
in any condition.
If an external regulator is used to generate the supply voltage, the allowed nominal range is VDD12, but
the start up value must be higher than the maximum LVD threshold LVD12 to clear POR and LVD flags
and exit the reset state.
All LVDs force reset at start-up. As soon as all of them are cleared, the trimming register can be loaded
from flash into the band gap. The low variation of band gap reference voltage after trim, reported in the
MPC5676R Microcontroller Data Sheet, allows the system to achieve high precision regulator target
voltage output (not considering transient effects on regulator loads) and LVD trip points.
voltage
(V) VDDREG
VDDSYN
VDD
time
Figure 9-5. PMC internal regulators nominal start-up sequence, rising slope may vary
A weak pull down of about 100 k is added to ensure the selection of the LDO regulator even when the
signal REGSEL is not connected at board level.
The bond diagram and over voltage protection is shown in Figure 9-6. Core LVD and flash supply are
provided by pad VDD33, which is also the default feedback signal for the 3.3V regulator loop. A high
voltage detect comparator switches the feedback point from VDD33 to the regulator output VDDSYN in
the event that this node raises above its maximum rating value, forcing the regulator to correct its DC point.
This feature protects the circuitry connected to the internal 3.3V supply in any event which disconnects
VDD33 and VDDSYN (e.g. a board failure or a bond wire failure).
Internal 3.3V
Supply
VDDREG
Vreg 3.3
Vbg
R
VDDSYN
R
R
+
R
R
-
Vbg
Tolerance of the 3.3V regulator, reported in the MPC5676R Microcontroller Data Sheet, assumes
appropriate decoupling capacitance on VDDSYN pin, maximum current load less than or equal to IDD33,
and a correct board layout with reduced parasitics. It excludes line and load variation above 10 kHz.
The regulator output voltage, VDD33OUT, is adjustable via software by writing to the field VDD33TRIM
of the correspondent trimming register PMC_TRIMR, which selects one of the 16 voltages spaced at
STEPV33 step and available through the relative resistor chain. The reset value of the 4-bit register is
“0000”.
The assertion and negation voltages are adjustable via software by writing to the LVD33TRIM field of the
PMC_TRIMR register, which selects one of the 16 voltages available through the appropriate tapped
output. The reset and default value of the 4-bit register is “0000”, corresponding to the nominal LVD33
voltage.
LVD scaled voltage can be measured via ADC by selecting the respective channel reported in Table 9-8.
During this measurement, the output of the LVD is temporarily forced to low level so that false events,
which may be caused by ADC reading, are discarded.
SMPS MODE
VDDREG VDDREG
SI3460
PWM
50kOhm
Controller
= Trimmed
REGSEL
NJD
VDDREG 2873
Vref
Band Gap
VRC1p2
Decoupling
LDO MODE
9.5.8 Trimming
During Power Up and Reset, the BandGap is untrimmed. This allows the MCU to come out of reset.
At the end of the Reset sequence, the BandGap is trimmed by the PMC. This trimming controls the
BandGap voltage, which is used as the reference for the Internal Regulators and LVD.
The BandGap Trim values are not visible and they cannot be altered or overwritten by the user.
The levels of the internal regulators and LVD, though, can be adjusted by the user by programming the
Trim Registers. This allows the user to control the internal regulator or LVD level within a range of +/- 8
steps from the default value. This is described in Section 9.4.2, “Trimming Register (PMC_TRIMR).
9.5.9 Interrupts
The PMC generates one interrupt request signal for each LVD source: VDDREG LVD, VDDSYN LVD,
VDD LVD, and VDDA1 LVD. The module also generates combined interrupt request signal which is
asserted whenever any of the individual interrupt request signals becomes asserted.
Specified Power
Supply Range
Power
Supply
Specified Vsupply
Range
Vsupply
Regulator feedback and LVD threshold signals propagated to ADC are a scaled down version of the
correspondent supply, by means of a resistive divider with programmable steps. The scaled signal read by
the ADC Vscaled will be approximately equal to the supply voltage Vsupply divided by the target voltage
(LVD or regulator output) Vtarget and multiplied by the band gap reference Vbg:
By measuring with ADC scaled supply voltage, supply voltage and bandgap voltage, it is possible to
calculate the approximate target LVD or regulator value. Vtarget is equal to: Vtarget=Vsupply*Vbg/Vadc.
During LVD measurement, the continuous time monitoring is temporarily disabled as the multiplexer
toggling could induce a false detection.
9.6 Initialization
The PMC module requires that its main supply voltage, VDDREG, rises above the POR level, so that the
band gap reference voltage can be enabled.
After the band gap has come up and stabilized, the 1.2V regulator soft start and optionally the 3.3V
regulator soft start begin.
When the internal regulator is used to generate 1.2V core supply, it is required to write “1100” to the
LVDCTRIM field before clock frequency is increased.
VDDREG
VDD12
*
Mandatory decoupling capacitor
network
VSS
VDDREG
REGSEL
VRCCTL
MCU
VDD12
VSS
Figure 9-11. VRC 1.2V buck SMPS LDO configuration with external MOS - Schottky diode
capacitor 6 x 4.7µF–20V Ceramic low ESR -One for each VDD pin
C3225X7R1E106M capacitor 2X10uF - 25V TDK high capacitance ceramic SMD (on VDD close
to coil)
C3225X7R1E225K capacitor 2x2.2uF - 25V TDK ceramic SMD (on VDD close to MCU)
capacitor 6 x 0.1uF - 20V Ceramic -One capacitor for each VDD pin
C3225X7R1E106M capacitor 2X10uF - 25V Supply decoupling cap - close to n-MOS drain
Software may distinguish which core it is executing on by reading the PIR (SPR 286) in Supervisor mode.
Table 10-1 lists the PIR reset values for each core. Note that software may change the value after reset.
Table 10-1. PIR reset values for each core
Core 0 0
Core 1 1
Performance Monitor
Registers1 PSU Registers1
Debug
10.3 Cache
This section lists the most commonly used registers, instructions, and features of Cache. For a complete
listing of all registers and features refer to z759n3 Core Reference Manual.
DCBZ32
DCECE
DCEDT
DCLOA
DCSLC
DCABT
DCLFC
DCWM
DCINV
DCWA
DCEA
DCLO
DCUL
WDD
DCEI
DCE
WID
0 0 0 0
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
This field also controls merging of store data into the linefill buffer while a cache linefill
is in progress. Store data will not be merged when write allocation is disabled. If DCWA
is non-zero, store data merging is enabled regardless of the type
(writethrough/copyback) of write.
14 — Reserved1
Data Cache Error Checking Enable
15 DCECE 0 Error Checking is disabled
1 Error Checking is enabled
Data Cache Error Injection
0 Cache Error Injection is disabled
1 Parity errors will be purposefully injected into every byte subsequently written into
the cache. The parity bit of each 8-bit data element written will be inverted. This
16 DCEI
includes writes due to store hits as well as writes due to cache line refills.
DCEI will cause injection of errors regardless of the setting of DCECE, although
reporting of errors will be masked while DCECE = 0.
17 — Reserved1
Data Cache Error Detection Type
00 Reserved (defaults to DCEDT=01(EDC) actions)
18:19 DCEDT 01 EDC Error Detection is selected for the tag array and parity is selected for the data
arrays
1x Reserved
Data Cache Snoop Lock Clear
0 Snoop has not invalidated a locked line
1 Snoop has invalidated a locked line
20 DCSLC
Indicates a cache line lock was cleared by a snoop operation which caused an
invalidation. This bit is set by hardware and will remain set until cleared by software
writing 0 to this bit location.
Data Cache Unable to Lock
Indicates a lock set instruction was not effective in locking a cache line. This bit is set
21 DCUL
by hardware on an “unable to lock” condition (other than lock overflows), and will
remain set until cleared by software writing 0 to this bit location.
ICEDT
ICLOA
ICABT
ICLFC
ICINV
ICEA
ICLO
ICUL
ICEI
ICE
0 0 0 0
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
0:14 — Reserved1
Instruction Cache Error Checking Enable
15 ICECE 0 Error Checking is disabled
1 Error Checking is enabled
Instruction Cache Error Injection Enable
0 Cache Error Injection is disabled
1 When ICEDT=01, a double-bit error will be injected into each doubleword written into
16 ICEI the cache by inverting the two uppermost parity check bits (p_chk[0:1]).
ICEI will cause injection of errors regardless of the setting of ICECE, although reporting
of errors will be masked when ICECE=0.
17 — Reserved1
Instruction Cache Error Detection Type
00 Reserved (defaults to ICEDT=01(EDC) actions)
18:19 ICEDT
01 EDC Error Detection is selected
1x Reserved
20 — Reserved1
10.3.2.3 L1FINV0
The SPR number for L1FINV0 is 1016 in decimal. The L1FINV0 register is shown in Figure 10-6.
CCMD
CWAY
CSET
0 0 0
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
10.3.2.4 L1FINV1
The SPR number for L1FINV1 is 959 in decimal. The L1FINV1 register is shown in Figure 10-7.
CCMD
CWAY
CSET
0 0 0
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
CCU_BASE=
Register Size Access Mode
0xFFF50000
31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
S C C M M M M E
C C C C S N
R R P P 3 2 1 0
P P P P R B
S 1 0
1 0 1 0 S
T W W W W
I I Reserved M M M M Reserved T
E E I I
F E E E E E E
R R D D
L N N N N N N E
R R L L
A E E N
G
W
Reset 0 0 0 0 0 0 1 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Field Description
31-30 Core Processor 1 Error. This field reperesents a flag maintained by the CCU for signaling the presence of a captured
CP1ERR snoop error or the occurence of a queue overflow. The error details are contained in CCU_EAR1 and
CCU_EDR1. CCU_CESR[31] is set when the snoop queue for Core1 has overflowed; the address and
attributes of the global write which caused the queue overflow are recorded in CCU_EAR1 and CCU_EDR1.
CCU_CESR[30] is set when the hardware detects a snoop error and records the faulting address and
attributes. This field is cleared when the corresponding bits are written as a logical one. If another Core1 error
occurs before CP1ERR bit is cleared, CP1ERR remains set while CCU_EAR1 and CCU_EDR1 capture
address and attributes for the most recent error event.
Field Description
29-28 Core Processor 0 Error. This field reperesents a flag maintained by the CCU for signaling the presence of a captured
CP0ERR snoop error or the occurence of a queue overflow. The error details are contained in CCU_EAR0 and
CCU_EDR0. CCU_CESR[29] is set when the snoop queue for Core0 has overflowed; the address and
attributes of the global write which caused the queue overflow are recorded in CCU_EAR0 and CCU_EDR0.
CCU_CESR[28] is set when the hardware detects a snoop error and records the faulting address and
attributes. This field is cleared when the corresponding bits are written as a logical one. If another Core0 error
occurs before CP0ERR bit is cleared, CP0ERR remains set while CCU_EAR0 and CCU_EDR0 capture
address and attributes for the most recent error event.
27 Software reset flag. This field represents a flag maintained by the CCU to indicate a software reset event has taken
SRST place. A software reset of the CCU is invoked by programming the CCU_CESR[SRST_EN] field.
FLAG
0 The last CCU reset event was a hardware reset event.
1 The last CCU reset event was a software-invoked reset event.
25 Core Processor 1 Idle. This read-only staus flag indicates when Core1 snoop queue is empty.
CP1IDLE 0 Core1 snoop queue not empty; core 1 snoop queue is busy processing valid snoop requests to core 1.
1 Core1 snoop queue is empty.
24 Core Processor 0 Idle. This read-only staus flag indicates when Core0 snoop queue is empty.
CP0IDLE 0 Core0 snoop queue not empty; core 0 snoop queue is busy processing valid snoop requests to core 0.
1 Core0 snoop queue is empty.
21 Core Processor 1 Interrupt Enable. This bit enables interrupt generation upon detection of a Core1 snoop requests
CP1IEN which results in an error.
0 CCU generates an interrupt request upon detection of a Core1 snoop that terminated with error.
1 CCU does not generate an interrupt request upon detection of a Core1 snoop request that terminated with
error.
20 Core Processor 0 Interrupt Enable. This bit enables interrupt generation upon detection of a Core0 snoop requests
CP0IEN which results in an error.
0 CCU generates an interrupt request upon detection of a Core0 snoop that terminated with error.
1 CCU does not generate an interrupt request upon detection of a Core0 snoop request that terminated with
error.
15 Master 3 Write Monitor Enable. This bit enables monitoring of eDMA_B for global writes
M3WMEN 0 Disable eDMA_B monitoring. Global writes from eDMA_B will not initiate any snoop requests.
1 Enable eDMA_B monitoring for global writes.
14 Master 2 Write Monitor Enable. This bit enables monitoring of eDMA_A for global writes
M2WMEN 0 Disable eDMA_A monitoring. Global writes from Master2 will not initiate any snoop requests.
1 Enable eDMA_A monitoring for global writes.
13 Master 1 Write Monitor Enable. This bit enables monitoring of Core 1 for global writes
M1WMEN 0 Disable Core 1 monitoring. Global writes from Master1 will not initiate any snoop requests.
1 Enable Core 1 monitoring for global writes.
Field Description
12 Master 0 Snoop Enable. This bit enables monitoring of Core 0 for global writes
M0WMEN 0 Disable Core 0 monitoring. Global writes from Master0 will not initiate any snoop requests.
1 Enable Core 0 monitoring for global writes.
11-2 Reserved
1 Software reset enable. Writing a ‘1’ to this bit invokes a software-driven reset of the CCU. On the next cycle following
SRST_EN the programming of CCU_CESR[SRST_EN], all programming model registers in the CCU will be reset, and all
snoop queue entries will be invalidated. CCU_CESR[SRST_FLAG] will be set to ‘1] to indicate a sofware-driven
reset of the CCU has occured. Writing a ‘0’ to this bit has no effect. Reading this bit will return ‘0’.
0 No software-driven reset is requested. Writing a ‘0’ to this field has no effect. Reading this bit will always return
‘0’.
1 Invoke software-driven reset.
31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
R EADDR
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Field Description
31-0 Error Address. This read-only field is the reference address associated with the global write which resulted in a snoop
EADDR error or overflow event.
31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 - - 0 0 0 0 0 0 0 0 0 0 0 - - -
Field Description
31-28 Error Master. This read-only field holds the AHB master ID associated with the global write which resulted in a snoop
EMSTR error or overflow event.
27-24 Reserved
23-16 Error Time Stamp. This read-only fields holds the time stamp value associated with the snoop error or overflow event.
ESTAMP The time stamp value is based on a free-running 8-bit timer which begins counting upon assertion of
CCU_CESR[ENB].
Upon a snoop error event, this field captures the value of the time stamp at the time the snoop request was loaded
into the queue.
Upon a queue overlow event, this field captures the value of the time stamp at the time the overflow condition is
detected.
13-8 Error Protection Attribute. This read-only field holds thes AHB protection attributes which resulted in a snoop error
EPROT or overflow event.
7-3 Error snoop response. This read-only field holds the snoop response associated with the snoop which terminated
ERESP with error. This field is cleared when CCU_EDRn is loaded on an overflow event. Upon a queue overflow event, this
field reads as all zeroes.
cc - # of collapsed reqests; 00-no collapsin, 01-two requests combined, 10-three requests combined, 11-four
requests combined.
31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
R O E
I I
W F F
Reset - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 0 0
Field Description
1 Overflow Interrupt Flag. This field indicates an outstanding interrupt request as a result of a a queue overflow. The
OIF flag and interrupt are cleared by writing a ‘1’ to this bit. Writing a ‘0’ to this bit has no effect.
0 No interrupt request.
1 Interrupt request due to snoop termination with error.
1 Error Interrupt Flag. This field indicates an outstanding interrupt request as a result of a snoop which terminated with
EIF error if CCU_CESR[MnIEN]. The flag and interrupt are cleared by writing a ‘1’ to this bit. Writing a ‘0’ to this bit has
no effect.
0 No interrupt request.
1 Interrupt request due to snoop termination with error.
10.4 MMU
This section lists the most commonly used registers, instructions, and features of MMU. For a complete
listing of all registers and features refer to z759n3 Core Reference Manual.
10.4.1 Overview
The MPC5676R Memory Management Unit is a 32-bit PowerPC Book E compliant implementation, with
the following feature set:
• Translates from 32-bit effective to 32-bit real addresses
• 32-entry fully associative TLB with support for twenty-three page sizes (1K, 2K, 4K, 8K, 16K,
32K, 64K, 128K, 256K, 512K, 1M, 2M, 4M, 8M, 16M, 32M, 64M, 128M, 256M, 512M, 1G, 2G,
4G)
• Hardware assist for TLB miss exceptions
• Software managed by tlbre, tlbwe, tlbsx, tlbsync, and tlbivax instructions
tlbre tlbre
tlb read entry
31 0 1110110010 0
0 5 6 20 21 30 31
tlbwe tlbwe
tlb write entry
31 0 1111010010 0
0 5 6 20 21 30 31
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
The DEAR register can be read or written using the mfspr and mtspr instructions.
TLB1_FI
0 0
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
0:29
— Reserved1
[32:61]
TLB1 flash invalidate
0 - No flash invalidate
1 - TLB1 invalidation operation
30 When written to a ‘1’, a TLB1 invalidation operation is initiated by hardware. Once
TLB1_FI
[62] complete, this bit is reset to ‘0’. Writing a ‘1’ while an invalidation operation is in
progress will result in an undefined operation. Writing a ‘0’ to this bit while an
invalidation operation is in progress will be ignored. TLB1 invalidation operations
require 3 cycles to complete.
31
— Reserved1
[63]
1
These bits are not implemented, will be read as zero, and writes are ignored.
ESEL
NV
0 0 0
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
The MAS1 register is shown in Figure 10-15. Fields are defined in Table 10-13.
IPROT
VALID
TSIZ
TID
0 0 TS 0
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
16:18 Reserved1
—
[48:50]
Translation address space
19
TS This bit is compared with the IS or DS fields of the MSR (depending on the type of
[51]
access) to determine if this TLB entry may be used for translation.
Entry’s page size
Supported page sizes are:
0b00000 - 1KB
0b00001 - 2KB
0b00010 - 4KB
0b00011 - 8KB
0b00100 - 16KB
0b00101 - 32KB
0b00110 - 64KB
0b00111 - 128KB
0b01000 - 256KB
0b01001 - 512KB
0b01010 - 1MB
20:24
TSIZE 0b01011 - 2MB
[52:56]
0b01100 - 4MB
0b01101 - 8MB
0b01110 - 16MB
0b01111 - 32MB
0b10000 - 64MB
0b10001 - 128MB
0b10010 - 256MB
0b10011 - 512MB
0b10100 - 1GB
0b10101 - 2GB
0b10110 - 4GB
The MAS2 register is shown in Figure 10-16. Fields are defined in Table 10-14.
V
EPN L W I M G E
0
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
The MAS3 register is shown in Figure 10-17. Fields are defined in Table 10-15.
U U U U U S U S U S
RPN
0 1 2 3 X X W W R R
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
The MAS4 register is shown in Figure 10-18. Fields are defined in Table 10-16.
TLBSELD (01)
TIDSELD
TSIZED
VLED
WD
MD
GD
ED
ID
0 0 0 0
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
0:1 Reserved1
—
[32:33]
Default TLB selected
2:3
TLBSELD 00 TLB0
[34:35]
01 TLB1
4:13 Reserved1
—
[36:45]
Default PID# to load TID from
00 PID0
14:15
TIDSELD 01 Reserved, do not use
[46:47]
10 Reserved, do not use
11 TIDZ (8’h00)) (Use all zeros, the globally shared value)
16:19 Reserved1
—
[48:51]
20:24 Default TSIZE value
TSIZED
[52:56]
25 Reserved1
—
[57]
26 Default VLE value
VLED
[58]
27:31 Default WIMGE values
DWIMGE
[59:63]
1
These bits are not implemented, will be read as zero, and writes are ignored.
The MAS6 register is shown in Figure 10-19. Fields are defined in Table 10-17.
SAS
0 SPID 0
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
0:7 Reserved1
—
[32:39]
8:15 PID value for searches
SPID
[40:47]
16:30 Reserved1
—
[48:62]
31 AS value for searches
SAS
[63]
1 These bits are not implemented, will be read as zero, and writes are ignored.
10.5 Exceptions
This section provides an overview of core exceptions. For detailed explanation see z759n3 Core Reference
Manual.
VLEMI
PUO
PPR
SPE
PTR
DLK
MIF
PIE
PIL
ILK
BO
AP
FP
ST
0 0 0 0 0 0
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
0:3 Reserved —
—
(32:35)
4 Illegal Instruction exception Program
PIL
(36)
5 Privileged Instruction exception Program
PPR
(37)
6 Trap exception Program
PTR
(38)
7 Floating-point operation Program
FP
(39)
Store operation Alignment
8
ST Data Storage
(40)
Data TLB
9 Reserved —
—
(41)
10 Data Cache Locking Data Storage
DLK
(42)
11 Instruction Cache Locking Data Storage
ILK
(43)
12 Reserved —
AP
(44)
13 Unimplemented Operation exception Program
PUO
(45)
UCLE
PMM
SPE
FE1
FE0
ME
PR
CE
DE
DS
EE
FP
RI
IS
0 0 0 0 0 0 0
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
0:4 Reserved
—
(32:36)
User Cache Lock Enable
5 0 Execution of the cache locking instructions in user mode (MSRPR=1) disabled; DSI
UCLE
(37) exception taken instead, and ILK or DLK set in ESR.
1 Execution of the cache lock instructions in user mode enabled.
SPE/EFPU Available
6 0 Execution of SPE and EFPU APU vector instructions is disabled; SPE/EFPU Unavailable
SPE
(38) exception taken instead, and SPE bit is set in ESR.
1 Execution of SPE and EFPU APU vector instructions is enabled.
7:12 Reserved
—
(39:44)
13 Reserved. Write a 0 for future compatibility.
—
(45)
Critical Interrupt Enable
14
CE 0 Critical Input and Watchdog Timer interrupts are disabled.
(46)
1 Critical Input and Watchdog Timer interrupts are enabled.
15 Reserved
—
(47)
External Interrupt Enable
16
EE 0 External Input, Decrementer, and Fixed-Interval Timer interrupts are disabled.
(48)
1 External Input, Decrementer, and Fixed-Interval Timer interrupts are enabled.
Problem State
0 The processor is in supervisor mode, can execute any instruction, and can access any
17
PR resource (e.g. GPRs, SPRs, MSR, etc.).
(49)
1 The processor is in user mode, cannot execute any privileged instruction, and cannot
access any privileged resource.
Floating-Point Available
18 0 Floating point unit is unavailable. The processor cannot execute floating-point instructions,
FP
(50) including floating-point loads, stores, and moves.
1 Floating-point unit is available. The processor can execute floating-point instructions.
BUS_WRERR
BUS_DRERR
BUS_IRERR
DC_DPERR
EXCP_ERR
DC_TPERR
DC_LKERR
IC_DPERR
IC_TPERR
IC_LKERR
CP_PERR
SNPERR
MCP
MEA
MAV
NMI
ST
LD
IF
0 0 0 0
G
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
Table 10-20 describes MCSR fields. The MCSR indicates the source of a machine check condition.
All bits in the MCSR are implemented as “write ‘1’ to clear”. Software in the machine check handler is
expected to clear the MCSR bits it has sampled prior to re-enabling MSRME to avoid a redundant machine
check exception and to prepare for updated status bit information on the next machine check interrupt.
Hardware will not clear a bit in the MCSR other than at reset.
Note that any set bit in the MCSR other than status-type bits will cause a subsequent machine check
interrupt once MSRME=1.
Exception
Bit Name Description Recoverable
Type1
4 ISI, ITLB, or Bus Error on first instruction fetch for an Async Mchk Precise
EXCP_ERR
(36) exception handler
Exception
Bit Name Description Recoverable
Type1
Exception
Bit Name Description Recoverable
Type1
27 Read bus error on Instruction fetch or linefill Async Mchk Precise if data
BUS_IRERR
(59) used
28 Read bus error on data load or linefill Async Mchk Precise if data
BUS_DRERR
(60) used
29 Write bus error on store or cache line push Async Mchk Unlikely
BUS_WRERR
(61)
Vector Base 0
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
Vector Base
This field is used to define the base location of the vector table, aligned to a 64KB boundary. This
0:15
Vec Base field provides the high-order 16 bits of the location of all interrupt handlers. The contents of the
(32:47)
IVORxx register appropriate for the type of exception being processed are concatenated with the
IVPR Vector Base to form the address of the handler in memory.
16:31 Reserved
—
(48:63)
0 Vector Offset 0
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
0:15 Reserved
—
(32:47)
Vector Offset
16:27 Vector
This field is used to provide a quadword index from the base address provided by the IVPR to
(48:59) Offset
locate an interrupt handler.
28:31 Reserved
(60:63) —
CSRR0 Set to the effective address of the instruction that the processor would have attempted to execute next
if no exception conditions were present.
CSRR1 Set to the contents of the MSR at the time of the interrupt
MSR UCLE 0 FP 0 FE1 0
SPE 0 ME — IS 0
WE 0 FE0 0 DS 0
CE 0 DE —/01 PMM 0
EE 0 RI —
PR 0
ESR Unchanged
MCSR Unchanged
DEAR Unchanged
Vector IVPR0:15 || IVOR016:27 || 4b0000 (autovectored)
IVPR0:15 || p_voffset[0:11] || 4b0000 (non-autovectored)
1
DE is cleared when the Debug APU is disabled. Clearing of DE is optionally supported by control in HID0 when the
Debug APU is enabled.
MCSRR0 On a best-effort basis Zen sets this to the address of some instruction that was executing or about to
be executing when the machine check condition occurred.
MCSRR1 Set to the contents of the MSR at the time of the interrupt
MSR UCLE 0 FP 0 FE1 0
SPE 0 ME 0 IS 0
WE 0 FE0 0 DS 0
CE 0 DE 0/—1 PMM 0
EE 0 RI 0
PR 0
ESR Unchanged
MCSR Updated to reflect the source(s) of a machine check. Hardware only sets appropriate bits, no previously
set bits are cleared by hardware.
MCAR See
Vector IVPR0:15 || IVOR116:27 || 4b0000
1
DE is cleared when the Debug APU is disabled. Clearing of DE is optionally supported by control in HID0 when the
Debug APU is enabled.
The Machine Check Syndrome register is provided to identify the source(s) of a machine check, and in
conjunction with MCSRR1RI, may be used to identify recoverable events.
Interrupt Vector
Interrupt Type Offset Causing Conditions
Register
1. Access control.
2. Byte ordering due to misaligned instruction across page boundary to
pages with mismatched VLE bits, or access to page with VLE set, and E
Instruction Storage IVOR 3
indicating little-endian.
3. Misaligned Instruction fetch due to a change of flow to an odd halfword
instruction boundary on a BookE (non-VLE) instruction page.
SRR0 Set to the effective address of the instruction that the processor would have attempted to execute next
if no exception conditions were present.
SRR1 Set to the contents of the MSR at the time of the interrupt
MSR UCLE 0 FP 0 FE1 0
SPE 0 ME — IS 0
WE 0 FE0 0 DS 0
CE — DE — PMM 0
EE 0 RI —
PR 0
ESR Unchanged
MCSR Unchanged
DEAR Unchanged
Vector IVPR0:15 || IVOR416:27 || 4b0000
IVPR0:15 || p_voffset[0:11] || 4b0000 (non-autovectored)
IVOR4 is the vector offset register used by auto-vectored External Input interrupts to determine the
interrupt handler location. Zen also provides the capability to directly vector External Input interrupts to
multiple handlers by allowing a External Input interrupt request to be accompanied by a vector offset.
Zen will invoke a Privileged Instruction program exception on attempted execution of the following
instructions when MSRPR=1 (user mode):
• A privileged instruction
• mtspr and mfspr instructions which specify a SPRN value with SPRN5=1 (even if the SPR is
undefined).
Zen will invoke an Trap exception on execution of the tw and twi instructions if the trap conditions are
met and the exception is not also enabled as a Debug interrupt.
Table 10-30 lists register settings when a Program interrupt is taken.
Table 10-30. Program Interrupt—Register Settings
MCSR Unchanged
DEAR Unchanged
Vector IVPR0:15 || IVOR616:27 || 4b0000
SRR0 Set to the effective address of the instruction following the sc instruction.
SRR1 Set to the contents of the MSR at the time of the interrupt
SRR0 Set to the effective address of the instruction that the processor would have attempted to execute next
if no exception conditions were present.
SRR1 Set to the contents of the MSR at the time of the interrupt
MSR UCLE 0 FP 0 FE1 0
SPE 0 ME — IS 0
WE 0 FE0 0 DS 0
CE — DE — PMM 0
EE 0 RI —
PR 0
ESR Unchanged
MCSR Unchanged
DEAR Unchanged
Vector IVPR0:15 || IVOR1016:27 || 4b0000
SRR0 Set to the effective address of the instruction that the processor would have attempted to execute next
if no exception conditions were present.
SRR1 Set to the contents of the MSR at the time of the interrupt
MSR UCLE 0 FP 0 FE1 0
SPE 0 ME — IS 0
WE 0 FE0 0 DS 0
CE — DE — PMM 0
EE 0 RI —
PR 0
ESR Unchanged
MCSR Unchanged
DEAR Unchanged
Vector IVPR0:15 || IVOR1116:27 || 4b0000
CSRR0 Set to the effective address of the instruction that the processor would have attempted to execute next
if no exception conditions were present.
CSRR1 Set to the contents of the MSR at the time of the interrupt
CSRR0/ Set to the effective address of the excepting instruction for IAC, BRT, RET, CRET, and TRAP.
DSRR01 Set to the effective address of the next instruction to be executed following the excepting instruction for DAC
and ICMP.
For a UDE, IRPT, CIRPT, DCNT, or DEVT type exception, set to the effective address of the instruction that
the processor would have attempted to execute next if no exception conditions were present.
CSRR1/ Set to the contents of the MSR at the time of the interrupt
DSRR1
SRR0 Set to the effective address of the instruction following the excepting EFPU instruction.
SRR1 Set to the contents of the MSR at the time of the interrupt
MSR UCLE 0 FP 0 FE1 0
SPE 0 ME — IS 0
WE 0 FE0 0 DS 0
CE — DE — PMM 0
EE 0 RI —
PR 0
ESR SPE, [VLEMI]. All other bits cleared.
MCSR Unchanged
DEAR Unchanged
Vector IVPR0:15 || IVOR3416:27 || 4b0000
wait wait
Wait for Interrupt
wait
0 5 6 10 11 15 16 20 21 31
0 1 1 1 1 1 /// 0 0 0 0 1 1 1 1 1 0 /
CACHE
WORD
CWAY
CSET
R/W
T/D
GO
0 0 0
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
Table 10-42 provides bit definitions for the Cache Debug Access Control Register.
Table 10-42. Cache Debug Access Control Register Definition
Tag / Data
0 T/D 0 Data array selected
1 Tag array selected
1 - Reserved1
Cache Way
2:3 CWAY
Specifies the cache way to be selected
4:5 - Reserved1
Cache Set:
6:12 CSET
Specifies the cache set to be selected
Word (Data array access only, I or D cache)
13:15 WORD
Specifies one of eight words of selected set
Parity check bits2 (I or D cache)
EDC Mode (L1CSR[0,1][D,I]CEDT = 01): Dcache Data array: Byte parity bits. One bit per data
PARITY byte. bit 16: Parity for byte 0, bit 17: Parity for byte 1.... bit 23: Parity for byte 7.
/ EDC
16:23
CHECK Icache Data Array: parity check bits for data. Bits 16:23 correspond to p_dchk[0:7] (See the
BITS Data Checkbit Generation table in the z759n3 Core Reference Manual).
Tag Array: parity check bits for tag. Bits 16:21 correspond to p_tchk[0:5] (See the Tag Checkbit
Generation table in the z759n3 Core Reference Manual). bits 22:23 reserved.
24:27 - Reserved1
Cache Select
Specifies the cache to be selected
28 CACHE
0 Selects the data cache for the operation.
1 Selects the instruction cache for the operation.
Read / Write:
0 Selects write operation. Write the data in the CDADATA register to the location specified by
this CDACNTL register.
29 R/W
1 Selects read operation. Read the cache memory location specified by this CDACNTL
register and store the resulting data in the CDADATA register and store the parity bits in this
CDACNTL register.
GO command bits
00 Inactive or complete (no action taken) hardware sets GO=00 when an operation is complete
30:31 GO
01 Read or write cache memory location specified by this CDACNTL register.
1x Reserved
1 These bits are not implemented and should be written zero for future compatibility.
2
Cache parity checkers assume odd parity when using parity protection. EDC coding is used otherwise.
TAG or DATA
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
Table 10-43 provides bit definitions for the Cache Debug Access Data Register.
Table 10-43. Cache Debug Access Data Register Bit Definitions
TAG Array Access Data - when accessing the tag array of either cache:
0:21 - Tag compare bits
22 - Reserved
TAG
23 - Valid bit
24:27 - Lock bits. These four bits should have the same value, 1-Locked, 0-Unlocked.
28:30 - Dirty bits - (data cache only). These three bits should have the same value, 1-Dirty, 0-Clean.
0:31
DATA Array Access Data (Bytes 0:3 of the selected word) - when accessing the data array of either
cache:
0:7 - byte 0
DATA
8:15 - byte 1
16:23 - byte 2
24:31 - byte 3
11.1.1 Overview
The XBAR allows concurrent transactions to occur from any master port to any slave port. It is possible
for all master ports and slave ports to be in use at the same time as a result of independent master requests.
If a slave port is simultaneously requested by more than one master port, arbitration logic selects the higher
priority master and grant it ownership of the slave port. All other masters requesting that slave port are
stalled until the higher priority master completes its transactions.
By default, requesting masters are granted access based on a fixed priority. A round-robin priority mode
also is available. In this mode, requesting masters are treated with equal priority and are granted access to
a slave port in round-robin fashion, based upon the ID of the last master to be granted access. A block
diagram of the XBAR is shown in Figure 11-1.
The XBAR can place a slave port in a low-power park mode to avoid dissipating any power transitional
address, control or data signals when the master port is not actively accessing the slave port. There is a
one-cycle arbitration overhead for exiting low-power park mode.
Master modules
Crossbar Switch
Slave modules
.... Slave
Slave Slave
Table 11-1 gives the crossbar switch port for each master and slave, and the assigned and fixed ID number
for each master. The following table shows the master ID numbers as they relate to the master port
numbers:
Table 11-1. XBAR Switch Ports
Port
Module Master ID
Type Number
11.1.3 Features
• Multiple master and slave ports with programmable priorities and attributes.
• 32-bit address, 64-bit data paths
• Fully concurrent transfers between independent master and slave ports
NOTE
XBAR_MPR must be written with a read/modify/write for code
compatibility.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 1 1 1 0 0 0
MSTR6 MSTR5 MSTR4
W 0 1 1 1 0 0 0
Reset 0 1 1 1 0 1 1 0 0 1 0 1 0 1 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R 0 0 0 0
MSTR3 MSTR2 MSTR1 MSTR0
W 0 0 0 0
Reset 0 0 1 1 0 0 1 0 0 0 0 1 0 0 0 0
Field Description
5–7 Master 6 priority. Set the arbitration priority for master port 6 on the associated slave port.
MSTR6 000 Master 6 has the highest priority when accessing slave port n.
....
101 Master 6 has the lowest priority when accessing slave port n.
110–111 Invalid values
8 Reserved, must be cleared.
9–11 Master 5 priority. Set the arbitration priority for master port 5 on the associated slave port.
MSTR5 000 Master 5 has the highest priority when accessing slave port n.
....
101 Master 5 has the lowest priority when accessing slave port n.
110–111 Invalid values
12 Reserved, must be cleared.
Field Description
13–15 Master 4 priority. Set the arbitration priority for master port 4 on the associated slave port.
MSTR4 000 Master 4 has the highest priority when accessing slave port n.
....
101 Master 4 has the lowest priority when accessing slave port n.
110–111 Invalid values
16 Reserved, must be cleared.
17–19 Master 3 priority. Set the arbitration priority for master port 3 on the associated slave port.
MSTR3 000 Master 3 has the highest priority when accessing slave port n.
....
101 Master 3 has the lowest priority when accessing slave port n.
110–111 Invalid values
20 Reserved, must be cleared.
21–23 Master 2 priority. Set the arbitration priority for master port 2 on the associated slave port.
MSTR2 000 Master 2 has the highest priority when accessing slave port n.
....
101 Master 2 has the lowest priority when accessing slave port n.
110–111 Invalid values
24 Reserved, must be cleared.
25–27 Master 1 priority. Set the arbitration priority for master port 1 on the associated slave port.
MSTR1 000 Master 1 has the highest priority when accessing slave port n.
....
101 Master 1 has the lowest priority when accessing slave port n.
110–111 Invalid values
28 Reserved, must be cleared.
29–31 Master 0 priority. Set the arbitration priority for master port 0 on the associated slave port.
MSTR0 000 Master 0 has the highest priority when accessing slave port n.
....
101 Master 0 has the lowest priority when accessing slave port n.
110–111 Invalid values
The PARK field indicates which master port this slave port parks on when no active access attempts are
being made to the slave and the parking control field is set to park on a specific master.
XBAR_SGPCRn[PARK] must only be programmed to select master ports that are actually available on
the device, otherwise undefined behavior results. The low-power park feature can result in an overall
power savings if the slave port is not saturated; however, an extra clock of latency results whenever any
master tries to access a slave (not being accessed by another master) because it is not parked on any master.
The XBAR_SGPCR can only be accessed in supervisor mode with 32-bit accesses. After the RO (read
only) bit is set in the XBAR_SGPCR, the XBAR_SGPCR and the SBAR_MPR can only be read. Attempts
to write to them have no effect and results in an error.
NOTE
Some of the unused bits in the SGPCRn registers are writeable and readable,
but they serve no function. Setting any of these bits has no effect on the
operation of this module.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
RO1
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R 0 0 0 0 0 0 0 0 0
ARB PCTL PARK
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
1 After this bit is set, only a hardware reset clears it.
Field Description
0 Read only. Used to force all of a slave port’s registers to be read only. After written to 1, it can only be cleared by
RO hardware reset.
0 All this slave port’s registers can be written.
1 All this slave port’s registers are read only and cannot be written (attempted writes have no effect and result
in an error response).
1–21 Reserved, must be cleared.
Field Description
22–23 Arbitration mode. Used to select the arbitration policy for the slave port. This field is initialized by hardware reset.
ARB 00 Fixed priority using MPR
01 Round-robin priority
10 Invalid value
11 Invalid value
24–25 Reserved, must be cleared.
26–27 Parking control. Used to select the parking algorithm used by the slave port. This field is initialized by hardware
PCTL reset.
00 When no master is making a request, the arbiter parks the slave port on the master port defined by the PARK
control field.
01 POL—Park on last. When no master is making a request, the arbiter parks the slave port on the last master
to own the slave port.
10 LPP—Low-power park. When no master is making a request, the arbiter parks the slave port on no master
and drives all slave port outputs to a safe state.
11 Invalid value
28 Reserved, must be cleared.
29–31 Park. Used to determine which master port this slave port parks on when no masters are actively making
PARK requests. PCTL must be set to 0b00.
000 Park on master port 0
001 Park on master port 1
010 Park on master port 2
011 Park on master port 3
100 Park on master port 4
101 Park on master port 5
110 Park on master port 6
111 Invalid value
Valid parking options vary by slave port number, as given in Table 11-6
0 Flash 0, 1
1 EBI 0, 1, 2, 3, 4, 5, 6
2 SRAM 0, 1, 2, 3, 4, 5, 6
3 Flash 2, 3, 4, 5, 6
6 PBRIDGE_A 0, 1, 2, 3, 4, 5, 6
7 PBRIDGE_B 0, 1, 2, 3, 4, 5, 6
11.3.1 Overview
The main goal of the XBAR is to increase overall system performance by allowing multiple masters to
communicate concurrently with multiple slaves. To maximize data throughput, it is essential to keep
arbitration delays to a minimum.
This section examines data throughput from the point of view of masters and slaves, detailing when the
XBAR stalls masters, or inserts bubbles on the slave side.
11.3.6 Arbitration
XBAR supports two arbitration schemes; a simple fixed-priority comparison algorithm, and a round-robin
fairness algorithm. The arbitration scheme is independently programmable for each slave port.
Parking may continue to be used in round-robin mode, but affects the round-robin pointer unless the
parked master actually performs a transfer. Hand-off to the next master in line occurs after one cycle of
arbitration.
The slave port does an arbitration check at every clock edge to ensure that the proper master (if any) has
control of the slave port.
A new requesting master must wait until the end of the fixed-length burst transfer, before it is granted
control of the slave port. If the new requesting master’s priority level is lower than that of the master that
currently has control of the slave port, the new requesting master is forced to wait until the master that
currently has control of the slave port completes its access.
11.3.6.2.1 Parking
If no master is currently requesting the slave port, the slave port is parked. The slave port parks in one of
three places, indicated by the value of the PCTL field in the XBAR_SGPCR.
• If park-on-specific master mode is selected, the slave port parks on the master designated by the
PARK field. When the master accesses the slave port again, a one clock arbitration penalty is
incurred only for an access request made by another master port to the slave port. No other
arbitration penalties are incurred. All other masters pay a one clock penalty.
• If park-on-last (POL) mode is selected, then the slave port parks on the last master to access it,
passing that master’s signals through to the slave bus. When the master accesses the slave port
again, no other arbitration penalties are incurred except that a one clock arbitration penalty is
incurred for each access request to the slave port made by another master port. All other masters
pay a one clock penalty.
• If the low-power-park (LPP) mode is selected, then the slave port enters low-power park mode. It
is not under control by any master and does not transmit any master signals to the slave bus. All
slave bus activity halts because all slave bus signals are not toggling. This saves power if the slave
port is not used for some time. However, when a master does make a request to a slave port parked
in low-power-park, a one clock arbitration delay is incurred to get ownership of the slave port.
12.2 Features
The CRC module on the MPC5676R includes the following features:
• Three “contexts”. A context is a CRC engine with its own independent set of configuration and
data registers. The MPC5676R CRC module can process up to three separate data streams
concurrently.
• Each context supports CRC-16-CCITT and CRC-32 ethernet polynomials
• Bit-swap and bit-inversion operations can be applied on the final CRC signature
• Support for byte/half-word/word width of the input data stream
• Computation is performed with zero wait states
1.16-bit operations must be aligned to 16-bit boundaries, i.e., bits 0-15 or bits 16-31. Any unaligned operation results
in a bus error.
2.Byte operations must be aligned to 8-bit boundaries, i.e., bits 0-7, bits 8-15, bits 16-23, or bits 24-31. Any unaligned
operation results in a bus error.
Start
Configure Context
Select polynomial, swap, inversion
via the CRC_CFG register
End of
Data Stream
Reached
16 12 5
X +X +X +1
32 26 23 22 16 12 11 10 8 7 5 4 2
X +X +X +X +X +X +X +X +X +X +X +X +X +X+1
The writes can be by the processor core or by DMA transfer. The writes continue until the end of the data
stream is reached.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R 0 0 0 0 0 0 0 0 0 0 0 0 0
POLYG
SWAP
INV
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0/11 0 0
Field Description
0-28 Reserved
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R INP
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R INP
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Field Description
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R CSTAT
Reset 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R CSTAT
Reset 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1
Field Description
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R OUTP
Reset 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R OUTP
Reset 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1
Field Description
Transmission Phase 1
Memory
CRC Context
Data to be DMA
CRC_INP
Transmitted
CRC_OUTP
Transmission Phase 2
Memory
CRC Context
Data to be
CPU CRC_INP
Transmitted
CRC_OUTP
CRC Checksum
Transmission Phase 3
Memory
SPI
Data to be CPU
Tx FIFO
Transmitted
CRC Checksum
Reception Phase 1
Memory
SPI
DMA
Received Data Rx FIFO
CRC Checksum
Received Data
Reception Phase 2
Memory
CRC Context
DMA
Received Data CRC_INP
CRC_OUTP
CRC Checksum
Reception Phase 3
CRC Context
CRC_INP
CRC_OUTP
Software Check
Figure 12-7. Reception Sequence
13.1.1 Introduction
The JTAG port of the device consists of four inputs and one output. These pins include JTAG compliance
select (JCOMP), test data input (TDI), test data output (TDO), test mode select (TMS), and test clock input
(TCK). TDI, TDO, TMS, and TCK are compliant with the IEEE 1149.1-2001 standard and are shared with
the NDI through the test access port (TAP) interface.
JCOMP
Power-on
reset Test access port (TAP)
TMS controller
TCK
13.1.1.2 Overview
The JTAGC provides the means to test chip functionality and connectivity while remaining transparent to
system logic when not in test mode. Testing is performed via a boundary scan technique, as defined in the
IEEE 1149.1-2001 standard. In addition, instructions can be executed that allow the Test Access Port
(TAP) to be shared with other modules on the MCU. All data input to and output from the JTAGC is
communicated in serial format.
13.1.1.3 Features
The JTAGC is compliant with the IEEE 1149.1-2001 standard, and supports the following features:
• IEEE 1149.1-2001 Test Access Port (TAP) interface.
• 4 pins (TDI, TMS, TCK, and TDO), Refer to Section 13.1.2, “External Signal Description.”
• A JCOMP input that provides the ability to share the TAP.
• A 5-bit instruction register that supports several IEEE 1149.1-2001 defined instructions, as well as
several public and private MCU specific instructions.
• Four test data registers: a bypass register, a boundary scan register, and a device identification
register. The size of the boundary scan register is 480 bits.
• A TAP controller state machine that controls the operation of the data registers, instruction register
and associated circuitry.
13.1.1.4.1 Reset
The JTAGC is placed in reset when the TAP controller state machine is in the TEST-LOGIC-RESET state.
The TEST-LOGIC-RESET state is entered upon the assertion of the power-on reset signal, negation of
JCOMP, or through TAP controller state machine transitions controlled by TMS. Asserting power-on reset
or negating JCOMP results in asynchronous entry into the reset state. While in reset, the following actions
occur:
• The TAP controller is forced into the test-logic-reset state, thereby disabling the test logic and
allowing normal operation of the on-chip system logic to continue unhindered.
• The instruction register is loaded with the IDCODE instruction.
In addition, execution of certain instructions can result in assertion of the internal system reset. These
instructions include EXTEST, CLAMP, and HIGHZ.
1
The pull is not implemented in this module. Pullup/down devices are implemented in the pads.
2
TDO output buffer enable is negated when JTAGC is not in the Shift-IR or Shift-DR states. A
weak pulldown can be implemented on TDO.
Field Description
0–3 Part revision number. Contains the revision number of the device. This field changes with each revision of the device
PRN or module.
4–9 Design center. Indicates the Freescale design center. For the MPC5676R this value is 0x20.
DC
10–19 Part identification number. Contains the part number of the device. For the MPC5676R, this value is 0x276.
PIN
20–30 Manufacturer identity code. Contains the reduced Joint Electron Device Engineering Council (JEDEC) ID for
MIC Freescale, 0xE.
31 IDCODE register ID. Identifies this register as the device identification register and not the bypass register. Always
ID set to 1.
MSB LSB
Test logic
reset
1
0
1 1 1
Run-test/idle Select-DR-scan Select-IR-scan
0
0 0
1 1
Capture-DR Capture-IR
0 0
Shift-DR Shift-IR
0 0
1 1
1 1
Exit1-DR Exit1-IR
0 0
Pause-DR Pause-IR
0 0
1 1
0 0
Exit2-DR Exit2-IR
1 1
Update-DR Update-IR
1 1
0 0
NOTE: The value shown adjacent to each state transition in this figure represents the value of TMS at the time
of a rising edge of TCK.
Figure 13-5. IEEE 1149.1-2001 TAP Controller Finite State Machine
SAMPLE/PRELOAD 00010 Selects boundary scan register for shifting, sampling, and preloading without
disturbing functional operation
SAMPLE 00011 Selects boundary scan register for shifting and sampling without disturbing
functional operation
EXTEST 00100 Selects boundary scan register while applying preloaded values to output
pins and asserting functional reset
CLAMP 01100 Selects bypass register while applying preloaded values to output pins and
asserting functional reset
ACCESS_AUX_TAP_OnCE 10001 Enables access to the primary e200 OnCE TAP controller
(Primary CPU, core 0)
ACCESS_AUX_TAP_eTPU 10010 Enables access to the eTPU Nexus TAP controller (eTPU_A, eTPU_B,
CDC_AB)
ACCESS_AUX_TAP_eTPU_ 10110 Enables access to a secondary set of eTPU modules (eTPU_C, eTPU_D,
SECONDARY CDC_CD)
in the update-DR state. The data is applied to the external output pins by the EXTEST or CLAMP
instruction. System operation is not affected.
13.2.1 Introduction
The device microcontroller contains multiple Nexus clients that communicate over a single IEEE-ISTO
5001™-2003 Nexus class 3 combined JTAG IEEE 1149.1/auxiliary out interface. Combined, all of the
Nexus clients are referred to as the Nexus development interface (NDI). Class 3 Nexus allows for program,
data, and ownership trace of the microcontroller execution without access to the external data and address
buses.
This chapter is organized into sections that provide a high level view of the Nexus development interface:
Section 13.2.1, “Introduction” through Section 13.2.8, “NPC Initialization and Application Information.”
The chapter contains sections that discuss the modules of the Nexus development interface:
• Nexus eTPU development interfaces (NDEDI and NSEDI). The device has three eTPU engines.
See Section 13.2.9, “Nexus TPU Development Interfaces (NDEDI and NSEDI)” and the eTPU
Reference Manual for more information.
• Nexus e200z7 core interface (NZ7C3). In this chapter, the NZ7C3 interface is discussed in
Section 13.2.10, “e200z7 Class 3 Nexus Module (NZ7C3) through Section 13.2.11, “NZ7C3
Memory Map and Register Definition.”
• Nexus crossbar eDMA interface (NXDM) and Nexus FlexRay interface (NXFR). Refer to
Section 13.2.15, “Nexus eDMA Interface (NXDM) and Nexus FlexRay Interface (NXFR).”
Communication to the NDI is managed via the auxiliary port and the JTAG port.
• The auxiliary port is comprised of 17 or 21 output pins and 1 input pin. The output pins include
one message clock out (MCKO) pin, 12 or 16 message data out (MDO) pins, two message start/end
out (MSEO) pins, one ready (RDY) pin, and one event out (EVTO) pin. Event in (EVTI) is the only
input pin for the auxiliary port.
• The JTAG port consists of four inputs and one output. These pins include JTAG compliance select
(JCOMP), test data input (TDI), test data output (TDO), test mode select (TMS), and test clock
input (TCK). TDI, TDO, TMS, and TCK are compliant with the IEEE 1149.1-2001 standard and
are shared with the NDI through the test access port (TAP) interface. JCOMP along with power-on
reset and the TAP state machine are used to control reset for the NDI module. Ownership of the
TAP is achieved by loading the appropriate enable instruction for the desired Nexus client in the
JTAG controller (JTAGC) when JCOMP is asserted. See Table 13-7 for the JTAGC opcodes to
access the different Nexus clients.
-&203 5'< 7', 7&. 7'2 706 (97, 06(2>@ 0&.2 0'2RU (972
5HDG:ULWH
$FFHVV
5HDG:ULWH
$FFHVV
3URJUDP'DWD
5:UHJLVWHU 2ZQHUVKLS H]B H]B
+DOW6WHS :DWFKSRLQW
&RQWLQXH 7UDFH
008 008
16(',B& '&DFKH ,&DFKH '&DFKH ,&DFKH
H738
5HVHUYHG
;%$5
038
13.2.1.2 Features
The NDI module is compliant with the IEEE-ISTO 5001-2003 standard. The following features are
implemented:
• Full duplex pin interface for medium and high visibility throughput
— One of two modes selected by register configuration: full port mode (FPM) and reduced port
mode (RPM). FPM comprises 16 MDO pins, and RPM comprises 12 MDO pins.
— Auxiliary output port
– One MCKO (message clock out) pin
– 16 MDO (message data out) pins
– Two MSEO (message start/end out) pins
– One RDY (ready) pin
– One EVTO (event out) pin
— Auxiliary input port uses one EVTI (event in) pin
— Five-pin JTAG port (JCOMP, TDI, TDO, TMS, and TCK)
• Two host processor (e200z7) development support features (NZ7C3)
— IEEE-ISTO 5001-2003 standard class 3 compliant.
— Data trace via data write messaging (DWM) and data read messaging (DRM). This allows the
development tool to trace reads and/or writes to selected internal memory resources.
— Ownership trace via ownership trace messaging (OTM). OTM facilitates ownership trace by
providing visibility of which process ID or operating system task is activated. An ownership
trace message is transmitted when a new process/task is activated, allowing development tools
to trace ownership flow.
— Program trace via branch trace messaging (BTM). Branch trace messaging displays program
flow discontinuities (direct branches, indirect branches, exceptions, etc.), allowing the
development tool to interpolate what transpires between the discontinuities. Thus, static code
can be traced.
— Watchpoint messaging (WPM) via the auxiliary port.
— Watchpoint trigger enable of program and/or data trace messaging.
— Data tracing of instruction fetches via private opcodes.
— Subset of Power Architecture Book E software debug facilities with OnCE block
(Nexus class 1 features).
• Two eDMA development support features (NXDM)
— Data trace via data write messaging (DWM) and data read messaging (DRM). This allows the
development tool to trace DMA generated reads and/or writes to selected address ranges in the
device’s memory map.
— Watchpoint messaging (WPM) via the auxiliary port.
— Watchpoint trigger enable/disable of data trace messaging.
• FlexRay development support features (NXFR)
— FlexRay Nexus trace via data write messaging (DWM) and data read messaging (DRM). This
allows the development tool to trace FlexRay generated reads and/or writes to selected address
ranges in the device’s memory map.
— Watchpoint messaging (WPM) via the auxiliary port.
— Watchpoint trigger enable/disable of data trace messaging.
• eTPU development support features (NDEDI and NSEDI)
— IEEE-ISTO 5001-2002 standard Class 3 compliant for the eTPU engines.
— Data trace via data write messaging and data read messaging. This allows the development tool
to trace reads and writes to selected shared parameter RAM (SPRAM) address ranges. Four
data trace windows are shared by the two eTPU engines.
— Ownership trace via ownership trace messaging (OTM). OTM facilitates ownership trace by
providing visibility of which channel is being serviced. An ownership trace message is
transmitted to indicate when a new channel service request is scheduled, allowing the
development tools to trace task flow. A special OTM is sent when the engine enters in idle state,
meaning that all requests were serviced and no new requests are yet scheduled.
— Program trace via branch trace messaging. BTM displays program flow discontinuities (start,
jumps, return, etc.), allowing the development tool to interpolate what transpires between the
discontinuities. Thus static code can be traced. The branch trace messaging method uses the
branch/predicate method to reduce the number of generated messages.
— Watchpoint messaging via the auxiliary port. WPM provides visibility of the occurrence of the
eTPU’s’ watchpoints and breakpoints.
— Nexus based breakpoint/watchpoint configuration and single step support.
• Run-time access to the on-chip memory map via the Nexus read/write access protocol. This feature
supports accesses for run-time internal visibility, calibration variable acquisition, calibration
constant tuning, and external rapid prototyping for powertrain automotive development systems.
• All features are independently configurable and controllable via the IEEE 1149.1 I/O port.
• The NDI block reset is controlled with JCOMP, power-on reset, and the TAP state machine. These
sources are independent of system reset.
• NDI port ready status indication via MDO[0] following power-on reset.
memory mapped resources and the transmission of Nexus trace messages. See Chapter 24, “Flash Memory
Array and Control,” for information on Nexus port enabling and disabling regarding censorship.
Index Register
NPC Registers
Index Register
0 Device ID (DID)
Index Register
NEXUS3_ACCESS Opcode for e200z7 OnCE Nexus Enable instruction (10-bits) 0x7C
BYPASS Opcode for the e200z7 OnCE BYPASS instruction (10-bits) 0x7F
BYPASS Opcode for the eDMA Nexus BYPASS instruction (4-bits) 0xF
BYPASS Opcode for the FlexRay Nexus BYPASS instruction (4-bits) 0xF
1
See the e200z7 Reference Manual for a complete list of available OnCE instructions.
No X X Reset
Yes 0 X Disabled
0b000 SYS_CLK
0b001 SYS_CLK 2
0b010 Invalid value
0b011 SYS_CLK 4
0b111 SYS_CLK 8
1
The SYS_CLK setting for MCKO should only
be used if this setting does not violate the
maximum operating frequency of the auxiliary
port pins (specified in the MPC5676R Data
Sheet).
SRC[3:0] Client
0b0001 eDMA_A
0b0010 eTPU_A
0b0011 eTPU_B
0b0101 Reserved
0b0110 FlexRay
0b0111 eDMA_B
0b1001 Reserved
0b1010 eTPU_C
0b1011 Reserved
SRC[3:0] Client
0b1101 Reserved
0b1110 Reserved
0b1111 Reserved
1
CDC is the eTPU Coherent Dual-Parameter Controller. See the eTPU
Reference Manual for more information.
Debug mode entry requests from the eTPUs (etpu_n3_bkpt_req) and core watchpoint events
(nex_wevto[1]) are sent to the NPC input ports nex_bkpt_req[], ORed together, and sent back out on
nex_de_req, which is returned to all cores and eTPUs. Core0 and core1 entry to debug mode is indicated
on their respective jd_debug_b signals, which are ORed and sent to the NPC on nex_debug_b. The NPC
block inverts this signal and returns it to ipg_debug as a device wide signal to other modules. ipg_debug
is also ORed with nex_de_req to provide a means for any core to halt any eTPU block.
13.2.5.1 Overview
The device incorporates multiple modules that require development support. Each of these modules
implements a development interface based on the IEEE-ISTO 5001-2001 standard and must share the
input and output ports that interface with the development tool. The NPC controls the usage of these ports
in a manner that allows the individual modules to share the ports, while appearing to the development tool
as a single module.
13.2.5.2 Features
The NPC performs the following functions:
• Controls arbitration for ownership of the Nexus auxiliary output port
• Nexus device identification register and messaging
• Generates MCKO enable and frequency division control signals
• Controls sharing of EVTO
• Control of the device-wide debug mode
• Generates asynchronous reset signal for Nexus modules based on JCOMP input, censorship status,
and power-on reset status
• System clock locked status indication via MDO[0] during Nexus reset
• Provides Nexus support for censorship mode
state results in asynchronous loading of the BYPASS instruction. During the Capture-IR TAP controller
state, the instruction register is loaded with the value of the previously executed instruction, making this
value the register’s read value when the TAP controller is sequenced into the Shift-IR state.
3 2 1 0
W Instruction Opcode
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R Part Identification
Manufacturer Identity Code 1
Number (continued)
W
Reset 0 1 1 0 0 0 0 0 0 0 0 1 1 1 0 1
Figure 13-8. Nexus Device ID Register (DID)
Field Description
31–28 Part revision number. Contains the revision number of the part. This field changes with each revision of
PRN the device or module.
27–22 Design center. Indicates the Freescale design center. This value is 0x20.
DC
21–12 Part identification number. Contains the part number of the device. The PIN for the MPC5676R is 0x276.
PIN
11–1 Manufacturer identity code. Contains the reduced Joint Electron Device Engineering Council (JEDEC) ID
MIC for Freescale, 0x000E.
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R PSTAT
W _EN
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 13-9. Port Configuration Register (PCR)
Field Description
31 Full port mode. Determines if the auxiliary output port uses the full MDO port or a reduced MDO port to
FPM transmit messages.
0 The subset of MDO[11:0] pins are used to transmit messages.
1 All MDO[15:0] pins are used to transmit messages.
Section 3.2.1.13, “Pad Configuration Registers (SIU_PCR)” shows how GPIO is enabled or disabled by the
FPM setting.
30 MCKO clock gating control. Enables or disables MCKO clock gating. If clock gating is enabled, the MCKO
MCKO_GT clock is gated when the NPC is in enabled mode but not actively transmitting messages on the auxiliary output
port. When clock gating is disabled, MCKO is allowed to run even if no auxiliary output port messages are
being transmitted.
0 MCKO gating is disabled.
1 MCKO gating is enabled.
29 MCKO enable. Enables the MCKO clock. When enabled, the frequency of MCKO is determined by the
MCKO_EN MCKO_DIV field.
0 MCKO clock is driven to zero.
1 MCKO clock is enabled.
Field Description
28–26 MCKO division factor. Determines the frequency of MCKO relative to the system clock frequency when
MCKO_DIV MCKO_EN is asserted. The table below shows the meaning of MCKO_DIV values. In this table, SYS_CLK
[2:0] represents the system clock frequency.
25–1 Reserved
0 Processor status mode enable. Enables processor status (PSTAT) mode. In PSTAT mode, all auxiliary output
PSTAT_EN port MDO pins are used to transmit processor status information, and Nexus messaging is unavailable.
0 PSTAT mode disabled
1 PSTAT mode enabled
Note: PSTAT mode is intended for factory processor debug only. The PSTAT_EN bit must be written to disable
PSTAT mode by the customer. No Nexus messages are transmitted under any circumstances when
PSTAT mode is enabled
MSEO = 11
MSEO = 01 Idle
MDO:
0 invalid
=1 MS
EO EO
1
MSEO = 10 MS =1 =0
0
MSEO = 10
EO
MS
End MSEO = 11
message Start
MDO: MSEO = 00 message
invalid
MS 1
E O =0
=1 EO
1 MS
MSEO = 01 MSEO = 11 MSEO = 00
MSEO = 00
End Normal
packet MSEO = 01 transfer
MSEO = 01 MSEO = 00
Figure 13-11 shows the various message formats that the pin interface formatter has to encounter.
Min. Max.
Message TCODE Field #1 Field #2 Field #3 Field #4 Field #5 Size1 Size2
Bits Bits
The double edges in Figure 13-11 indicate the starts and ends of messages. Fields without shaded areas
between them are grouped into super-fields and can be transmitted together without end-of-packet
indications between them.
Rules of Messages
The rules of messages include the following:
• A variable-sized field within a message must end on a port boundary. (Port boundaries depend on
the number of MDO pins active with the current reset configuration.)
• A variable-sized field can start within a port boundary only when following a fixed-length field.
• Super-fields must end on a port boundary.
• When a variable-length field is sized such that it does not end on a port boundary, it is necessary
to extend and zero fill the remaining bits after the highest order bit so that it can end on a port
boundary.
• Multiple fixed-length packets can start and/or end on a single clock.
• When any packet follows a variable-length packet, it must start on a port boundary.
• The field containing the TCODE number is always transferred out first, followed by subsequent
fields of information.
• Within a field, the lowest significant bits are shifted out first. Figure 13-12 shows the transmission
sequence of a message that is made up of a TCODE followed by three fields.
4 3 2 1
Data is shifted between TDI and TDO starting with the least significant bit as illustrated in Figure 13-13.
This applies for the instruction register and all Nexus tool-mapped registers.
msb lsb
TEST LOGIC
RESET
1
0
1 1 1
RUN-TEST/IDLE SELECT-DR-SCAN SELECT-IR-SCAN
0
0 0
1 1
CAPTURE-DR CAPTURE-IR
0 0
SHIFT-DR SHIFT-IR
0 0
1 1
1 1
EXIT1-DR EXIT1-IR
0 0
PAUSE-DR PAUSE-IR
0 0
1 1
0 0
EXIT2-DR EXIT2-IR
1 1
UPDATE-DR UPDATE-IR
1 1
0 0
NOTE: The value shown adjacent to each state transition in this figure represents the value of TMS
at the time of a rising edge of TCK.
Figure 13-14. IEEE 1149.1-2001 TAP Controller State Machine
NEXUS-ENABLE=0
TEST-LOGIC-RESET=1
IDLE
NEXUS-ENABLE=1
REG_SELECT
DATA_ACCESS
4 — 0 SHIFT-IR IDLE TDO becomes active, and the IEEE 1149.1-2001 shifter
is ready. Shift in all but the last bit of the
5–7 0 0 3 TCKS in SHIFT-IR IDLE NEXUS_ENABLE instruction.
3 0 SHIFT-DR REG_SELECT TDO becomes active, and write bit and 6 bits of
register index shifted in.
7 TCKs
31 TCKs
47 1 EXIT1-DR DATA_ACCESS Last bit of current value shifted out TDO. Last bit of
new value shifted in TDI.
13.2.7.2.6 MCKO
MCKO is an output clock to the development tools used for the timing of MSEO and MDO pin functions.
MCKO is derived from the system clock and its frequency is determined by the value of the
MCKO_DIV[2:0] field in the PCR. Possible operating frequencies include one-half, one-quarter, and
one-eighth system clock speed. MCKO is enabled by setting the MCKO_EN bit in the PCR.
The NPC also controls dynamic MCKO clock gating when in full- or reduced-port modes. The setting of
the MCKO_GT bit inside the PCR determines whether or not MCKO gating control is enabled. The
MCKO_GT bit resets to a logic 0. In this state gating of MCKO is disabled. To enable gating of MCKO,
the MCKO_GT bit in the PCR is written to a logic 1. When MCKO gating is enabled, MCKO is driven to
a logic 0 if the auxiliary port is enabled but not transmitting messages and there are no pending messages
from Nexus clients.
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R PIN MIC 1
W
Reset(NDEDI) 0 1 0 0 0 0 0 0 0 0 0 1 1 1 0 1
Reset(NSEDI) 0 1 0 0 0 0 0 0 0 0 0 1 1 1 0 1
Figure 13-17. NDEDI Device ID Register (DID)
Field Description
31–28 Part revision number. Contains the revision number of the part. This field changes with each revision of the
PRN device or module.
27–22 Design center. Indicates the Freescale design center. This value is 0x20.
DC
21–12 Part identification number. Contains the part number of the device.
PIN
11–1 Manufacturer identity code. Contains the reduced Joint Electron Device Engineering Council (JEDEC) ID
MIC for Freescale, 0xE.
13.2.10.1 Introduction
This section defines the auxiliary pin functions, transfer protocols and standard development features of
the NZ7C3 module. The development features supported are Program trace, data trace, watchpoint
messaging, ownership trace, and read/write access via the JTAG interface.
NOTE
Throughout this section references are made to the auxiliary port and its
specific signals, such as MCKO, MSEO[1:0], MDO[15:0] and others. The
device NPC module arbitrates the access of the single auxiliary port. To
simplify the description of the function of the NZ7C3 module, the
interaction of the NPC is omitted and the configuration in this chapter
describes an NPC with a dedicated auxiliary port. The auxiliary port is fully
described in Section 13.2.2, “External Signal Description.”
NPC
Control and
Arbitration
Instruction
Snoop n +1
Message MDO[n:0]
Queues
MSEO[0]
I/O Logic
MSEO[1]
Core CPU Virtual Bus
MCKO
Data
Snoop EVTO
Memory Control
EVTI
RDY
System Bus
DMA TDI
(R/W) Registers OnCE Debug
TDO
Control/Status Breakpoint/
TMS
Registers Watchpoint
Control TCLK
DMA Registers
TRST
Nexus3 Module
Nexus1 Module (within core CPU)
13.2.10.3 Overview
Table 13-21 contains a set of terms and definitions associated with the NZ7C3 module.
Table 13-21. Terms and Definitions
Term Description
IEEE-ISTO 5001 Consortium and standard for real-time embedded system design. World wide
Web documentation at http://www.ieee-isto.org/Nexus5001
Auxiliary Port Refers to Nexus auxiliary port. Used as auxiliary port to the IEEE 1149.1 JTAG
interface.
Branch Trace Messaging (BTM) Visibility of addresses for taken branches and exceptions, and the number of
sequential instructions executed between each taken branch.
Client A functional block on an embedded processor which requires development
visibility and controllability. Examples are a central processing unit (CPU) or an
intelligent peripheral.
Data Read Message (DRM) External visibility of data reads to memory-mapped resources.
Data Write Message (DWM) External visibility of data writes to memory-mapped resources.
Term Description
Data Trace Messaging (DTM) External visibility of how data flows through the embedded system. This can
include DRM and/or DWM.
JTAG Compliant Device complying to IEEE 1149.1 JTAG standard
JTAG IR & DR Sequence JTAG instruction register (IR) scan to load an opcode value for selecting a
development register. The JTAG IR corresponds to the OnCE command
register (OCMD). The selected development register is then accessed via a
JTAG data register (DR) scan.
Nexus1 The e200z7 (OnCE) debug module. This module integrated with each e200z7
processor provides all static (core halted) debug functionality. This module is
compliant with Class1 of the IEEE-ISTO 5001 standard.
Ownership Trace Message (OTM) Visibility of process/function that is currently executing.
Public Messages Messages on the auxiliary pins for accomplishing common visibility and
controllability requirements
Standard The phrase ‘according to the standard’ is used to indicate according to the
IEEE-ISTO 5001 standard.
Transfer Code (TCODE) Message header that identifies the number and/or size of packets to be
transferred, and how to interpret each of the packets.
Watchpoint A data or instruction breakpoint which does not cause the processor to halt.
Instead, a pin is used to signal that the condition occurred. A watchpoint
message is also generated.
13.2.10.4 Features
The NZ7C3 module is compliant with Class 3 of the IEEE-ISTO 5001-2003 standard. The following
features are implemented:
• Program trace via branch trace messaging (BTM). Branch trace messaging displays program flow
discontinuities (direct and indirect branches, exceptions, etc.), allowing the development tool to
interpolate what transpires between the discontinuities. Thus static code can be traced.
• Data trace via data write messaging (DWM) and data read messaging (DRM). This provides the
capability for the development tool to trace reads and/or writes to selected internal memory
resources.
• Ownership trace via ownership trace messaging (OTM). OTM facilitates ownership trace by
providing visibility of which process ID or operating system task is activated. An ownership trace
message is transmitted when a new process/task is activated, allowing the development tool to
trace ownership flow.
• Run-time access to embedded processor registers and memory map via the JTAG port. This allows
for enhanced download/upload capabilities.
• Watchpoint messaging via the auxiliary pins.
• Watchpoint trigger enable of program and/or data trace messaging.
• High-speed data input/output via the auxiliary port.
• Auxiliary interface for higher data input/output
Packet Size
(bits) Packet Packet
Message Name Packet Description
Name Type
Min Max
Packet Size
(bits) Packet Packet
Message Name Packet Description
Name Type
Min Max
Packet Size
(bits) Packet Packet
Message Name Packet Description
Name Type
Min Max
Packet Size
(bits) Packet Packet
Message Name Packet Description
Name Type
Min Max
Program Trace - 6 6 TCODE Fixed TCODE number = 28 (0x1C) (see footnote 1 below)
Indirect Branch
History Message 4 4 SRC Fixed Source processor identifier
Table 13-23 shows the error code encodings used when reporting an error via the Nexus3 Error Message.
Table 13-23. Error Code Encoding (TCODE = 8)
Error Code
Description
(ECODE)
Error Code
Description
(ECODE)
Table 13-24 shows the encodings used for resource codes for certain messages.
Table 13-24. RCODE values (TCODE = 27)
0000 Program Trace Instruction Counter overflow (reached 255 and was reset) 0xFF
0001 Program Trace, Branch and Predicate Instruction History. This type of Branch History. This type of
packet is terminated by a stop bit set to 1 after the last history bit. packet is terminated by a stop bit
set to a 1 after the last history bit.
Table 13-25 shows the event code encodings used for certain messages.
Table 13-25. Event Code Encoding (TCODE = 33)
Table 13-26 shows the data trace size encodings used for certain messages.
Table 13-26. Data Trace Size Encodings (TCODE = 5, 6, 13, 14)
DTM Size
Transfer Size
Encoding
000 Byte
Table 13-26. Data Trace Size Encodings (TCODE = 5, 6, 13, 14) (continued)
DTM Size
Transfer Size
Encoding
NOTE
Program trace can be implemented using either branch history/predicate
instruction messages, or traditional direct and indirect branch messages. The
user can select between the two types of Program Trace. The advantages for
each are discussed in Section 13.2.13.1, “Branch Trace Messaging (BTM).”
If the Branch History method is selected, the shaded TCODES are not
messaged out.
Nexus
Read Write
Nexus Register Access Read/Write
Address Address
Opcode
Nexus
Read Write
Nexus Register Access Read/Write
Address Address
Opcode
Program Trace Start Trigger Control (PTSTC) 0x35 R/W 0x6A 0x6B
Program Trace End Trigger Control (PTETC) 0x36 R/W 0x6C 0x6D
Data Trace Start Trigger Control (DTSTC) 0x37 R/W 0x6E 0x6F
Data Trace End Trigger Control (DTETC) 0x38 R/W 0x70 0x71
2. The second pass through the DR then shifts the data in or out of the JTAG port, lsb first.
a) During a read access, data is latched from the selected Nexus register when the JTAG state
machine passes through the capture-DR state.
b) During a write access, data is latched into the selected Nexus register when the JTAG state
machine passes through the update-DR state.
Error information is messaged out in the following format (see Table 13-23):
3 2 1
— Number of sequential instructions executed since the last exception was processed, as well as
the unique portion of the exception vector address
— Number of sequential instructions executed since the last predicate instruction was taken
— History field in the branch and predicate instruction unique to the branch target address or
exception vector address. Each bit in the history field represents a direct branch or predicated
instruction where a value of one (1) indicates taken, and a value of zero (0) indicates not taken.
Certain instructions (evsel) generate a pair of predicate bits which are both reported as
consecutive bits in the history field.
Taken direct branch instructions b, ba, bl, bla, bc, bca, bcl, bcla
msb 1–32 bits 1–32 bits 1–8 bits 1 bit 4 bits 6 bits lsb
Max length = 83 bits; Min length = 14 bits
NOTE
When DC[PTM] is set, direct branch messages are not transmitted. Instead,
each direct branch or predicated instruction toggles a bit in the history
buffer.
5 4 3 2 1
The formats for program trace direct/indirect branch with sync. messages and indirect branch history with
sync. messages are as follows:
6 5 4 3 2 1
msb 1–32 bits 1–32 bits 1–8 bits 1 bit 4 bits 6 bits lsb
Max length = 83 bits; Min length = 14 bits
Figure 13-29. Indirect Branch History with Sync. Message Format
Exception conditions that result in program trace synchronization are summarized in Table 13-30.
Table 13-30. Program Trace Exception Summary
System Reset Negation At the negation of JTAG reset (JCOMP), queue pointers, counters, state machines, and
registers within the NZ7C3 module are reset. Upon the first branch out of system reset
(if program trace is enabled), the first program trace message is a direct/indirect branch
with sync. message.
Program Trace Enabled The first program trace message (after program trace has been enabled) is a
synchronization message.
Exit from Low Power/Debug Upon exiting from the low power or debug modes, the next direct/indirect branch is
converted to a direct/indirect branch with sync. message.
Queue Overrun An error message occurs when a new message cannot be queued due to the message
queue being full. The FIFO discards messages until the queue is completely empty. After
it is empty, an error message is queued. The error encoding indicates the message types
denied queueing while the FIFO was emptying. The next BTM message in the queue is
a direct/indirect branch with sync. message.
Periodic Program Trace Sync. A forced synchronization occurs periodically after 255 program trace messages have
been queued. A direct/indirect branch with sync. message is queued. The periodic
program trace message counter then resets.
Event In If the Nexus module is enabled, an EVTI assertion initiates a direct/indirect branch with
sync. message upon the next direct/indirect branch (if program trace is enabled and the
EIC bits of the DC1 register have enabled this feature).
Sequential Instruction Count When the sequential instruction counter reaches its maximum count (up to 255
Overflow sequential instructions can be executed), a forced synchronization occurs. The
sequential counter then resets. A program trace direct/indirect branch with sync.message
is queued upon execution of the next branch.
Attempted Access to Secure For devices which implement security, any attempt to branch to secure memory locations
Memory temporarily disables program trace and cause the corresponding BTM to be lost. The
following direct/indirect branch queues a direct/indirect branch with sync. message. The
count value within this message can be inaccurate since re-enabling program trace does
not guarantee alignment on an instruction boundary.
Collision Priority All messages have the following priority: WPM OTM BTM DTM. A BTM message
which attempts to enter the queue at the same time as a watchpoint message or
ownership trace message is lost. An error message is sent indicating the BTM was lost.
The following direct/indirect branch queues a direct/indirect branch with sync. message.
The count value within this message reflects the number of sequential instructions
executed after the last successful BTM message was generated. This count includes the
branch which did not generate a message due to the collision.
Message Generation:
Address Re-creation:
A1 M1 = A2
A1 = 0000 0000 0000 0011 1111 1100 0000 0001
M1 = 0000 0000 0000 0000 0000 1111 0110 0100
A2 = 0000 0000 0000 0011 1111 0011 0110 0101
A value of one (1) is shifted into the history buffer on a taken branch (condition or unconditional) and on
any instruction whose predicate condition executed as true. A value of zero (0) is shifted into the history
buffer on any instruction whose predicate condition executed as false as well as on branches not taken.
This includes indirect as well as direct branches were not taken. For the evsel instruction, two bits are
shifted in, corresponding to the low element (shifted in first) and the high element (shifted in second)
conditions.
MCKO
MSEO[1:0] 00 01 11
MDO[11:0] 0000 0000 0100 0000 0010 0000 0000 1010 0101
TCODE = 4
Source Processor = 0b0000
Number of Sequence Instructions = 128
Relative Address = 0xA5
MCKO
MSEO
MDO[1:0] 00 11 01 00 00 00 01 01 10 10 01 01 10 10 00
TCODE = 28
Source Processor = 0b0000
Number of Sequential Instructions = 0
Relative Address = 0xA5
Branch History = 0b1010_0101 (with Stop)
MSEO
MDO[1:0] 11 00 00 00 00 11 00 00 10 00 00 00 01 00 00
DBM: Error:
TCODE = 3 TCODE = 8
Source Processor = 0b0000 Source Processor = 0b0000
Number of Sequential Instructions = 3 Error Code = 1 (Queue Overrun ‚ÄöÐÑйÐêÐë
MCKO
MSEO
MDO[1:0] 00 11 00 00 00 11 10 11 00 11 10 10 11 11 01 11 10 10 10 11 01 11 00
TCODE = 12
Source Processor = 0b0000
Number of Sequential Instructions = 3
Full Target Address = 0xDEAD_FACE
matching target addresses). The NZ7C3 module traces all data access that meet the selected range and
attributes.
NOTE
Data trace is only performed on the e200z7 virtual data bus. This allows for
data visibility for the incorporated data cache. Only e200z7 CPU initiated
accesses are traced. No DMA accesses to the NXDM system bus are traced.
Data trace messaging can be enabled in one of two ways:
• Setting the TM field of the DC1 register to enable data trace (DC1[TM]).
• Using WT[DTS] to enable data trace on watchpoint hits (e200z7 watchpoints are configured within
the Nexus1 module)
msb 1–64 bits 1–32 bits 4 bits 1 bits 4 bits 6 bits lsb
Max length = 111 bits; Min length = 17 bits
msb 1–64 bits 1–32 bits 4 bits 4 bits 4 bits 6 bits lsb
Max length = 111 bits; Min length = 17 bits
Figure 13-36. Data Read Message Format
NOTE
For the e200z7 based CPU, the doubleword encoding (data size = 0b000)
indicates a doubleword access and sends out as a single data trace message
with a single 64-bit data value.
reference address for subsequent data messages, in which only the unique portion of the data trace address
is transmitted. The format for data trace write/read with sync. messages is as follows:
5 4 3 2 1
Exception conditions that result in data trace synchronization are summarized in Table 13-31.
Table 13-31. Data Trace Exception Summary
System Reset Negation At the negation of JTAG reset (JCOMP), queue pointers, counters, state machines,
and registers within the NZ7C3 module are reset. If data trace is enabled, the first
data trace message is a data write/read with sync. message.
Data Trace Enabled The first data trace message (after data trace has been enabled) is a
synchronization message.
Exit from Low Power/Debug Upon exiting from low power or debug modes, the next data trace message is
converted to a data write/read with sync. message.
Queue Overrun An error message occurs when a new message cannot be queued due to a full
message queue. The FIFO discards messages until it has completely emptied the
queue. After the queue is empty, an error message is queued that indicates the
message types denied queuing while the FIFO was emptying. The next DTM
message in the queue is a data write/read with sync. message.
Periodic Data Trace Sync. A forced synchronization occurs periodically after 255 data trace messages have
been queued. A data write/read with sync. message is queued. The periodic data
trace message counter then resets.
Event In If the Nexus module is enabled, a EVTI assertion initiates a data trace write/read
with sync. message upon the next data write/read (if data trace is enabled and the
EIC bits of the DC1 register have enabled this feature).
Attempted Access to Secure For devices which implement security, any attempted read or write to secure
Memory memory locations temporarily disables data trace and loses the DTM. A
subsequent read/write queues a data trace read/write with sync. message.
Collision Priority All messages have the following priority: WPM OTM BTM DTM. A DTM
message which attempts to enter the queue at the same time as a watchpoint
message or ownership trace message or branch trace message can be lost. A
subsequent read/write queues a data trace read/write with sync. message.
DTM Queueing
NZ7C3 implements a message queue for DTM messages. Messages that enter the queue are transmitted
via the auxiliary pins in the order in which they are queued.
NOTE
If multiple trace messages must be queued at the same time, watchpoint
messages have the highest priority (WPM OTM BTM DTM).
Relative Addressing
The relative address feature is compliant with the IEEE-ISTO 5001-2003 standard recommendations, and
is designed to reduce the number of bits transmitted for addresses of data trace messages. See
Section 13.2.14.2, “ Relative Addressing for details.
e200z7 bus cycle with data error (TEA) Data Trace Message discarded
e200z7 bus cycle completed without error Cycle captured & transmitted
e200z7 bus cycle accesses misaligned data (across 64-bit 1st and 2nd cycle captured, and 2 DTM’s
boundary)—both 1st and 2nd transactions within data trace transmitted (see Note)
range
e200z7 bus cycle accesses misaligned data (across 64-bit 1st cycle captured and transmitted; 2nd cycle
boundary)—1st transaction within data trace range; 2nd ignored
transaction out of data trace range
e200z7 bus cycle accesses misaligned data (across 64-bit 1st cycle ignored; 2nd cycle capture and
boundary)—1st transaction out of data trace range; 2nd transmitted
transaction within data trace range
NOTE
For misaligned accesses (crossing 64-bit boundary), the access is broken
into two accesses. If both accesses are within the data trace range, two
DTMs are sent: one with a size encoding indicating the size of the original
access (a word), and one with a size encoding for the portion which crossed
the boundary (3 bytes).
NOTE
An STM to the cache’s store buffer within the data trace range initiates a
DTM message. If the corresponding memory access causes an error, a
checkstop condition occurs. The debug/development tool must use this
indication to invalidate the previous DTM.
MCKO
MSEO[1:0] 11 00 00 01 00 11
MCKO
MSEO[1:0] 11 00 01 11
MCKO
MSEO[1:0] 11 00 11 xx
13.2.14.7.1 Overview
The NZ7C3 module provides watchpoint messaging via the auxiliary pins, as defined by the IEEE-ISTO
5001-2003 standard.
NZ7C3 is not compliant with Class4 breakpoint/watchpoint requirements defined in the standard. The
breakpoint/watchpoint control register is not implemented.
Watchpoint Source
Watchpoint Description
(8 bits)
3 2 1
13.2.14.7.4 Watchpoint Timing Diagram (Two MDO and One MSEO Configuration)
Watchpoint Error
MCKO
MSEO
MDO[1:0] 11 11 00 00 10 00 00 00 10 00 00 10 01 00
WPM: Error:
TCODE = 15 TCODE = 8
Source Processor = 0b00 Source Processor = 0b00
Watchpoint Number = 2 Error Code = 6 (Queue Overrun ‚ÄöÐÑйÐêÐë
2. Initialize the read/write access control/status register (RWCS) through the access method outlined
in Section 13.2.11.1, “ NZ7C3 Register Access via JTAG / OnCE,” using the Nexus Register Index
of 0x7 (see Table 13-27). Configure the bits as follows:
– Access Control RWCS[AC] 0b1 (to indicate start access)
– Map Select RWCS[MAP] 0b000 (primary memory map)
– Access Priority RWCS[PR] 0b00 (lowest priority)
– Read/Write RWCS[RW] 0b1 (write access)
– Word Size RWCS[SZ] 0b0xx (32-bit, 16-bit, 8-bit)
– Access Count RWCS[CNT] 0x0000 or 0x0001 (single access)
NOTE
Access count RWCS[CNT] of 0x0000 or 0x0001 performs a single access.
3. Initialize the read/write access data register (RWD) through the access method outlined in
Section 13.2.11.1, “ NZ7C3 Register Access via JTAG / OnCE,” using the Nexus register index of
0xA (see Table 13-27). Configure the write data to 0xnnnnnnnn (write data).
4. The NZ7C3 module then arbitrates for the system bus and transfer the data value from the data
buffer RWD register to the memory mapped address in the read/write access address register
(RWA). When the access has completed without error (ERR=1’b0), NZ7C3 asserts the RDY pin
and clears the DV bit in the RWCS register. This indicates that the device is ready for the next
access.
NOTE
Only the RDY pin as well as the DV and ERR bits within the RWCS provide
read/write access status to the external development tool.
2. Initialize the burst data buffer (read/write access data register) through the access method outlined
in Section 13.2.11.1, “ NZ7C3 Register Access via JTAG / OnCE,” using the Nexus register Index
of 0xA (see Table 13-27).
3. Repeat step 2 until all doubleword values are written to the buffer.
NOTE
The data values must be shifted in 32-bits at a time lsb first (that is,
doubleword write = two word writes to the RWD).
4. The Nexus module then arbitrates for the system bus and transfer the burst data values from the
data buffer to the system bus beginning from the memory mapped address in the read/write access
address register (RWA). For each access within the burst, the address from the RWA register is
incremented to the next doubleword size (specified in the SZ field) modulo the length of the burst,
and the number from the CNT field is decremented.
5. When the entire burst transfer has completed without error (ERR = 0), NZ7C3 then asserts the
RDY pin, and the DV bit within the RWCS is cleared to indicate the end of the block write access.
NOTE
The actual RWA value as well as the CNT field within the RWCS are not
changed when executing a block write access (burst or non-burst). The
original values can be read by the external development tool at any time.
4. The data can then be read from the read/write access data register (RWD) through the access
method outlined in Section 13.2.11.1, “ NZ7C3 Register Access via JTAG / OnCE,” using the
Nexus register index of 0xA (see Table 13-27).
NOTE
Only the RDY pin as well as the DV and ERR bits within the RWCS provide
Read/Write Access status to the external development tool.
NOTE
The actual RWA value as well as the CNT field within the RWCS are not
changed when executing a block read access (burst or non-burst). The
original values can be read by the external development tool at any time.
Access Termination
The following cases are defined for sequences of the read/write protocol that differ from those described
in the above sections:
1. If the AC bit in the RWCS register is set to start read/write accesses and invalid values are loaded
into the RWD and/or RWA, then a system bus access error can occur. This is handled as described
above.
2. If a block access is in progress (all cycles not completed), and the RWCS register is written, then
the original block access is terminated at the boundary of the nearest completed access.
a) If the RWCS is written with the AC bit set, the next read/write access begins and the RWD can
be written to/ read from.
b) If the RWCS is written with the AC bit cleared, the read/write access is terminated at the nearest
completed access. This method can be used to break (early terminate) block accesses.
13.2.14.9 Examples
The following are examples of program trace and data trace messages.
Table 13-34 illustrates an example indirect branch message with an eight MDO and two MSEO
configuration.
T0 and S0 are the least significant bits where:
• Tx = TCODE number (fixed)
• Sx = Source processor (fixed)
• Ix = Number of instructions (variable)
• Ax = Unique portion of the address (variable)
Table 13-34. Indirect Branch Message Example (12 MDO and Two MSEO)
MDO[11:0]
Clock MSEO[1:0] State
11 10 9 8 7 6 5 4 3 2 1 0
1 I1 I0 S3 S2 S1 S0 T5 T4 T3 T2 T1 T0 0 0 Start Message
2 0 0 0 0 0 0 0 0 I5 I4 I3 I2 0 1 End Packet
Table 13-35 illustrates an example of direct branch message with 12 MDO and two MSEO.
T0 and I0 are the least significant bits where:
• Tx = TCODE number (fixed)
• Sx = Source processor (fixed)
• Ix = Number of instructions (variable)
Table 13-35. Direct Branch Message Example (12 MDO and Two MSEO)
MDO[11:0]
Clock MSEO[1:0] State
11 10 9 8 7 6 5 4 3 2 1 0
1 I1 I0 S3 S2 S1 S0 T5 T4 T3 T2 T1 T0 0 0 Start Message
Table 13-36 an example data write message with 12 MDO and two MSEO configuration.
T0, A0, D0 are the least significant bits (LSB) where:
• Tx = TCODE number (fixed)
• Sx = Source processor (fixed)
MDO[11:0]
Clock MSEO[1:0] State
11 10 9 8 7 6 5 4 3 2 1 0
1 Z1 Z0 S3 S2 S1 S0 T5 T4 T3 T2 T1 T0 0 0 Start Message
2 0 0 0 0 0 0 0 A3 A2 A1 A0 Z2 0 1 End Packet
1 1 IDLE SELECT-DR_SCAN
3 0 CAPTURE-DR SHIFT-DR
4 0 (7) TCK clocks issued to shift in direction (read/write) bit and first 6 bits of Nexus reg. addr.
7 1 UPDATE-DR SELECT-DR_SCAN
9 0 CAPTURE-DR SHIFT-DR
10 0 (31) TCK clocks issued to transfer register value to TDO pin while shifting in TDI value
4 37 Write RWCS (initialize read access mode and CNT value—data input on TDI)
2 37 Write RWCS (initialize write access mode and CNT value—data input on TDI)
13.2.15 Nexus eDMA Interface (NXDM) and Nexus FlexRay Interface (NXFR)
The third module of the device NDI interface is the e200z7 eDMA Nexus module (NXDM) which is
compliant with the Class 3 defined data trace feature of the IEEE-ISTO 5001-2003 standard.The fourth
module of the device NDI interface is the FlexRay module (NXFR) which is compliant with the Class 3
defined data trace feature of the IEEE-ISTO 5001-2003 standard. The NXDM can be programmed to trace
data accesses for the eDMA module on the system bus. The NXFR can be programmed to trace data
accesses for the FlexRay module on the system bus. This eDMA module and FlexRay module as well as
the Nexus module are components of the e200z7 platform. All output messages and register accesses are
compliant with the protocol defined in the IEEE-ISTO 5001 standard.
NOTE
The auxiliary port and its signals, such as MCKO, MSEO[1:0], MDO[15:0]
and others, are referenced. The device NPC module arbitrates the access of
the single auxiliary port. The functions of the NXDM and FlexRay modules
are described without the interaction of the NPC, as if Nexus has a dedicated
auxiliary port, to simplify the description. The auxiliary port function is
described in full in Section 13.2.2, “External Signal Description.”
NPC
Control and
arbitration
n+1
Message MDO[n:0]
queues
MSEO[0]
I/O logic
MSEO[1]
MCKO
System bus
Data
snoop EVTO
Memory control
EVTI
Registers
TDI
General control
and status TDO
IEEE 1149.1
(JTAG) TMS
Breakpoint/ TAP controller
watchpoint TCLK
control
TRST
(JCOMP)
Figure 13-46. NXDM and NXFR Block Diagram
13.2.15.2 Features
Features include the following:
• Data trace via data write messaging (DWM) and data read messaging (DRM). This provides the
capability for the development tool to trace reads and/or writes through the eDMA and FlexRay
modules to (selected) internal memory resources.
• Watchpoint messaging via the auxiliary pins.
• Watchpoint trigger enable of data trace messaging (DTM).
• Registers for data trace, watchpoint generation, and watchpoint trigger.
• All features controllable and configurable via the JTAG port.
• Power management.
15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
R 0 C 0 0 0 0 0 0 0 0 0
EIC TM
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 13-47. Development Control Register 1 (DC1)
Field Description
Field Description
or ownership trace.
Access: R/W
31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
R 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
EWC
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 13-48. Development Control Register 2 (DC2)
Field Description
Field Description
NOTE
The WT bits ONLY enable data trace if the tm bits within the development
control register (DC) have not already been set to enable data trace.
Bit Description
7 Range control 1
RC1 0 Condition trace on address within range (endpoints inclusive)
1 Condition trace on address outside of range (endpoints exclusive)
6 Range control 2
RC2 0 Condition trace on address within range (endpoints inclusive)
1 Condition trace on address outside of range (endpoints exclusive)
5–0 Reserved, read as 0.
13.2.17.2.4 Data Trace Start Address Registers 1 and 2 (DTSA1 and DTSA2)
The data trace start address registers define the start addresses for each trace channel.
Access: R/W
31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
R
DATA TRACE START ADDRESS
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 13-51. Data Trace Start Address Registers (DTSA1, DTSA2)
13.2.17.2.5 Data Trace End Address Registers 1 and 2 (DTEA1 and DTEA2)
The data trace end address registers define the end addresses for each trace channel.
Access: R/W
31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
R
DATA TRACE END ADDRESS
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 13-52. Data Trace Start Address Registers (DTEA1, DTEA2)
Table 13-45 illustrates the range that is selected for data trace for various cases of DTSA being less than,
greater than, or equal to DTEA.
Table 13-45. Data Trace Address Range Options
NOTE
DTSA must be less than (or equal to) DTEA to guarantee correct data
write/read traces. When the range control bit is 0 (internal range), accesses
to DTSA and DTEA addresses are traced. When the range control bit is 1
(external range), accesses to DTSA and DTEA are not traced.
Field Description
15 Breakpoint/watchpoint #1 type
BWT1 0 Invalid value
1 Watchpoint #1 on data accesses
14–0 Reserved, read as 0.
Field Description
Field Description
15 Breakpoint/watchpoint #2 Type
BWT2 0 Invalid value
1 Watchpoint #2 on data accesses
14–0 Reserved, read as 0.
Field Description
21–12 NXDM and NXFR module part identification number, defines the features set. (0x60)
PIN
After the JTAG NEXUS_ACCESS instruction has been loaded, the JTAG port allows tool/target
communications with all Nexus registers according to the map in Table 13-40.
Reading/writing of a Nexus register then requires two (2) passes through the data-scan (DR) path of the
JTAG state machine (refer to Section 13.1, “IEEE 1149.1 Test Access Port Controller (JTAGC)”).
1. The first pass through the DR selects the Nexus register to be accessed by providing an index
(refer to Table 13-40), and the direction (read/write). This is achieved by loading an 8-bit value into
the JTAG data register (DR). This register has the following format:
Access: R/W
7 6 5 4 3 2 1 0
R
Nexus Register Index R/W
W
Reset
2. The second pass through the DR then shifts the data in or out of the JTAG port, lsb first.
a) During a read access, data is latched from the selected Nexus register when the JTAG state
machine passes through the capture-DR state.
b) During a write access, data is latched into the selected Nexus register when the JTAG state
machine passes through the update-DR state.
Packet Size
Bits Packet
Message Name Packet Type Packet Description
Name
Min Max
Packet Size
Bits Packet
Message Name Packet Type Packet Description
Name
Min Max
Error Code
Description
(ECODE)
Table 13-52. Data Trace Size (DSZ) Encodings (TCODE = 5, 6, 13, 14)
000 Byte
Table 13-52. Data Trace Size (DSZ) Encodings (TCODE = 5, 6, 13, 14)
If only a data trace message attempts to enter the queue while it is being emptied, the error message
incorporates the data trace only error encoding (00010). If a watchpoint also attempts to be queued while
the FIFO is being emptied, then the error message incorporates error encoding (01000).
Error information is messaged out in the following format:
3 2 1
Exception conditions that result in data trace synchronization are summarized in Table 13-53., “Data Trace
Exception Summary.”
Table 13-53. Data Trace Exception Summary
System Reset Negation At the negation of JTAG reset (JCOMP), queue pointers, counters, state
machines, and registers within the NXDM and NXFR module are reset. If
data trace is enabled, the first data trace message is a data write/read w/
sync. message.
Data Trace Enabled The first data trace message (after data trace has been enabled) is a
synchronization message.
Exit from Low Power/Debug Upon exit from a low power mode or debug mode the next data trace
message is converted to a data write/read w/ sync. message.
Queue Overrun An error message occurs when a new message cannot be queued due to
the message queue being full. The FIFO discards messages until it has
completely emptied the queue. After it is emptied, an error message is
queued. The error encoding indicates the types of messages that attempted
to be queued while the FIFO was being emptied. The next DTM message in
the queue is a data write/read w/ sync. message.
Periodic Data Trace Synchronization A forced synchronization occurs periodically after 255 data trace messages
have been queued. A data write/read w/ sync. message is queued. The
periodic data trace message counter then resets.
Event In If the nexus module is enabled, an EVTI assertion initiates a data trace
write/read w/ sync. message upon the next data write/read (if data trace is
enabled and the eic bits of the dc register have enabled this feature).
Attempted Access to Secure Memory Any attempted read or write to secure memory locations temporarily disable
data trace & cause the corresponding DTM to be lost. A subsequent
read/write queues a data trace read/write with sync. message.
Collision Priority All messages have the following priority: Error WPM DTM. A DTM
message which attempts to enter the queue at the same time as an error
message, or watchpoint message is lost. A subsequent read/write queues a
data trace read/write with sync. message.
DTM Queueing
NXDM and NXFR implements a programmable depth queue for queuing all messages. Messages that
enter the queue are transmitted via the auxiliary pins in the order in which they are queued.
NOTE
If multiple trace messages must be queued at the same time, watchpoint
messages have the highest priority (WPM DTM).
Relative Addressing
The relative address feature is compliant with IEEE-ISTO Nexus 5001-2003 and is designed to reduce the
number of bits transmitted for addresses of data trace messages. Relative addressing is the same as
described for the NZ7C3 in Section 13.2.14.2, “ Relative Addressing.”
System bus cycle with data error Data Trace Message discarded
System bus cycle completed without error Cycle captured and transmitted
The Nexus module provides watchpoint messaging using the TCODE. When either of the two possible
watchpoint sources asserts, a message is sent to the queue to be messaged out. This message indicates the
watchpoint number.
3 2 1
14.1 Overview
This document describes the Decimation Filter block functionality for the MPC5676R.
There are 12 independent Decimation Filter blocks (A through L) on the MPC5676R device. Each
Decimation Filter block contains a multiply-accumulate (MAC) unit capable of implementing a 16-bit, 4th
order IIR or 8th order FIR filter. The Decimation Filter blocks can be cascaded to create larger filters. Filter
output data can be decimated at a programmable rate in the range 1 to 16.
Each Decimation Filter has a 32-bit integrator unit, which allows the block to sum a series of signed or
absolute value filter outputs. The integrator input can be selected from before or after the decimator. The
integrator can be enabled and disabled, cleared, and read by software or by hardware triggers from certain
channels of the eTPU modules on the device. The integrator control triggers are selected in the
SIU_DECFIL1 and SIU_DECFIL2 and SIU_DECFIL3 registers.
The data and control registers for each Decimation Filter block are independently accessed by the CPU.
All Decimation Filters support DMA writes to the input data register, and DMA reads of the output data
register. The eQADC_A and eQADC_B blocks have an internal hardware link to Decimation Filters A
through L. This allows CPU independent transfer of eQADC_A and eQADC_B analog to digital
conversion result data to the Decimation Filter input data registers, and filter output data back to the
eQADC_A and eQADC_B conversion result FIFOs.
Each Decimation Filter block supports 4 combinations of input data source and output result destination:
1. Input from eQADC/Output to eQADC: In this mode, the Decimation Filter receives analog to
digital conversion data samples from the eQADC block. The output result from the Decimation
Filter is automatically returned to the RFIFO in eQADC that was specified in the conversion
command for the ADC input.
2. Input from system RAM/Output to system RAM: In this mode, the input data to the Decimation
filter is supplied from system RAM by the CPU or DMA. The filter data and associated commands
are written to a memory mapped input register, and the output results are written to a memory
mapped register, where they can be read by either CPU or DMA.
3. Input from eQADC/Output to system RAM: In this mode, the Decimation Filters can be
configured for input data from eQADC and output result to the system RAM (CPU or DMA).
4. Input from system RAM/Output to eQADC: In this mode, the Decimation Filter input data from
system RAM (CPU or DMA), and the output result is sent to an eQADC result FIFO.
Each Decimation Filter block can be programmed to generate interrupt requests when input data is
received from the eQADC, when the filter result is written to the output buffer, if a filter overflow occurs,
and if either input or output buffer overruns occur. An interrupt can also be generated when an integrator
result is ready to be read.
Figure 14-1 shows a system-level block diagram of a single Decimation Filter. All Decimation Filters
share the same configuration, with some differences in the hardware trigger sources for the integrator
controls.
Interrupt
CPU
eDMA_A eDMA_B Controller
Crossbar Switch
MPU
SIU
Interrupts
32-bit Count
Integrator Value
4th order
Input Tap IIR Decimator
Buffer -or- Rate 1 to Output
Regs
Buffer
8th order 16 or eTPU
FIR Trigger
Coeff
51-bit MAC
Decimation Filter Block
ADC AN[n] eTPUA
Trigger
RFIFO eQADC
14.1.1 Features
The decimation filter block includes these features:
Freeze 0 1, 1
Disabled 1 X
Module Address
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R
IDIS SAT IO_SEL[1:0] DEC_RATE[3:0] SDIE DSEL IBIE OBIE EDME TORE TMODE
W
Reset 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 14-2. Decimation Filter Module Configuration Register (DECFILT_x_MCR)
Field Description
0 Module Disable—Puts the Decimation Filter in low power mode. Communication through the eQADC Interface
MDIS is ignored in this mode. Writes to the configuration register are allowed with the exception of writes to the FREN
and SRES bits, which are ignored. Writes to the Coefficient registers are allowed. The Decimation Filter cannot
enter Freeze mode once in disable mode.
0 Normal Mode
1 Low Power Mode
1 Freeze Enable—Enables the Decimation Filter to enter freeze mode See Section 14.3.8, “Freeze Mode”, for
FREN more details.
0 Freeze mode disabled
1 Freeze mode enabled
2 Reserved
3 Freeze Mode—Controls the freeze mode of the Decimation Filter. For this bit to take effect the FREN freeze
FRZ enable bit also needs to be asserted. While in freeze mode the MAC operations are halted. See Section 14.3.8,
“Freeze Mode”, for more details.
0 Normal Mode
1 Freeze Mode
4 Software-reset bit—A self-negated bit which provides the capability to initialize the Decimation Filter interface.
SRES This bit always reads as zero. See Section 14.3.7, “Soft Reset Command”, for more details.
0 No action
1 Software-Reset
5–6 Cascade Mode Configuration—Configures the block to work in cascade mode of operation. For more details
CASCD about the cascade mode, see Section 14.3.14, “Cascade Mode”.
00 No cascade mode (single block)
01 Cascade Mode, Head block config
10 Cascade Mode, Tail block config
11 Cascade Mode, Middle block config
Note: Any change to this field must follow the procedure described in the Section 14.3.14.2, “Cascade Freeze,
Stop, and Configuration Change Procedures”.
7 Input Data Interrupt Enable—Enables the Decimation Filter to generate interrupt requests on all new input data
IDEN written to the Interface Input Buffer register.
0 Input Data Interrupt Disabled
1 Input Data Interrupt Enabled
Field Description
8 Output Data Interrupt Enable—Enables the Decimation Filter to generate interrupt requests on all new data
ODEN written to the filter Output buffer. This is independent of the IO_SEL field setting.
0 Output Data Interrupt Disabled
1 Output Data Interrupt Enabled
9 Error Interrupt Enable—Enables the Decimation Filter to generate interrupt requests based on the assertion of
ERREN the DECFILTER_MSR register error flags OVF, DIVR, SVR, OVR or IVR.
0 Error Interrupts Disabled
1 Error Interrupts Enabled
10 Reserved
13 Reserved
14–15 Filter Scaling Factor—Selects the scaling factor used by the filter algorithm.
SCAL 00 Scaling Factor = 1
01 Scaling Factor = 4
10 Scaling Factor = 8
11 Scaling Factor = 16
16 Input Disable—Disables the block input, so that writes to the input buffer have no effect and input DMA or
IDIS interrupt requests are not issued. Input disabling is needed to change the block configuration to or from cascade
mode.
0 Input enabled
1 Input disabled
17 Saturation Enable—Enables the saturation of the filter output. See Section 14.3.11, “Saturation”, for more
SAT details.
0 Disables Saturation
1 Enable Saturation
18–19 Input Data Source and Output Result Destination Selection—Selects the source of the input data to the
IO_SEL Decimation Filter, and the destination for the filter output result. The IO_SEL[1:0] encoding and associated
source and destination definitions is given below. Note that when Decimation Filters are cascaded to form larger
filters, the IO_SEL[1:0] field only is applicable to the input data source for the head filter in the cascade, and to
the output result destination for the tail filter in the cascade. Filters in the middle of the cascade receive input and
send output to their adjacent filters in the cascade. Regardless of the IO_SEL setting, the Decimation Filter input
and output buffer registers can be read by the CPU/DMA at any time, and the output buffer register is updated
in the case of the eQADC result destination. Note that the eQADC module has to be configured to send
conversion results to a decimation filter in addition to setting the IO_SEL field.
Field Description
20–23 Decimation Rate Selection—Selects the decimation rate used by the Decimation Filter. The decimation rate
DEC_RATE defines the number of data samples from the master block that is required to generate one decimated result in
the Decimation Filter output.
0000 No Decimation: one filter output for each sample input
0001–1111 One filter output for each (DEC_RATE+1) sample inputs
24 Integrator Data Interrupt Enable—Enables output buffer interrupts due to integrator data result being ready.
SDIE 0 Integration ready does not cause an output interrupt.
1 Integration ready causes an output interrupt
25 DMA Selection—Determines whether the data transfers — to the input buffer (write to) and from the output buffer
DSEL (read from) — are performed by DMA requests or by interrupt requests.
0 Interrupt requests are generated
1 DMA requests are generated
26 Input Buffer Interrupt Request Enable—Enables the Decimation Filter to generate interrupt requests when:
IBIE • CPU/DMA is selected (IO_SEL[1]=1), DSEL=0, and the input buffer is available to receive new data;
• eQADC input is selected with Enhanced debug (IO_SEL[1]=0, EDME=1), DSEL=0, and the input buffer has
data to be read by the CPU.
0 Input Buffer Interrupt Request Disabled
1 Input Buffer Interrupt Request Enabled
27 Output Buffer Interrupt Request Enable—Enables the Decimation Filter interrupt requests when outputs are
OBIE directed to the CPU/DMA and DMA requests is not selected (DSEL=0).
0 Output Buffer Interrupt Request Disabled
1 Output Buffer Interrupt Request Enabled
29 Enhanced Debug Monitor Enable—Defines the enhanced debug monitor when input selection is from eQADC
EDME (IO_SEL[1]=0).
0 Enhanced debug monitor disabled
1 Enhanced debug monitor enabled
29 Triggered Output Result Enable—Enables an eTPU signal to transfer the filter result to its destination, using the
TORE mode specified by TMODE[1:0].
0 Output buffer transfer by eTPU signal disabled
1 Output buffer transfer by eTPU signal enabled1
30–31 Trigger Mode—Selects the way the eTPU signal controls the transfer of a new output result
TMODE 00 result is transferred at the rising edge of the eTPU signal
01 result is transferred while the eTPU signal is 0
10 result is transferred at the falling edge of the eTPU signal
11 result is transferred while the eTPU signal is 1
1
Refer to Section 3.2.1.24, “Decimation Filter Register 4, 5 (SIU_DECFIL4, SIU_DECFIL5) for details of available signals.
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R 0 0 0 0 0 0 IDF ODF 0 IBIF OBIF 0 DIVR OVF OVR IVR
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 14-3. Decimation Filter Status Register (DECFILT_x_MSR)
Field Description
0 Decimation Filter Busy indication—The BSY bit indicates that the Decimation Filter is actively processing a new
BSY input data sample. BSY is not asserted when the filter is disabled (FTYPE = 00). The BSY bit is asserted when
the soft reset is executed.
0 Decimation Filter Idle
1 Decimation Filter Busy
1 Reserved
2–5 Decimation Counter—The DEC_COUNTER[3:0] field indicates the current value of the DEC_COUNTER
DEC_ Decimation Counter, which counts the number of input data samples received by the Decimation Filter. When
COUNTER the value of this counter matches the DEC_RATE[3:0] Configuration Register field, one result is available and
the DEC_COUNTER counter is re-initialized at zero. This register is cleared by a soft reset or a flush command.
6 Input Data Flag Clear bit—The IDFC bit clears the IDF Flag bit in the Status Register. This bit is self negated,
IDFC therefore it is always read as zero.
0 No action
1 Clears IDF
7 Output Data Flag Clear bit—The ODFC bit clears the ODF Flag bit in the Status Register. This bit is self negated,
ODFC therefore it is always read as zero.
0 No action
1 Clears ODF
8 Reserved
9 Input Buffer Interrupt Request Clear bit—The IBIC bit clears the IBIF Flag bit in the Status Register. This bit is
IBIC self negated, therefore it is always read as zero.
0 No action
1 Clears IBIF
10 Output Buffer Interrupt Request Clear bit—The OBIC bit clears the OBIF Flag bit in the Status Register. This bit
OBIC is self negated, therefore it is always read as zero.
0 No action
1 Clears OBIF
11 Reserved
Field Description
12 DIVR Clear bit—The DIVRC bit clears the DIVR Debug Filter Input Data Read Overrun indication bit in the Status
DIVRC Register. This bit is self negated, therefore it is always read as zero.
0 No action
1 Clears DIVR
13 OVF Clear bit—The OVFC bit clears the OVF Output Overflow bit in the Status Register. This bit is self negated,
OVFC therefore it is always read as zero.
0 No action
1 Clears OVF
14 OVR Clear bit—The OVRC bit clears the OVR Output Overrun bit in the Status Register. This bit is self negated,
OVRC therefore it is always read as zero.
0 No action
1 Clears OVR
15 IVR Clear bit—The IVRC bit clears the IVR Filter Input Overrun indication bit in the Status Register. This bit is
IVRC self negated, therefore it is always read as zero.
0 No action
1 Clears IVR
16–21 Reserved
22 Input Data Flag—The IDF bit flag indicates when new data is available at the DECFILT_x_IB register or at the
IDF DECFILT_x_IOB register. This flag generates an Interrupt Request if enabled by the IDEN bit in the
Configuration Register. This Flag is cleared by setting the IDFC Status bit or by a soft reset of the decimation
filter.
0 Sample not received
1 New Sample received
Note: This flag is not used for read / write requests. It is used only to announce the input data event. For read /
write request flag, refer to IBIF.
23 Output Data Flag—The ODF bit flag indicates when a new decimated sample is available at the DECFILT_x_OB
ODF register or at the DECFILT_x_IOB register. This flag generates an Interrupt Request if enabled by the ODEN bit
in the Configuration Register. This Flag is cleared by setting the ODFC Status bit or by a soft reset of the
decimation filter.
0 No new Decimated Output Sample available
1 New Decimated Output Sample available
Note: This flag is not used for read requests. It is used only to announce the output data event. For read request
flag, refer to OBIF.
24 Reserved
25 Input Buffer Interrupt Request Flag—The IBIF bit flag indicates that the input buffer DECFILT_x_IB is available
IBIF to be filled with new data, when Enhanced Debug Monitor is off. In Enhanced Debug Monitor, it indicates the
input buffer DECFILT_x_IB was filled with a new sample and is ready to be read. This flag is cleared by setting
the IBIC bit or by a soft reset of the decimation filter.
0 No action
1 New Sample is requested (IO_SEL[1] = 1, EDME=0) or new sample is available in Enhanced Debug Monitor
(IO_SEL[1]=0, EDME=1).
26 Output Buffer Interrupt Request Flag—The OBIF bit flag indicates that either a new decimated sample is
OBIF available at the DECFILT_x_OB register. This flag is cleared by setting the OBIC bit or by a soft reset of the
decimation filter.
0 No new Decimated Output available
1 New Decimated Output available
27 Reserved
Field Description
28 Enhanced Debug Monitor Input Data Read Overrun—The DIVR bit indicates that a received sample in the Filter
DIVR Interface Input Register was overwritten by a new sample and was not read by the CPU/DMA. This flag
generates an Interrupt Request if enabled by the ERREN bit in the Configuration Register. This Flag is cleared
by the DIVRC Status bit or by a soft reset of the decimation filter.
0 Input Data Read Overrun did not occur in Enhanced Debug monitor
1 Enhanced Debug Monitor Input Data Read Overrun occurred
29 Filter Overflow Flag—The OVF bit indicates that an overflow occurred in the filtered sample result. This flag
OVF generates an Interrupt Request if enabled by the ERREN bit in the Configuration Register. This Flag is cleared
by the OVFC Status bit or by a soft reset of the decimation filter.
0 No overflow
1 Overflow occurred
30 Output Interface Buffer Overrun—The OVR bit indicates that a decimated sample was overwritten by a new
OVR sample in the Interface Output Buffer Register. This flag generates an Interrupt Request if enabled by the
ERREN bit in the Configuration Register. This Flag is cleared by the OVRC Status bit or by a soft reset of the
decimation filter.
0 No Output Overrun
1 Filter Output Overrun occurred
31 Input Interface Buffer Overrun—The IVR bit indicates that a received sample in the Filter Interface Input Register
IVR was overwritten by a new sample. This flag generates an Interrupt Request if enabled by the ERREN bit in the
Configuration Register. This Flag is cleared by the IVRC Status bit or by a soft reset of the decimation filter.
0 Input Buffer Overrun did not occur
1 Input Buffer Overrun occurred
Note: This bit does not set on an input register write when the input is disabled (DECFILTER_x_MCR[IDIS]=1).
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R 0 0 0 0 0 0
SISEL SZROSEL SHLTSEL SRQSEL SENSEL
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 14-4. Decimation Filter Extended Configuration Register (DECFILT_x_MXCR)
Field Description
0 Integrator DMA Enable—The SDMAE bit enables a DMA request when an integrator output is available (see
SDMAE Section 14.3.13.2, “Integrator Output”).
0 Integrator DMA request disabled
1 Integrator DMA request enabled
Note: The DMA channel used is the same one used for filter outputs, and any configuration that generates DMA
requests from both of those sources is not allowed.
1 Integrator Signal operation selection—The SSIG bit defines how the filtered data signal is treated for integration:
SSIG 0 Integrator input takes the absolute value of filter output
1 Integrator input takes the signed filter output
2 Integrator Saturated operation selection—The SSAT bit defines how the integrator accumulator behaves in case
SSAT of an overflow.
0 Integrator accumulator holds a modulo 217 value (considering the 15-bit fractional part) on an overflow.
1 Integrator accumulator saturates on an overflow
Note: In saturated operation the overflown integration sum holds the value 0xFFFFFFFF for absolute integration
(SSIG=0), or values 0x7FFFFFFF (positive saturation) and 0x80000000 (negative saturation) for signed
integration (SSIG=1).
Note: Non-saturated mode is not supported with signed integration, therefore one must not configure SSIG=1
and SSAT=0.
3 Integrator Counter Saturated operation selection—The SCSAT bit defines how the integrator sample counter
SCSAT behaves in case of an overflow.
0 Integrator sample counter holds a modulo 232 value on an overflow.
1 Integrator sample counter saturates on an overflow, holding a value of 0xFFFFFFFF.
4–13 Reserved
14 Integrator Output Request—The SRQ bit is used to command the update of the integrator output, reflected in
SRQ the registers DECFILT_x_FINTVAL and DECFILT_x_FINTCNT. It may also cause a DMA or interrupt request,
depending on the DECFILT_x_MCR bit SDIE and DECFILT_x_MXCR bit SDMAE. This is a write-only bit, so
reads always return 0. For more details see Section 14.3.13.2, “Integrator Output”.
0 No integrator output update request
1 Requests integrator output update
15 Integrator Zero—The SZRO bit is used to zero the integrator sum. This is a write-only bit, reads always return
SZRO 0. For more details see Section 14.3.13.3, “Integrator Reset”.
0 Does not zero integrator sum
1 Zeroes integrator sum
Note: If bits SRQ and SZRO are both written 1 at the same time, the integrator is reset only after the registers
DECFILT_x_FINTVAL and DECFILT_x_FINTCNT are updated.
16 Integrator Input Selection—The SISEL bit selects the input of the integrator. For more details see
SISEL Section 14.3.13.1, “Integrator Inputs”.
0 Decimated filter outputs feed the integrator
1 Filter outputs before the decimation feed the integrator
17 Reserved
Field Description
18–19 Integrator Zero Control Mode Selection—The SZROSEL field defines the use of the integrator zero hardware
SZROSEL input signal. For more details see Section 14.3.13.3, “Integrator Reset”.
SZROSEL[1:0] Description
22–23 Integrator Halt Control Selection—The SHLTSEL field defines the integrator halting mechanism. When the
SHLTSEL integrator is halted, the integration accumulator remains unaltered on filter outputs independently of the enabling
selected by SENSEL. For more details see Section 14.3.13.4, “Integrator Enabling and Halting”.
SHLTSEL[1:0] Description
25–27 Integrator Output Read Request Mode Selection—The SRQSEL field defines the use of the integrator output
SRQSEL read request hardware input signal. An integrator output read request updates the registers
DECFILT_x_FINTVAL and DECFILT_x_FINTCNT, also causing a DMA or interrupt request. Note that DMA or
interrupt requests due to integrator output updates depend on the DECFILT_x_MXCR bit SDMAE and
DECFILT_x_MCR bit SDIE.
When continuous output is on, an integrator output read request is automatically issued whenever a new filter
output is accumulated. For more details see Section 14.3.13.2, “Integrator Output”.
SRQSEL[2:0] Description
100 Reserved
Field Description
28–29 Reserved
30–31 Integrator Enable Control Selection—The SENSEL field defines the integrator enabling mechanism. When the
SENSEL integrator is enabled, filter outputs selected by the SISEL bit are added to the integration accumulator. When the
integrator is disabled, the integration accumulator remains unaltered on filter outputs. For more details see
Section 14.3.13.4, “Integrator Enabling and Halting”.
SENSEL[1:0] Description
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R 0 0 0 0 0 0 0 SDF 0 0 SSE SCE 0 SSOVF SCOVF SVR
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 14-5. Decimation Filter Extended Status Register (DECFILT_x_MXSR)
Field Description
0–6 Reserved
7 Integrator Output Data Flag Clear bit—The SDFC bit clears the SDF Flag bit in the Status Register. This bit is
SDFC self negated, therefore it is always read as zero.
0 No action
1 Clears SDF
8–9 Reserved
Field Description
10 SSEC — Integrator Sum Exception Clear bit—The SSEC bit clears the SSE flag bit in the Status Register. This
SSEC bit is self negated, therefore it is always read as zero.
0 No action
1 Clears SSE
11 Integrator Count Exception Clear bit—The SCEC bit clears the SCE flag bit in the Status Register. This bit is self
SCEC negated, therefore it is always read as zero.
0 No action
1 Clears SCE
12 Reserved
13 Integrator Sum Overflow Clear bit—The SSOVFC bit clears the SSOVF Flag bit in the Status Register. This bit
SSOVFC is self negated, therefore it is always read as zero.
0 No action
1 Clears SSOVF
14 Integrator Count Overflow Clear bit—The SCOVFC bit clears the SCOVF Flag bit in the Status Register. This bit
SCOVFC is self negated, therefore it is always read as zero.
0 No action
1 Clears SCOVF
15 SVR Clear bit—The SVRC bit clears the SVR Integrator Data Overrun indication bit in the Status Register. This
SVRC bit is self negated, therefore it is always read as zero.
0 No action
1 Clears SVR
16–22 Reserved
23 Integrator Data Flag—The SDF bit flag indicates when a new integrator result is available at the
SDF DECFILT_x_FINTVAL register. This flag generates an Interrupt Request if enabled by the SDIE bit in the
Configuration Register. This Flag is cleared by the SDFC Status bit or by a soft reset of the decimation filter.
0 No new integrator result available
1 New integrator result available
24–25 Reserved
26 Integrator Sum Exception flag—The SSE bit indicates an exceptional condition of the integrator accumulator.
SSE This flag generates an Interrupt Request if enabled by the DECFILT_x_MCR bit ERREN, and it is cleared by the
SSEC bit or by a soft reset. Integrator exceptions are defined in Section 14.3.13.5, “Integrator Exceptions”.
0 No exception in the integrator accumulator.
1 Integrator accumulator exception.
27 Integrator Count Exception flag—The SCE bit indicates an exceptional condition of the integrator counter. This
SCE flag generates an Interrupt Request if enabled by the DECFILT_x_MCR bit ERREN, and it is cleared by the
SCEC bit or by a soft reset. Integrator exceptions are defined in Section 14.3.13.5, “Integrator Exceptions”.
0 No exception in the integrator counter.
1 Integrator counter exception.
28 Reserved
Field Description
29 Integrator Sum Overflow Flag—The SSOVF bit indicates an overflow of the integrator accumulator. This Flag is
SSOVF cleared by the SSOVFC bit or by a soft reset.
0 No overflow in the integrator accumulator.
1 Integrator accumulator overflown.
Note: The SSOVF bit samples the integrator accumulator overflow condition when and only when either
registers DECFILT__FINTVAL or DECFILT__CINTCNT are updated. Therefore, only one of the register
pairs (DECFILT_x_FINTVAL/DECFILT_x_FINTCNT and DECFILT_x_CINTVAL/DECFILT_x_CINTCNT)
must be used by the application, in order to avoid races.
30 Integrator Count Overflow Flag—The SCOVF bit flag indicates an overflow of the internal integrated sample
SCOVF counter. This Flag is cleared by the SCOVFC bit or by a soft reset.
0 No overflow in the integrator sample counter.
1 Integrator sample counter overflown.
Note: The SCOVF bit samples the integrator accumulator overflow condition when and only when either
registers DECFILT_x_FINTVAL or DECFILT_x_CINTCNT are updated. Therefore, only one of the register
pairs (DECFILT_x_FINTVAL/DECFILT_x_FINTCNT and DECFILT_x_CINTVAL/DECFILT_x_CINTCNT)
must be used by the application, in order to avoid races.
31 Integrator Data Overrun—The SVR bit indicates that an integration value and count in the registers
SVR DECFILT_x_FINTVAL and DECFILT_x_FINTCNT was overwritten by a new integrator output request and was
not read by the CPU or DMA. This flag generates an Interrupt Request if enabled by the ERREN bit in the
Configuration Register. This Flag is cleared by the SVRC bit or by a soft reset.
0 Integrator Data Overrun did not occur.
1 Integrator Data Overrun occurred.
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R
INPBUF[15:0]
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 14-6. Decimation Filter Interface Input Buffer Register (DECFILT_x_IB)
Field Description
0–2 Reserved
3 The OSEL bit indicates whether the filter output returns to eQADC_A or eQADC_B. This field has no meaning
OSEL when both the data source and destination are not eQADC modules.
0 Result data is returned to eQADC_A
1 Result data is returned to eQADC_B
4–7 Decimation filter input tag bits —The INTAG[3:0] bit field is defined as a selector signal and it is used to identify
INTAG different destinations for the INBUF[15:0] data.
When the input data source is the CPU/DMA and the output destination is an eQADC, INTAG is used to address
the appropriate RFIFO in the eQADC block.
8–13 Reserved
14 Decimation Filter Prefill/Filter control bit—The PREFILL bit selects the Decimation Filter operation mode. For
PREFILL more details, see Section 14.3.4, “Filter Prefill Control”.
0 Decimation Filter normal sample
1 Decimation Filter prefill sample
15 Decimation Filter Flush control bit—Assertion of the FLUSH bit initializes the Decimation Filter to a initial state,
FLUSH as defined in Section 14.3.6, “Flush Command”. This bit is self negated and it is cleared only when the data is
read and the flush is executed.
0 No flush request
1 Flush request
16–31 Input Buffer Data—The INPBUF[15:0] bit field carries the sample data to be filtered. This data buffer can be
INPBUF written from the eQADC or by the CPU/DMA. See Section 14.3.1, “Decimation Filter Input”, for more details.
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R OUTBUF[15:0]
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 14-7. Decimation Filter Interface Output Buffer Register (DECFILT_x_OB)
Field Description
0–10 Reserved
11 The OSEL bit indicates whether the filter output returns to eQADC_A or eQADC_B. This field has no meaning
OSEL when the destination is not an eQADC module.
0 Result data is returned to eQADC_A
1 Result data is returned to eQADC_B
12–15 Decimation filter output tag bits—The OUTTAG[3:0] bit field is defined as a selector signal and it is used to
OUTTAG identify different destinations for the OUTBUF[15:0] data.
When the output result destination is an eQADC, OUTTAG holds the same value as the DECFILT_x_IB[INTAG],
which is used to address the destination RFIFO.
16–31 Output Buffer Data—The OUTPBUF[15:0] bit field is the result data in the decimation filter Output Buffer. It
OUTBUF represents a fixed point signed number in two’s complement format and is updated only when a decimated result
is ready to be transmitted, meaning it contains the last decimated result from the filter.
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R
COEFn[15:0]
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 14-8. Decimation Filter Coefficient n Register (DECFILT_x_COEFn)
Field Description
0–31 Coefficient n field—The COEFn[23:0] bit fields are the digital filter coefficients registers. The coefficients are
COEFn fractional signed values in two’s complement format, in the range (-1 coef < 1).
Note: Reads to this register are sign-extended, meaning the coefficient’s sign bit is copied to all 8 most
significant register bits.
Note: Writing to these fields when BSY=1 is not allowed.
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R TAPn[15:0]
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 14-9. Decimation Filter TAPn Register (DECFILT_x_TAPn)
Field Description
0–31 TAPn Register—The read-only TAPn[23:0] bit fields shows the contents of the digital filter tap registers, as
TAPn fractional signed values in two’s complement format, in the range (-1 coef < 1). The tap registers hold the input
data delay line (Xn, Xn-1,......,Xn-7 for 8th order FIR).
Note: Reads to this register are sign-extended, meaning the coefficient’s sign bit is copied to all 8 most
significant register bits.
Note: The content of these registers is meaningless when BSY=1.
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R SAMP_DATA[15:0]
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 14-10. Decimation Filter Interface Input Buffer Register (DECFILT_x_EDID)
Field Description
0–15 Reserved
16–31 Conversion Sample Data—The SAMP_DATA[15:0] bit field carries the data that was loaded into the Decimation
SAMP_DATA Filter input buffer to be processed by the FIR/IIR sub-block. This value is only updated by input data received
from an eQADC (DECFILT_x_MCR[IO_SEL[1]] = 0), and the Enhanced Debug Monitor is enabled
(DECFILT_x_MCR[EDME] = 1).
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R SUM_VALUE[15:0]
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 14-11. Decimation Filter Final Integration Value Register (DECFILT_x_FINTVAL)
Field Description
0–31 Integration Sum Value—The SUM_VALUE[31:0] field holds the sum of filtered output values. The 17 most
SUM_VALUE significant bits hold the integer part, and the 15 least significant ones the fractional part of the integration value.
The control of the integration sum and update of this register is determined by the register DECFILT_x_MXCR
(see Section 14.2.2.3, “Decimation Filter Module Extended Configuration Register (DECFILT_x_MXCR)”). The
register is updated only upon an integration output request.
SUM_VALUE should be taken as an unsigned number when the integrator is configured for absolute operation
(DECFILTER_MXCR bit SSIG=0), and a two’s complement signed number otherwise.
Note: If DEFILT_x_MXCR[SSAT]=0, DECFILT_x_FINTVAL holds the integration sum modulo 217 (considering
the 15-bit fractional part).
Note: If DEFILT_x_MXCR[SSAT]=1, the integration sum is saturated, so that if the accumulation overflows
DECFILT_x_FINTVAL holds the value 0xFFFFFFFF for absolute integration (SSIG=0), or values
0x7FFFFFFF (positive saturation) and 0x80000000 (negative saturation) for signed integration (SSIG=1).
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R COUNT[15:0]
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 14-12. Decimation Filter Final Integration Count Value Register (DECFILT_x_FINTCNT)
Field Description
0–31 Integration Count Value—The COUNT field holds the count of filtered outputs integrated. The control of the
COUNT integration sum and update of this register is determined by the register DECFILT_x_MXCR. The register is
updated together with DECFILT_x_FINTVAL, only upon an integration output request.
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R SUM_VALUE[15:0]
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 14-13. Decimation Filter Current Integration Value Register (DECFILT_x_CINTVAL)
Field Description
0–31 Integration Sum Value—The SUM_VALUE[31:0] field holds an unsigned number representing the sum of filtered
SUM_VALUE output values, continuously updated as the integration proceeds. The control of the integration sum is
determined by the register DECFILT_x_MXCR (see Section 14.2.2.3, “Decimation Filter Module Extended
Configuration Register (DECFILT_x_MXCR)”).
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R COUNT[15:0]
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 14-14. Decimation Filter Current Integration Count Value Register (DECFILT_x_CINTCNT)
Field Description
0–31 Integration Count Value—The COUNT field holds the count of filtered outputs integrated. The value is updated
COUNT only when register DECFILT_x_CINTVAL is read, to keep the coherency between the integration and count
values.
When the filter is bypassed (DECFILT_x_MCR[FTYPE] = 0b00) or in disable mode, the data from the
input buffer is transferred to the output buffer, if it is not already full. If the output buffer is full, the input
buffer is loaded, and another word of input data is sent, then an input overrun occurs.
When bypass mode is selected, an output overrun cannot occur because the data written into the input
buffer (DECFILT_x_IB) is written into the output buffer (DECFILT_x_OB) only when this buffer is
empty, but an input overrun may still occur (see Section 14.3.1.1, “Input Buffer Overrun”).
By-pass
00
A y(n)
x(n) Register Coefficient 0 + + Scale Factor S Round/Sat
IIR
Round/Sat
FIR
01 10
B
-1 -1 FTYPE[1:0]
Z Z
-1 -1
Z Z
-1 -1
Z Z
-1 -1
Z Z
14.3.10 Rounding
The Decimation Filter performs rounding operations in two different locations, as shown in Figure 14-15:
• to obtain the filter output result with 16 bits
• to obtain the IIR feedback result to be stored in tap4 registers with 24 bits
The rounding mechanism implements the Convergent Rounding methodology (also known as
round-to-nearest even number), which makes the decision on rounding up or down based on the value of
the lower portion of data to be rounded (LS_WORD). The rounding up/down condition is equal to the
traditional rounding except when the LS_WORD has the format {1000...00}. In this particular case, the
rounding procedure is like the example of Figure 14-16. If the MS_WORD is odd, the value is rounded
up. Otherwise the value is rounded down.
+0
MS_WORD LS_WORD
+1
14.3.11 Saturation
Filter output saturation occurs when an overflow or underflow condition of the filter is detected by
dedicated logic, and if it is enabled by the SAT control bit of the configuration register DECFILT_x_MCR.
In this condition, the filter output is set to a saturated value equal to the maximum or minimum value that
can be represented by the 16-bit output port. Also, for the IIR filter an equivalent logic is used to assert the
saturation for the 24-bit feedback result.
14.3.13 Integrator
The decimation filter output result may be optionally routed to a dedicated hardware integrator. The
integrator may be operated in a windowed mode, controlled by signals routed internally from eTPU2
channels, or operated in a continuous mode. Additionally, the integrator output may be configured to
saturate at the maximum value of the supported range, or permitted to continue integration. Figure 14-17
shows the high level data flows and controls for the integrator. The RFIFO and Output Buffer data paths
are shown in this figure to highlight that they are independent of the integrator. Note however that the
Output Buffer shares a DMA and Interrupt request with the Integrator output value, FINTVAL
(DECFILTER_FINTVAL).
eTPU2 eTPU2
Channel Channel
Filter
Integration Sample
Value Count
An integrator output update can also issue a DMA or interrupt request. The interrupt and DMA requests
are the same ones used for the filter output buffer (see Section 14.3.12.2, “Output Buffer Interrupt and
DMA Requests”, and Section 14.3.12.1.3, “Input Buffer DMA Request”). DECFILTER_MCR[SDIE] is
used to enable integrator interrupts, and the DECFILTER_MXCR[SDMAE] enables the DMA integrator
requests. The integrator DMA request uses the same signal as the filter output DMA request, so one must
never use any configuration that allows both the integrator and filter output to make DMA requests.
Integrator output updates are flagged by DECFILTER_MXSR[SDF]. The integrator overrun is detected in
the same way as a filter output buffer overrun, and is flagged by DECFILTER_MXSR[SVR]. An
integrator overrun also generates an error interrupt if DECFILTER_MCR[ERREN] = 1 (see
Section 14.3.2.1, “Output Buffer Overrun”).
Registers DECFILTER_CINTVAL and DECFILTER_CINTCNT provide a way to poll intermediate
integration values and sample counts, respectively (see Section 14.2.2.12, “Decimation Filter Current
Integration Value Register (DECFILT_x_CINTVAL)”, and Section 14.2.2.13, “Decimation Filter Current
Integration Count Value Register (DECFILT_x_CINTCNT)”). DECFILTER_CINTVAL is updated
whenever the integrator is reset or a new sample is accumulated. DECFILTER_CINTCNT is updated only
when DECFILTER_CINTVAL is read, so that coherency between the value and count values is
guaranteed. Therefore, the read access order of that pair of registers must be DECFILTER_CINTVAL first,
followed by DECFILTER_CINTCNT.
NOTE
The flags SSOVF and SCOVF can also asserted when
DECFILTER_CINTVAL is read. The SSOVF and SCOVF set and clearing
rules apply for the DECFILTER_CINTVAL read the same way as for an
integrator output request.
for counter exception. These flags generate an error interrupt, if it is enabled (see Section 14.3.12,
“Interrupts and DMA Overview”).
The accumulator exception condition depends on whether it operates in saturated mode or not, as follows:
• In Saturated operation (DECFILTER_MXCR[SSAT] = 1): a sum exception occurs (SSE=1)
whenever an overflow is flagged; SSE asserts together with SSOVF.
• In Non-saturated operation (DECFILTER_MXCR[SSAT] = 0): a sum exception occurs (SSE=1)
when an overflow is flagged and DECFILTER_MXSR[SSOVF] is already set to 1.
• In Non-saturated operation, an accumulator exception also occurs if the accumulator overflows
twice without any update of the final integrator value DECFILTER_FINTVAL or the current
integrator counter DECFILTER_CINTCNT (by a read to the DECFILTER_CINTVAL register),
neither an integrator reset occurs. The SSOVF flag does not assert in this situation.
NOTE
The SSOVF flag can only be asserted upon a hardware request, a software
request, or when DECFILTER_CINTVAL is read, based on the internal
accumulator overflow state.
Similarly, the sample counter exception condition depends on whether it operates in saturated mode or not,
as follows:
• In Saturated operation (DECFILTER_MXCR[SCSAT] = 1): a counter exception occurs (SCE=1)
whenever an overflow is flagged; SCE asserts together with SCOVF.
• In Non-saturated operation (DECFILTER_MXCR[SCSAT] = 0): a counter exception occurs
(SCE=1) when an overflow is flagged and the DECFILTER_MXSR bit SCOVF is already set to 1.
• In Non-saturated operation, a counter exception also occurs if the counter overflows twice without
any update of the final count DECFILTER_FINTCNT or the current integrator counter
DECFILTER_CINTCNT (by a read to the DECFILTER_CINTVAL register), neither an
integration reset occurs. The SCOVF flag does not assert in this situation.
NOTE
The SCOVF flag can only be asserted upon a hardware request, a software
request, or when DECFILTER_CINTVAL is read (also updating
DECFILTER_CINTCNT), based on the internal counter overflow state.
preceding and following decimation filter blocks in the cascade. Middle blocks are optional. A minimum
of two blocks, one head block feeding one tail block can be used in cascade.
NOTE
The values passed between cascaded blocks can be monitored using
Enhanced Debug Monitor (see Section 14.3.15, “Enhanced Debug Monitor
Description”).
The following are general considerations for creating and using cascaded filters:
• The block configurations as head, tail or middle must respect their physical connections such that
all the following apply:
— a ‘head’ block must feed a ‘middle’ or a ‘tail’ block
— a ‘middle’ must feed another ‘middle’ block or a ‘tail’ block
— a ‘tail’ feeds no other block, and its output will be either the CPU/DMA interface or the
eQADC FIFOs.
— A ‘head’ is fed by no other block. Its input is either the CPU/DMA interface or the eQADC.
— Cascaded filters must be sequential, that is; Filter A feeds Filter B which feeds Filter C etc.
• As a consequence of the conditions above, there must be one and only one ‘head’ block and one
and only one ‘tail’ block in a cascade.
• More than one group of physically chained blocks can form a cascade. For example, Figure 14-19
shows two physical chains, with blocks A and B configured as head and tail, respectively, forming
one cascaded filter block. Two of the remaining blocks form another cascaded filter block starting
with block E (head), and ending with block F (tail).
• Blocks not used in a cascaded chain can be used normally by setting the
DECFILT_x_MCR[CASCD] field to 0b00, as shown in Section 14.3.14.1.
• The optional connection show from block L to block A in Section 14.3.14.1 allows block L to be
configured as head or middle, feeding block A configured as middle or tail, yielding more
flexibility, as in the last example of Section 14.3.14.1.
• The input to a cascaded configuration is selected by the DECFILT_x_MCR[IO_SEL] bit-field of
the head block. The output target of the cascaded blocks is selected by the
DECFILT_x_MCR[IO_SEL] bit-field of the tail block.
Configuration/Control DECFILT_A
(head) Data
eQADC
MCR[IO_SEL]=0b00
MCR[CASCD]=0b01
DECFILT_B
CPU (middle) RFIFOs
MCR[IO_SEL]=0b00
MCR[CASCD]=0b11
DECFILT_C
(tail)
MCR[IO_SEL]=0b00
MCR[CASCD]=0b10
Configuration/Control DECFILT_A
Data eQADC
(head) Data
MCR[IO_SEL]=0b00
MCR[CASCD]=0b01
RFIFOs
CPU DECFILT_B
(tail)
MCR[IO_SEL]=0b00
MCR[CASCD]=0b10
DECFILT_E
(head)
MCR[IO_SEL]=0b00
MCR[CASCD]=0b01
DECFILT_F
(tail)
MCR[IO_SEL]=0b00
MCR[CASCD]=0b10
DECFILT_A
Tail
eQADC
DECFILT_B
Single
CPU
DECFILT_C RFIFOs
Head
DECFILT_D
Middle
Configuration and Control Configurations:
Head:
DECFILT_E MCR[IO_SEL]=0b00
Tail MCR[CASCD]=0b01
Middle:
DECFILT_F MCR[IO_SEL]=0b00
Single MCR[CASCD]=0b11
Tail:
MCR[IO_SEL]=0b00
DECFILT_K
MCR[CASCD]=0b10
Head
Single:
MCR[IO_SEL]=0b00
DECFILT_L MCR[CASCD]=0b00
Middle
• Take the Head to freeze or low-power first, wait for DECFILTER_x_MSR bit BSY=0, and repeat
the procedure for the other blocks in the chain in sequence, towards the Tail block.
Take the blocks out of freeze or low-power modes in the inverse sequence, from Tail to Head.
The Alternate and Extended Alternate Configurations are stored in the ADC by executing write commands
to the On-Chip ADC Alternate and Extended Alternate Configuration Registers. The write command is
specified in the Write Configuration Command Format for On-Chip ADC Operation section of the
reference manual. The Alternate and Extended Alternate Configuration register addresses an eQADC are
given in Table 19-20 and described in detail in the Section 19.6.3.6, “Alternate Configuration 1-14 Control
Registers (ADC_ACR1-14)” and Section 19.6.3.7, “ADC0/1 Alternate Gain Registers (ADC0_AGR1-2
and ADC1_AGR1-2)”.
x(n) B0 + + y(n)
-1 -1
Z Z
x(n-1) B1 + + A1 y(n-1)
-1 -1
Z Z
x(n-2) B2 + A2 y(n-2)
+
-1 -1
Z Z
x(n-3) B3 + + A3 y(n-3)
-1 -1
Z Z
x(n-4) B4 A4 y(n-4)
The generalized difference equation for the IIR filter of Figure 14-21 can be written as:
Eqn. 14-1
N M
yn =
B xn – i + A yn – j
i j
i=0 j=1
where x(n) is the filter input at time n, y(n) is the filter output at time n, N is the number of feed-forward
filter coefficients minus one, Bi are the feed-forward filter coefficients, M is the number of feed-back filter
coefficients, and Aj are the feedback filter coefficients.
In order to optimize the hardware implementation, the coefficients must be scaled to a maximum range of
+1 to -1. Taking scaling into account, Equation 14-1 can be expressed as:
Eqn. 14-2
N M
Bi Aj
yn = S
S
----- x n – i +
-----y n – j
S
i = 0 j=1
All coefficients are scaled down by S, and the output of the accumulator is multiplied by S.
The block diagram shown in Figure 14-22 represents the hardware implementation of the Decimation
Filter, which includes the scale factor hardware that compensates for the scaling of the coefficients. The
scale factor, S, is set by the bit field DECFILT_x_MCR[SCAL].
Coefficients B0 to B4 correspond to DECFILT_x_COEF0 to DECFILT_x_COEF4
Coefficients A1 to A4 correspond to DECFILT_x_COEF5 to DECFILT_x_COEF8.
The delay taps labelled Tap0 to Tap7 correspond to the memory mapped registers DECFILT_x_TAP0 to
DECFILT_x_TAP7.
-1 -1
Z Z
Tap0 B1 A1 Tap4
-1 -1
Z Z
Tap1 B2 A2 Tap5
-1 -1
Z Z
Tap2 B3 A3 Tap6
-1 -1
Z Z
Tap3 B4 A4 Tap7
The examples given here implement a filter with the following characteristics:
• Filter type: elliptic/low pass IIR
• Filter order: 4th order
• Input sample rate: 800k sample/s
• Passband edge: 100 kHz
• Stopband edge: 150 kHz
• Passband attenuation: 1 dB
Table 14-17 lists the computed coefficients, in real number notation, to achieve the above characteristics.
Table 14-17. Computed Coefficient Values
B0 0.0221455 A0 -1.0
B1 0.00445582948893748 A1 2.69772868375858
B2 0.0318517846509088 A2 -3.234056294853
B3 0.00445582948893748 A3 1.92028561712454
B4 0.0221455 A4 -0.47939080709495
Since the number range of the computed coefficients exceeds the range of the hardware, the coefficients
must be scaled, by at least a factor of 4. In this example, a factor of 8 is chosen. Table 14-18 below lists
the scaled values and their 24 bit signed fractional values, in hexadecimal notation.
Table 14-18. Coefficient Values for Decimation Filter
Hexadecimal Values
Filter Coefficients Decimal Value Decimal Value
(24 bits)
c) Configure and enable a DMA channel or CPU interrupt handler to transfer result from RFIFO
to memory.
6. If the input data source is the CPU/DMA, configure a CPU interrupt handler or polling software to
input unfiltered data and retrieve the filter data.
14.5.2.1.2 DECFILT_A_COEFn
Write the filter coefficients given in Table 14-18 to the following registers.
DECFILT_A_COEF0 = 0x005AB5
DECFILT_A_COEF1 = 0x001240
DECFILT_A_COEF2 = 0x008277
DECFILT_A_COEF3 = 0x001240
DECFILT_A_COEF4 = 0x005AB5
DECFILT_A_COEF5 = 0x2B29E6
DECFILT_A_COEF6 = 0xCC414E
DECFILT_A_COEF7 = 0x1EB97D
DECFILT_A_COEF8 = 0xF8546A
Note that the ADC_ADRn registers are internal to the ADC and can only be accessed indirectly by writing
a register write command to the eQADC CFIFO. To do this the CPU should write a command to any eQADC
CFIFO with the following format:
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
EB R/W
EOQ PAUSE REP RESERVED BN ADC_REGISTER HIGH BYTE
(0b0) (0b0)
CFIFO Header ADC Command
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
ADC Command
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
CHANNEL_NUMBER ALT_CONFIG_SEL
ADC Command
The ALT_CONFIG_SEL field should be set to select the ADC_ACRn register that was configured in
Section 14.5.2.1.3. For example, if ADC_ACR1 were selected, then the ALT_CONFIG_SEL field should
be 0x08.
14.5.2.2 Use Case 2 - Input/Output from/to the CPU/DMA, Stored data filtering.
The input to Filter C is through the memory mapped input register.
Filter C is configured as a 4th order low pass IIR.
The output from the filter is routed to a memory mapped output register and an interrupt is issued when
new data is available.
In this example the ADC is not used at all, and no ADC configuration or commands are needed to support
the Decimation Filter operation.
Decimation is not enabled.
Saturation is enabled.
14.5.2.2.2 DECFILT_C_COEFn
Write the filter coefficients given in Table 14-18 to the following registers.
DECFILT_C_COEF0 = 0x005AB5
DECFILT_C_COEF1 = 0x001240
DECFILT_C_COEF2 = 0x008277
DECFILT_C_COEF3 = 0x001240
DECFILT_C_COEF4 = 0x005AB5
DECFILT_C_COEF5 = 0x2B29E6
DECFILT_C_COEF6 = 0xCC414E
DECFILT_C_COEF7 = 0x1EB97D
DECFILT_C_COEF8 = 0xF8546A
Chapter 15
Deserial Serial Peripheral Interface (DSPI)
15.1 Introduction
Figure 15-1 is a block diagram of the Deserial Serial Peripheral Interface (DSPI) module.
SPI
DMA and Interrupt Control
DSPI_PUSHR DSPI_POPR
RX FIFO
TX FIFO
ASDR SDR
Internal
32
Parallel Inputs
32
CSI
Priority DDR
Internal
Logic Parallel Outputs
32
32
SOUT
Shift Register
SIN
15.2 Overview
The Deserial Serial Peripheral Interface (DSPI) module provides a synchronous serial interface for
communication between the MPC5676R and external devices. The DSPI supports pin count reduction
through serialization and deserialization of eTPU channels, eMIOS channels and memory-mapped
registers. Incoming deserialized data can also be used to trigger external interrupt requests. The channels
and register content are transmitted using a SPI-like protocol. There are five identical DSPI modules
(DSPI_A, DSPI_B, DSPI_C, DSPI_D and DSPI_E) on the MPC5676R.
The DSPIs have three configurations:
• Serial Peripheral Interface (SPI)—DSPI operates as a SPI with support for queues
• Deserial Serial Interface (DSI)—DSPI serializes eTPU and eMIOS output channels and
deserializes the received data by placing it on the eTPU and eMIOS input channels and as inputs
to the External Interrupt Request sub-block of the SIU
• Combined Serial Interface (CSI)—DSPI operates in both SPI and DSI configurations interleaving
DSI frames with SPI frames, giving priority to SPI frames
For queued operations, the SPI queues reside in system memory external to the DSPI. Data transfers
between the memory and the DSPI FIFOs are accomplished through the use of the eDMA controller or
through host software.
15.3 Features
The DSPI supports these SPI features:
• Full-duplex, synchronous transfers
• Selectable LVDS Pads working at 40 MHz for SOUT and SCK pins (only in DSPI_C)
• Master and Slave Mode
• Buffered transmit operation using the TX FIFO with depth of 4 entries
• Buffered receive operation using the RX FIFO with depth of 4 entries
• TX and RX FIFOs can be disabled individually for low-latency updates to SPI queues
• Visibility into the TX and RX FIFOs for ease of debugging
• FIFO Bypass Mode for low-latency updates to SPI queues
• Programmable transfer attributes on a per-frame basis:
— Parameterized number of transfer attribute registers (from 2 to 8)
— Serial clock with programmable polarity and phase
— Various programmable delays:
– PCS to SCK delay
– SCK to PCS delay
– Delay between frames
— Programmable serial frame size of 4 to 32 bits, expandable with software control
— Continuously held chip select capability
• Up to 6 Peripheral Chips Selects, expandable to 64 with external demultiplexer
System RAM
Addr/Ctrl
Done
RX Queue DMA Controller
Data
Data
TX Queue
Addr/Ctrl
Data Data
DSPI
Req
TX FIFO RX FIFO
Shift Register
SCK SCK
Baud Rate
Generator
PCSx SS
Specifically in the TSB configuration, detailed in Section 15.9.8, “Timed serial bus (TSB)”, the DSPI
serializes from 4 to 32 Parallel Input signals or register bits. The TSB downstream frame used to
communicate with a single slave is shown in Figure 15-37.
120 LVDS 40 Use sys clock /3 divide ratio. Gives 33/66 duty cycle. Use DSPI
configuration DBR = 0b1 (double baud rate), BR = 0b0000
(scaler value 2) and PBR = 0b01 (prescaler value 3).
15.7.1 Overview
Table 15-2 lists the signals that may connect off-chip depending on the device implementation.
Table 15-2. Signal properties
Function
Name I/O type
Master mode Slave mode
DSPI_A 0xFFF9_0000
DSPI_B 0xFFF9_4000
DSPI_C 0xFFF9_8000
DSPI_D 0xFFF9_C000
DSPI_E 0xFFFA_0000
DSPI_BASE on page
DSPI Module Configuration Register (DSPI_MCR)
15-11
DSPI_BASE+0x4 Reserved
on page
DSPI_BASE+0x8 DSPI Transfer Count Register (DSPI_TCR)
15-14
on page
DSPI_BASE+0x2C DSPI Status Register (DSPI_SR)
15-20
on page
DSPI_BASE+0x30 DSPI DMA/Interrupt Request Select and Enable Register (DSPI_RSER)
15-23
FIFO Registers
on page
DSPI_BASE+0x34 DSPI Push TX FIFO Register (DSPI_PUSHR)
15-25
on page
DSPI_BASE+0x38 DSPI Pop RX FIFO Register (DSPI_POPR)
15-27
DSPI_BASE+0x8C –
Reserved
DSPI_BASE+0xB8
DSI Registers
on page
DSPI_BASE+0xBC DSPI DSI Configuration Register (DSPI_DSICR)
15-29
on page
DSPI_BASE+0xC0 DSPI DSI Serialization Data Register (DSPI_SDR)
15-31
on page
DSPI_BASE+0xC4 DSPI DSI Alternate Serialization Data Register (DSPI_ASDR)
15-32
on page
DSPI_BASE+0xC8 DSPI DSI Transmit Comparison Register (DSPI_COMPR)
15-32
on page
DSPI_BASE+0xCC DSPI DSI Deserialization Data Register (DSPI_DDR)
15-33
on page
DSPI_BASE+0xD0 DSPI DSI Configuration Register 1 (DSPI_DSICR1)
15-34
DSPI_BASE+0xE8 DSPI DSI Deserialized Data Interrupt Mask Register (DSPI_DIMR) on page
15-40
DSPI_BASE+0xEC DSPI DSI Deserialized Data Polarity Interrupt Register (DSPI_DPIR) on page
15-40
Address: DSPI_BASE
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
CONT_SCKE
R 0 0
PCSIS5
PCSIS4
PCSIS3
PCSIS2
PCSIS1
PCSIS0
PCSSE
ROOE
MTFE
W MSTR DCONF FRZ
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R 0 0 0 0 0 0 0 0
DIS_RXF
DIS_TXF
CLR_RXF
CLR_TXF
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1
Field Description
Field Description
4 Freeze
FRZ The FRZ bit enables the DSPI transfers to be stopped on the next frame boundary when the device
enters Debug mode.
0 Do not stop serial transfers
1 Stop serial transfers
8–9 Reserved
16 Doze Enable
DOZE The DOZE bit provides support for externally controlled Doze mode power-saving mechanism. See
Section 15.9.18, “Power saving features,” for details.
0 Device Doze mode has no effect on DSPI.
1 Device Doze mode disables DSPI.
17 Module Disable
MDIS The MDIS bit allows the clock to be stopped to the non-memory mapped logic in the DSPI effectively
putting the DSPI in a software controlled power-saving state. See Section 15.9.18, “Power saving
features,” for more information. The reset value of the MDIS bit is parameterized, with a default reset
value of ‘0’.
0 Enable DSPI clocks.
1 Allow external logic to disable DSPI clocks.
Field Description
20 Clear TX FIFO
CLR_TXF CLR_TXF is used to flush the TX FIFO. Writing a ‘1’ to CLR_TXF clears the TX FIFO Counter. The
CLR_TXF bit is always read as zero.
0 Do not clear the TX FIFO Counter
1 Clear the TX FIFO Counter
21 Clear RX FIFO
CLR_RXF CLR_RXF is used to flush the RX FIFO. Writing a ‘1’ to CLR_RXF clears the RX Counter. The
CLR_RXF bit is always read as zero.
0 Do not clear the RX FIFO Counter
1 Clear the RX FIFO Counter
31 Halt
HALT The HALT bit starts and stops DSPI transfers. See Section 15.9.1, “Start and stop of DSPI transfers,”
for details on the operation of this bit.
0 Start transfers
1 Stop transfers
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R
TCNT
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Field Description
In master mode, the DSPI_CTAR0 – DSPI_CTAR7 registers define combinations of transfer attributes
such as frame size, clock phase and polarity, data bit ordering, baud rate, and various delays. In slave mode,
a subset of the bit-fields in the DSPI_CTAR0 and DSPI_CTAR1 registers are used to set the slave transfer
attributes.
When the DSPI is configured as a SPI master, the CTAS field in the command portion of the TX FIFO
entry selects which of the DSPI_CTAR registers is used. When the DSPI is configured as a SPI bus slave,
the DSPI_CTAR0 register is used.
When the DSPI is configured as a DSI master, field DSPI_DSICR[DSICTAS] selects which of the
DSPI_CTAR registers is used. When the DSPI is configured as a DSI bus slave, the DSPI_CTAR1 register
is used.
In CSI configuration, the transfer attributes are selected based on whether the current frame is SPI data or
DSI data. SPI transfers in CSI configuration follow the protocol described for SPI configuration, and DSI
transfers in CSI configuration follow the protocol described for DSI configuration. CSI configuration is
only valid in conjunction with master mode. See Section 15.9.4, “Combined serial interface (CSI)
configuration,” for more details.
TSB mode sets some limitations on transfer attributes:
• Clock phase is forced to be CPHA = 1 and the CPHA bit setting has no effect.
• PCS lines are driven at the driving edge of the SCK clock together with SOUT, so PCS assertion
and negation delays control is unavailable and PCSSCK, PASC, CSSCK and ASC fields have no
effect.
• Delay after transfer can be set from 1 to 64 serial clocks with help of PDT and DT fields.
Address: DSPI_BASE + 0xC–DSPI_BASE + 0x28
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R
DBR FMSZ CPOL CPHA LSBFE PCSSCK PASC PDT PBR
W
Reset 0 1 1 1 1 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R
CSSCK ASC DT BR
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 15-7. DSPI Clock and Transfer Attributes Register 0–7 (DSPI_CTAR0–DSPI_CTAR7) in the master
mode
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R
FMSZ CPOL CPHA PE PP Not used
W
Reset 0 1 1 1 1 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R
Not used
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 15-8. DSPI Clock and Transfer Attributes Register 0 (DSPI_CTAR0) in the slave mode
Field Descriptions
5 Clock Polarity
CPOL The CPOL bit selects the inactive state of the Serial Communications Clock (SCK). This bit is used
in both master and slave mode. For successful communication between serial devices, the devices
must have identical clock polarities. When the Continuous selection format is selected, switching
between clock polarities without stopping the DSPI can cause errors in the transfer due to the
peripheral device interpreting the switch of clock polarity as a valid clock edge.
0 The inactive state value of SCK is low
1 The inactive state value of SCK is high
6 Clock Phase
CPHA The CPHA bit selects which edge of SCK causes data to change and which edge causes data to be
captured. This bit is used in both master and slave mode. For successful communication between
serial devices, the devices must have identical clock phase settings. In Continuous SCK mode or TSB
mode the bit value is ignored and the transfers are done as CPHA bit is set to 1.
0 Data is captured on the leading edge of SCK and changed on the following edge
1 Data is changed on the leading edge of SCK and captured on the following edge
Field Descriptions
7 LSB First
LSBFE The LSBFE bit selects if the LSB or MSB of the frame is transferred first. When operating in TSB
configuration, this bit should be set to be compliant to MSC specification.
0 Data is transferred MSB first
1 Data is transferred LSB first
1
t CSC = ----------- PCSSCK CSSCK Eqn. 15-1
f SYS
See Section 15.9.5.2, “PCS to SCK delay (tCSC),” for more details.In the TSB mode the field has no
effect.
Field Descriptions
1
t ASC = ----------- PASC ASC Eqn. 15-2
f SYS
See Section 15.9.5.3, “After SCK delay (tASC),” for more details. In the TSB mode the field has no
effect.
1
t DT = ----------- PDT DT Eqn. 15-3
f SYS
In the TSB mode the Delay after Transfer is equal to a number formed by concatenation of PDT and
DT fields plus 1 of the SCK clock periods.
See Section 15.9.5.4, “Delay after transfer (tDT),” for more details.
1 0 00 50/50
1 0 01 33/66
1 0 10 40/60
1 0 11 43/57
1 1 00 50/50
1 1 01 66/33
1 1 10 60/40
1 1 11 57/43
Field Descriptions
5 Clock Polarity
CPOL The CPOL bit selects the inactive state of the Serial Communications Clock (SCK).
0 The inactive state value of SCK is low
1 The inactive state value of SCK is high
6 Clock Phase
CPHA The CPHA bit selects which edge of SCK causes data to change and which edge causes data to be
captured.
0 Data is captured on the leading edge of SCK and changed on the following edge
1 Data is changed on the leading edge of SCK and captured on the following edge
Field Descriptions
7 Parity Enable
PE PE bit enables parity bit transmission and reception for the frame
0 No parity bit included/checked.
1 Parity bit is transmitted instead of last data bit in frame, parity checked for received frame.
8 Parity Polarity
PP PP bit controls polarity of the parity bit transmitted and checked
0 Even Parity: number of “1” bits in the transmitted frame is even. The DSPI_SR[SPEF] bit is set if
in the received frame number of “1” bits is odd.
1 Odd Parity: number of “1” bits in the transmitted frame is odd. The DSPI_SR[SPEF] bit is set if in
the received frame number of “1” bits is even.
29–31 Not used, write always zero to keep software compatible with future updates.
—
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R TCF TXRXS 0 EOQF TFUF 0 TFFF 0 0 DPEF SPEF DDIF RFOF 0 RFDF 0
W w1c w1c w1c w1c w1c w1c w1c w1c w1c w1c
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Field Description
Field Description
1 TX & RX Status
TXRXS The TXRXS bit reflects the run status of the DSPI. Section 15.9.1, “Start and stop of DSPI transfers,”
explains what causes this bit to be set or cleared.
0 TX and RX operations are disabled (DSPI is in STOPPED state)
1 TX and RX operations are enabled (DSPI is in RUNNING state)
Field Description
15 Reserved.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
RFDFDIRS
TFFFDIRS
R 0 0 0 0 0
EOQFRE
RFOFRE
DPEFRE
RFDFRE
SPEFRE
TFUFRE
TCF_RE
TFFFRE
DDIFRE
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 15-10. DSPI DMA/Interrupt Request Select and Enable Register (DSPI_RSER)
Field Description
Field Description
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0
CONT CTAS EOQ CTCNT PE PP PCS5 PCS4 PCS3 PCS2 PCS1 PCS0
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R
TXDATA
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Field Descriptions
4 End Of Queue
EOQ The EOQ bit provides a means for host software to signal to the DSPI that the current SPI transfer is
the last in a queue. At the end of the transfer the EOQF bit in the DSPI_SR is set.
0 The SPI data is not the last data to transfer
1 The SPI data is the last data to transfer
Field Descriptions
6 Parity Enable
PE PE bit enables parity bit transmission and parity reception check for the SPI frame
0 No parity bit included/checked.
1 Parity bit is transmitted instead of last data bit in frame, parity checked for received frame.
7 Parity Polarity
PP PP bit controls polarity of the parity bit transmitted and checked
0 Even Parity: number of “1” bits in the transmitted frame is even. The DSPI_SR[SPEF] bit is set if
in the received frame number of “1” bits is odd.
1 Odd Parity: number of “1” bits in the transmitted frame is odd. The DSPI_SR[SPEF] bit is set if in
the received frame number of “1” bits is even.
8–9 Reserved
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R
TXDATA
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R
TXDATA
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Field Descriptions
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R RXDATA
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R RXDATA
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Field Description
Address: DSPI_BASE+0x3C–DSPI_BASE+0x78
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R TXCMD/TXDATA
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R TXDATA
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Field Description
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R RXDATA
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R RXDATA
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Field Description
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 0
FMSZ
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
DPCS5
DPCS4
DPCS3
DPCS2
DPCS1
DPCS0
R 0 0 0 0 0 0
DCONT DSICTAS
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Field Description
13 Trigger Polarity
TPOL The TPOL bit selects the active edge of the hardware trigger input signal (HT). initiating DSI frames
transfer. See Section 15.9.3.5, “DSI transfer initiation control,” for more information.
0 Falling edge will initiate a transfer
1 Rising edge will initiate a transfer
Field Description
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R SER_DATA
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R SER_DATA
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Field Description
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R
ASER_DATA
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R
ASER_DATA
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Field Descriptions
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R COMP_DATA
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R COMP_DATA
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Field Description
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R DESER_DATA
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R DESER_DATA
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Field Descriptions
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 0 0 0 0 0 0 0 DSE DSE
TSBCNT
W 1 0
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
DPCS1_5
DPCS1_4
DPCS1_3
DPCS1_2
DPCS1_1
DPCS1_0
R 0 0 0 0 0 0 0 0 0 0
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Field Description
15 Data Select Enable0. When TBSC bit is set, the DSE0 bit controls insertion of the zero bit (Data
DSE0 Select) in the beginning of the data frame.
0 No Zero bit inserted in the beginning of the frame
1 Zero bit is inserted at the beginning of the data frame. Total number of bits in the data frame is
increased by 1.
Field Description
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R
SS
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R
SS
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Field Description
0–31 Source Select. The SS bits select serialization source for DSI frame. Each SS bit selects data for
SS[0:31] corresponded bit in the transmitted frame.
0 the bit in transmitted frame is taken from Parallel Input pin;
1 the bit in transmitted frame is taken from DSPI_ASDR register
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R
IPS24 IPS25 IPS26 IPS27
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R
IPS28 IPS29 IPS30 IPS31
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Field Description
0–3 Input Pin Select 24. The IPS24 field selects Parallel Input pin for transmitted frame bit 24.
IPS24
4–7 Input Pin Select 25. The IPS25 field selects Parallel Input pin for transmitted frame bit 25.
IPS25
8–11 Input Pin Select 26. The IPS26 field selects Parallel Input pin for transmitted frame bit 26.
IPS26
12–15 Input Pin Select 27. The IPS27 field selects Parallel Input pin for transmitted frame bit 27.
IPS27
16–19 Input Pin Select 28. The IPS28 field selects Parallel Input pin for transmitted frame bit 28.
IPS28
20–23 Input Pin Select 29. The IPS29 field selects Parallel Input pin for transmitted frame bit 29.
IPS29
Field Description
24–27 Input Pin Select 30. The IPS30 field selects Parallel Input pin for transmitted frame bit 30.
IPS30
28–31 Input Pin Select 31. The IPS31 field selects Parallel Input pin for transmitted frame bit 31.
IPS31
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R
IPS16 IPS17 IPS18 IPS19
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R
IPS20 IPS21 IPS22 IPS23
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Field Description
0–3 Input Pin Select 16. The IPS16 field selects Parallel Input pin for transmitted frame bit 16.
IPS16
4–7 Input Pin Select 17. The IPS17 field selects Parallel Input pin for transmitted frame bit 17.
IPS17
8–11 Input Pin Select 18. The IPS18 field selects Parallel Input pin for transmitted frame bit 18.
IPS18
12–15 Input Pin Select 19. The IPS19 field selects Parallel Input pin for transmitted frame bit 19.
IPS19
16–19 Input Pin Select 20. The IPS20 field selects Parallel Input pin for transmitted frame bit 20.
IPS20
20–23 Input Pin Select 21. The IPS21 field selects Parallel Input pin for transmitted frame bit 21.
IPS21
24–27 Input Pin Select 22. The IPS22 field selects Parallel Input pin for transmitted frame bit 22.
IPS22
28–31 Input Pin Select 23. The IPS23 field selects Parallel Input pin for transmitted frame bit 23.
IPS23
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R
IPS8 IPS9 IPS10 IPS11
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R
IPS12 IPS13 IPS14 IPS15
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Field Description
0–3 Input Pin Select 8. The IPS8 field selects Parallel Input pin for transmitted frame bit 8.
IPS8
4–7 Input Pin Select 9. The IPS9 field selects Parallel Input pin for transmitted frame bit 9.
IPS9
8–11 Input Pin Select 10. The IPS10 field selects Parallel Input pin for transmitted frame bit 10.
IPS10
12–15 Input Pin Select 11. The IPS11 field selects Parallel Input pin for transmitted frame bit 11.
IPS11
16–19 Input Pin Select 12. The IPS12 field selects Parallel Input pin for transmitted frame bit 12.
IPS12
20–23 Input Pin Select 13. The IPS13 field selects Parallel Input pin for transmitted frame bit 13.
IPS13
24–27 Input Pin Select 14. The IPS14 field selects Parallel Input pin for transmitted frame bit 14.
IPS14
28–31 Input Pin Select 15. The IPS15 field selects Parallel Input pin for transmitted frame bit 15.
IPS15
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R
IPS0 IPS1 IPS2 IPS3
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R
IPS4 IPS5 IPS6 IPS7
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Field Description
0–3 Input Pin Select 0. The IPS0 field selects Parallel Input pin for transmitted frame bit 0.
IPS0
4–7 Input Pin Select 1. The IPS1 field selects Parallel Input pin for transmitted frame bit 1.
IPS1
8–11 Input Pin Select 2. The IPS2 field selects Parallel Input pin for transmitted frame bit 2.
IPS2
12–15 Input Pin Select 3. The IPS3 field selects Parallel Input pin for transmitted frame bit 3.
IPS3
16–19 Input Pin Select 4. The IPS4 field selects Parallel Input pin for transmitted frame bit 4.
IPS4
20–23 Input Pin Select 5. The IPS5 field selects Parallel Input pin for transmitted frame bit 5.
IPS5
24–27 Input Pin Select 6. The IPS6 field selects Parallel Input pin for transmitted frame bit 6.
IPS6
28–31 Input Pin Select 7. The IPS7 field selects Parallel Input pin for transmitted frame bit 7.
IPS7
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R
MASK
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R
MASK
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 15-27. DSPI DSI Deserialized Data Interrupt Mask Register (DSPI_DIMR)
Field Description
0–31 MASK. The MASK bits define which bits in received deserialization data should be checked to
MASK[0:31] produce the Deserialized Data Interrupt (DDI).
0 the bit in received DSI frame does not produce DDI interrupt.
1 the bit in received DSI frame can produce DDI interrupt if the data bit matches to configured
polarity.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R
DP
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R
DP
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 15-28. DSPI DSI Deserialized Data Polarity Interrupt Register (DSPI_DIPR)
Field Description
0–31 Data Polarity. The DP bits define what value of the received deserialization data sets the
DP[0:31] DSPI_SR[DDIF] bit.
0 if received bit is 0 the DSPI_SR[DDIF] bit is set.
1 if received bit is 1 the DSPI_SR[DDIF] bit is set.
SCK SCK
Baud Rate
Generator
PCSx SS
Generally more than one slave device can be connected to the DSPI master. Eight Peripheral Chip Select
(PCS) signals of the DSPI masters can be used to select which of the slaves to communicate with.
The three DSPI configurations share transfer protocol and timing properties which are described
independently of the configuration in Section 15.9.6, “Transfer formats”. The transfer rate and delay
settings are described in Section 15.9.5, “DSPI baud rate and clock delay generation.”
The DSPI is started (DSPI transitions to RUNNING) when all of the following conditions are true:
• DSPI_SR[EOQF] bit is clear
• Device is not in the debug mode is or the DSPI_MCR[FRZ] bit is clear
• DSPI_MCR[HALT] bit is clear
The DSPI stops (transitions from RUNNING to STOPPED) after the current frame when any one of the
following conditions exist:
• DSPI_SR[EOQF] bit is set
• Device in the debug mode and the DSPI_MCR[FRZ] bit is set
• DSPI_MCR[HALT] bit is set
State transitions from RUNNING to STOPPED occur on the next frame boundary if a transfer is in
progress, or immediately if no transfers are in progress.
when the RX FIFO is disabled, the RFDF, RFOF and RXCTR fields in the DSPI_SR behave as if there is
a one-entry FIFO, but the contents of the DSPI_RXFR registers and POPNXTPTR are undefined.
is added to the RX FIFO at the completion of a transfer when the received data in the shift register is
transferred into the RX FIFO. SPI data are removed (popped) from the RX FIFO by reading the DSPI POP
RX FIFO Register (DSPI_POPR). RX FIFO entries can only be removed from the RX FIFO by reading
the DSPI_POPR or by flushing the RX FIFO.
The RX FIFO Counter field DSPI_SR[RXCTR] indicates the number of valid entries in the RX FIFO.
Field DSPI_SR[RXCTR] is updated every time the DSPI _POPR is read or SPI data is copied from the
shift register to the RX FIFO.
Field DSPI_SR[POPNXTPTR] points to the RX FIFO entry that is returned when the DSPI_POPR is read.
Field DSPI_SR[POPNXTPTR] contains the positive offset from DSPI_RXFR0 in number of 32-bit
registers. For example, POPNXTPTR equal to two means that the DSPI_RXFR2 contains the received SPI
data that will be returned when DSPI_POPR is read. Field DSPI_SR[POPNXTPTR] is incremented every
time the DSPI_POPR is read. The maximum value of the field is equal to DSPI_HCR[RXFR] and it rolls
over after reaching the maximum.
concatenated bits from multiple DSPIs. The DSPI also supports parallel chaining allowing several DSPIs
and off-chip SPI devices to share the same Serial Communications Clock (SCK) and Peripheral Chip
Select (PCS) signals. See Section 15.9.3.6, “Multiple transfer operation (MTO),” for details on the serial
and parallel chaining support.
IPS6, set to 3 (binary 0011), preselects Parallel Input 3 to be bit number 6 in the transmitted frame, while
the value minus 2 (1110) preselects Parallel Input 8.
IPS31, set to minus 8 (binary 1000), preselects Parallel Input 7 to be bit number 31 in the transmitted
frame.
(Of course, the Parallel Input pin state, to be transmitted, should be selected by TXSS and the frame size
should be higher than the bit position in the preselected frame.)
The DSPI_SSR provides additional way to create the frame for transmission. Each bit from this register is
OR’d with the TXSS bit and controls individual transmitted bit source. This way, the transmitted frame
can have any combination of the DSPI_SDR and DSPI_ASDR bits. This feature allows control SPI based
devices, requiring control and data fields in the frame. Control field may come from DSPI_ASDR, set by
the device’s CPU, while data field can be generated by device peripheral modules, such as PWM timers.
A copy of the last 32-bit DSI frame shifted out of the Shift Register is stored in the DSPI DSI Transmit
Comparison Register (DSPI_COMPR). This register provides added visibility for debugging and it serves
as a reference for transfer initiation control. Figure 15-30 shows the DSI Serialization logic.
32
DSPI Parallel Inputs
Select Registers 0-3 32
32
DSI Serialization
32 x 16 to 1 Muxes
Data Register
0 1 N SOUT
Parallel 32 1
Inputs 32 0 Shift Register
Clock
SCK
Logic
Control
Logic PCS
HT
DSI Deserialization
Data Register
SIN 0 1 N-1
32 32 Parallel
Shift Register Outputs
DSPI_DSICR bits
Transfer initiation control
TRRE CID
0 0 Continuous
0 1 Change in Data
1 0 Triggered
DEVICE
DSPI_B Master DSPI_C Slave DSPI_D Slave
HT MTRIG HT MTRIG
SOUT_B
SIN_C
PCS_B[0]
SOUT_C
SIN_B
SIN_D
SOUT_D
In the parallel chaining example, the SOUT and SIN of the three DSPIs connect to separate external SPI
devices. All internal and external SPI blocks share PCS and SCK signals. DSPI_B controls and initiates
all transfers, but the DSPI slaves each have a trigger output signal MTRIG that indicates to DSPI_B that
a trigger condition has occurred in the DSPI slaves. When the slave DSPI has a change in data to be
serialized, it asserts the MTRIG signal that propagates to DSPI_B which initiates the transfer.
DEVICE
DSPI_B Master DSPI_C Slave DSPI_D Slave
HT MTRIG HT MTRIG
SCK_B
SOUT_D
SIN_B
SS SCK
SOUT SIN
External SPI Slave Device
The SOUT of DSPI_B is connected to the SIN of DSPI_C, the SOUT of DSPI_C is connected to the SIN
of DSPI_D and the SOUT of the DSPI_D is connected to the SIN of the external SPI slave. The SOUT of
the external SPI slave is connected to the SIN of DSPI_B.
DSPI_B controls and initiates all transfers, but the slave DSPIs use the trigger output signal MTRIG to
indicate to DSPI_B that a trigger condition has occurred. When an on-chip DSPI slave has a change in data
to be serialized it can assert the MTRIG signal to the DSPI master which initiates the transfer. The DSPI
slaves also propagate trigger signals from other slaves to the DSPI master.
Field DSPI_DSICR[MTOCNT] in DSPI_B must be written with the total number of bits to be transferred.
Field DSPI_DSICR[MTOCNT] must equal the sum of all FMSZ fields in the selected DSPI_CTAR
registers for DSPI_B and all on-chip DSPI slaves. For example, if one 16-bit DSI frame is created by
concatenating 8 bits from DSPI_B and 4 bits from DSPI_C and DSPI_D each, then DSPI_B’s frame size
must be set to 8, and the DSPI slaves’ frame size must be set to 4 each. Field DSPI_DSICR[MTOCNT] in
DSPI_B must be set to 16.
In CSI configuration the DSPI transfers DSI data based on DSI transfer initiation control. When there are
SPI commands in the TX FIFO, the SPI data has priority over the DSI frames. When the TX FIFO is empty,
DSI transfer resumes.
Two peripheral chip select signals indicate whether DSI data or SPI data is transmitted. The user must
configure the DSPI so that the two DSPI_CTAR registers associated with DSI data and SPI data assert
different peripheral chip select signals denoted in the figure as PCSx and PCSy. The CSI configuration is
only supported in master mode.
Data returned from the external slave while a DSI frame is transferred is placed on the Parallel Output
signals. Data returned from the external slave while a SPI frame is transferred is moved to the RX FIFO.
The TX FIFO and RX FIFO are fully functional in CSI mode.
When in non-continuous clock mode the tDT delay is configured according Equation 15-3. When in
continuous clock mode and TSB is not enabled the delay is fixed at 1 SCK period.
In TSB mode the Delay after Transfer is equal to a number formed by concatenation of PDT and DT fields
plus 1 of the SCK clock periods. See detailed information in Section 15.9.8, “Timed serial bus (TSB)”.
PCSx
PCSS
tPCSSCK tPASC
The delay between the assertion of the PCS signals and the assertion of PCSS is selected by field
DSPI_CTAR[PCSSCK] based on the following formula:
1
t PCSSCK = ---------- PCSSCK Eqn. 15-5
f SYS
At the end of the transfer the delay between PCSS negation and PCS negation is selected by field
DSPI_CTAR[PASC] based on the following formula:
1
t PASC = ---------- PASC Eqn. 15-6
f SYS
Table 15-37 shows an example of how to compute the tpcssck delay.
Table 15-37. Peripheral chip select strobe assert computation example
The PCSS signal is not supported when Continuous Serial Communication SCK or TSB mode are enabled.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16
SCK (CPOL = 0)
SCK (CPOL = 1)
Master SOUT/
Slave SIN
Master SIN/
Slave SOUT
PCSx/SS
MSB first (LSBFE = 0): MSB Bit 6 Bit 5 Bit 4 Bit 3 Bit 2 Bit 1 LSB
LSB first (LSBFE = 1): LSB Bit 1 Bit 2 Bit 3 Bit 4 Bit 5 Bit 6 MSB
tCSC = PCS to SCK delay
tASC = After SCK delay
tDT = Delay after Transfer (Minimum CS idle time)
The master initiates the transfer by placing its first data bit on the SOUT pin and asserting the appropriate
peripheral chip select signals to the slave device. The slave responds by placing its first data bit on its
SOUT pin. After the tCSC delay elapses, the master outputs the first edge of SCK. The master and slave
devices use this edge to sample the first input data bit on their serial data input signals. At the second edge
of the SCK the master and slave devices place their second data bit on their serial data output signals. For
the rest of the frame the master and the slave sample their SIN pins on the odd-numbered clock edges and
changes the data on their SOUT pins on the even-numbered clock edges. After the last clock edge occurs
a delay of tASC is inserted before the master negates the PCS signals. A delay of tDT is inserted before a
new frame transfer can be initiated by the master.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16
SCK (CPOL = 0)
SCK (CPOL = 1)
Master SOUT/
Slave SIN
Master SIN/
Slave SOUT
PCSx/SS
MSB first (LSBFE = 0): MSB Bit 6 Bit 5 Bit 4 Bit 3 Bit 2 Bit 1 LSB
LSB first (LSBFE = 1): LSB Bit 1 Bit 2 Bit 3 Bit 4 Bit 5 Bit 6 MSB
The master initiates the transfer by asserting the PCS signal to the slave. After the tCSC delay has elapsed,
the master generates the first SCK edge and at the same time places valid data on the master SOUT pin.
The slave responds to the first SCK edge by placing its first data bit on its slave SOUT pin.
At the second edge of the SCK the master and slave sample their SIN pins. For the rest of the frame the
master and the slave change the data on their SOUT pins on the odd-numbered clock edges and sample
their SIN pins on the even-numbered clock edges. After the last clock edge occurs a delay of tASC is inserted
before the master negates the PCS signal. A delay of tDT is inserted before a new frame transfer can be
initiated by the master.
sys clk
Tasc
PCS
Thd_ms
Tvd_sl Tsu_ms
SOUT of Ext Slave D0 D1 D2 Dn
SCK
Thd_sl
Tsys Tsu_sl
SOUT
D0 D1 D2 Dn
Tvd_sl
SOUT of DSPI Slave D0 D1 D2 Dn
Figure 15-39. DSPI Modified Transfer Format (MTFE = 1, CPHA = 0, fsck = fsys/4)
sys clk
Tasc
PCS
Tsu_ms
Tvd_sl Thd_ms
SIN D0 D1 D2 Dn
SCK
Thd_sl
Tsu_sl
SOUT
D0 D1 D2 Dn
Figure 15-40. DSPI Modified Transfer Format (MTFE = 1, CPHA = 0, fsck = fsys/2)
sys clk
Tasc
PCS
Thd_ms
Tvd_sl Tsu_ms
SIN D0 D1 D2 Dn
SCK
Tsu_sl Thd_sl
SOUT D0 D1 D2 Dn
Figure 15-41. DSPI modified transfer format (MTFE = 1, CPHA = 0, fsck = fsys/3)
sys clk
Tasc
PCS
Thd_ms
Tvd_sl Tsu_ms
SIN D0 D1 D2 Dn
7 2n+2
SCK 1 2 3 4 5 6 8 2n+1
Thd_sl
Tsu_sl
SOUT
D0 D1 D2 Dn
Figure 15-42. DSPI modified transfer format (MTFE = 1, CPHA = 1, fsck = fsys/2)
sys clk
Tasc
PCS
Thd_ms
Tvd_sl Tsu_ms
SIN D0 D1 D2 Dn
SCK
Tsu_sl Thd_sl
SOUT D0 D1 D2 Dn
Figure 15-43. DSPI modified transfer format (MTFE = 1, CPHA = 1, fsck = fsys/3)
sys clk
Tasc
PCS
Thd_ms
Tvd_sl Tsu_ms
SIN D0 D1 D2 Dn
SCK
Thd_sl
Tsu_sl
SOUT
D0 D1 D2 Dn
Figure 15-44. DSPI Modified transfer format (MTFE = 1, CPHA = 1, fsck = fsys/4)
SCK (CPOL = 0)
SCK (CPOL = 1)
Master SOUT
Master SIN
PCSx
When the CONT bit = 1, the PCS signal remains asserted for the duration of the two transfers. The Delay
between Transfers (tDT) is not inserted between the transfers. Figure 15-46 shows the timing diagram for
two 4-bit transfers with CPHA = 1 and CONT = 1.
SCK (CPOL = 0)
SCK (CPOL = 1)
Master SOUT
Master SIN
PCS
NOTE
It is mandatory to fill the TXFIFO with the number of entries that will be
concatenated under one PCS assertion for both master and slave before the
TXFIFO becomes empty. For example, while transmitting in master mode,
it should be ensured that the last entry in the TXFIFO, after which TXFIFO
becomes empty, must have the CONT bit in command frame as deasserted
(i.e. CONT bit = 0).While operating in slave mode, it should be ensured that
when the last-entry in the TXFIFO is completely transmitted (that is, the
corresponding TCF flag is asserted and TXFIFO is empty) the slave should
be deselected for any further serial communication; else an underflow error
occurs.
SCK (CPOL = 0)
SCK (CPOL = 1)
Master SOUT
Master SIN
PCS
tDT
If the CONT bit in the TX FIFO entry is set or the DCONT in the DSPI_DSICR is set, PCS remains
asserted between the transfers. Under certain conditions, SCK can continue with PCS asserted, but with
no data being shifted out of SOUT (SOUT pulled high). This can cause the slave to receive incorrect data.
Those conditions include:
• Continuous SCK with CONT bit set, but no data in the transmit FIFO.
• Continuous SCK with CONT bit set and entering STOPPED state (refer to Section 15.9.1, “Start
and stop of DSPI transfers”).
• Continuous SCK with CONT bit set and entering Stop mode or Module Disable mode.
Figure 15-48 shows timing diagram for Continuous SCK format with Continuous Selection enabled.
SCK (CPOL = 0)
SCK (CPOL = 1)
Master SOUT
Master SIN
PCS
transfer 1 transfer 2
TSB configuration provides the Micro Second Channel (MSC) downstream channel support.
The MSC upstream channel is not supported by the DSPI, but can be supported by any available Serial
Communication Controller (SCI or UART) in the device.
To work in TSB mode the DSPI must be in master mode and in DSI (DCONF = 0b01) or CSI
(DCONF = 0b10) configuration. Both Continuous and Non Continuous Serial Communication Clock
(controlled by bit DSPI_MCR[CONT_SCKE]) are supported in the TSB mode.
Figure 15-49 shows the signals used in the TSB interface.
In the TSB configuration the DSPI is able to send from 4 to 34 bits MSC data frames (4 to 32 serialized
data bits and up to 2 Data Selection zero bits). The serialized data bits source can be either:
• the DSPI DSI Alternate Serialization Data Register (DSPI_ASDR), written by the host software,
• Parallel Input pin states latched into the DSPI DSI Serialization Data Register (DSPI_SDR).
DSPI_DSICR TXSS bit or DSPI_SSR bits define the source of the data.
The Least Significant Bits of the DSPI_ASDR or DSPI_SDR registers are selected to be serialized if the
data frame is set to less than 32 bits.
downstream channel
DSPI
SCK CLK
SOUT DIN Slave1
PCS1 CS
CLK
DIN Slave2
PCS2 CS
The PCS signals are driven together with SOUT. The tCSC and tASC delays are not available. Delay after
Transfer (DT) is set in SCK clock periods as a binary number formed by concatenation of the
DSPI_CTARn PDT and DT fields plus one, allowing to set DT from 1 to 64 serial clock periods. DT field
provides least significant bits and PDT field provides most significant bits of the Delay after Transfer.
SCK
(CPOL = 0)
Invalid Invalid
Master SOUT 1 LSB 0 LSB
PCS
tDT tDT
Figure 15-50 shows the two types of MSC downstream frames: command frame and data frame.
The first transmitted bit, called the selection bit, determines the frame type:
• The selection bit “0” indicates a data frame
• The selection bit “1” indicates a command frame
Data frame may contain up to two selection bits to support two external slave devices, (so called dual
receiver configuration) or no selection bits at all.
The command frame can be written by software, through SPI TX FIFO, using one or two FIFO entries
with help of the CONT bit. The data frame consists of up to 32 bits from the DSPI_SDR or DSPI_ASDR
registers and up to two zero selection bits. The number of data bits in the data frame is defined by field
DSPI_DSCICR1[TSBCNT].
The selection bit of the MSC command frames (1) can be implemented by software.
To comply with MSC specification, set DSPI_CTARn[LSBFE] to transmit the least significant bit first.
Regardless of the LSBFE bit setting, the Data Frame Selection Bits, if enabled, are always transmitted first,
before the corresponding data subframes.
The PCS switchover occurs at driving edge of the SCK clock output.
The second Data Selection Bit is inserted after the PCS switchover if enabled.
Data Frame with PCS switchover is shown in Figure 15-51.
SCK
SOUT Invalid
0 LSB 0
PCS0 DSPI_CTARn[FMSZ] + 1
TSBCNT - FMSZ
PCS1
Figure 15-51. TSB data frame format for MSC dual receiver operation
Request type
Condition Flag
Interrupt DMA
Each condition has a flag bit in the DSPI Status Register (DSPI_SR) and an Request Enable bit in the DSPI
DMA/Interrupt Request Select and Enable Register (DSPI_RSER). The TX FIFO Fill Flag (TFFF) and
RX FIFO Drain Flag (RFDF) generate interrupt requests or DMA requests depending on the TFFFDIRS
and RFDFDIRS bits in the DSPI_RSER.
The DSPI module also provides a global interrupt request line, which is asserted when any of individual
interrupt requests lines is asserted.
fields up to 16 bits wide. The RX FIFOs store 16-bit words of received data from external devices. When
the DSPI is configured for Slave Mode, the DSPI ignores the SPI command in the TX FIFO.
For queued operations, the SPI queues reside in system memory external to the DSPI. Data transfers
between the memory and the DSPI FIFOs are accomplished through the use of the eDMA controller or
through Host software. See Figure 15-52 for a conceptual diagram of the queue data transfer control in the
MPC5676R MCU.
System RAM
Address
RX Queue
Data DMA Controller/Host
Data
TX Queue
Address
DMA
Data Data Control/
DSPI Host
TX FIFO RX FIFO
Shift Register
DSPI
PCSS
PCS0
8 PCS1
PCS0-PCS7
PCS256
Request type
Condition Flag
Interrupt DMA
End of queue reached EOQF x
All request conditions are detected in the SPI configuration and in the CSI configuration. In DSI
configuration only the transfer of current frame complete condition is detected.
ipp_do pad_n
lvds_obe
LVDS
Transmitter
lvds_opt0 pad_p
lvds_opt1
VREF_LVDS
V_IREF_LVDS
Signals lvds_opt0 and lvds_opt1 control the voltage swing on the LVDS pad. These two signals are
controlled by bits SRC[1:0] of the respective PCR. Table 15-41 gives the configuration for these bits.
Table 15-41. LVDS pads voltage swing
0 1 increased increased
1 0 decreased decreased
eMIOS DSPI_B
CH [8:11] IN [3:0]
SIU/IMUX
CH [0:6] IN [10:4]
OUT 0 IN1 IRQ[0]
CH [23] IN [11]
CH [12:15] IN [15:12]
CH [23] OUT 15 IN1 IRQ[15]
IN [16]
CH [8:15] IN [24:17]
CH [0:6] IN [31:25] eTPU_A
OUT 8 CH 29
eTPU_A
CH [16:23] IN [7:0] OUT 13 CH 24
CH [24:29] IN [13:8]
CH [30:31] eMIOS
IN [15:14]
OUT 14 CH 13
CH [15:12] IN [19:16] OUT 15 CH 12
CH [11:0] IN [31:20]
DSPI_B DSPI_B
Connected to: Connected to:
input output
eMIOS Output Channel 11
0 eTPU_A Output Channel 23 0 Input 1 on IMUX for External IRQ[0]
GPDO350
DSPI_B DSPI_B
Connected to: Connected to:
input output
eMIOS Output Channel 8
3 eTPU_A Output Channel 20 3 Input 1 on IMUX for External IRQ[3]
GPDO353
DSPI_B DSPI_B
Connected to: Connected to:
input output
eMIOS Output Channel 15
17 eTPU_A Output Channel 13 17 NC
GPDO367
DSPI_B DSPI_B
Connected to: Connected to:
input output
eMIOS Output Channel 0
31 eTPU_A Output Channel 11 31 NC
GPDO381
DSPI_C
eMIOS
CH [15:12] IN [3:0]
CH [23] IN [4] SIU/IMUX
CH [6:0] IN [11:5]
OUT 0 IN2 IRQ[15]
CH [11:8] IN [15:12] OUT 1 IN2 IRQ[0]
CH [6:0] IN [22:16]
CH [15:8] IN [30:23]
OUT 15 IN2 IRQ[14]
CH [23] IN [31]
eTPU_A
CH [15:12] IN [3:0]
CH [11:0] IN [15:4]
CH [16:23] IN [23:16]
CH [24:29] IN [29:24]
CH [30:31] IN [31:30]
DSPI_C DSPI_C
Connected to: Connected to:
input output
eMIOS Output Channel 7
eMIOS Output Channel 12
0 0 Input 2 on IMUX for External IRQ[15]
eTPU_A Output Channel 12
GPDO382
DSPI_C DSPI_C
Connected to: Connected to:
input output
eMIOS Output Channel 17
eMIOS Output Channel 14
2 2 Input 2 on IMUX for External IRQ[1]
eTPU_A Output Channel 14
GPDO384
DSPI_C DSPI_C
Connected to: Connected to:
input output
eMIOS Output Channel 11
15 eTPU_A Output Channel 11 15 Input 2 on IMUX for External IRQ[14]
GPDO397
DSPI_C DSPI_C
Connected to: Connected to:
input output
eMIOS Output Channel 14
29 eTPU_A Output Channel 24 29 NC
GPDO411
DSPI_D SIU/IMUX
DSPI_D DSPI_D
Connected to: Connected to:
input output
2 NC 2 NC
3 NC 3 NC
DSPI_D DSPI_D
Connected to: Connected to:
input output
16–31 NC 16–31 NC
enable_clk
&
&
&
doze
&
stop_ack
Power
Management Frame Boundary DOZE MDIS
stop Detection
Block
Logic Memory Mapped Area
clk
Non-Memory Mapped Area
system clock &
DSPI
addr,
byte_en,
rwb, &
wdata
module_en D Q
clk_s
&
Figure 15-58.
The DSPI supports the stop mode protocol. When a request is made to enter external stop mode, the DSPI
module acknowledges the request. If a serial transfer is in progress, the DSPI waits until it reaches the
frame boundary before it is ready to have its clocks shut off. While the clocks are shut off, the DSPI
memory-mapped logic is not accessible. The states of the interrupt and DMA request signals cannot be
changed while in External Stop mode.
mode, all status bits and register flags in the DSPI return the correct values when read, but writing to them
has no effect. Writing to the DSPI_TCR during module disable mode has no effect. Interrupt and DMA
request signals cannot be cleared while in the module disable mode.
2 3 5 7
1 3 5 7
• For DSCK = 0 1/2 SCK period: For this value, the value for the DSPI is 20 ns
Table 15-47. DSPI Compatibility with MPC500 family QSPI
BITS DSPI_CTAR
CTAS[0] DT CTAS[1] DSCK CTAS[2] FMSZ PDT DT PCSSCK CSSCK
E x
Transmit Next
TX FIFO Base — Data Pointer
—
Entry A (first-in)
Entry B
Entry C
Entry D (last-in)
—
—
+1 TX FIFO Counter -1
15.10.6.1 Address calculation for the first-in entry and last-in entry in the TX FIFO
The memory address of the first-in entry in the TX FIFO is computed by the following equation:
The memory address of the last-in entry in the TX FIFO is computed by the following equation:
Last-in Entry address = TX FIFO Base + 4 TXCTR + TXNXTPTR – 1 mod TXFIFOdepth Eqn. 15-8
TX FIFO Base: Base address of TX FIFO
TXCTR: TX FIFO Counter
TXNXTPTR: Transmit Next Pointer
TX FIFO Depth: Transmit FIFO depth, implementation-specific
15.10.6.2 Address calculation for the first-in entry and last-in entry in the RX FIFO
The memory address of the first-in entry in the RX FIFO is computed by the following equation:
The memory address of the last-in entry in the RX FIFO is computed by the following equation:
Last-in Entry address = RX FIFO Base + 4 RXCTR + POPNXTPTR – 1 mod (RXFIFOdepth) Eqn. 15-10
RX FIFO Base: Base address of RX FIFO
RXCTR: RX FIFO counter
POPNXTPTR: Pop Next Pointer
RX FIFO Depth: Receive FIFO depth, implementation specific
Chapter 16
Development Trigger Semaphore (DTS)
16.1 Introduction
Devices in the MPC5676R family include a system development feature, the Development Trigger
Semaphore (DTS) module, that enables software to signal an external tool by driving a persistent (affected
only by reset or an external tool) signal on an external device pin. There are a variety of ways this module
can be used, including as a component of an external real-time data acquisition system1.
16.2 Overview
The Development Trigger Semaphore (DTS) module consists of three registers and a small amount of
combinational logic to generate an output signal—DTS Trigger Out (DTO). The registers are as follows.
• The DTS_SEMAPHORE register. Any bit in this 32-bit register, when set to a value of logic “1”,
causes the DTS module output signal to be asserted, enabling an external tool to detect up to 32
signals from the application software. In an application, each bit is generally associated with a
specific data set.
Only the processor core and DMA module can set bits in this register. The bits can only be cleared
by a tool access via Nexus Read/Write Access over the JTAG port.
• The DTS_STARTUP register. This register provides a mechanism for the external tool to notify
software running on the CPU that the tool is connected and can provide information about either
the type of tool or options that can be used by the software.
• The DTS_ENABLE register provides an enable/disable capability for the DTS feature.
The architecture is shown in Figure 16-1.
1.When used as a component of a triggered data acquisition system, Nexus read/write access is via the JTAG interface
of the Nexus debug port and is different than the data acquisition protocol defined in the IEEE-ISTO 5001-2003 or
IEEE-ISTO 5001-2010 Nexus standards, which use the Nexus Auxiliary port.
DTS_EN
DTS_ENABLE
Peripheral Bus
DTS_STARTUP
The DTS Trigger Out (DTO) signal is connected to one of the EVTO inputs of the Nexus Port Controller
(NPC). The other EVTO inputs to the NPC are connected to the other Nexus modules in the device. DTO
is asserted when any bit in the DTS_SEMAPHORE register is set.
NOTE
When the DTS module is enabled (DTS_ENABLE[DTS_EN]=0b1), the
Nexus EVTO function of the EVTO pin is disabled and EVTO becomes the
DTO. Unlike the EVTO function that only asserts for one clock, the DTO
function remains asserted until the tool reads the DTS_SEMAPHORE
register, clearing the register’s contents.
Figure 16-2, shows the chain of events that begins with setting of a bit in the DTS_SEMAPHORE register
and the clearing of the register caused by a Nexus read.
~
~
DTS_SEMAPHORE register
~
~
EVTO Pin
~
~
Nexus RWA reads
Internal DTO EVTO negated
DTS_SEMAPHORE,
signal is negated externally
Initial conditions: which clears register
– DTS_ENABLE[DTS_EN] = 0b1
– DTS_SEMAPHORE = 0x0000_0000
1.The External Bus Interface XBAR master port is used for internal test of the device and is not accessible to the user.
2.DTS_SEMAPHORE bits are cleared automatically when read through the Nexus/JTAG port.
Access to DTS module registers is controlled based on the XBAR Master ID of the accessing module. The
table below shows the XBAR Master IDs for each of port.
NOTE
The XBAR Master ID should not be confused with the Master Port number
of the XBAR. See Chapter 11, “AMBA Crossbar Switch (XBAR)” for
details.
Tools must access the DTS registers (DTS_ENABLE, DTS_STARTUP, and DTS_SEMAPHORE)
through the Nexus Read/Write Access mechanism of the core. JTAG accesses through the core appear as
if the access is via the core and therefore will not have the same level of access as a Nexus R/W access.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
DTS_EN
R 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
W
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
= Unimplemented or Reserved
Name Description
31 DTS Enable. Controls whether the DTO signal is routed to the EVTO pin.
DTS_EN
0: DTS output is disabled.
1: DTS output is enabled. Any bit set in the DTS_SEMAPHORE register will assert the DTS Trigger
Output signal (DTO).
Note: The DTS Enable bit is cleared by a device reset (either the assertion of the external RESET
or by an internally generated reset). A JTAG reset does not change the state of this register.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R
AD31
AD30
AD29
AD28
AD27
AD26
AD25
AD24
AD23
AD22
AD21
AD20
AD19
AD18
AD17
AD16
W
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R
AD15
AD14
AD13
AD12
AD11
AD10
AD9
AD8
AD7
AD6
AD5
AD4
AD3
AD2
AD1
AD0
W
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Name Description
AD[31:0] Application Dependent register bits. The bits have no defined meaning to the microcontroller. They
are used to by an external tool to pass information, e.g., application options and status, to application
software running on target microcontroller at startup time. Use a Nexus RWA 32-bit write access to
update the contents of this register.
Note: • A device reset (either from the RESET pin or an internally generated reset) clears all bits in
the register. A JTAG reset does not change the contents of the register.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R
ST31
ST30
ST29
ST28
ST27
ST26
ST25
ST24
ST23
ST22
ST21
ST20
ST19
ST18
ST17
ST16
W
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R
ST15
ST14
ST13
ST12
ST11
ST10
ST06
ST04
ST02
ST9
ST8
ST7
ST5
ST3
ST1
ST0
W
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
core and eDMA are bitwise ORed to the contents of the register. Nexus can only read this register but all bits are
cleared after the read operation.
Name Description
ST[31:0] Semaphore Trigger. When a core or eDMA writes a logical '1' to a bit, the bit is set. A write of '0' by
the core or DMA does not change the state of the bit.
0: No flag.
1: Flag is set.
1.MPC5676R devices also include an MMU modification feature, which enables real-time switching of calibration ta-
bles.
() &$+'!
#$
!
&$! ,,
&&&&&&&&
Figure 16-7. DTS startup sequence example
eDMA SRAM
transfer control descriptor
(TCD)
Slave write address
Slave write data
SRAM TCD0
Slave interface
System bus
TCDn – 1*
eDMA engine
Bus read data
Program model/
channel arbitration
Address
Data path Control
path Slave read data
Bus write data
Bus address
17.1.2 Features
Each eDMA has these major features:
• All data movement via dual-address transfers: read from source, write to destination
— Programmable source, destination addresses, transfer size, and support for enhanced
addressing modes
• Performs complex data transfers with minimal intervention from a host processor
— 32 bytes of data registers, used as temporary storage to support burst transfers
(refer to SSIZE bit)
— Connections to the crossbar switch for bus mastering the data movement
• Transfer control descriptor organized to support two-deep, nested transfer operations
— An inner data transfer loop defined by a minor byte transfer count
— An outer data transfer loop defined by a major iteration count
Offset from
Register Bits Access Reset Value Section/Page
EDMA_x_BASE
Offset from
Register Bits Access Reset Value Section/Page
EDMA_x_BASE
0x0040–0x00FF Reserved
Offset from
Register Bits Access Reset Value Section/Page
EDMA_x_BASE
Offset from
Register Bits Access Reset Value Section/Page
EDMA_x_BASE
0x0140–0x0FFF Reserved
Offset from
Register Bits Access Reset Value Section/Page
EDMA_x_BASE
Offset from
Register Bits Access Reset Value Section/Page
EDMA_x_BASE
Arbitration within a group can be configured to use a fixed priority or a round robin. In fixed-priority
arbitration, the highest priority channel requesting service is selected to execute. The priorities are
assigned by the channel priority registers. See Section 17.3.2.17, “eDMA Channel n Priority Registers
(EDMA_x_CPRn)”. In round-robin arbitration mode, the channel priorities are ignored and the channels
within each group are cycled through, from channel 15 down to channel 0,without regard to priority.
The group priorities operate in a similar fashion. In group fixed-priority arbitration mode, channel service
requests in the highest priority group are executed first where priority level 3 is the highest and priority
level 0 is the lowest. The group priorities are assigned in the GRPnPRI fields of the eDMA control register
(EDMA_x_MCR). All group priorities must have unique values prior to any channel service requests
occur, otherwise a configuration error is reported. In group round-robin mode, the group priorities are
ignored and the groups are cycled through, from group 3 down to group 0, without regard to priority.
Minor loop offsets are address offset values added to the final source address (SADDR) or destination
address (DADDR) upon minor loop completion. When minor loop offsets are enabled, the minor loop
offset (MLOFF) is added to the final source address (SADDR) or to the final destination address
(DADDR) or to both addresses prior to the addresses being written back into the TCD. If the major loop
is complete, the minor loop offset is ignored and the major loop address offsets (SLAST and
DLAST_SGA) are used to compute the next EDMA_x_TCD.SADDR and EDMA_x_TCD.DADDR
values.
When minor loop mapping is enabled (EDMA_x_MCR[EMLM] = 1), TCDn word2 is redefined. A
portion of TCDn word2 is used to specify multiple fields: a source enable bit (SMLOE) to specify that the
minor loop offset should be applied to the source address (SADDR) upon minor loop completion, a
destination enable bit (DMLOE) to specify the minor loop offset should be applied to the destination
address (DADDR) upon minor loop completion, and the sign extended minor loop offset value (MLOFF).
The same offset value (MLOFF) is used for both source and destination minor loop offsets.
When either of the minor loop offsets is enabled (SMLOE is set or DMLOE is set), the NBYTES field is
reduced to 10 bits. When both minor loop offsets are disabled (SMLOE is cleared and DMLOE is cleared),
the NBYTES field becomes a 30-bit vector.
When minor loop mapping is disabled (EDMA_x_MCR[EMLM] = 0), all 32 bits of TCDn word2 are
assigned to the NBYTES field. See Section 17.3.2.18, “Transfer Control Descriptor (TCD)”, for more
details.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 0 0 0 0 0 0 0 0 0 0 0 0
CXFR ECX
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R 0
GRP3PRI GRP2PRI GRP1PRI GRP0PRI EMLM CLM HALT HOE ERGA ERCA EDBG
W
Reset 1 1 1 0 0 1 0 0 0 0 0 0 0 0 0 0
Field Description
0–13 Reserved
14 Cancel Transfer.
CXFR 0 Normal operation.
1 Cancel the remaining data transfer. Stop the executing channel and force the minor loop to be finished.
The cancel takes effect after the last write of the current read/write sequence. The CXFR bit clears
itself after the cancel has been honored. This cancel retires the channel normally as if the minor loop
was completed.
16–17 Channel group 3 priority. Group 3 priority level when fixed priority group arbitration is enabled.
GRP3PRI
18–19 Channel group 2 priority. Group 2 priority level when fixed priority group arbitration is enabled.
GRP2PRI
20–21 Channel group 1 priority. Group 1 priority level when fixed priority group arbitration is enabled.
GRP1PRI
22–23 Channel group 0 priority. Group 0 priority level when fixed priority group arbitration is enabled.
GRP0PRI
Field Description
27 Halt on error.
HOE 0 Normal operation.
1 Any error causes the HALT bit to be set. Subsequently, all service requests are ignored until the HALT
bit is cleared.
30 Enable Debug.
EDBG 0 The assertion of the system debug control input is ignored.
1 The assertion of the system debug control input causes the eDMA to stall the start of a new channel.
Executing channels are allowed to complete. Channel execution resumes when either the system
debug control input is negated or the EDBG bit is cleared.
31 Reserved
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R VLD 0 0 0 0 0 0 0 0 0 0 0 0 0 0 ECX
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R GPE CPE ERRCHN SAE SOE DAE DOE NCE SGE SBE DBE
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Field Description
1–14 Reserved
15 Transfer canceled.
ECX 0 No canceled transfers.
1 The last recorded entry was a canceled transfer via the error cancel transfer input.
16 Group-priority error.
GPE 0 No group-priority error.
1 The last recorded error was a configuration error among the group priorities indicating not all group
priorities are unique.
17 Channel-Priority Error.
CPE 0 No channel-priority error.
1 The last recorded error was a configuration error in the channel priorities within a group, indicating not
all channel priorities within a group are unique.
18–23 Error Channel Number or Canceled Channel Number. Channel number of the last recorded error
ERRCHN (excluding GPE and CPE errors) or last recorded transfer that was error cancelled.
Note: Do not rely on the number in the ERRCHN field group for channel-priority errors. Group- and
Channel-priority errors must be resolved by inspection. The application code must interrogate the
priority registers to find groups or channels with duplicate priority level.
Field Description
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R ERQ ERQ ERQ ERQ ERQ ERQ ERQ ERQ ERQ ERQ ERQ ERQ ERQ ERQ ERQ ERQ
W 63 62 61 60 59 58 57 56 55 54 53 52 51 50 49 48
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R ERQ ERQ ERQ ERQ ERQ ERQ ERQ ERQ ERQ ERQ ERQ ERQ ERQ ERQ ERQ ERQ
W 47 46 45 44 43 42 41 40 39 38 37 36 35 34 33 32
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R ERQ ERQ ERQ ERQ ERQ ERQ ERQ ERQ ERQ ERQ ERQ ERQ ERQ ERQ ERQ ERQ
W 31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 19 19 20 21 22 23 24 25 26 27 28 29 30 31
R ERQ ERQ ERQ ERQ ERQ ERQ ERQ ERQ ERQ ERQ ERQ ERQ ERQ ERQ ERQ ERQ
W 15 14 13 12 11 10 09 08 07 06 05 04 03 02 01 00
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Field Description
As a given channel completes processing its major iteration count, there is a flag in the transfer control
descriptor that may affect the ending state of the EDMA_x_ERQR bit for that channel. If the
EDMA_x_TCD.D_REQ bit is set, then the corresponding EDMA_x_ERQR bit is cleared after the major
loop is complete, disabling the eDMA hardware request. Otherwise if the D_REQ bit is cleared, the state
of the EDMA_x_ERQR bit is unaffected.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R EEI EEI EEI EEI EEI EEI EEI EEI EEI EEI EEI EEI EEI EEI EEI EEI
W 63 62 61 60 59 58 57 56 55 54 53 52 51 50 49 48
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R EEI EEI EEI EEI EEI EEI EEI EEI EEI EEI EEI EEI EEI EEI EEI EEI
W 47 46 45 44 43 42 41 40 39 38 37 36 35 34 33 32
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R EEI EEI EEI EEI EEI EEI EEI EEI EEI EEI EEI EEI EEI EEI EEI EEI
W 31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R EEI EEI EEI EEI EEI EEI EEI EEI EEI EEI EEI EEI EEI EEI EEI EEI
W 15 14 13 12 11 10 09 08 07 06 05 04 03 02 01 00
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Field Description
0 1 2 3 4 5 6 7
R 0 0 0 0 0 0 0 0
W NOP SERQ[0:6]
Reset 0 0 0 0 0 0 0 0
Field Descriptions
0 No operation.
NOP 0 Normal operation.
1 No operation, ignore bits 1–7.
0 1 2 3 4 5 6 7
R 0 0 0 0 0 0 0 0
W NOP CERQ[0:6]
Reset 0 0 0 0 0 0 0 0
Field Description
0 No operation.
NOP 0 Normal operation.
1 No operation, ignore bits 1–7.
0 1 2 3 4 5 6 7
R 0 0 0 0 0 0 0 0
W NOP SEEI[0:6]
Reset 0 0 0 0 0 0 0 0
Field Description
0 No operation.
NOP 0 Normal operation.
1 No operation, ignore bits 1–7.
0 1 2 3 4 5 6 7
R 0 0 0 0 0 0 0 0
W NOP CEEI[0:6]
Reset 0 0 0 0 0 0 0 0
Field Description
0 No operation.
NOP 0 Normal operation.
1 No operation, ignore bits 1-7.
0 1 2 3 4 5 6 7
R 0 0 0 0 0 0 0 0
W NOP CINT[0:6]
Reset 0 0 0 0 0 0 0 0
Field Description
0 No operation.
NOP 0 Normal operation.
1 No operation, ignore bits 1-7.
0 1 2 3 4 5 6 7
R 0 0 0 0 0 0 0 0
W NOP CERR[0:6]
Reset 0 0 0 0 0 0 0 0
Field Description
0 No operation.
NOP 0 Normal operation.
1 No operation, ignore bits 1–7.
0 1 2 3 4 5 6 7
R 0 0 0 0 0 0 0 0
W NOP SSB[0:6]
Reset 0 0 0 0 0 0 0 0
Field Description
0 No operation.
NOP 0 Normal operation.
1 No operation, ignore bits 1–7.
0 1 2 3 4 5 6 7
R 0 0 0 0 0 0 0 0
W NOP CDSB[0:6]
Reset 0 0 0 0 0 0 0 0
Field Description
0 No operation.
NOP 0 Normal operation.
1 No operation, ignore bits 1–7.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R INT INT INT INT INT INT INT INT INT INT INT INT INT INT INT INT
W 63 62 61 60 59 58 57 56 55 54 53 52 51 50 49 48
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R INT INT INT INT INT INT INT INT INT INT INT INT INT INT INT INT
W 47 46 45 44 43 42 41 40 39 38 37 36 35 34 33 32
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R INT INT INT INT INT INT INT INT INT INT INT INT INT INT INT INT
W 31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 19 19 20 21 22 23 24 25 26 27 28 29 30 31
R INT INT INT INT INT INT INT INT INT INT INT INT INT INT INT INT
W 15 14 13 12 11 10 09 08 07 06 05 04 03 02 01 00
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Field Description
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R ERR ERR ERR ERR ERR ERR ERR ERR ERR ERR ERR ERR ERR ERR ERR ERR
W 63 62 61 60 59 58 57 56 55 54 53 52 51 50 49 48
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R ERR ERR ERR ERR ERR ERR ERR ERR ERR ERR ERR ERR ERR ERR ERR ERR
W 47 46 45 44 43 42 41 40 39 38 37 36 35 34 33 32
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R ERR ERR ERR ERR ERR ERR ERR ERR ERR ERR ERR ERR ERR ERR ERR ERR
W 31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R ERR ERR ERR ERR ERR ERR ERR ERR ERR ERR ERR ERR ERR ERR ERR ERR
W 15 14 13 12 11 10 09 08 07 06 05 04 03 02 01 00
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Field Description
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R HRS HRS HRS HRS HRS HRS HRS HRS HRS HRS HRS HRS HRS HRS HRS HRS
W 63 62 61 60 59 58 57 56 55 54 53 52 51 50 49 48
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R HRS HRS HRS HRS HRS HRS HRS HRS HRS HRS HRS HRS HRS HRS HRS HRS
W 47 46 45 44 43 42 41 40 39 38 37 36 35 34 33 32
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R HRS HRS HRS HRS HRS HRS HRS HRS HRS HRS HRS HRS HRS HRS HRS HRS
W 31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R HRS HRS HRS HRS HRS HRS HRS HRS HRS HRS HRS HRS HRS HRS HRS HRS
W 15 14 13 12 11 10 09 08 07 06 05 04 03 02 01 00
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Field Description
completes one read/write sequence, it is again eligible for preemption. If any higher priority channel
requests service, the restored channel is suspended and the higher priority channel is serviced. Nested
preemption (attempting to preempt a preempting channel) is not supported. After a preempting channel
begins execution, it cannot be preempted. Preemption is available only when fixed arbitration is selected
for both group and channel arbitration modes.
A channel’s ability to pre-empt another channel can be disabled by setting EDMA_x_CPR[DPA]. When a
channel’s pre-empt ability is disabled, that channel cannot suspend a lower priority channel’s data transfer;
regardless of the lower priority channel’s ECP setting. This allows for a pool of low priority, large data
moving channels to be defined. These low priority channels can be configured to not preempt each other,
thus preventing a low priority channel from consuming the preempt slot normally available a true, high
priority channel.
0 1 2 3 4 5 6 7
R GRPPRI
ECP DPA CHPRI
W
Reset 0 0 0 0 —1
1
The reset value for the channel priority field, CHPRI[0–3], is equal
to the corresponding channel number for each priority register for
example, EDMA_x_CPRI0[CHPRI] = 0b0000 and
EDMA_x_CPR15[CHPRI] = 0b1111.
Field Description
2–3 Channel n current group priority. Group priority assigned to this channel group when fixed-priority
GRPPRI arbitration is enabled. These two bits are read-only; writes are ignored. The reset value for the group
priority fields, is equal to the corresponding channel number for each priority register; that is,
EDMA_x_CPR31[GRPPRI] = 0b01.
4–7 Channel n Arbitration Priority. Channel priority when fixed-priority arbitration is enabled. The reset value
CHPRI for the channel priority fields CHPRI[0–3], is equal to the corresponding channel number for each priority
register; for example, EDMA_x_CPR31[CHPRI] = 0b1111.
1,... channel 63. The definitions of the TCD are presented as eight 32-bit values. Table 17-18 is a field list
of the basic TCD structure.
Table 17-18. TCDn 32-bit Memory Structure
0x1000+(32 x n)+0x0014 Current major iteration count (citer) Signed destination address offset (doff)
0x1000 (32 x n) 0x0018 Last destination address adjustment / scatter-gather address (dlast_sga)
Figure 17-24 and Table 17-19 define the fields of the TCDn structure.
Word
Offset 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
0x0000 SADDR
0x0008 NBYTES1
DMLOE1
SMLOE1
0x000C SLAST
0x0010 DADDR
CITER.E_ LINK
CITER or
0x0014 CITER DOFF
CITER.LINKCH
0x0018 DLAST_SGA
MAJOR.E_LINK
BITER.E_ LINK
INT_HALF
INT_MAJ
ACTIVE
D_REQ
START
DONE
E_SG
BITER or
0x001C BITER BWC MAJOR LINKCH
BITER.LINKCH
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
NOTE
The TCD structures for the eDMA channels shown in Figure 17-24 are
implemented in internal SRAM. These structures are not initialized at reset;
therefore, all channel TCD parameters must be initialized by the application
code before activating that channel.
Table 17-19. TCDn Field Descriptions
Field Description
0x0 [0:31] Source address. Memory address pointing to the source data.
SADDR Word 0x0, bits 0–31.
0x4 [13:15] Destination data transfer size. See the SSIZE[0:2] definition.
DSIZE
0x4 [16:31] Source address signed offset. Sign-extended offset applied to the current source address to
SOFF form the next-state value as each source read is completed.
Field Description
0x8 [2-21] Inner “minor” byte transfer count or Minor loop offset
MLOFF or If both SMLOE and DMLOE are cleared, this field is part of the byte transfer count.
NBYTES 1
If either SMLOE or DMLOE are set, this field represents a sign-extended offset applied to the
source or destination address to form the next-state value after the minor loop is completed.
0x8 [22:31] Inner “minor” byte transfer count. Number of bytes to be transferred in each service request
NBYTES 1 of the channel. As a channel is activated, the contents of the appropriate TCD is loaded into
the eDMA engine, and the appropriate reads and writes performed until the complete byte
transfer count has been transferred. This is an indivisible operation and cannot be stalled or
halted. Once the minor count is exhausted, the current values of the SADDR and DADDR are
written back into the local memory, the major iteration count is decremented and restored to
the local memory. If the major iteration count is completed, additional processing is
performed.
Note: The NBYTES value of 0x0000_0000 is interpreted as 0x1_0000_0000, thus specifying
a 4 GB transfer.
0xC [0:31] Last source address adjustment. Adjustment value added to the source address at the
SLAST completion of the outer major iteration count. This value can be applied to “restore” the source
address to the initial value, or adjust the address to reference the next data structure.
0x10 [0:31] Destination address. Memory address pointing to the destination data.
DADDR
0x14 [0] Enable channel-to-channel linking on minor loop completion. As the channel completes the
CITER.E_LINK inner minor loop, this flag enables the linking to another channel, defined by
CITER.LINKCH[0:5]. The link target channel initiates a channel service request via an internal
mechanism that sets the EDMA_x_TCD.START bit of the specified channel. If channel linking
is disabled, the CITER value is extended to 15 bits in place of a link channel number. If the
major loop is exhausted, this link mechanism is suppressed in favor of the MAJOR.E_LINK
channel linking.
0 The channel-to-channel linking is disabled.
1 The channel-to-channel linking is enabled.
Note: This bit must be equal to the BITER.E_LINK bit. Otherwise, a configuration error is
reported.
Field Description
0x14 [7:15] Current major iteration count. This 9 or 15-bit count represents the current major loop count
CITER for the channel. It is decremented each time the minor loop is completed and updated in the
transfer control descriptor memory. After the major iteration count is exhausted, the channel
performs a number of operations (for example, final source and destination address
calculations), optionally generating an interrupt to signal channel completion before reloading
the CITER field from the beginning iteration count (BITER) field.
Note: When the CITER field is initially loaded by software, it must be set to the same value
as that contained in the BITER field.
Note: If the channel is configured to execute a single service request, the initial values of
BITER and CITER should be 0x0001.
0x14 [16:31] Destination address signed Offset. Sign-extended offset applied to the current destination
DOFF address to form the next-state value as each destination write is completed.
0x18 [0:31] Last destination address adjustment or the memory address for the next transfer control
DLAST_SGA descriptor to be loaded into this channel (scatter-gather).
If scatter-gather processing for the channel is disabled (EDMA_x_TCD.E_SG = 0) then
• Adjustment value added to the destination address at the completion of the outer major
iteration count.
This value can be applied to restore the destination address to the initial value, or adjust the
address to reference the next data structure.
Otherwise,
• This address points to the beginning of a 0-modulo-32 byte region containing the next
transfer control descriptor to be loaded into this channel. This channel reload is performed
as the major iteration count completes. The scatter-gather address must be 0-modulo-32
byte, otherwise a configuration error is reported.
0x1C [0] Enables channel-to-channel linking on minor loop complete. As the channel completes the
BITER.E_LINK inner minor loop, this flag enables the linking to another channel, defined by
BITER.LINKCH[0:5]. The link target channel initiates a channel service request via an internal
mechanism that sets the EDMA_x_TCD.START bit of the specified channel. If channel linking
is disabled, the BITER value is extended to 15 bits in place of a link channel number. If the
major loop is exhausted, this link mechanism is suppressed in favor of the MAJOR.E_LINK
channel linking.
0 The channel-to-channel linking is disabled.
1 The channel-to-channel linking is enabled.
Note: When the TCD is first loaded by software, this field must be set equal to the
corresponding CITER field. Otherwise, a configuration error is reported. As the major
iteration count is exhausted, the contents of this field is reloaded into the CITER field.
Field Description
0x1C [7:15] Starting major iteration count. As the transfer control descriptor is first loaded by software, this
BITER field must be equal to the value in the CITER field. As the major iteration count is exhausted,
the contents of this field are reloaded into the CITER field.
Note: If the channel is configured to execute a single service request, the initial values of
BITER and CITER should be 0x0001.
0x1C [16:17] Bandwidth control. This two-bit field provides a mechanism to effectively throttle the amount
BWC of bus bandwidth consumed by the eDMA. In general, as the eDMA processes the inner minor
loop, it continuously generates read/write sequences until the minor count is exhausted. This
field forces the eDMA to stall after the completion of each read/write access to control the bus
request bandwidth seen by the system bus crossbar switch (XBAR).
00 No DMA engine stalls
01 Reserved
10 DMA engine stalls for 4 cycles after each r/w
11 DMA engine stalls for 8 cycles after each r/w
0x1C [24] Channel done. This flag indicates the eDMA has completed the outer major loop. It is set by
DONE the DMA engine as the CITER count reaches zero; it is cleared by software or hardware when
the channel is activated (when the DMA engine has begun processing the channel, not when
the first data transfer occurs).
Note: This bit must be cleared to write the MAJOR.E_LINK or E_SG bits.
0x1C [25] Channel active. This flag signals the channel is currently in execution. It is set when channel
ACTIVE service begins, and is cleared by the DMA engine as the inner minor loop completes or if any
error condition is detected.
0x1C [26] Enable channel-to-channel linking on major loop completion. As the channel completes the
MAJOR.E_LINK outer major loop, this flag enables the linking to another channel, defined by
MAJOR.LINKCH[0:5]. The link target channel initiates a channel service request via an
internal mechanism that sets the EDMA_x_TCD.START bit of the specified channel.
Note: To support the dynamic linking coherency model, this field is forced to zero when
written to while the EDMA_x_TCD.DONE bit is set.
0 The channel-to-channel linking is disabled.
1 The channel-to-channel linking is enabled.
0x1C [27] Enable scatter-gather processing. As the channel completes the outer major loop, this flag
E_SG enables scatter-gather processing in the current channel. If enabled, the DMA engine uses
DLAST_SGA as a memory pointer to a 0-modulo-32 address containing a 32-byte data
structure which is loaded as the transfer control descriptor into the local memory.
Note: To support the dynamic scatter-gather coherency model, this field is forced to zero
when written to while the EDMA_x_TCD.DONE bit is set.
0 The current channel’s TCD is normal format.
1 The current channel’s TCD specifies a scatter gather format. The DLAST_SGA field
provides a memory pointer to the next TCD to be loaded into this channel after the outer
major loop completes its execution.
Field Description
0x1C [28] Disable hardware request. If this flag is set, the eDMA hardware automatically clears the
D_REQ corresponding EDMA_x_ERQH or EDMA_x_ERQL bit when the current major iteration count
reaches zero.
0 The channel’s EDMA_x_ERQH or EDMA_x_ERQL bit is not affected.
1 The channel’s EDMA_x_ERQH or EDMA_x_ERQL bit is cleared when the outer major loop
is complete.
0x1C [29] Enable an interrupt when major counter is half complete. If this flag is set, the channel
INT_HALF generates an interrupt request by setting the appropriate bit in the EDMA_x_ERQH or
EDMA_x_ERQL when the current major iteration count reaches the halfway point.
Specifically, the comparison performed by the eDMA engine is (CITER == (BITER >> 1)). This
halfway point interrupt request is provided to support double-buffered (aka ping-pong)
schemes, or other types of data movement where the processor needs an early indication of
the transfer’s progress. CITER = BITER = 1 with INT_HALF enabled will generate an interrupt
as it satisfies the equation (CITER == (BITER >> 1)) after a single activation.
0 The half-point interrupt is disabled.
1 The half-point interrupt is enabled.
0x1C [30] Enable an interrupt when major iteration count completes. If this flag is set, the channel
INT_MAJ generates an interrupt request by setting the appropriate bit in the EDMA_x_ERQH or
EDMA_x_ERQL when the current major iteration count reaches zero.
0 The end-of-major loop interrupt is disabled.
1 The end-of-major loop interrupt is enabled.
0x1C [31] Channel start. If this flag is set the channel is requesting service. The eDMA hardware
START automatically clears this flag after the channel begins execution.
0 The channel is not explicitly started.
1 The channel is explicitly started via a software initiated service request.
the TCDn.{SADDR, DADDR, CITER} back into the local memory. If the major iteration
count is exhausted, additional processing is performed, including the final address pointer
updates, reloading the TCDn.CITER field, and a possible fetch of the next TCDn from memory
as part of a scatter-gather operation.
— Data path: This module implements the actual bus master read/write datapath. It includes 32
bytes of register storage (matching the maximum transfer size) and the necessary mux logic to
support any required data alignment. The system read data bus is the primary input, and the
system write data bus is the primary output.
— The address and data path modules directly support the two-stage pipelined system bus. The
address path module represents the 1st stage of the bus pipeline (the address phase), while the
data path module implements the second stage of the pipeline (the data phase).
— Program model/channel arbitration: This module implements the first section of eDMA’s
programming model and also the channel arbitration logic. The programming model registers
are connected to the slave bus (not shown). The eDMA peripheral request inputs and eDMA
interrupt request outputs are also connected to this module (via the control logic).
— Control: This module provides all the control functions for the DMA engine. For data transfers
where the source and destination sizes are equal, the DMA engine performs a series of source
read, destination write operations until the number of bytes specified in the inner minor loop
byte count has been moved.
A minor loop interaction is defined as the number of bytes to transfer (nbytes) divided by the
transfer size. Transfer size is defined as:
if (SSIZE < DSIZE)
transfer size = destination transfer size (# of bytes)
else
transfer size = source transfer size (# of bytes)
Minor loop TCD variables are SOFF, SMOD, DOFF, DMOD, NBYTES, SADDR, DADDR,
BWC, ACTIVE, AND START. Major loop TCD variables are DLAST, SLAST, CITER,
BITER, DONE, D_REQ, INT_MAJ, MAJOR_LNKCH, and INT_HALF.
For descriptors where the sizes are not equal, multiple access of the smaller size data are
required for each reference of the larger size. For example, if the source size references 16-bit
data and the destination is 32-bit data, two reads are performed, then one 32-bit write.
• TCD local memory
— Memory controller: This logic implements the required dual-ported controller, handling
accesses from both the DMA engine as well as references from the slave bus. As noted earlier,
in the event of simultaneous accesses, the DMA engine is given priority and the slave
transaction is stalled.
— Memory array: The TCD is implemented using a single-ported, synchronous compiled RAM
memory array.
eDMA SRAM
Transfer control descriptor
(TCD)
Slave write address
Slave write data
SRAM TCD0
Slave interface
System bus
TCDn – 1*
eDMA engine
Bus read data
Program model/
channel arbitration
Address
Data path Control
path Slave read data
Bus write data
Bus address
*n = 64 channels
eDMA interrupt request eDMA peripheral request
eDMA done handshake
Figure 17-25. eDMA Operation, Part 1
In the second part of the basic data flow as shown in Figure 17-26, the modules associated with the data
transfer (address path, data path, and control) sequence through the required source reads and destination
writes to perform the actual data movement. The source reads are initiated and the fetched data is
temporarily stored in the data path module until it is gated onto the system bus during the destination write.
This source read/destination write processing continues until the inner minor byte count has been
transferred. The eDMA done handshake signal is asserted at the end of the minor byte count transfer.
eDMA SRAM
Transfer control descriptor
(TCD)
Slave write address
Slave write data
SRAM TCD0
Slave interface
System bus
TCDn – 1*
eDMA engine
Bus read data
Program model/
channel arbitration
Address
Data path Control
path Slave read data
Bus write data
Bus address
*n = 64 channels
eDMA peripheral eDMA interrupt request
request eDMA done handshake
Figure 17-26. eDMA Operation, Part 2
After the inner minor byte count has been moved, the final phase of the basic data flow is performed. In
this segment, the address path logic performs the required updates to certain fields in the channel’s TCD;
for example, SADDR, DADDR, CITER. If the outer major iteration count is exhausted, then there are
additional operations performed. These include the final address adjustments and reloading of the BITER
field into the CITER. Additionally, assertion of an optional interrupt request occurs at this time, as does a
possible fetch of a new TCD from memory using the scatter-gather address pointer included in the
descriptor. The updates to the TCD memory and the assertion of an interrupt request are shown in
Figure 17-27.
eDMA SRAM
Transfer control descriptor
(TCD)
Slave write address
Slave write data
SRAM TCD0
Slave interface
System bus
TCDn – 1*
eDMA engine
Bus read data
Program model/
channel arbitration
*n = 64 channels
eDMA peripheral eDMA done
request
Figure 17-27. eDMA Operation, Part 3
After any channel requests service, a channel is selected for execution based on the arbitration and priority
levels written into the programmer's model. The DMA engine reads the entire TCD, including the primary
transfer control parameter shown in Table 17-20, for the selected channel into its internal address path
module. As the TCD is being read, the first transfer is initiated on the system bus unless a configuration
error is detected. Transfers from the source (as defined by the source address, EDMA_x_TCD.SADDR)
to the destination (as defined by the destination address, EDMA_x_TCD.DADDR) continue until the
specified number of bytes (EDMA_x_TCD.NBYTES) have been transferred. When the transfer is
complete, the DMA engine's local EDMA_x_TCD.SADDR, EDMA_x_TCD.DADDR, and
EDMA_x_TCD.CITER are written back to the main TCD memory and any minor loop channel linking is
performed, if enabled. If the major loop is exhausted, further post processing is executed; for example,
interrupts, major loop channel linking, and scatter-gather operations, if enabled.
Table 17-20. TCD Primary Control and Status Fields
TCD Field
Description
Name
START Control bit to start channel when using a software initiated DMA
service (Automatically cleared by hardware)
INT_HALF Control bit to enable interrupt when major loop is half complete
Figure 17-28 shows how each DMA request initiates one minor loop transfer (iteration) without CPU
intervention. DMA arbitration can occur after each minor loop, and one level of minor loop DMA
preemption is allowed. The number of minor loops in a major loop is specified by the beginning iteration
count (biter).
DMA request
• Minor loop 3
•
•
DMA request
DMA request
• Minor loop 1
•
•
Figure 17-29 lists the memory array terms and how the TCD settings interrelate.
Transfer
Address
Number
1 0x12345670
2 0x12345674
3 0x12345678
4 0x1234567C
5 0x12345670
6 0x12345674
the major loop. Two EDMA_x_TCD.ACTIVE bits set at the same time in the overall TCD map indicates
a higher priority channel is actively preempting a lower priority channel.
Desired Link
TCD Control Field Name Description
Behavior
NOTE
The user must clear the EDMA_x_TCD.DONE bit before writing the
EDMA_x_TCD.MAJOR.E_LINK or EDMA_x_TCD.E_SG bits. The
EDMA_x_TCD.DONE bit is cleared automatically by the eDMA engine
after a channel begins execution.
Redline
Enhanced Modular
I/O System former STAC
(eMIOS200) Bus
Channel[23] EMIOS[23]
Global Time
Base Enable [D]
• •
• •
• •
Global Time Base
Bit (GTBE) Output Channel[16] EMIOS[16]
Internal
System Clock Counter
Clock Prescaler Clock
Enable Channel[15] EMIOS[15]
[C]
• •
• •
• •
Channel[8] EMIOS[8]
Channel[7] EMIOS[7]
[A]
Counter [B]
• •
Buses • •
(Time • •
Output Disable Bases)
Control Bus Channel[0] EMIOS[0]
18.1.2 Features
• 32 unified channels (UC)
• Channel features:
— 24-bit registers for captured/match values
— 24-bit internal counter
— Internal prescaler
— Selectable time base
— Can generate its own time base
• Five 24-bit-wide counter buses
— Counter bus A can be driven by unified channel 23or by the STAC bus.
— Counter buses B, C, D, and E are driven by unified channels 0, 8, 16, and 24, respectively
— Counter bus A can be shared among all unified channels. UCs 0 to 7, 8 to 15, 16 to 23, and 24
to 31 can share counter buses B, C, D, and E, respectively
• One global prescaler
• The output signal from the module configuration register’s global time base enable bit
(EMIOS_MCR[GTBE]) is wrapped back into the global timebase enable input so that the timebase
of each channel can be started simultaneously.
• Shared time bases through the counter buses
• Shadow FLAG register
• State of eMIOS200 can be frozen for debug purposes
• Debug mode is supported
18.2.1 eMIOS[n]
eMIOS[n] are the eMIOS channel pins. When used as an input, an eMIOS[n] signal is available to be read
by the MCU through the UCIN bit in the EMIOS_CSR[n] register. When used as an output, the UCOUT
bit of the EMIOS_CSR[n] register reflects the state of the output pin.
NOTE
All eMIOS channels support both input and output functions, however some
channels do not support input from the physical pins, but through internal
routing logic. Refer to Table 2-4 for complete details of the I/O capability of
each channel.
Offset from
EMIOS_BASE Register Bits Access1 Reset Value Section/Page
(0xC3FA_0000)
Global Registers
0x000C–0x001F Reserved
0x0038–0x003F Reserved
0x0058–0x005F Reserved
Offset from
EMIOS_BASE Register Bits Access1 Reset Value Section/Page
(0xC3FA_0000)
0x0078–0x007F Reserved
0x0420–0x3FFF Reserved
1
Note that R/W registers may contain some read-only or write-only bits.
2
The alternate address register provides and alternate read-only address to access A2 channel registers in pulse edge counting
(PEC) and windowed programmable time accumulation (WPTA) modes. IF EMIOS_CADR[n] register is used with
EMIOS_ALTA[n], both A1 and A2 registers can be accessed in these modes.
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R 0 0 0 0 0 0 0 0
GPRE[0:7]
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 18-2. eMIOS200 Module Configuration Register (EMIOS_MCR)
Field Description
0 Reserved.
Note: Writing to this bit updates the register value, and reading it returns the last value written, but the bit has
no other effect.
1 Module Disable Bit. Puts the eMIOS200 in low-power mode. The MDIS bit is used to stop the clock of the
MDIS block, except the access to registers EMIOS_MCR and EMIOS_OUDR.
0 Clock is running.
1 Enter low-power mode.
2 Freeze Bit. Enables the eMIOS200 to freeze the registers of the unified channels when debug mode is
FRZ requested at MCU level. Each unified channel must have FREN bit set in order to enter freeze mode. While
in freeze mode, the eMIOS200 continues to operate to allow the MCU access to the unified channel registers.
The unified channel remains frozen until the FRZ bit is written to 0 or the MCU exits debug mode or the unified
channel FREN bit is cleared.
0 Exit freeze mode.
1 Stops unified channel operation when in debug mode and the FREN bit is set in the EMIOS_CCR[n]
register.
3 Global Time Base Enable Bit. The GTBE bit is used to export a global time base enable from the module and
GTBE provide a method to start time bases of several blocks simultaneously.
0 Global time base enable out signal negated.
1 Global time base enable out signal asserted.
Note: The global time base enable input pin controls the internal counters. When asserted, internal counters
are enabled. When negated, internal counters are disabled.
4 External Time Base Bit. The ETB bit selects the time base source that drives counter bus[A].
ETB 0 Counter bus[A] assigned to Unified Channel 23
1 STAC drives counter bus [A]
If ETB is set to select STAC as the counter bus[A] source, the GTBE must be set to enable the STAC to
counter bus[A]. See the STAC bus configuration register (ETPU_REDCR) section of the eTPU chapter for
more information about the STAC.
Field Description
5 Global Prescaler Enable Bit. The GPREN bit enables the prescaler counter.
GPREN 0 Prescaler disabled and prescaler counter is cleared.
1 Prescaler enabled.
6–11 Reserved
12–15 Server time slot. Selects the address of a specific STAC server to which the STAC client submodule is
SRV assigned. See Section 18.4.3, “STAC Client Submodule”.
0000 eTPU engine A, TCR1
0001 eTPU engine B, TCR1
0010 eTPU engine A, TCR2
0011 eTPU engine B, TCR2
0100 eTPU engine C, TCR1
0101 eTPU engine C, TCR2
0110-1111 Reserved
16–23 Global Prescaler Bits. The GPRE bits select the clock divider value for the global prescaler.
GPRE
GPRE Divide Ratio
0000_0000 1
0000_0001 2
0000_0010 3
0000_0011 4
. .
. .
. .
1111_1110 255
1111_1111 256
24–31 Reserved
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R F15 F14 F13 F12 F11 F10 F9 F8 F7 F6 F5 F4 F3 F2 F1 F0
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 18-3. eMIOS200 Global Flag Register (EMIOS_GFR)
Field Description
0–31 FLAG Bits. The EMIOS_GFR is a read-only register that groups the FLAG bits from all channels. These bits are
Fn mirrors of the FLAG bits of each channel register (EMIOS_CSR[n]).
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R
OU15 OU14 OU13 OU12 OU11 OU10 OU9 OU8 OU7 OU6 OU5 OU4 OU3 OU2 OU1 OU0
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 18-4. eMIOS200 Output Update Disable Register (EMIOS_OUDR)
Field Description
0–31 Channel [n] Output Update Disable Bits. When running MC, MCB, or an output mode, values are written to
OUn registers A2 and B2. OUn bits are used to disable transfers from registers A2 to A1 and B2 to B1. Each bit controls
one channel.
0 Transfer enabled. Depending on the operation mode, transfer may occur immediately or in the next period.
Unless stated otherwise, transfer occurs immediately.
1 Transfers disabled.
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R
A[0:23]
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 18-5. eMIOS200 A Register (EMIOS_CADR[n])
Depending on the mode of operation, internal registers A1 or A2, used for matches and captures, can be
assigned to address EMIOS_CADR[n]. A1 and A2 are cleared by reset. Table 18-7 summarizes the
EMIOS_CADR[n] writing and reading accesses for all operation modes. For more information see
Section 18.4.1.1, “Unified Channel Modes of Operation”.
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R
B[0:23]
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 18-6. eMIOS200 B Register (EMIOS_CBDR[n])
Register Access
Operation Mode
Write Read Write Read Alternate Write Alternate Read
SAOC1 A2 A1 B2 B2 — —
IPWM — A2 — B1 — —
IPM — A2 — B1 — —
DAOC A2 A1 B2 B1 — —
PEA A1 A2 — B1 — —
1
PEC A1 A1 B1 B1 — A2
QDEC1 A1 A1 B2 B2 — —
WPTA A1 A1 B1 B1 — A2
MC1 A2 A1 B2 B2 — —
OPWFM A2 A1 B2 B1 — —
OPWMC A2 A1 B2 B1 — —
OPWM A2 A1 B2 B1 — —
MCB1 A2 A1 B2 B2 — —
Register Access
Operation Mode
Write Read Write Read Alternate Write Alternate Read
OPWFMB A2 A1 B2 B1 — —
OPWMCB A2 A1 B2 B1 — —
OPWMB A2 A1 B2 B1 — —
1
In these modes, the register EMIOS_CBDR[n] is not used, but B2 can be accessed.
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R C[0:23]
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
1
In GPIO mode or freeze action, this register is writable.
Figure 18-7. eMIOS200 Counter Register (EMIOS_CCNTR[n])
The EMIOS_CCNTR[n] register contains the value of the internal counter for eMIOS channel n. When
GPIO mode is selected or the channel is frozen, the EMIOS_CCNTR[n] register is read/write. For all other
modes, the EMIOS_CCNTR[n] is a read-only register. When entering some operation modes, this register
is automatically cleared (refer to Section 18.4.1.1, “Unified Channel Modes of Operation”, for details).
Depending on the channel configuration it may have an internal counter or not. It means that if at least one
mode that requires the counter is implemented, then the counter is present, otherwise it is absent.
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R 0 0 FORC FORC 0 ED ED
BSL MODE
W MA MB SEL POL
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 18-8. eMIOS200 Control Register (EMIOS_CCR[n])
The control register gathers bits reflecting the status of the unified channel input/output signals and the
overflow condition of the internal counter, as well as several read/write control bits.
Table 18-8. EMIOS_CCR[n] Field Descriptions
Field Description
0 Freeze Enable Bit. The FREN bit, if set and validated by FRZ bit in EMIOS_MCR register, freezes all registers’
FREN values when in debug mode, allowing the MCU to perform debug functions.
0 Normal operation.
1 Freeze unified channel registers’ values.
1 Output Disable Bit. The ODIS bit allows disabling the output pin when running any of the output modes with
ODIS the exception of GPIO mode.
0 The output pin operates normally.
1 If the selected output disable input signal is asserted, the output pin goes to EDPOL for OPWFMB and
OPWMB modes and to the complement of EDPOL for other modes, but the unified channel continues to
operate normally, i.e., it continues to produce FLAG and matches. When the selected output disable input
signal is negated, the output pin operates normally.
2–3 Output Disable Select Bits. The ODISSL bits select an eMIOS channel flag to disable an output when the flag
ODISSL asserts.
00 11
01 10
10 9
11 8
4–5 Prescaler Bits. The UCPRE bits select the clock divider value for the internal prescaler of unified channel.
UCPRE
UCPRE Divide Ratio
00 1
01 2
10 3
11 4
6 Prescaler Enable Bit. The UCPREN bit enables the prescaler counter.
UCPREN 0 Prescaler disabled.
1 Prescaler enabled and the prescaler counter is loaded with UCCPRE value.
7 Direct Memory Access Bit. The DMA bit selects whether the FLAG generation is used as an interrupt or as a
DMA DMA request.
0 FLAG/overrun assigned to interrupt request.
1 FLAG/overrun assigned to DMA request.
8 Reserved
Field Description
9–12 Input Filter Bits. The IF bits control the programmable input filter, selecting the minimum input pulse width that
IF can pass through the filter. For output modes, these bits have no meaning.
0000 Bypassed2
0001 02
0010 04
0100 08
1000 16
13 Filter Clock Select Bit. The FCK bit selects the clock source for the programmable input filter.
FCK 0 Prescaled clock.
1 Main clock.
14 FLAG Enable Bit. The FEN bit allows the unified channel FLAG bit to generate an interrupt signal or a DMA
FEN request signal (the type of signal to be generated is defined by the DMA bit).
0 Disable (FLAG does not generate an interrupt or DMA request).
1 Enable (FLAG generates an interrupt or DMA request).
15–17 Reserved
18 Force Match A Bit. For output modes, the FORCMA bit is equivalent to a successful comparison on
FORCMA comparator A (except that the FLAG bit is not set). This bit is cleared by reset and is always read as 0. This
bit is valid for every output operation mode which uses comparator A, otherwise it has no effect.
0 Has no effect.
1 Force a match at comparator A.
For input modes, the FORCMA bit is not used and writing to it has no effect.
19 Force Match B Bit. For output modes, the FORCMB bit is equivalent to a successful comparison on
FORCMB comparator B (except that the FLAG bit is not set). This bit is cleared by reset and is always read as 0. This
bit is valid for every output operation mode which uses comparator B, otherwise it has no effect.
0 Has no effect.
1 Force a match at comparator B.
For input modes, the FORCMB bit is not used and writing to it has no effect.
20 Reserved
Field Description
21–22 Bus Select Bits. The BSL bits are used to select either one of the counter buses or the internal counter to be
BSL used by the unified channel.
10 Reserved
23 Edge Selection Bit. For input modes, the EDSEL bit selects if the internal counter is triggered by both edges
EDSEL of a pulse or by a single edge only as defined by the EDPOL bit. When not shown in the mode of operation
description, this bit has no effect.
0 Single edge triggering defined by the EDPOL bit.
1 Both edges triggering.
For GPIO in mode, the EDSEL bit selects if a FLAG can be generated.
0 A FLAG is generated as defined by the EDPOL bit.
1 No FLAG is generated.
For SAOC mode, the EDSEL bit selects the behavior of the output flip-flop at each match.
0 The EDPOL value is transferred to the output flip-flop.
1 The output flip-flop is toggled.
Field Description
24 Edge Polarity Bit. For input modes, the EDPOL bit asserts which edge triggers either the internal counter or
EDPOL an input capture or a FLAG. When not shown in the mode of operation description, this bit has no effect.
0 Trigger on a falling edge.
1 Trigger on a rising edge.
For QDEC (MODE[6] cleared), the EDPOL bit selects the count direction according to direction signal (UC[n]
input).
0 counts down when UC[n] is asserted
1 counts up when UC[n] is asserted
Note: UC[n-1] EDPOL bit selects which edge clocks the internal counter of UC[n]
0 Trigger on a falling edge
1 Trigger on a rising edge
For QDEC (MODE[6] set), the EDPOL bit selects the count direction according to the phase difference.
0 internal counter decrements if phase_A is ahead phase_B signal
1 internal counter increments if phase_A is ahead phase_B signal
Note: In order to operate properly, EDPOL bit must contain the same value in UC[n] and UC[n-1]
For output modes, the EDPOL bit is used to select the logic level on the output pin.
0 A match on comparator A clears the output flip-flop, while a match on comparator B sets it.
1 A match on comparator A sets the output flip-flop, while a match on comparator B clears it.
25–31 Mode Selection Bits. The MODE bits select the mode of operation of the unified channel, as shown in
MODE Table 18-9. Refer to Table 18-1 for more information on the different modes.
000_0110 DAOC Double Action Output compare (with FLAG set on B match)
000_0111 DAOC Double Action Output compare (with FLAG set on both match)
000_1100 QDEC Quadrature Decode (for count & direction encoders type)
000_1101 QDEC Quadrature Decode (for phase_A & phase_B encoders type)
000_1111 Reserved
001_0000 MC Modulus Counter (Up counter with clear on match start, internal clock)
001_0001 MC Modulus Counter (Up counter with clear on match start, external clock)
001_0010 MC Modulus Counter (Up counter with clear on match end, internal clock)
001_0011 MC Modulus Counter (Up counter with clear on match end, external clock)
001_0100 MC Modulus Counter (Up/Down counter with flag on A match, internal clock)
001_0101 MC Modulus Counter (Up/Down counter with flag on A match, external clock)
001_0110 MC Modulus Counter (Up/Down counter with flag on A match and cycle boundary,
internal clock)
001_0111 MC Modulus Counter (Up/Down counter with flag on A match and cycle boundary,
external clock)
001_1000 OPWFM Output Pulse Width and Frequency Modulation (flag on B match, immediate update)
001_1001 OPWFM Output Pulse Width and Frequency Modulation (flag on B match, next period update)
010_0000 OPWM Output Pulse Width Modulation (flag on B match, immediate update)
010_0001 OPWM Output Pulse Width Modulation (flag on B match, next period update)
010_0010 OPWM Output Pulse Width Modulation (flag on both matches, immediate update)
010_0011 OPWM Output Pulse Width Modulation (flag on both matches, next period update)
101_0000 MCB Modulus Counter Buffered (Up counter with clear on match start, internal clock)
101_0001 MCB Modulus Counter Buffered (Up counter with clear on match start, external clock)
101_0100 MCB Modulus Counter Buffered (Up/Down counter with flag on A match, internal clock)
101_0101 MCB Modulus Counter Buffered (Up/Down counter with flag on A match, external clock)
101_0110 MCB Modulus Counter Buffered (Up/Down counter with flag on A match and cycle boundary,
internal clock)
101_0111 MCB Modulus Counter Buffered (Up/Down counter with flag on A match and cycle boundary,
external clock)
101_1000 OPWFMB Output Pulse Width and Frequency Modulation Buffered, (flag on B match)
101_1001 Reserved
101_1010 OPWFMB Output Pulse Width and Frequency Modulation Buffered, (flag on both A and B matches)
101_1011 Reserved
110_0010 OPWMB Output Pulse Width Modulation Buffered (flag on both A and B matches)
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R OVFL 0 0 0 0 0 0 0 0 0 0 0 0 UCIN UCOUT FLAG
W w1c w1c
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 18-9. eMIOS200 Status Register (EMIOS_CSR[n])
Field Description
0 Overrun Bit. The OVR bit indicates that FLAG generation occurred when the FLAG bit was already set. This
OVR bit can be cleared by clearing the FLAG bit or by software writing a 1.
0 Overrun has not occurred.
1 Overrun has occurred.
1–15 Reserved
16 Overflow Bit. The OVFL bit indicates that an overflow has occurred in the internal counter. This bit must be
OVFL cleared by software writing a 1.
0 An overflow has not occurred.
1 An overflow has occurred.
17–28 Reserved
29 Unified Channel Input Pin Bit. The UCIN bit reflects the input pin state after being filtered and synchronized.
UCIN
30 Unified Channel Output. The UCOUT bit reflects the output pin state.
UCOUT
31 FLAG Bit. The FLAG bit is set when an input capture or a match event in the comparators occurred. This bit
FLAG must be cleared by software writing a 1.
0 FLAG cleared.
1 FLAG set event has occurred.
Note: emios_flag_out reflects the FLAG bit value. When the DMA bit is set, the FLAG bit can be cleared by
the DMA controller.
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R
ALTA[0:23]
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 18-10. eMIOS200 Alternate A Register (EMIOS_ALTA[n])
The EMIOS_ALTA[n] register provides an alternate read-only address to access A2 channel registers in
GPIO, PEC, WPTA modes. If the EMIOS_CADR[n] register is used with EMIOS_ALTA[n], both A1 and
A2 registers can be accessed in these modes.
When changing the MODE bits, the application software must go to GPIO mode first to reset the unified
channel’s internal functions properly. Failure to do this could lead to invalid and unexpected output
compare or input capture results or the FLAGs being set incorrectly.
In GPIO input mode (MODE = 000_0000), the FLAG generation is determined according to EDPOL and
EDSEL bits and the input pin status can be determined by reading the UCIN bit.
In GPIO output mode (MODE = 000_0001), the unified channel is used as a single output port pin and the
value of the EDPOL bit is permanently transferred to the output flip-flop.
Input Signal1
Selected
0x000500 0x001000 0x001100 0x001250 0x001525 0x0016A0
Counter Bus
FLAG Pin/Register
Input Signal1
Selected Counter Bus 0x001000 0x001001 0x001102 0x001103 0x001104 0x001105 0x001106 0x001107 0x001108
FLAG Pin/Register
FLAG Clear
EDSEL = 0 Update to
EDPOL = 1 A1 A1 Match A1 Match A1 Match
Output Flip-Flop
Selected
0x000500 0x001000 0x001100 0x001000 0x001100 0x001000
Counter Bus
FLAG Pin/Register
Notes: 1. EMIOS_CADR[n] = A2
A2 = A1 according to OU[n] bit
Figure 18-13. SAOC Example — EDPOL Value Being Transferred to the Output Flip-flop
EDSEL = 1 Update to
EDPOL = x A1 A1 Match A1 Match A1 Match
Output Flip-Flop
Selected
0x000500 0x001000 0x001100 0x001000 0x001100 0x001000
Counter Bus
FLAG Pin/Register
Note: 1. EMIOS_CADR[n] = A2
Figure 18-14. SAOC Example — Toggling the Output Flip-Flop
EDSEL = 1
EDPOL = x
Output Flip-Flop
Selected Counter Bus 0x000000 0x000001 0x000002 0x000003 0x000001 0x000002 0x000000 0x000001 0x000002
System Clock
A1 Match
FLAG Pin/Register
FLAG Clear
A2 Value1 0x000001
Note: 1. EMIOS_CADR[n] A2
Figure 18-15. SAOC Example with Flag Behavior
Input Signal1
Selected
0x000500 0x001000 0x001100 0x001250 0x001525 0x0016A0
Counter Bus
Figure 18-17 shows the A1 and B1 updates when EMIOS_CADR[n] and EMIOS_CBDR[n] register reads
occur. The A1 register has always coherent data related to the A2 register. When a EMIOS_CADR[n] read
is performed, the B1 register is loaded with the A1 register content. This guarantees that the data in register
B1 always has the coherent data related to the last EMIOS_CADR[n] read. The B1 register updates remain
Input Signal1
Selected
0x000500 0x001000 0x001100 0x001250 0x001525 0x0016A0
Counter Bus
Input signal1
3
B1 value $0xxxxxxx 0x001000 0x001250
Figure 18-19 shows the A1 and B1 register updates when EMIOS_CADR[n] and EMIOS_CBDR[n] read
operations are performed. When a EMIOS_CADR[n] read occurs, the contents of A1 are transferred to
B1, thus providing coherent data in the A2 and B1 registers. Transfers from B2 to B1 are then blocked until
EMIOS_CBDR[n] is read. After EMIOS_CBDR[n] is read, the contents of register A1 are transferred to
register B1 and the transfers from B2 to B1 are re-enabled to occur at the transfer edges, which is the
leading edge in the Figure 18-19 example.
EDPOL = 1 Read EMIOS_CADR[n] Read EMIOS_CBDR[n]
A A A
Input Signal1
Selected
0x000500 0x001000 0x001100 0x001250 0x001525 0x0016A0
Counter Bus
MODE[6] = 0
Update to
A1 & B1 A1 Match B1 Match A1 Match B1 Match
Output Flip-Flop
Selected
0x000500 0x001000 0x001100 0x001000 0x001100
Counter Bus
FLAG Pin/Register
A1 Value1 0xxxxxxx 0x001000 0x001000 0x001000
B1 Value2 0xxxxxxx 0x001100 0x001100 0x001100
Notes: 1. EMIOS_CADR[n] = A1
2. EMIOS_CBDR[n] = B1
A2 = A1 according to OU[n] bit
B2 = B1 according to OU[n] bit
Figure 18-20. DAOC with FLAG Set on the Second Match
MODE[6] = 1
Update to
A1 & B1 A1 Match B1 Match A1 Match B1 Match
Output Flip-Flop
Selected
0x000500 0x001000 0x001100 0x001000 0x001100
Counter Bus
FLAG Pin/Register
A1 Value1 0xxxxxxx 0x001000 0x001000 0x001000
B1 Value2 0xxxxxxx 0x001100 0x001100 0x001100
Notes: 1. EMIOS_CADR[n] = A1
2. EMIOS_CBDR[n] = B1
A2 = A1 according to OU[n] bit
B2 = B1 according to OU[n] bit
Figure 18-21. DAOC with FLAG Set on Both Matches
MODE[6] = 1
EDSEL = 1
EDPOL = x Write to A2 Write to A2 Write to A2
Write to B2 Write to B2 Write toB2
Output Flip-Flop
Selected Counter Bus 0x000000 0x000001 0x000002 0x000000 0x000001 0x000002 0x000000 0x000001 0x000002
System Clock
Enabled A1 Match
Enabled B1 Match
FLAG Pin/Register
FLAG Clear
OU1
A1 Value2 0xxxxxxx 0x000001 0x000001 0x000001
1. If B1 was not updated due to B2 to B1 transfer being disabled after reading register EMIOS_CADR[n], further
EMIOS_CADR[n] and EMIOS_CBDR[n] reads will not return coherent data until a new bus capture is triggered to registers A2
and B2. This capture event is indicated by the channel FLAG being asserted. If enabled, the FLAG also generates an interrupt.
In order to have coherent data in continuous operation mode, the following steps should be performed,
assuming the FLAG bit is initially cleared:
1. Wait for FLAG assertion.
2. Read the EMIOS_CADR[n] register.
3. Read the EMIOS_CBDR[n] register.
4. Clear the FLAG bit.
5. Return to step #1.
Accumulation cycles may be lost if the read is not performed in a timely manner. Whenever the Overrun
bit is asserted it means that one or more cycles have been lost.
Triggering of the counter clock (input event) is done by a rising or falling edge or both edges on the input
pin. The polarity of the triggering edge is selected by the EDSEL and EDPOL bits in EMIOS_CCR[n]
register.
For continuous mode operation (MODE[6] cleared, MODE[0:6] = 000_1000), the counter is cleared on
the next input event after a FLAG generation and continues to operate as previously described.
For single-shot operation (MODE[6] set, MODE[0:6] = 000_1001), the counter is not cleared or
incremented after a FLAG generation until a new writing operation to register A (EMIOS_CADR) is
performed.
Figure 18-23 and Figure 18-24 show how the unified channel can be used for continuous and single-shot
pulse/edge accumulation mode.
MODE[6] = 0
0xFFFFFF
0x001500
0x000000
FLAG Pin/Register Time
Selected Counter Bus 0x000090 0x000400 0x001000 0x007000
2
Input Signal Events A1 Events No Events A1 Events
A1 Value3 0xxxxxxx 0x001500 0x001500 0x001500
A2 Value4 0xxxxxxx 0x000400 0x007000
B1 Value 0xxxxxxx 0x000090 0x001000
B2 Value5 0xxxxxxx 0x000090 0x000400 0x001000 0x007000
MODE[6] = 1
Write to A1 A1 Match
1
EMIOS_CCNTR[n]
0xFFFFFF
0x001500
0x000000
FLAG Pin/Register Time
MODE[6] = 0 A1 & B1
Write
A1 Match B1 Match A1 Match B1 Match
EMIOS_CCNTR[n]
0x000000
Time
Flag Pin/Register
Notes: 1. EMIOS_CADR[n] = A1
2. EMIOS_CBDR[n] = B1
3. EMIOS_ALTA[n] = A2
Figure 18-25. PEC Continuous Mode Example
MODE[6] = 1 A1 & B1
Write
EMIOS_CCNTR[n] A1 Match B1 Match A1 Match B1 Match
0x000000
Time
Flag Pin/Register
Selected Counter Bus 0x000090 0x000303 0x000090 0x000303
A1 Value1
0x000090 0x000090 0x000090
B1 Value2 0x000303 0x000303 0x000303
A2 Value3 A2 EMIOS_CCNTR[n] A2 EMIOS_CCNTR[n]
Notes: 1. EMIOS_CADR[n] = A1
2. EMIOS_CBDR[n] = B1
3. EMIOS_ALTA[n] = A2
Figure 18-26. PEC Single-Shot Mode Example
EMIOS_CCNTR[n] inc/dec +1 +1 +1 +1 +1 +1 +1 +1 –1 –1 –1 –1 –1
Value 1
0x000000
Time
FLAG Pin/Register
Note: EMIOS_CADR[n] A1
Figure 18-27. QDEC Mode Example with Count & Direction Encoder
MODE[6] = 1
Phase A (from UC[n])
EMIOS_CCNTR[n] +1 +1 +1 +1 +1 +1 +1 +1 –1 –1 –1 –1 –1 –1 –1 +1 +1 +1 +1 +1 +1 +1 +1 –1 –1 –1 –1 –1 –1 –1 +1 +1 +1 +1 +1 +1 +1
inc/dec
A1 Write A1 Write
(Value 1) (Value 2)
EMIOS_CCNTR[n] A1 Match A1 Match A1 Match A1 Match A1 Match
Value 2
Value 1
0x000000
Time
FLAG Pin/Register
Note: EMIOS_CADR[n] = A1
Figure 18-28. QDEC Example with Phase_A & Phase_B Encoder
EDPOL = 1
A1 & B1 A1 & B1
Time Accumulator Write Write
A1 Match B1 Match A1 Match B1 Match
(EMIOS_CCNTR[n])
0xFFFFFF
0x000000
Time
Input Signal1
FLAG Pin/Register
Selected Counter Bus 0x000100 0x001500 0x003000 0x004200
2
A1 Value 0x000100 0x000100 0x003000 0x003000
B1 Value3 0x001500 0x001500 0x004200 0x004200
A2 Value4 A2 ¨ EMIOS_CCNTR[n] A2 ¨ EMIOS_CCNTR[n]
— When MODE[6] is set, the external clock is selected. In this case, the internal counter clears
when the match signal is asserted and the input event occurs. The channel FLAG bit is set at
the same time the counter is cleared. See Figure 18-59 and Figure 18-63.
— When MODE[6] is cleared, the internal clock source is selected. In this case, the internal
counter clears when the match signal is asserted and the prescaler tick occurs. The channel
FLAG bit is set at the same time the counter is cleared. See Figure 18-59 and Figure 18-63.
NOTE
If the internal clock source is selected and the prescaler of the internal
counter is set to 1, the MC mode behaves the same way even in Clear on
Match Start or Clear on Match End sub-modes.
When in up/down count mode (MODE = 001_01bb), a match between the internal counter and register A1
sets the FLAG and changes the counter direction from increment to decrement. A match between register
B1 and the internal counter changes the counter direction from decrement to increment and sets the FLAG
only if MODE[5] bit is set.
Only values other than 0x00_0000 must be written into register A (EMIOS_CADR). Loading 0x00_0000
leads to unpredictable results.
Updates on register A (EMIOS_CADR) or the counter in MC mode may cause a loss of match in the
current cycle if the transfer occurs near the match. In this case, the counter may roll over and resume
operation in the next cycle.
Figure 18-30 and Figure 18-31 show how the unified channel can be used as a modulus counter in up mode
and up/down mode, respectively.
MODE[4] = 0 Write Write
to A2 to A2
A1 Match A1 Match A1 A1 Match
EMIOS_CCNTR[n] Match
0xFFFFFF
0x000303
0x000200
0x000000
Time
FLAG pin/register
Notes: 1. EMIOS_CADR[n] = A1
A2 = A1 according to OU[n] bit
Figure 18-30. MC Up Mode Example
0x000303
0x000200
0x000000
Time
A1 Value1 0xxxxxxx 0x000303 0x000303 0x000200 0x000200 0x000200
FLAG Pin/Register
Notes: 1. EMIOS_CADR[n] = A1
A2 = A1 according to OU[n] bit
Figure 18-31. MC Up/Down Mode Example
boundary and therefore is used on cycle (n + 1). The cycle boundary between cycle (n) and cycle (n + 1)
is defined as the first system clock cycle of cycle (n + 1). The flags are generated as soon as the A1 match
occurs.
Prescaler Ratio = 1 Cycle n Cycle n + 1 Cycle n + 2
0x000007
0x000006
0x000005
0x000001
Time
FLAG Set Event
FLAG Pin/Register
FLAG Clear
Figure 18-33 shows the MCB in up/down counter mode. Register A1 is updated at the cycle boundary. If
A2 is written in cycle (n), this new value is used in cycle (n + 1) for an A1 match. When MODE[5] is
cleared, flags are generated only on an A1 match. If MODE[5] is set to 1, flags are also generated at the
cycle boundary.
Prescaler Ratio = 1 Cycle n Cycle n + 1 Cycle n + 2
A1 Match
A1 Match
Write to A2
EMIOS_CCNTR[n] Write to A2
0x000007
0x000006
0x000005
0x000001
Time
FLAG Set Event
FLAG Pin/Register
FLAG Clear
A2 Value 0x000005 0x000007
A1 Value 0x000006 0x000005 0x000007
Figure 18-34 shows the A1 register update process in up counter mode. The A1 load signal is generated at
the last system clock period of a counter cycle.
The A1 load signal is generated based on the detection of the internal counter reaching 0x00_0001 and has
the duration of one system clock cycle. During the load pulse, A1 still holds its previous value. It is updated
at the second system clock cycle only. Thus, A1 is updated with A2 value at the same time that the counter
(EMIOS_CCNTR[n]) is loaded with 0x00_0001. The load signal pulse has the duration of one system
clock period. If A2 is written within cycle (n), its value is available at A1 at the first clock of cycle (n + 1)
and the new value is used for match at cycle (n + 1). The update disable bits OU[n] of the EMIOS_OUDR
register can be used to control the update of this register, thus allowing the A1 register update to be delayed
for synchronization purposes.
Prescaler Ratio = 2 Cycle n Cycle n + 1 Cycle n + 2
A1 match A1 match A1 match
Internal Counter Write to A2 Write to A2
8
0x000008
6
0x000006
4
0x000004
0x000002 1
0x000001
Time
Counter = A1
A1 Load Signal
Figure 18-35 shows the A1 register update in up/down counter mode. Note that A2 can be written at any
time within cycle (n) in order to be used in cycle (n + 1). Thus A1 receives this new value at the next cycle
boundary. The update disable bits (OU[n] in EMIOS_OUDR) can be used to disable the update of A1
register.
Prescaler Ratio = 2 Cycle n Cycle n + 1 Cycle n + 2
A1 Match A1 Match
EMIOS_CCNTR[n] Write to A2 Write to A2
0x000006
0x000005
0x000001
Time
Selected Counter = 2
A1 Load Signal
MODE[6] = 0 B2
A2 & B2 Write
Write A1 Match B1 Match A1 Match B1 Match
EMIOS_CCNTR[n]
0x001000
0x000900
0x000200
0x000000
Time
Output Flip-Flop
Notes: 1. EMIOS_CADR[n] = A1
2. EMIOS_CBDR[n] = B2
A2 = A1according to OU[n] bit
B2 = B1according to OU[n] bit
MODE[6] = 1
A2 & B2 B2
Write A1 Match B1 Match A1 Match Write B1 Match A1 Match B1 Match
Internal Counter
0x001000
0x000900
0x000200
0x000000
Time
Output Flip-Flop
B2 Value 2
0x001000 0x000900
Notes: 1. EMIOS_CADR[n] = A1
2. EMIOS_CBDR[n] = B2
A2 = A1according to OU[n] bit
B2 = B1according to OU[n] bit
At OPWFMB mode entry, the output flip-flop is set to the value of the EDPOL bit in the EMIOS_CCR[n]
register.
To provide smooth and consistent channel operation, this mode differs substantially from the OPWFM
mode. The main differences reside in the A1 and B1 registers update, on the delay from the A1 match to
the output pin transition, and on the internal counter values, which range from 0x00_0001 up to the value
in register B1.
When entering OPWFMB mode (coming out of GPIO mode), if the internal counter value is not within
that range, then the B match will not occur, causing the channel internal counter to wrap at the maximum
counter value which is 0xFF_FFFF. After the counter wrap occurs, the value returns to 0x00_0001 and the
counter resumes normal OPWFMB mode operation. Thus in order to avoid the counter wrap condition,
make sure its initial value is within the range between 0x00_0001 and the B1 register value the OPWFMB
mode is entered.
When a match on comparator A occurs, the output register is set to the value of EDPOL. When a match
on comparator B occurs, the output register is set to the complement of EDPOL. B1 match also causes the
internal counter to transition to 0x00_0001, thus restarting the counter cycle.
Only values greater than 0x00_0001 are allowed to be written to the B1 register. Loading values other than
those leads to unpredictable results.
Figure 18-38 shows the operation of the OPWFMB mode regarding output pin transitions and A1/B1
registers match events. The output pin transition occurs when the A1 or B1 match signal is deasserted,
which is indicated by the A1 match negative edge detection signal. If register A1 is set to 0x00_0004, the
output pin transitions four counter periods after the cycle has started, plus one system clock cycle. In the
example shown in Figure 18-38 the internal counter prescaler has a ratio of two.
Prescaler Ratio = 2
EDPOL = 0
System Clock
Prescaler
8
EMIOS_CCNTR[n]
5
4
1
A1 Value 0x000004 A1 Match Time
Negative Edge
B1 Value 0x000008
Detection
A1 Match
B1 Match
B1 Match Negative Edge
Detection
B1 Match Negative Edge Detection
Output Pin
Figure 18-39 shows the generated output signal if A1 is set to 0x0. Because the counter does not reach 0
in this mode, the channel internal logic infers a match as if A1 = 0x00_0001 with the difference that in this
case, the positive edge of the match signal is used to trigger the output pin transition instead of the negative
edge used when A1 = 0x00_0001. An A1 positive edge match signal from cycle (n + 1) occurs at the same
time as B1 negative edge match signal from cycle (n). This allows using the A1 positive edge match to
mask the B1 negative edge match when they occur at the same time. The result is that no transition occurs
on the output flip-flop and a 0% duty cycle is generated.
Prescaler Ratio = 2 Write to A2
EDPOL = 0 Cycle n Cycle n + 1
System Clock
Prescaler
EMIOS_CCNTR
5
4
1 1
Time
A1 Value 0x000004 0x000000
A2 Value 0x000000 A1 Match
B1 Value 0x000008 Negative Edge
Detection
A1 Match
B1 Match
Figure 18-40 shows the timing for the A1 and B1 registers load. The A1 and B1 load use the same signal
which is generated at the last system clock period of a counter cycle. Thus, A1 and B1 are updated
respectively with A2 and B2 values at the same time that the EMIOS_CCNTR[n] counter is loaded with
0x00_0001. This event is defined as the cycle boundary. The load signal pulse has the duration of one
system clock period. If A2 and B2 are written within cycle (n), their values are loaded into A1 and B1,
respectively, at the first clock of cycle (n + 1) and the new values are used for matches at cycle (n + 1). The
update disable bits (OU[n] in EMIOS_OUDR) can be used to control the update of these registers, thus
allowing to delay the A1 and B1 registers update for synchronization purposes.
In Figure 18-40, it is assumed that both the channel and global prescalers are set to 0x00_0001 (each divide
ratio is two), meaning that the channel internal counter transitions at every four system clock cycles.
FLAGs can be generated only on B1 matches when MODE[5] is cleared, or on either A1 or B1 matches
when MODE[5] is set. Because the B1 FLAG occurs at the cycle boundary, this flag can be used to indicate
that A2 or B2 data written on cycle (n) were loaded to A1 or B1, respectively, thus generating matches in
cycle (n + 1). Note that the FLAG has a synchronous operation, meaning that it is asserted one system
clock cycle after the FLAG set event.
MODE[6] = 1 Cycle n Cycle (n + 1) Cycle (n + 2)
EDPOL = 0
Prescaler Ratio = 4 Match A1
Write to A2 Write to B2 Match B1
Internal Counter Match A1 Match B1 Write to A2 Match B1
0x000008
0x000006
0x000004
0x000002
0x000001
Time
Due to B1 Match
Cycle (n – 1)
Output Pin
FLAG Set Event
FLAG Pin/Register
FLAG Clear
Figure 18-41 shows the operation of the output disable feature in OPWFMB mode. In contrast to the
OPWFM mode, the output disable forces the channel output flip-flop to the value of the EDPOL bit. This
functionality targets applications that use active-high signals and a high-to-low transition at A1 match. In
this case, EDPOL should be set to 0. Note that both the channel and global prescalers are set to 0x00_0000
(each divide ratio is one), meaning that the channel internal counter transitions at every system clock cycle.
0x000008
0x000006
0x000004
0x000002
0x000001
Due to B1 Match Cycle (n – 1) Time
Output Pin
FLAG Pin/Register
Output Disable
A1 Value 0x000002 0x000004 0x000006
The output disable has a synchronous operation, meaning that the assertion of the output disable input pin
causes the channel output flip-flop to transition to EDPOL at the next system clock cycle. If the output
disable input is deasserted the output pin transition at the following A1 or B1 match.
In Figure 18-41 it is assumed that the output disable input is enabled and selected for the channel. Refer
to Section 18.3.2.7, “eMIOS200 Control Register (EMIOS_CCR[n])”, for a description of how the ODIS
and ODISSL bits enable and select the output disable inputs.
The FORCMA and FORCMB bits allow the software to force the output flip-flop to the level
corresponding to a match on comparators A or B, respectively. Similar to a B1 match, FORCMB sets the
internal counter to 0x00_0001. The FLAG bit is not set by the FORCMA or FORCMB bits being asserted.
Figure 18-42 shows the generation of 100% and 0% duty cycle signals. It is assumed EDPOL = 0 and the
resultant prescaler value is 1. Initially, A1 = 0x00_0008 and B1 = 0x00_0008. In this case, the B1 match
has precedence over the A1 match, thus the output flip-flop is set to the complement of EDPOL bit. This
cycle corresponds to a 100% duty cycle signal. The same output signal can be generated for any A1 value
greater or equal to B1.
EDPOL = 0
Prescaler = 1
EMIOS_CCNTR[n] Cycle 1 Cycle 2 Cycle 3 Cycle 4 Cycle 5 Cycle 6 Cycle 7 Cycle 8 Cycle 9
Time
Output Pin 100% 0%
A1 Value 0x000008 0x000007 0x000006 0x000005 0x000004 0x000003 0x000002 0x000001 0x000000
A2 Value 0x000007 0x000006 0x000005 0x000004 0x000003 0x000002 0x000001 0x000000
B1 Value 0x000008
Figure 18-42. OPWFMB Mode from 100% to 0% Duty Cycle
A 0% duty cycle signal is generated if A1 = 0x00_0000 as shown in cycle 9 in Figure 18-42. In this case,
the B1 = 0x00_0008 match from cycle 8 occurs at the same time as the A1 = 0x00_0000 match from cycle
9. Refer to Figure 18-39 for a description of the A1 and B1 match generation. In this case, the A1 match
has precedence over the B1 match and the output signal transitions to EDPOL.
18.4.1.1.15 Center Aligned Output Pulse Width Modulation with Dead Time (OPWMC)
Mode
The OPWMC mode generates a center aligned PWM with dead time insertion in the leading
(MODE = 001_11b1) or trailing edge (MODE = 001_11b0).
The selected counter bus must be running an up/down time base, as shown in Figure 18-31. BSL[1:0] bits
select the time base. Register A1 contains the ideal duty cycle for the PWM signal and is compared with
the selected time base. Register B1 contains the dead time value and is compared with the internal counter.
For a leading-edge dead time insertion, the output PWM duty cycle is equal to the difference between
register A1 and register B1, and for a trailing edge dead time insertion, the output PWM duty cycle is equal
to the sum of register A1 and register B1. Mode[6] bit selects between trailing and leading dead time
insertion.
NOTE
The internal counter may be running in the internal prescaler ratio, while
the selected time base may be running in a different prescaler ratio. The
output signal may produce an unexpected output if the dead time interval is
greater than the duty cycle of the PWM signal.
When OPWMC mode is entered, coming out from GPIO mode, the output flip-flop is set to the
complement of the EDPOL bit in the EMIOS_CCR[n] register.
When operating with leading edge dead time insertion, the first match between A1 and the selected time
base clears the internal counter and switches the selected time base to the internal counter. When a match
occurs between register B1 and the selected time base, the output flip-flop is set to the value of the EDPOL
bit and the time base is switched to the selected counter bus. In the next match between register A1 and
the selected time base, the output flip-flop is set to the complement of the EDPOL bit. This sequence
repeats continuously.
When operating with trailing edge dead time insertion, the first match between A1 and the selected time
base sets the output flip-flop to the value of the EDPOL bit. In the next match between register A1 and the
selected time base, the internal counter is cleared and the selected time base is switched to the internal
counter. When a match occurs between register B1 and the selected time base, the output flip-flop is set to
the complement of the EDPOL bit and the time base is switched to the selected counter bus. This sequence
repeats continuously.
FLAG can be generated in the trailing edge of the output PWM signal when MODE[5] is cleared, or in
both edges, when MODE[5] is set.
At any time, the FORCMA or FORCMB bits are equivalent to a successful comparison on comparator A
or B with the exception that the FLAG bit is not set.
NOTE
When in freeze state, the FORCMA or FORCMB bits only allow the
software to force the output flip-flop to the level corresponding of a match
on A or B respectively.
If subsequent matches occur on comparators A and B, the PWM pulses continue to be generated,
regardless of the state of the FLAG bit.
In order to achieve a duty cycle of 100%, both registers A1 and B1 must be set to the same value. When a
simultaneous match occurs between the selected time base and registers A1 and B1, the output flip-flop is
set to the value of EDPOL bit and the selected time base switches to the selected counter bus, allowing a
new cycle to begin at any time, as previously described. 0% duty cycle is possible by writing 0x00_0000
to register A (EMIOS_CADR). When a match occurs, the output flip-flop is set to the complement of
EDPOL bit and the selected time base switches to the selected counter bus, allowing a new cycle to begin
at any time, as previously described. In both cases, FLAG is generated regardless of the MODE[6] bit.
NOTE
If A1 and B1 are set to 0x00_0000, a 0% duty cycle waveform is produced.
Figure 18-43 and Figure 18-44 show the unified channel running in OPWMC with leading and trailing
dead time, respectively.
MODE[0] = 1
Update A1
Match A1 Match A1 Update A1 Match A1 Match A1
Selected Counter Bus
0x000303
0x000200
0x000000
Time
A1 Value1 0xxxxxxx 0x000303 0x000303 0x000303 0x000200 0x000200 0x000200
Match B1 Match B1
Internal Counter Update B1
0x000010
0x000000
Time
B1 Value2 0x000010
Output Flip-Flop
Notes: 1. EMIOS_CADR[n] = A1
2. EMIOS_CBDR[n] = B1
A2 = A1 according to OU[n] bit
B2 = B1 according to OU[n] bit
MODE[0] = 1
Update A1
Match A1 Match A1 Update A1 Match A1 Match A1
Selected Counter Bus
0x000303
0x000200
0x000000
Time
A1 Value1 0xxxxxxx 0x000303 0x000303 0x000303 0x000200 0x000200 0x000200
0x000010
0x000000
Time
B1 Value2 0x000010
Output Flip-Flop
Notes: 1. EMIOS_CADR[n] = A1
2. EMIOS_CBDR[n] = B1
A2 = A1 according to OU[n] bit
B2 = B1 according to OU[n] bit
Figure 18-44. OPWMC with Trailing Dead Time Insertion
18.4.1.1.16 Center-Aligned Output PWM Buffered with Dead Time (OPWMCB) Mode
The OPWMCB mode generates a center-aligned PWM with dead time insertion to the leading or trailing
edge. A1 and B1 registers are double-buffered to allow smooth output signal generation when changing
A2 or B2 registers values on the fly.
The BSL bits select the time base. The time base selected for a channel configured to OPWMCB mode
should be a channel configured to MCB Up/Down mode, as shown in Figure 18-33. It is recommended to
start the MCB channel time base after the OPWMCB mode is entered in order to avoid missing A matches
at the very first duty cycle.
Register A1 contains the ideal duty cycle for the PWM signal and is compared with the selected time base.
Register B1 contains the dead time value and is compared against the internal counter. For a leading edge
dead time insertion, the output PWM duty cycle is equal to the difference between register A1 and register
B1. For a trailing edge dead time insertion, the output PWM duty cycle is equal to the sum of register A1
and register B1. Mode[6] selects between trailing and leading dead time insertion.
NOTE
The internal counter runs in the internal prescaler ratio, while the selected
time base may be running in a different prescaler ratio.
When OPWMCB mode is entered (coming out of GPIO mode), the output flip-flop is set to the
complement of the EDPOL bit in the EMIOS_CCR[n] register.
The following basic steps summarize proper OPWMCB startup, assuming the channels are initially in
GPIO mode:
1. [global] Disable Global Prescaler.
2. [MCB channel] Disable Channel Prescaler.
3. [MCB channel] Write $1 at internal counter.
4. [MCB channel] Set A register.
5. [MCB channel] Set channel to MCB Up mode.
6. [MCB channel] Set prescaler ratio.
7. [MCB channel] Enable Channel Prescaler.
8. [OPWMCB channel] Disable Channel Prescaler.
9. [OPWMCB channel] Set A register.
10. [OPWMCB channel] Set B register.
11. [OPWMCB channel] Select time base input through BSL[1:0] bits.
12. [OPWMCB channel] Enter OPWMCB mode.
13. [OPWMCB channel] Set prescaler ratio.
14. [OPWMCB channel] Enable Channel Prescaler.
15. [global] Enable Global Prescaler.
Figure 18-45 shows the load of A1 and B1 registers, which occurs when the selected counter bus
transitions from 0x00_0002 to 0x00_0001. This event defines the cycle boundary. Values written to A2 or
B2 within cycle (n) are loaded into A1 or B1 registers, respectively, and used to generate matches in cycle
(n + 1).
Prescaler Ratio = 2 Cycle n Cycle (n + 1) Cycle (n + 2)
0x000006
0x000005
0x000001
Time
Selected Counter = 2
The (OU[n] in EMIOS_OUDR) bit can be used to disable the A1 and B1 updates, thus allowing to
synchronize the load on these registers with the load of A1 or B1 registers in others channels. Using the
update disable bit, A1 and B1 registers can be updated at the same counter cycle, allowing both registers
to change at the same time.
In this mode A1 matches always sets the internal counter to 0x00_0001. When operating with leading edge
dead time insertion the first A1 match sets the internal counter to 0x00_0001. When a match occurs
between register B1 and the internal time base, the output flip-flop is set to the value of the EDPOL bit. In
the following match between register A1 and the selected time base, the output flip-flop is set to the
complement of the EDPOL bit. This sequence repeats continuously. The internal counter should not reach
0x00_0000 as consequence of a rollover. To avoid this, the user must not write a value greater than twice
the difference between external count up limit and EMIOS_CADR[n] value to the EMIOS_CBDR[n]
register.
Figure 18-46 shows two cycles of a center-aligned PWM signal. Both A1 and B1 register values are
changing within the same cycle, which allows to vary at the same time the duty cycle and dead time values.
EDPOL = 1 Write to A2
Selected Write to B2
Counter Bus
0x000020
0x000015
0x000013
0x000001
Time
A1 Value 0x000015 0x000013
Internal
Time Base
Internal Counter is
Set to 0x00_0001 on A1 Match
0x000004
0x000002
0x000001
Time
Dead Time Dead Time
Output Flip-Flop
FLAG Pin/Register
When operating with trailing edge dead time insertion, the first match between A1 and the selected time
base sets the output flip-flop to the value of the EDPOL bit and sets the internal counter to 0x00_0001. In
the second match between register A1 and the selected time base, the internal counter is set to 0x00_0001
and B1 matches are enabled. When the match between register B1 and the selected time base occurs, the
output flip-flop is set to the complement of the EDPOL bit. This sequence repeats continuously.
EDPOL = 1
Write to A2
Selected Write to B2
Counter Bus
0x000020
0x000015
0x000013
0x000001
Time
A1 Value 0x000015 0x000013
Internal
Time Base
Internal Counter is
Set to 1 on A1 Match
0x000004
0x000002
0x000001
Time
Dead Time Dead Time
Output Flip-Flop
FLAG Pin/Register
FLAG can be generated in the trailing edge of the output PWM signal when MODE[5] is cleared, or in
both edges when MODE[5] is set. If subsequent matches occur on comparators A and B, the PWM pulses
continue to be generated regardless of the state of the FLAG bit.
NOTE
In OPWMCB mode, FORCMA and FORCMB do not have the same
behavior as a regular match. Instead they force the output flip-flop to
constant value, which depends on the selected dead time insertion mode,
leading or trailing, and the value of the EDPOL bit.
FORCMA has different behaviors depending on the selected dead time insertion mode, leading or trail. In
leading dead time insertion, FORCMA forces a transition in the output flip-flop to the opposite of the
EDPOL bit. In trailing dead time insertion, the output flip-flop is forced to the value of the EDPOL bit.
If the FORCMB bit is set, the output flip-flop value depends on the selected dead time insertion mode. In
leading dead time insertion, FORCMB forces the output flip-flop to transition to the EDPOL bit value. In
trailing dead time insertion the output flip-flop is forced to the opposite of the EDPOL bit value.
NOTE
The FORCMA bit set does not set the internal time-base to 0x00_0001 as a
regular A1 match.
The FLAG bit is not set either in case of FORCMA or FORCMB, even if both forces are issued at the same
time.
NOTE
FORCMA and FORCMB have the same behavior even in freeze or normal
mode regarding the output pin transition.
When FORCMA is issued along with FORCMB, the output flip-flop is set to the opposite of the EDPOL
bit value. This is the equivalent of saying that FORCMA has precedence over FORCMB when leading
dead time insertion is selected, and FORCMB has precedence over FORCMA when trailing dead time
insertion is selected.
Duty cycles from 0% to 100% can be generated by setting appropriate values to the A1 and B1 registers
relative to the period of the external time base. Setting A1 = 0x00_0001 generates a 100% duty cycle
waveform. If A1 is greater than the maximum value of the selected counter bus period, then a 0% duty
cycle is produced. Assuming EDPOL is set to 1 in OPWMCB mode with trailing dead time insertion,
100% duty cycle signals can be generated if B1 occurs at or after the cycle boundary (external counter = 1).
If A1 is greater than the maximum value of the selected counter bus period, then a 0% duty cycle is
produced, only if the pin starts the current cycle in the opposite of the EDPOL value. In case of 100% duty
cycle, the transition from EDPOL to the opposite of EDPOL may be obtained by forcing the pin using
FORCMA and/or FORCMB.
NOTE
If A1 is set to 0x00_0001 at OPWMCB entry the 100% duty cycle may not
be obtained in the very first PWM cycle due to the pin condition at mode
entry.
Only values different than 0x0 are allowed to be written to A1 register. If 0x00_0000 is loaded to A1, the
results are unpredictable.
NOTE
A special case occurs when A1 is set to (external counter bus period)/2,
which is the maximum value of the external counter. In this case, the output
flip-flop is constantly set to the EDPOL bit value.
The internal channel logic prevents matches from one cycle to propagate to the next cycle. In trailing dead
time insertion, a B1 match from cycle (n) could eventually cross the cycle boundary and occur in cycle
(n + 1). In this case, the B1 match is masked out and does not cause the output flip-flop to transition.
Therefore, matches in cycle (n + 1) are not affected by the late B1 matches from cycle (n).
Figure 18-48 shows a 100% duty cycle output signal generated by setting A1 = 4 and B1 = 3. In this case
the trailing edge is positioned at the boundary of cycle n + 1, which is actually considered to belong to
cycle n + 2 and therefore does not cause the output flip-flip to transition.
0x000001
A1 Value 0x000015 0x000004 Time
A2 Value 0x000015 0x000004
B1 Value 0x000003
B2 Value 0x000003
0x000003
0x000001
Dead Time Time
Dead Time Dead Time
Output Flip-Flop
The output disable feature, if enabled, causes the output flip-flop to transition to the EDPOL inverted state.
This feature allows an application to force the channel output pin to a “safe” state. The internal channel
matches continue to occur even in this case, thus generating flags. As soon as the output disable is
deasserted, the channel output pin is again controlled by the A1 and B1 matches. This process is
synchronous, meaning that the output channel pin transitions on system clock edges only.
It is important to notice that, as in OPWMB and OPWFMB modes, the match signal used to set or clear
the channel output flip-flop is generated on the deassertion of the channel combinational comparator
output signal, which compares the selected time base with A1 or B1 register values. Refer to Figure 18-38,
which shows the delay from matches to output flip-flop transition in OPWFMB mode. The operation of
OPWMCB mode is similar to OPWFMB regarding matches and output pin transition.
At any time, the FORCMA and FORCMB bits allow the software to force the output flip-flop to the level
corresponding to a match on A or B respectively. Note that FLAG bit is not set by the FORCMA and
FORCMB operations.
If subsequent matches occur on comparators A and B, the PWM pulses continue to be generated,
regardless of the state of the FLAG bit.
At OPWM mode entry, the output flip-flop is set to the complement of the EDPOL bit in the
EMIOS_CCR[n] register.
In order to achieve 100% duty cycle, both registers A1 and B1 must be set to the same value. When a
simultaneous match on comparators A and B occur, the output flip-flop is set at every period to the value
of EDPOL bit. 0% duty cycle is possible by writing 0x0 to register A (EMIOS_CADR). When a match
occurs, the output flip-flop is set at every period to the complement of EDPOL bit. The transfer from
register B2 to B1 is still controlled by MODE[6] bit.
NOTE
If A1 and B1 are set to 0x00_0000, a 0% duty cycle waveform is produced.
Figure 18-49 and Figure 18-50 show the unified channel running in OPWM with immediate update and
next period update, respectively.
MODE[6] = 0 Update to B2 Update to
A1 Write A1
0x000000
Time
Output Flip-Flop
A1 Value1 0xxxxxxx 0x000200 0x000900 0x000900
B1 Value 0xxxxxxx 0x001000 0x001000 0x001000
Notes: 1. EMIOS_CADR[n] = A1
2. EMIOS_CBDR[n] = B2
A2 = A1 according to OU[n] bit
B2 = B1 according to OU[n] bit
Figure 18-49. OPWM with Immediate Update
0x000200
0x000000
Time
Output Flip-Flop
Notes: 1. EMIOS_CADR[n] = A1
2. EMIOS_CBDR[n] = B2
A2 = A1 and A2 = A1 according to OU[n] bit
• Any value written to A2 or B2 on cycle(n) is loaded to A1 and B1 registers at the following cycle
boundary (assuming (OU[n] in EMIOS_OUDR) is not asserted). The new values are used for A1
and B1 matches in cycle(n + 1)
Figure 18-51 shows the operation of the OPWMB mode regarding A1 and B1 matches and the transition
of the channel output pin. In this example, EDPOL is set to 0.
EDPOL = 0 Cycle n Cycle (n + 1)
Write to A2
Clock
Prescaler
8
Selected 6 6
Counter Bus
4
1 1
Time
A1 Value 0x000004 0x000000
A2 Value 0x000000
B1 Value 0x000006
A1 Match
A1 Match Positive A1 Match Positive Edge Detection
Edge Detection
A1 Match Negative Edge
A1 Match Negative
Detection
Edge Detection
B1 Match
B1 Match Negative Edge
B1 Match Negative
Detection
Edge Detection
Output Pin
The output pin transitions are based on the negative edges of the A1 and B1 match signals. Figure 18-51
shows in cycle(n + 1) the value of the A1 register being set to 0. In this case, the match positive edge is
used instead of the negative edge to transition the output flip-flop.
Figure 18-52 shows the channel operation for 0% duty cycle. Note that the A1 match positive edge signal
occurs at the same time as the B1 = 0x00_0008 negative edge signal. In this case A1 match has precedence
over B1 match, causing the output pin to remain at EDPOL bit value, thus generating a 0% duty cycle
signal.
Clock
Prescaler
8 8
Selected
Counter Bus
4
1 1
Time
A1 Value 0x000004 0x000000
A2 Value 0x000000
B1 Value 0x000008
A1 Match
A1 Match Positive A1 Match Positive Edge Detection
Edge Detection
A1 Match Negative Edge
A1 Match Negative
Detection
Edge Detection
B1 Match
B1 Match Negative
A1 Match Negative Edge Detection
Edge Detection
Output Pin
EDPOL = 0
FLAG Pin/Register
Figure 18-53 shows the operation of the OPWMB mode with the output disable signal asserted. The output
disable forces a transition in the output pin to the EDPOL bit value. After deassertion, the output disable
allows the output pin to transition at the following A1 or B1 match. The output disable does not modify
the flag bit behavior. There is a delay of one system clock between the assertion of the output disable signal
and the transition of the output pin to EDPOL.
Output Disable
Figure 18-54 shows a waveform changing from 100% to 0% duty cycle. In this case, EDPOL is 0. In this
example, B1 is programmed to the same value as the period of the external selected time base.
EDPOL = 0
Prescaler = 1
Selected Cycle 1 Cycle 2 Cycle 3 Cycle 4 Cycle 5 Cycle 6 Cycle 7 Cycle 8 Cycle 9
Counter Bus
Time
Output Pin 100% 0%
A1 Value 0x000008 0x000007 0x000006 0x000005 0x000004 0x000003 0x000002 0x000001 0x000000
A2 Value 0x000007 0x000006 0x000005 0x000004 0x000003 0x000002 0x000001 0x000000
B1 Value 0x000008
Figure 18-54. OPWMB Mode from 100% to 0% Duty Cycle
In Figure 18-54, if B1 is set to a value lower than 0x00_0008, it is not possible to achieve 0% duty cycle
by changing only the A1 register value. Because B1 matches have precedence over A1 matches, the output
pin transitions to the opposite of EDPOL bit at B1 match. If B1 is set to 0x00_0009, for instance, B1 match
does not occur, thus a 0% duty cycle signal is generated.
FCK
The input signal is synchronized by system clock. When a state change occurs in this signal, the 5-bit
counter starts counting up. As long as the new state is stable on the pin, the counter remains incrementing.
If a counter overflow occurs, the new pin value is validated. In this case, it is transmitted as a pulse edge
to the edge detector. If the opposite edge appears on the pin before validation (overflow), the counter is
reset. At the next pin transition, the counter starts counting again. Any pulse that is shorter than a full range
of the masked counter is regarded as a glitch and it is not passed on to the edge detector. Figure 18-56
shows a timing diagram of the input filter.
Selected Clock
EMIOSI
5-bit Counter
Filter Out
The filter is not disabled during either freeze state or negated GTBE input.
In order to ensure safe working and avoid glitches the following steps must be performed whenever any
update in the prescaling rate is desired:
1. Write 0 at both GPREN bit in EMIOSMCR register and UCPREN bit in EMIOS_CCR[n] register,
thus disabling prescalers;
2. Write the desired value for prescaling rate at UCPRE[] bits in EMIOS_CCR[n] register;
3. Enable channel prescaler by writing 1 at UCPREN bit in EMIOS_CCR[n] register;
4. Enable global prescaler by writing 1 at GPREN bit in EMIOSMCR register.
The prescaler is not disabled during either freeze state or negated GTBE input.
The device’s STAC server identification assignment is shown in Table 18-11. The time slot assignment is
fixed, so only time bases running at system clock divided by four or slower can be integrally exported. The
STAC client submodule runs with the system clock, and its time slot timing is synchronized with the eTPU
timing on reset. The time slot sequence is 0-1-2-3, such that they alternate between engines one and two.
Table 18-11. STAC Client Submodule Server Slot Assignment
1 TCR1 0
1 TCR2 2
2 TCR1 1
2 TCR2 3
Figure 18-57 provides a block diagram for the STAC client submodule.
EMIOS_MCR[SRV] bits select the time slot of the STAC output bus. Figure 18-58 shows a timing
diagram for the STAC client submodule.
System clock
STAC bus TS[00] TS[01] TS[02] TS[03] TS[00] TS[03] TS[00] TS[01] TS[02]
(submodule input)
STAC bus (REDC input) TS[00] TS[01] TS[02] TSn1 TS[00] TS[01] TS[02]
Every time the selected time slot changes, the STAC client submodule output is updated.
18.5 Reset
The eMIOS200 is reset by the global asynchronous system reset signal.
The MDIS bit in the EMIOS_MCR register is cleared during reset.
On resetting the eMIOS200 all unified channels enter GPIO input mode.
18.6 Interrupts
The eMIOS200 can generate one interrupt per channel. An interrupt request is generated according to the
configuration of the channel and input events or matches. See Chapter 27, “Interrupts and Interrupt
Controller (INTC)”, for details on the eMIOS200 interrupt vectors.
18.7.1 Considerations
Before changing an operating mode, the unified channel must be programmed to GPIO mode and
EMIOS_CADR[n] and EMIOS_CBDR[n] registers must be updated with the correct values for the next
operating mode. Then the EMIOS_CCR[n] register can be written with the new operating mode. If a
unified channel is changed from one mode to another without performing this procedure, the first operation
cycle of the selected time base can be random, i.e., matches can occur in random time if the contents of
EMIOS_CADR[n] or EMIOS_CBDR[n] were not updated with the correct value before the time base
matches the previous contents of EMIOS_CADR[n] or EMIOS_CBDR[n].
When interrupts are enabled, the software must clear the FLAG bits before exiting the interrupt service
routine.
Clock
Prescaled Clock = 1
See Note
Internal Counter 1 2 3 0 1 2 3 0 1 2 3 0 1 2 3 0 1 2 3 0 1 2 3
Match Value = 3
Note: When a match occurs, the first clock cycle is used to clear the internal counter,
starting another period.
Figure 18-59. Time Base Period when Running in the Fastest Prescaler Ratio
If the prescaler ratio is greater than one or external clock is selected, the counter may behave in three
different ways depending on the channel mode:
• If MC mode and Clear on Match Start and External Clock source are selected the internal counter
behaves as described in Figure 18-61.
• If MC mode and Clear on Match Start and Internal Clock source are selected the internal counter
behaves as described in Figure 18-62.
• If MC mode and Clear on Match End are selected the internal counter behaves as described in
Figure 18-63.
• If OPWFM mode is selected the internal counter behaves as described in Figure 18-62. The
internal counter clears at the start of the match signal, skips the next prescaled clock edge and then
increments in the subsequent prescaled clock edge.
NOTE
MCB and OPWFMB modes have a different behavior.
Clock
Prescaled Clock
Internal Counter 1 2 3 0 0 1 2 3 0 0
See Note
Match Value = 3
Note: When a match occurs, the first clock cycle is used to clear the internal counter, and only
after a second edge of prescaled clock the counter will start counting.
Figure 18-60. Time Base Period when Running with a Prescaler Ratio Greater Than 1
System Clock
Input Event
Internal Counter 1 2 3 0 1 2 3 0 1 2
See Note
Match Value = 3
FLAG Set Event
FLAG Pin/Register
FLAG Clear
Note: When a match occurs, the first system clock cycle is used to clear the internal counter, and at the next edge
of prescaler clock enable the counter will start counting.
Figure 18-61. Time Base Generation with External Clock and Clear on Match Start
Internal Counter 1 2 3 0 0 1 2 3 0 0
See Note
Match Value = 3
FLAG Set Event
FLAG Pin/Register
FLAG Clear
Note: When a match occurs, the first clock cycle is used to clear the internal counter,
and only after a second edge of prescaled clock the counter will start counting.
Figure 18-62. Time Base Generation with Internal Clock and Clear on Match Start
System Clock
Input Event/
Prescaler Clock Enable
Internal Counter 1 2 3 0 1 2 3 0
See Note
Match Value = 3
FLAG Set Event
FLAG Pin/Register
FLAG Clear
Note: The match occurs only when the input event/prescaler clock enable is active.
Then, the internal counter is immediately cleared.
Figure 18-63. Time Base Generation with Clear on Match End
19.1 Overview
The Enhanced Queued Analog-to-Digital Converter (EQADC) module provides fast and accurate
conversions for a wide range of applications. There are two EQADC modules on the MPC5676R,
EQADC_A and EQADC_B. Each EQADC module provides a parallel interface to two on-chip,
independent analog-to-digital converter cores. Each EQADC module has a hardware interface to the
twelve decimation filter blocks on the MPC5676R. This allows transferring of conversion and filtered
values to and from the EQADC and decimation filters without CPU or DMA interaction. Each EQADC
module has 24 dedicated external analog input pins, and 16 pins are shared by each module.
The EQADC transfers commands from multiple Command FIFOs (CFIFOs) to the on-chip ADCs. The
multiple Result FIFOs (RFIFOs) can receive data from the on-chip ADCs or from an on-chip DSP module
(decimation filters). Data from the on-chip ADCs can be routed to the side interface, processed by the
decimation filters and then routed back through the side interface to the RFIFOs. The EQADC supports
software and external hardware triggers (via package pins) from other blocks (eTPU and eMIOS) to
initiate transfers of commands from the CFIFOs to the on-chip ADCs. It also monitors the fill level of the
CFIFOs and RFIFOs, and accordingly generates DMA or interrupt requests to control data movement
between the FIFOs and the system memory.
SIU eMIOS
PIT/RTI
ETRIG0
ETRIG1
VDDA_AN_A eTPU
VDDA_DIG_A
VSSA_AN_A
VSSA_DIG_A
VRH_A
VRL_A time
REFBYPCA base
REFBYPCA1
External Trigger
24
eQADC_A
ANA0 conversion commands
CQueue y
ADC0 CFIFOx
ANA23
results
RQueue y
Temp Sensor
Absolute Ref RFIFOx
ADC1
16 STAC Bus
Interface
Parallel Side DMA SYSTEM
AN24 Interface
or
CPU RAM
AN39
eQADC_B
CQueue y
ADC0 CFIFOx
RQueue y
ANB0
RFIFOx
ADC1
16 STAC Bus 24
ANB23 Interface
Parallel Side
Interface
VDDA_AN_B
VDDA_DIG_B
VSSA_AN_B
VSSA_DIG_B Decimation Filter
VRH_B
VRL_B (12)
REFBYPCB
REFBYPCB1
Figure 19-1. Analog to Digital Conversion Sub-system
Priority
Abort
CQueue y
MUX
AN7/DAN3- Cont
AN8/ANW ADC0
AN9/ANX/TBIAS 32 bits
AN10/ANY
AN11/ANZ
Result
AN12/T50PVREF RFIFOx
Decoder
Format
AN13/T25PVREF REF BIAS and
GEN GEN Calibra- RQueue y
AN14/T75PVREF tion
AN15
AN16/ANR 16 bits
AN17/ANS CBuffer1
AN18/ANT
MUX
VDDA
VSSA
VRH EQADC
Parallel Side Interface
VRL (EQADC PSI)
NOTE: x=0, 1, 2, 3, 4, 5
On-Chip y=0, 1, 2, 3, ...
Digital Signal Processor
(Decimation Filter)
Component Function
Figure 19-2 also depicts data flow through the EQADC. Commands are contained in system memory in a
user defined data structure. The most likely data structure to be used is a queue (as shown in Figure 19-21).
Command data is moved from the command queue (CQueue) to the CFIFOs by either the host CPU or by
the system DMA controller. Once a CFIFO is triggered and becomes the highest priority CFIFO using a
certain CBuffer, command data is transferred from the CFIFO to the on-chip ADCs. The ADC executes
the command, and the result is moved through the Result Format and Calibration Sub-Block to either the
side interface or to the RFIFO. Data from the on-chip companion module (decimation filter) bypasses the
Result Format and Calibration Sub-Block and is moved directly to its specified RFIFO. When data is
stored in an RFIFO, data is moved from the RFIFO by the host CPU or by the system DMA controller to
a data structure in system memory as a result queue (RQueue).
If you are familiar with the QADC, the EQADC system upgrades the functionality provided by that block.
Refer to Section 19.8.7, “EQADC Versus QADC,” for a comparison between the EQADC and QADC.
1. Command and result data can be stored in system memory in any user defined data structure. However, in this document
it will be assumed that the data structure of choice is a queue, since it is the most likely data structure to be used and
because queues are the only type of data structure supported by the DMAC.
19.2.1 Features
Each EQADC block includes these distinctive features (except where noted):
• Two independent on-chip RSD Cyclic ADCs
— 8, 10, and 12 bits AD Resolution
— Differential conversions
— Differential channels include variable gain amplifier for improved dynamic range (x1; x2; x4)
— Differential channels include programmable pull-up and pull-down resistors for biasing and
sensor diagnostics (200k ohms; 100k ohms; 5k ohms)
— Sample times of 2 (default), 8, 64 or 128 ADC clock cycles
— Each conversion result can be marked with an imported timestamp from the eTPU, or an
independent timestamp
— Parallel interface to EQADC CFIFOs and RFIFOs
— Supports both right-justified unsigned and signed formats for conversion results
— Two REFBYPC pins for each EQADC module: REFBYPC25 and REFBYPC75
— Temperature sensor (available only to the primary ADC pair (eQADC_A’s ADC0 and ADC1)
— Ability to directly measure Vdd
• Automatic application of ADC calibration constants
• Parallel Side Interface allows eQADC_B to route conversion results without CPU intervention to
the Decimation Filter block for signal processing
• Priority Based CFIFOs
— Supports six CFIFOs with fixed priority. The lower the CFIFO number, the higher its priority.
When commands of distinct CFIFOs are bound for the same CBuffer, the higher priority
CFIFO is always served first.
— Immediate conversion command feature with conversion abort control
— Streaming mode operation of CFIFO0 to execute defined commands multiple times
— Supports software and several hardware trigger modes to arm a particular CFIFO
— Generates interrupt when command coherency is not achieved
• External (to the eQADC) Hardware Triggers
— Supports rising edge, falling edge, high level and low level triggers
— Supports configurable digital filter
— Supports controls to bypass the trigger digital filters (refer to the SIU chapter)
• Two Triggers operation mode for queue0
— Additional internal trigger (not filtered) called Advance trigger that is used to enable the
external trigger of queue0 and to control the loop behavior of CFIFO0 (only available on
EQADC_B)
• Supports 4 to 8 external 8-to-1 muxes which can expand the input channel number from 40 to 96
scheme is implemented to write-protect registers during debug mode. DMA and interrupt requests
continue to be generated as in Normal Mode.
If at the time the debug mode entry request is detected, there are commands in the on-chip CBuffers that
were already under execution, these commands will be completed but the generated results, if any, will not
be sent to the RFIFOs until debug mode is exited. Commands whose execution has not started will not be
executed until debug mode is exited.The clock associated with an on-chip ADC stops, during its low phase,
after the ADC ceases executing commands. The time base counter will only stop after all on-chip ADCs
cease executing commands.
When exiting debug mode, the EQADC relies on the CFIFO operation modes and on the CFIFO status to
determine the next command entry to transfer.
The EQADC’s internal behavior after the debug mode entry request is detected differs depending on the
status of command transfers.
• No command transfer is in progress.
The EQADC immediately halts future command transfers from any CFIFO.
• Command transfer is in progress.
EQADC will complete the transfer and update CFIFO status before halting future command
transfers from any CFIFO. Command transfers to the internal CBuffers are considered completed
when a command is written to the buffers.
EQADC will complete the transfer and update CFIFO status before halting future command
transfers from any CFIFO. Command transfers to the internal CBuffers are considered completed
when a command is written to the buffers.
19.4.1 Overview
The following is a list of external pins (applies to both EQADC_A and EQADC_B).
NOTE
At chip integration level, some of the digital and analog signals listed here
might share pins or not be available external to the chip. Refer to the Signals
chapter for details.
Table 19-2. eQADC Signals
Reset
Name Port Function Type
State
AN0/DAN0+ Input Single-ended analog input / Differential analog — Analog
input positive terminal
AN1/DAN0- Input Single-ended analog input / Differential analog — Analog
input negative terminal
AN2/DAN1+ Input Single-ended analog input / Differential analog — Analog
input positive terminal
AN3/DAN1- Input Single-ended analog input / Differential analog — Analog
input negative terminal
AN4/DAN2+ Input Single-ended analog input / Differential analog — Analog
input positive terminal
AN5/DAN2- Input Single-ended analog input / Differential analog — Analog
input negative terminal
AN6/DAN3+ Input Single-ended analog input / Differential analog — Analog
input positive terminal
AN7/DAN3- Input Single-ended analog input / Differential analog — Analog
input negative terminal
AN8/ANW Input Single-ended analog input / Single-ended — Analog
analog input from external multiplexers
AN9/ANX Input Single-ended analog input / Single-ended — Analog
analog input from external multiplexers
AN10/ANY Input Single-ended analog input/Single-ended analog — Analog
input from external multiplexers
AN11/ANZ Input Single-ended analog input / Single-ended — Analog
analog input from external multiplexers
AN12 Input / Output Single-ended analog input — Analog
AN13 Input / Output Single-ended analog input — Analog
AN14 Input / Output Single-ended analog input — Analog
AN15 Input Single-ended analog input — Analog
AN16/ANR1 Input Single-ended analog input / Single-ended — Analog
analog input from external multiplexers
Reset
Name Port Function Type
State
AN17/ANS1 Input Single-ended analog input / Single-ended — Analog
analog input from external multiplexers
AN18/ANT1 Input Single-ended analog input / Single-ended — Analog
analog input from external multiplexers
AN19/ANU1 Input Single-ended analog input / Single-ended — Analog
analog input from external multiplexers
AN20–AN39 Input Single-ended analog inputs — Analog
MA0 Output External multiplexer control signal 0 Digital
MA1 Output External multiplexer control signal 0 Digital
MA2 Output External multiplexer control signal 0 Digital
VDDA Input Analog Positive Power Supply — Power
VSSA Input Analog Negative Power Supply — Power
VRH Input Voltage Reference High — Power
VRL Input Voltage Reference Low — Power
REFBYPC Input External Bypass capacitor Pin — Power
ETRIG0 Input External trigger for CFIFO0 — Digital
ETRIG1 Input External trigger for CFIFO1 — Digital
ETRIG2 Input External trigger for CFIFO2 — Digital
ETRIG3 Input External trigger for CFIFO3 — Digital
ETRIG4 Input External trigger for CFIFO4 — Digital
ETRIG5 Input External trigger for CFIFO5 — Digital
1
Can be disabled or not using configuration parameters.
ADC Number
eQADC_A eQADC_B
Analog Input Pin
Function Channel Channel
416 package
eQADC_A eQADC_B Number Number
ADC Number
eQADC_A eQADC_B
Analog Input Pin
Function Channel Channel
416 package
eQADC_A eQADC_B Number Number
Address
Register Access Section/Page
Offset1
0x0000 EQADC_MCR—EQADC Module Configuration Register R/W 19.6.2.1/19-16
0x0004 Reserved —
0x0008 Reserved —
0x000C EQADC_ETDFR—EQADC External Trigger Digital Filter Register R/W 19.6.2.2/19-17
0x0010 EQADC_CFPR0—EQADC CFIFO Push Register 0 W 19.6.2.3/19-19
0x0014 EQADC_CFPR1—EQADC CFIFO Push Register 1 W
0x0018 EQADC_CFPR2—EQADC CFIFO Push Register 2 W
0x001C EQADC_CFPR3—EQADC CFIFO Push Register 3 W
0x0020 EQADC_CFPR4—EQADC CFIFO Push Register 4 W
0x0024 EQADC_CFPR5—EQADC CFIFO Push Register 5 W
0x0028 Reserved —
0x002C Reserved —
0x0030 EQADC_RFPR0—EQADC Result FIFO Pop Register 0 R 19.6.2.4/19-19
0x0034 EQADC_RFPR1—EQADC Result FIFO Pop Register 1 R
0x0038 EQADC_RFPR2—EQADC Result FIFO Pop Register 2 R
0x003C EQADC_RFPR3—EQADC Result FIFO Pop Register 3 R
0x0040 EQADC_RFPR4—EQADC Result FIFO Pop Register 4 R
0x0044 EQADC_RFPR5—EQADC Result FIFO Pop Register 5 R
0x0048 Reserved — —
0x004C Reserved — —
0x0050 EQADC_CFCR0-1—EQADC CFIFO Control Register 0 and 1 R/W 19.6.2.5/19-20
0x0054 EQADC_CFCR2-3—EQADC CFIFO Control Register 2 and 3 R/W
0x0058 EQADC_CFCR4-5—EQADC CFIFO Control Register 4 and 5 R/W
0x005C Reserved — —
0x0060 EQADC_IDCR0—EQADC Interrupt and DMA Control Register 0 R/W 19.6.2.6/19-23
0x0064 EQADC_IDCR1—EQADC Interrupt and DMA Control Register 1 R/W
0x0068 EQADC_IDCR2—EQADC Interrupt and DMA Control Register 2 R/W
0x006C Reserved — —
0x0070 EQADC_FISR0—EQADC FIFO and Interrupt Status Register 0 R/W 19.6.2.7/19-26
0x0074 EQADC_FISR1—EQADC FIFO and Interrupt Status Register 1 R/W
0x0078 EQADC_FISR2—EQADC FIFO and Interrupt Status Register 2 R/W
0x007C EQADC_FISR3—EQADC FIFO and Interrupt Status Register 3 R/W
0x0080 EQADC_FISR4—EQADC FIFO and Interrupt Status Register 4 R/W
0x0084 EQADC_FISR5—EQADC FIFO and Interrupt Status Register 5 R/W
Address
Register Access Section/Page
Offset1
0x0088 Reserved — —
0x008C Reserved — —
0x0090 EQADC_CFTCR0—EQADC CFIFO Transfer Counter Register 0 R/W 19.6.2.8/19-30
0x0094 EQADC_CFTCR1—EQADC CFIFO Transfer Counter Register 1 R/W
0x0098 EQADC_CFTCR2—EQADC CFIFO Transfer Counter Register 2 R/W
0x009C Reserved — —
0x00A0 EQADC_CFSSR0—EQADC CFIFO Status Snapshot Register 0 R 19.6.2.9/19-31
0x00A4 EQADC_CFSSR1—EQADC CFIFO Status Snapshot Register 1 R
0x00A8 Reserved — —
0x00AC EQADC_CFSR—EQADC CFIFO Status Register R 19.6.2.10/19-32
0x00B0–0x00CC Reserved — —
0x00D0 EQADC_REDLCCR—EQADC Red Line Client Configuration Register 19.6.2.11/19-33
0x00D4–0x00FC Reserved — —
0x0100–0x010C EQADC_CF0Rw—EQADC CFIFO0 Registers (w=0, .., 3) R 19.6.2.12/19-35
0x0110–0x011C EQADC_CF0ERw—EQADC CFIFO0 Extension Registers (w=0, .., 3) R 19.6.2.13/19-37
0x0120 –0x013C Reserved — —
0x0140–0x014C EQADC_CF1Rw—EQADC CFIFO1 Registers (w=0, .., 3) R 19.6.2.13/19-37
0x0150–0x017C Reserved — —
0x0180–0x018C EQADC_CF2Rw—EQADC CFIFO2 Registers (w=0, .., 3) R 19.6.2.13/19-37
0x0190–0x01BC Reserved — —
0x01C0–0x01CC EQADC_CF3Rw—EQADC CFIFO3 Registers (w=0, .., 3) R 19.6.2.13/19-37
0x01D0–0x01FC Reserved — —
0x0200–0x020C EQADC_CF4Rw—EQADC CFIFO4 Registers (w=0, .., 3) R 19.6.2.13/19-37
0x0210–0x023C Reserved — —
0x0240–0x024C EQADC_CF5Rw—EQADC CFIFO5 Registers (w=0, .., 3) R 19.6.2.13/19-37
0x0250–0x02FC Reserved — —
0x0300–0x030C EQADC_RF0Rw—EQADC RFIFO0 Registers (w=0, .., 3) R 19.6.2.14/19-37
0x0310–0x033C Reserved — —
0x0340–0x034C EQADC_RF1Rw—EQADC RFIFO1 Registers (w=0, .., 3) R 19.6.2.14/19-37
0x0350–0x037C Reserved — —
0x0380–0x038C EQADC_RF2Rw—EQADC RFIFO2 Registers (w=0, .., 3) R 19.6.2.14/19-37
0x0390–0x03BC Reserved — —
0x03C0–0x03CC EQADC_RF3Rw—EQADC RFIFO3 Registers (w=0, .., 3) R 19.6.2.14/19-37
0x03D0–0x03FC Reserved — —
0x0400–0x040C EQADC_RF4Rw—EQADC RFIFO4 Registers (w=0, .., 3) R 19.6.2.14/19-37
0x0410–0x043C Reserved — —
0x0440–0x044C EQADC_RF5Rw—EQADC RFIFO5 Registers (w=0, .., 3) R 19.6.2.14/19-37
0x0450–0x07FC Reserved — —
1
EQADC_A_BASE = 0xFFF8_0000
EQADC_B_BASE = 0xFFF8_4000
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R 0 0 0 0 0 0 0 0 0 0
ICEA0 ICEA1 DSM DBG
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 19-3. EQADC Module Configuration Register (EQADC_MCR)
Field Description
ICEAn Immediate Conversion Command Enable ADCn (n=0,1). ICEAn enables the EQADC to abort on-chip ADCn current
conversion and to start the immediate conversion command from CFIFO0 in the requested ADCn.
0 Disable immediate conversion command request.
1 Enable immediate conversion command request.
DSM Destination Select Mode. DSM selects between two modes of sending the same conversion result to two different
destinations. This is applied only when using Alternate Conversion Commands.
0 Legacy mode. Uses a defined set of pairs of companion module destinations as defined by the DEST field
encodings of the ADC_ACR1–14 registers specified in Table 19-31. The Extended Alternate Configuration registers
(ADC_EACR1-14) are not considered.
1 Selects the Extended Alternate Configuration Registers to send result to a second destination in addition to the
destination selected by the Alternate Configuration Registers. These destinations can be RFIFOs and companion
modules (Decimation filters) connected to the PSI. See Section 19.6.3.9, "Extended Alternate Configuration 1-14
Control Registers (ADC_EACR1-14)" for details.
DBG Debug enable. The DBG field defines the EQADC response to a debug mode entry request.
00 Do not enter debug mode.
01 Reserved
1x Enter debug mode.
Field Description
DFL Digital Filter Length. The DFL field specifies the minimum number of peripheral clocks that must be counted by
[0:3] the digital filter counter to recognize a logic state change. The count specifies the sample period of the digital filter
which is calculated according to the following equation:
DFL
FilterPeriod = S ystemClockPeriod 2 + 1 S ystemClockPeriod
Minimum clock counts for which an ETRIG signal needs to be stable to be passed through the filter are shown below.
Refer to Section 19.7.4.5, “Hardware Trigger Event Detection,” for more information on the digital filter.
0b0000 2 16.66
0b0001 3 25.00
0b0010 5 41.66
0b0011 9 75.00
0b0100 17 141.66
0b0101 33 275.00
0b0110 65 541.66
0b0111 129 1075.00
0b1000 257 2141.66
0b1001 513 4275.00
0b1010 1025 8541.66
0b1011 2049 17075.00
0b1100 4097 34141.00
0b1101 8193 68275.00
0b1110 16385 136541.66
0b1111 32769 273075.00
Note: The DFL field must only be written when the MODEx of all CFIFOs are configured to disabled.When the digital
filter is bypassed (i.e. for on-chip triggers), the DFL is not considered and the trigger input signal is not filtered.
Field Description
CF_PUSHx CFIFO Push Data x. When CFIFOx is not full, writing to the whole word or any bytes of EQADC_CFPRx will push
[0:31] the 32-bit CF_PUSHx value into CFIFOx. Writing to this field also increments the corresponding
EQADC_FISR[CFCTRx] value by one. When the CFIFOx is full, the EQADC ignores any write to the CF_PUSHx.
Reading EQADC_CFPRx always returns zero.
Note: Only whole words must be written to EQADC_CFPR. Writing half-words or bytes to EQADC_CFPR will still
push the whole 32-bit CF_PUSH field into the corresponding CFIFO, but undefined data will fill the areas of
CF_PUSH that were not specifically designated as target locations for the write.
Field Description
RF_POPx Result FIFO Pop Data x. When RFIFOx is not empty, the RF_POPx contains the next unread entry value of
[0:15] RFIFOx. Reading a word, a half-word, or any bytes from EQADC_RFPRx will pop one entry from RFIFOx and
cause the EQADC_FISR[RFCTRx] field to be decremented by one. When the RFIFOx is empty, any read on
EQADC_RFPRx returns undefined data value and does not decrement the RFCTRx value. Writing to
EQADC_RFPRx has no effect.
Field Description
CFEEE0 CFIFO0 Entry Number Extension Enable. The CFEEE0 bit is used to enable the extension of the CFIFO0 entries.
When in extended mode, the CFIFO0 total entries is the sum of normal entries plus the defined value for extension.
For more details, refer to Section 19.7.4.2, “CFIFO0 Streaming Mode Description.”
1 Enable the extension of CFIFO0 entries.
0 CFIFO0 has a normal value of entries.
STRME0 CFIFO0 Streaming Mode Operation Enable. The STRME0 bit is used to enable the streaming mode of operation
of CFIFO0. In this case, it is possible to repeat some sequence of commands of this FIFO without having to load
new commands from a command queue. For more details, refer to Section 19.7.4.2, “CFIFO0 Streaming Mode
Description.”
1 Enable the streaming mode of CFIFO0.
0 Streaming mode of CFIFO0 is disabled.
SSEx CFIFO Single-Scan Enable Bit x. The SSEx bit is used to set the EQADC_FISR[SSSx] bit. Writing a “1” to SSEx
will set the EQADC_FISR[SSSx] field if the CFIFO is in single-scan mode. When EQADC_FISR[SSSx] is already
asserted, writing a “1” to SSEx has no effect. If the CFIFO is in continuous-scan mode or is disabled, writing a “1”
to SSEx will not set EQADC_FISR[SSSx]. Writing a “0” to SSEx has no effect. SSEx always is read as “0”.
0 No effect.
1 Set the SSSx bit.
CFINVx CFIFO Invalidate Bit x. The CFINVx bit causes the EQADC to invalidate all entries of CFIFOx. Writing a “1” to
CFINVx will reset the value of EQADC_FISR[CFCTRx]. Writing a “1” to CFINVx also resets the Push Next Data
Pointer, Transfer Next Data Pointer to the first entry of CFIFOx in Figure 19-52. CFINVx always is read as “0”.
Writing a “0” has no effect.
0 No effect.1Invalidate all of the entries in the corresponding CFIFO.
Note: Writing CFINVx only invalidates commands stored in CFIFOx; previously transferred commands that are
waiting for execution, that is commands stored in the CBuffers, will still be executed, and results generated
by them will be stored in the appropriate RFIFO.
Note: CFINVx must not be written unless the MODEx is configured to disabled, and CFIFO status is IDLE.
Field Description
MODEx CFIFO Operation Mode x. The MODEx field selects the CFIFO operation mode for CFIFOx. Refer to
[0:3] Section 19.7.4.6, “CFIFO Scan Trigger Modes,” for more information on CFIFO trigger mode.
Note: If MODEx is not disabled, it must not be changed to any other mode besides disabled. If MODEx is disabled
and the CFIFO status is IDLE, MODEx can be changed to any other mode.
0b0000 Disabled
0b0001 Software Trigger, Single Scan
0b0010 Low Level Gated External Trigger, Single Scan
0b0011 High Level Gated External Trigger, Single Scan
0b0100 Falling Edge External Trigger, Single Scan
0b0101 Rising Edge External Trigger, Single Scan
0b0110 Falling or Rising Edge External Trigger, Single Scan
0b0111– 0b1000 Reserved
0b1001 Software Trigger, Continuous Scan
0b1010 Low Level Gated External Trigger, Continuous Scan
0b1011 High Level Gated External Trigger, Continuous Scan
0b1100 Falling Edge External Trigger, Continuous Scan
0b1101 Rising Edge External Trigger, Continuous Scan
0b1110 Falling or Rising Edge External Trigger, Continuous Scan
0b1111 Reserved
Field Description
AMODE0 CFIFO0 Advance Trigger Operation Mode 0. The AMODE0 field selects the trigger mode for the ATRIG0 trigger
[0:3] signal in streaming mode. The use of reserved values drives to unknown behavior of the block.
Note: If AMODE0 is not disabled, it must not be changed to any other mode besides disabled If AMODE0 is
disabled and the CFIFO0 status is IDLE, AMODE0 can be changed to any other mode.
Note: For the streaming mode of operation when the ATRIG0 is used to enable the ETRIG0 or to advance the
command queue, the normal mode of operation is external trigger single scan. Other settings are not fully
tested.
0b0000 Disabled
0b0001 Software Trigger, Single Scan
0b0010 Low Level Gated External Trigger, Single Scan
0b0011 High Level Gated External Trigger, Single Scan
0b0100 Falling Edge External Trigger, Single Scan
0b0101 Rising Edge External Trigger, Single Scan
0b0110 Falling or Rising Edge External Trigger, Single Scan
0b0111–0b1111 Reserved
R 0 0 0 0 0 0
NCIE1 TORIE1 PIE1 EOQIE1 CFUIE1 CFFE1 CFFS1 RFOIE1 RFDE1 RFDS1
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 19-8. EQADC Interrupt and DMA Control Register 0 (EQADC_IDCR0)
R 0 0 0 0 0 0
NCIE3 TORIE3 PIE3 EOQIE3 CFUIE3 CFFE3 CFFS3 RFOIE3 RFDE3 RFDS3
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 19-9. EQADC Interrupt and DMA Control Register 1 (EQADC_IDCR1)
R 0 0 0 0 0 0
NCIE5 TORIE5 PIE5 EOQIE5 CFUIE5 CFFE5 CFFS5 RFOIE5 RFDE5 RFDS5
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 19-10. EQADC Interrupt and DMA Control Register 2 (EQADC_IDCR2)
Field Description
NCIEx Non-Coherency Interrupt Enable x. NCIEx enables the EQADC to generate an interrupt request when the
corresponding EQADC_FISR[NCFx] is asserted.
TORIEx Trigger Overrun Interrupt Enable x. TORIEx enables the EQADC to generate an interrupt request when the
corresponding EQADC_FISR[TORFx] is asserted.
Apart from generating an independent interrupt request for a CFIFOx Trigger Overrun event, the EQADC also
provides a combined interrupt at which the Result FIFO Overflow Interrupt, the Command FIFO Underflow
Interrupt, and the Command FIFO Trigger Overrun Interrupt requests of ALL CFIFOs are ORed. When RFOIEx,
CFUIEx, and TORIEx are all asserted, this combined interrupt request is asserted whenever one of the following
18 flags becomes asserted: RFOFx, CFUFx, and TORFx (assuming that all interrupts are enabled). See
Section 19.7.8, “EQADC DMA/Interrupt Request,” for details.
0 Disable trigger overrun interrupt request.
1 Enable trigger overrun interrupt request.
PIEx Pause Interrupt Enable x. PIEx enables the EQADC to generate an interrupt request when the corresponding
EQADC_FISR[PFx] is asserted.
EOQIEx End of Queue Interrupt Enable x. EOQIEx enables the EQADC to generate an interrupt request when the
corresponding EQADC_FISR[EOQFx] is asserted.
CFUIEx CFIFO Underflow Interrupt Enable x. CFUIEx enables the EQADC to generate an interrupt request when the
corresponding EQADC_FISR[CFUFx] is asserted.
Apart from generating an independent interrupt request for a CFIFOx underflow event, the EQADC also provides
a combined interrupt at which the Result FIFO Overflow Interrupt, the Command FIFO Underflow Interrupt, and
the Command FIFO Trigger Overrun Interrupt requests of all CFIFOs are ORed. When RFOIEx, CFUIEx, and
TORIEx are all asserted, this combined interrupt request is asserted whenever one of the following 18 flags
becomes asserted: RFOFx, CFUFx, and TORFx (assuming that all interrupts are enabled). See Section 19.7.8,
“EQADC DMA/Interrupt Request,” for details.
CFFEx CFIFO Fill Enable x. CFFEx enables the EQADC to generate an interrupt request (CFFSx is asserted) or DMA
request (CFFSx is negated) when EQADC_FISR[CFFFx] is asserted.
Field Description
CFFSx CFIFO Fill Select x. CFFSx selects if a DMA or interrupt request is generated when EQADC_FISR[CFFFx] is
asserted. If CFFEx is asserted, the EQADC generates an interrupt request when CFFSx is negated, or it
generates a DMA request if CFFSx is asserted.
0 Generate interrupt request to move data from the system memory to CFIFOx.
1 Generate DMA request to move data from the system memory to CFIFOx.
RFOIEx RFIFO Overflow Interrupt Enable x. RFOIEx enables the EQADC to generate an interrupt request when the
corresponding EQADC_FISR[RFOFx] is asserted.
Apart from generating an independent interrupt request for an RFIFOx overflow event, the EQADC also provides
a combined interrupt at which the Result FIFO Overflow Interrupt, the Command FIFO Underflow Interrupt, and
the Command FIFO Trigger Overrun Interrupt requests of ALL CFIFOs are ORed. When RFOIEx, CFUIEx, and
TORIEx are all asserted, this combined interrupt request is asserted whenever one of the following 18 flags
becomes asserted: RFOFx, CFUFx, and TORFx (assuming that all interrupts are enabled). See Section 19.7.8,
“EQADC DMA/Interrupt Request,” for details.
0 Disable Overflow Interrupt request.
1 Enable Overflow Interrupt request.
RFDEx RFIFO Drain Enable x. RFDEx enables the EQADC to generate an interrupt request (RFDSx is asserted) or DMA
request (RFDSx is negated) when EQADC_FISR[RFDFx] is asserted.
RFDSx RFIFO Drain Select x. RFDSx selects if a DMA or interrupt request is generated when EQADC_FISR[RFDFx] is
asserted. If RFDEx is asserted, the EQADC generates an interrupt request when RFDSx is negated, or it
generates a DMA request when RFDSx is asserted.
0 Generate interrupt request to move data from RFIFOx to the system memory.
1 Generate DMA request to move data from RFIFOx to the system memory.
Field Description
NCFx Non-Coherency Flag. NCFx is set whenever a command sequence being transferred through CFIFOx becomes
non coherent. If EQADC_IDCR[NCIEx] and NCFx are asserted, an interrupt request will be generated. Write “1”
to clear NCFx. Writing a “0” has no effect. For more information refer to Section 19.7.4.7.5, “Command Sequence
Non-Coherency Detection.”
TORFx Trigger Overrun Flag for CFIFOx. TORFx is set when trigger overrun occurs for the specified CFIFO in edge or
level trigger mode. Trigger overrun occurs when an already triggered CFIFO receives an additional trigger. When
EQADC_IDCR[TORIEx] and TORFx are asserted, an interrupt request will be generated.
Apart from generating an independent interrupt request for a CFIFOx Trigger Overrun event, the EQADC also
provides a combined interrupt at which the Result FIFO Overflow Interrupt, the Command FIFO Underflow
Interrupt, and the Command FIFO Trigger Overrun Interrupt requests of ALL CFIFOs are ORed. When RFOIEx,
CFUIEx, and TORIEx are all asserted, this combined interrupt request is asserted whenever one of the following
18 flags becomes asserted: RFOFx, CFUFx, and TORFx (assuming that all interrupts are enabled). See
Section 19.7.8, “EQADC DMA/Interrupt Request,” for details.
Write “1” to clear the TORFx bit. Writing a “0” has no effect.
Note: The trigger overrun flag will not set for CFIFOs configured for software trigger mode.
Field Description
PFx Pause Flag x. PF behavior changes according to the CFIFO trigger mode. In edge trigger mode, PFx is set when
the EQADC completes the transfer of an entry with an asserted Pause bit from CFIFOx. In level trigger mode, when
CFIFOx is in TRIGGERED status, PFx is set when CFIFO status changes from TRIGGERED due to the detection
of a closed gate. An interrupt routine, generated due to the asserted PF, can be used to verify if a complete scan
of the CQueue was performed. If a closed gate is detected while no command transfers are taking place, it will
have immediate effect on the CFIFO status. If a closed gate is detected while a command transfer to an on-chip
CBuffer is taking place, it will only affect the CFIFO status when the transfer completes. The transfer of entries
bound for the on-chip ADCs is considered completed when they are stored in the appropriate CBuffer.
If EQADC_IDCR[PIEx] and PFx are asserted, an interrupt will be generated. Write “1” to clear the PFx. Writing a
“0” has no effect. Refer to Section 19.7.4.7.3, “Pause Status,” for more information on the Pause Flag.
0 Entry with asserted PAUSE bit was not transferred from CFIFOx (CFIFO in edge trigger mode), or CFIFO status
did not change from TRIGGERED due to detection of a closed gate (CFIFO in level trigger mode).
1 Entry with asserted PAUSE bit was transferred from CFIFOx (CFIFO in edge trigger mode), or CFIFO status
changes from TRIGGERED due to detection of a closed gate (CFIFO in level trigger mode).
Note: In edge trigger mode, an asserted PFx only implies that the EQADC has finished transferring a command
with an asserted PAUSE bit from CFIFOx. It does not imply that result data for the current command and for
all previously transferred commands has been returned to the appropriate RFIFO.
Note: In software or level trigger mode, when the EQADC completes the transfer of an entry from CFIFOx with an
asserted PAUSE bit, PFx will not be set and transfer of commands will continue without pausing.
EOQFx End of Queue Flag x. EOQFx indicates that an entry with an asserted EOQ bit was transferred from CFIFOx to
the on-chip ADCs - see Section 19.7.2.2, “Message Format in EQADC,” for details about command message
formats. When the EQADC completes the transfer of an entry with an asserted EOQ bit from CFIFOx, EOQFx will
be set. The transfer of entries bound for the on-chip ADCs is considered completed when they are stored in the
appropriate CBuffer. If the EQADC_IDCR[EOQIEx] and EOQFx are asserted, an interrupt will be generated.
Write “1” to clear the EOQFx bit. Writing a “0” has no effect. Refer to Section 19.7.4.7.2, “CQueue Completion
Status,” for more information on the End of Queue Flag.
Note: An asserted EOQFx only implies that the EQADC has finished transferring a command with an asserted
EOQ bit from CFIFOx. It does not imply that result data for the current command and for all previously
transferred commands has been returned to the appropriate RFIFO.
Field Description
CFUFx CFIFO Underflow Flag x. CFUFx indicates an underflow event on CFIFOx. CFUFx is set when CFIFOx is in
TRIGGERED state and it becomes empty. No commands will be transferred from an underflowing CFIFO, nor will
command transfers from lower priority CFIFOs be blocked. When EQADC_IDCR[CFUIEx] and CFUFx are both
asserted, the EQADC generates an interrupt request.
Apart from generating an independent interrupt request for a CFIFOx underflow event, the EQADC also provides
a combined interrupt at which the Result FIFO Overflow Interrupt, the Command FIFO Underflow Interrupt, and
the Command FIFO Trigger Overrun Interrupt requests of ALL CFIFOs are ORed. When RFOIEx, CFUIEx, and
TORIEx are all asserted, this combined interrupt request is asserted whenever one of the following 18 flags
becomes asserted: RFOFx, CFUFx, and TORFx (assuming that all interrupts are enabled). See Section 19.7.8,
“EQADC DMA/Interrupt Request,” for details.
SSSx CFIFO Single-Scan Status Bit x. An asserted SSSx bit enables the detection of trigger events for CFIFOs
programmed into single-scan level- or edge-trigger mode, and works as trigger for CFIFOs programmed into
single-scan software-trigger mode. Refer to Section 19.7.4.6.2, “Single-Scan Mode,” for further details. The SSSx
bit is set by writing a “1” to EQADC_CFCR[SSEx]. The EQADC clears the SSSx bit when a command with an
asserted EOQ bit is transferred from a CFIFO in single-scan mode, when a CFIFO is in single-scan level-trigger
mode and its status changes from TRIGGERED due to the detection of a closed gate, or when the value of the
CFIFO operation mode (EQADC_CFCR[MODEx]) is changed to disabled. Writing to SSSx has no effect. SSSx
has no effect in continuous-scan or in disabled mode.
0 CFIFO in single-scan level- or edge-trigger mode will ignore trigger events, or CFIFO in single-scan
software-trigger mode is not triggered.
1 CFIFO in single-scan level- or edge-trigger mode will detect a trigger event, or CFIFO in single-scan
software-trigger mode is triggered.
CFFFx CFIFO Fill Flag x. CFFFx is set when the CFIFOx is not full. When EQADC_IDCR[CFFEx] and CFFFx are both
asserted, an interrupt or a DMA request will be generated depending on the status of the CFFSx bit. When CFFSx
is negated (interrupt requests selected), software clears CFFFx by writing a “1” to it. Writing a “0” has no effect.
When CFFSx is asserted (DMA requests selected), CFFFx is automatically cleared by the EQADC when the
CFIFO becomes full.
0 CFIFOx is full.
1 CFIFOx is not full.
Note: Writing “1” to CFFFx when CFFSx is asserted (DMA requests selected) is not allowed.
Note: When generation of interrupt requests is selected (CFFSx=0), CFFFx must only be cleared in the ISR after
the CFIFOx push register is accessed.
Field Description
RFOFx RFIFO Overflow Flag x. RFOFx indicates an overflow event on RFIFOx. RFOFx is set when RFIFOx is already full,
and a new data is received from the on-chip ADCs. The RFIFOx will not overwrite older data in the RFIFO, and
the new data will be ignored. When EQADC_IDCR[RFOIEx] and RFOFx are both asserted, the EQADC generates
an interrupt request.
Apart from generating an independent interrupt request for an RFIFOx overflow event, the EQADC also provides
a combined interrupt at which the Result FIFO Overflow Interrupt, the Command FIFO Underflow Interrupt, and
the Command FIFO Trigger Overrun Interrupt requests of ALL CFIFOs are ORed. When RFOIEx, CFUIEx, and
TORIEx are all asserted, this combined interrupt request is asserted whenever one of the following 18 flags
becomes asserted: RFOFx, CFUFx, and TORFx (assuming that all interrupts are enabled). See Section 19.7.8,
“EQADC DMA/Interrupt Request,” for details.
RFDFx RFIFO Drain Flag x. RFDFx indicates if RFIFOx has valid entries or not. RFDFx is set when the RFIFOx has at
least one valid entry in it. When EQADC_IDCR[RFDEx] and RFDFx are both asserted, an interrupt or a DMA
request will be generated depending on the status of the RFDSx bit. When RFDSx is negated (interrupt requests
selected), software clears RFDFx by writing a “1” to it. Writing a “0” has no effect. When RFDSx is asserted (DMA
requests selected), RFDFx is automatically cleared by the EQADC when the RFIFO becomes empty.
0 RFIFOx is empty.
1 RFIFOx has at least one valid entry.
Note: Writing “1” to RFDFx when RFDSx is asserted (DMA requests selected) is not allowed.
Note: When the generation of interrupt requests is selected (RFDSx=0), RFDFx must only be cleared in the ISR
after the RFIFOx pop register is accessed.
CFCTRx CFIFOx Entry Counter. CFCTRx indicates the number of commands stored in the CFIFOx. When the EQADC
[0:3] completes transferring a piece of new data from the CFIFOx, it decrements CFCTRx by one. Writing a word or any
bytes to the corresponding EQADC_CFPR increments CFCTRx by one. Writing any value to CFCTRx has no
effect.
TNXTPTRx CFIFOx Transfer Next Pointer. TNXTPTRx indicates the index of the next entry to be removed from CFIFOx when
[0:3] it completes a transfer. When TNXTPTRx is zero, it points to the entry with the smallest memory-mapped address
inside CFIFOx. TNXTPTRx is only updated when a command transfer is completed. If the maximum index number
(CFIFO depth minus one) is reached, TNXTPTRx is wrapped to zero, else, it is incremented by one. For details
refer to Section 19.7.4.1, “CFIFO Basic Functionality.” Writing any value to TNXTPTRx has no effect.
RFCTRx RFIFOx Entry Counter. RFCTRx indicates the number of data items stored in the RFIFOx. When the EQADC
[0:3] stores a piece of new data into RFIFOx, it increments RFCTRx by one. Reading the whole word, half-word or any
bytes of the corresponding EQADC_RFPR decrements RFCTRx by one. Writing any value to RFCTRx itself has
no effect.
POPNXT RFIFOx Pop Next Pointer. POPNXTPTRx indicates the index of the entry that will be returned when
PTRx EQADC_RFPRx is read. When POPNXTPTRx is zero, it points to the entry with the smallest memory-mapped
[0:3] address inside RFIFOx. POPNXTPTRx is updated when EQADC_RFPRx is read. If the maximum index number
(RFIFO depth minus one) is reached, POPNXTPTRx is wrapped to zero, else, it is incremented by one. For details
refer to Section 19.7.5.1, “RFIFO Basic Functionality.” Writing any value to POPNXTPTRx has no effect.
R 0 0 0 0 0
TC_CF1
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 19-12. EQADC CFIFO Transfer Counter Register 0 (EQADC_CFTCR0)
R 0 0 0 0 0
TC_CF3
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 19-13. EQADC CFIFO Transfer Counter Register 1 (EQADC_CFTCR1)
R 0 0 0 0 0
TC_CF5
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 19-14. EQADC CFIFO Transfer Counter Register 2 (EQADC_CFTCR2)
Field Description
TC_CFx Transfer Counter for CFIFOx. TC_CFx counts the number of commands which have been completely transferred
[0:10] from CFIFOx. The transfer of entries bound for the on-chip ADCs is considered completed when they are stored in
the appropriate CBuffer. The EQADC increments the TC_CFx value by one after a command is transferred. TC_CFx
resets to zero after EQADC completes transferring a command with an asserted EOQ bit. Writing any value to
TC_CFx sets the counter to that written value.
Note: If CFIFOx is in TRIGGERED state when its MODEx field is programmed to disabled, the exact number of
entries transferred from the CFIFO until that point - TC_CFx - is only known after the CFIFO status changes
to IDLE, as indicated by CFSx. For details refer to Section 19.7.4.6.1, “Disabled Mode.”
R 0 LCFTCB0 TC_LCFTCB0
W
Reset 0 1 1 1 1 0 0 0 0 0 0 0 0 0 0 0
Figure 19-15. EQADC CFIFO Status Snapshot Register 0 (EQADC_CFSSR0)
R 0 LCFTCB1 TC_LCFTCB1
W
Reset 0 1 1 1 1 0 0 0 0 0 0 0 0 0 0 0
Figure 19-16. EQADC CFIFO Status Snapshot Register 1 (EQADC_CFSSR1)
Field Description
CFSx_TCBn[0:1] CFIFO Status at Transfer to CBuffern (n=0,1). CFSx_TCBn indicates the CFIFOx status of previously
completed command transfer. CFSx_TCBn is a copy of the corresponding CFSx in the Section 19.6.2.10,
“EQADC CFIFO Status Register (EQADC_CFSR),” captured at the time a current command transfer to
CBuffern is initiated.
LCFTCBn[0:3] Last CFIFO to Transfer to CBuffern (n=0,1). LCFTCBn holds the CFIFO number to have completed a
previous command transfer to CBuffern.
TC_LCFTCBn[0:10] Transfer Counter for Last CFIFO to transfer commands to CBuffern. TC_LCFTCBn indicates the number
of commands which have been completely transferred from CFIFOx when a current command transfer
from CFIFOx to CBuffern is initiated. TC_LCFTCBn is a copy of the corresponding TC_CFx in the
Section 19.6.2.8, “EQADC CFIFO Transfer Counter Registers (EQADC_CFTCR),” captured at the time a
current command transfer from CFIFOx to CBuffern is initiated. This field has no meaning when LCFTCBn
is 0b1111.
R 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 19-17. EQADC CFIFO Status Register (EQADC_CFSR)
Field Description
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R REDBS2 SRV2 REDBS1 SRV1
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Field Description
REDBSm[0:3] Red Line Timebase Bits Selection m (m=1,2)—Selects 16 bits from the total of 24 bits that are received
from the Red Line interface as described in below. Consider TBASEm[0:23] the selected time base from
slot SRVm:
0b0000 TBASEm[0:15]
0b0001 TBASEm[1:16]
0b0010 TBASEm[2:17]
0b0011 TBASEm[3:18]
0b0100 TBASEm[4:19]
0b0101 TBASEm[5:20]
0b0110 TBASEm[6:21]
0b0111 TBASEm[7:22]
0b1000 TBASEm[8:23]
Others Reserved
SRVm[0:3] Red Line Server Data Slot Selector m (m=1,2)—Indicates the slot number that contains the desired time
base value sent by the Red Line server. This value selects which eTPU timebase on the STAC bus is used
to timestamp an ADC sample.
R CFIFO0_DATAw
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 19-19. EQADC CFIFO0 Registers (EQADC_CF0Rw) (w=0, .., 3)
R CFIFO0_DATAw
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 19-20. EQADC CFIFO1 Registers (EQADC_CF1Rw) (w=0, .., 3)
R CFIFO2_DATAw
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 19-21. EQADC CFIFO2 Registers (EQADC_CF2Rw) (w=0, .., 3)
R CFIFO3_DATAw
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 19-22. EQADC CFIFO3 Registers (EQADC_CF3Rw) (w=0, .., 3)
R CFIFO4_DATAw
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 19-23. EQADC CFIFO4 Registers (EQADC_CF4Rw) (w=0, .., 3)
R CFIFO5_DATAw
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 19-24. EQADC CFIFO5 Registers (EQADC_CF5Rw) (w=0, .., 3)
Field Description
CFIFOx_DATAw[0:3 CFIFOx Data w (w = 0, .., 3). Reading CFIFOx_DATAw returns the value stored on the wth entry of CFIFOx.
1] Each CFIFO is composed of four 32-bit entries, with register 0 being mapped to the one with the smallest
memory mapped address.
R CFIFO0_EDATAw
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 19-25. EQADC CFIFO0 Extension Registers (EQADC_CF0ERw) (w=0, .., 3)
Field Description
CFIFO0_EDATAw[0:31] CFIFOx Extension Data w (w = 0, .., 3). Reading CFIFO0_EDATAw returns the value stored on the
wth entry of CFIFO0’s extended portion.
R RFIFO0_DATAw
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 19-26. EQADC RFIFO0 Registers (EQADC_RF0Rw) (w=0, .., 3)
R RFIFO1_DATAw
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 19-27. EQADC RFIFO1 Registers (EQADC_RF0Rw) (w=0, .., 3)
R RFIFO2_DATAw
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 19-28. EQADC RFIFO2 Registers (EQADC_RF0Rw) (w=0, .., 3)
R RFIFO2_DATAw
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 19-29. EQADC RFIFO2 Registers (EQADC_RF0Rw) (w=0, .., 3)
R RFIFO3_DATAw
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 19-30. EQADC RFIFO3 Registers (EQADC_RF0Rw) (w=0, .., 3)
R RFIFO4_DATAw
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 19-31. EQADC RFIFO4 Registers (EQADC_RF0Rw) (w=0, .., 3)
R RFIFO5_DATAw
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 19-32. EQADC RFIFO5 Registers (EQADC_RF0Rw) (w=0, .., 3)
Field Description
RFIFOx_DATAw RFIFOx Data w (w = 0, .., 3). Reading RFIFOx_DATAw returns the value stored on the wth entry of RFIFOx.
[0:15] Each RFIFO is composed of four 16-bit entries, with register 0 being mapped to the one with the smallest
memory mapped address.
ADC
Use Access
Address
0x00 ADC0/ADC11 Conversion Command for Standard Configuration (See page 63) Write
0x01 ADC0/ADC1 Configuration Control Register (ADC0_CR, ADC1_CR) Write/Read
0x02 Time Stamp Control Register (ADC_TSCR) Write/Read
0x03 Time Base Counter Register (ADC_TBCR) Write/Read
0x04 ADC0/ADC1 Gain Calibration Constant Register (ADC0_GCCR, ADC1_GCCR) Write/Read
0x05 ADC0/ADC1 Offset Calibration Constant Register (ADC0_OCCR, ADC1_OCCR) Write/Read
0x06– 0x07 Reserved —
0x08 ADC0/ADC1 Conversion Command for Alternate Configuration 1 (See page 65) Write
0x09 ADC0/ADC1 Conversion Command for Alternate Configuration 2 (See page 65) Write
0x0A ADC0/ADC1 Conversion Command for Alternate Configuration 3 (See page 65) Write
0x0B ADC0/ADC1 Conversion Command for Alternate Configuration 4 (See page 65) Write
0x0C ADC0/ADC1 Conversion Command for Alternate Configuration 5 (See page 65) Write
0x0D ADC0/ADC1 Conversion Command for Alternate Configuration 6 (See page 65) Write
0x0E ADC0/ADC1 Conversion Command for Alternate Configuration 7 (See page 65) Write
Field Description
ADC0/1_EN Enable bit for ADC0/1. ADC0/1_EN enables ADC0/1 to perform A/D conversions. Refer to
Section 19.7.6.1, “Enabling and Disabling the On-chip ADCs,” for details.
0 ADC is disabled. Clock supply to ADC0/1 is stopped.
1 ADC is enabled and ready to perform A/D conversions.
Note: The bias generator circuit inside the ADC hard macro ceases functioning when both ADC0_EN and
ADC1_EN bits are negated.
Note: Conversion commands sent to the CBuffer of a disabled ADC are ignored by the ADC control
hardware.
Note: When the ADC0/1_EN status is changed from asserted to negated, the ADC Clock will not stop until
it reaches its low phase.
Note: Both ADC0 and ADC1 of an eQADC module pair must be enabled before calibrating or using either
ADC0 or ADC1 of the pair. Failure to enable both ADC0 and ADC1 of the pair can result in inaccurate
conversions.
ADC0/1_EMUX External Multiplexer enable for ADC0/1. When ADC0/1_EMUX is asserted, the MA pins will output digital
values according to the number of the external channel being converted for selecting external multiplexer
inputs. Refer to Section 19.7.7, “Internal/External Multiplexing,” for a detailed description about how
ADC0/1_EMUX affects channel number decoding.
Note: Both ADC0/1_EMUX bits must not be asserted at the same time.
Note: The ADC0/1_EMUX bit must only be written when the ADC0/1_EN bit is negated. ADC0/1_EMUX
can be set during the same write cycle used to set ADC0/1_EN.
ADC0/1_TBSEL Timebase Selection for ADC0/1. The ADC0/1_TBSEL[0:11:0] field selects the time information to be used
as timestamp.
ADC0/1_TBSEL[0:1] Definition
Note: This selection is overridden by the corresponding field ATBSEL in the ADC_ACR1-14 registers when
the alternate conversion command is used.
ADC0/1_ODD_PS Clock Prescaler Odd Rates Selector for ADC0/1. The ADC0/1_ODD_PS field is used together with the
ADC0/1_CLK_PS field to define even/odd divide factors in the generation of the ADC0/1 clocks. Refer to
Table 19-22 for available divide factors.
0 Even divide factor is selected. The final divide factor is dependent of ADC0/1_CLK_PS field.
1 Odd divide factor is selected. The final divide factor is dependent of ADC0/1_CLK_PS field.
Field Description
ADC0/1_CLK_DTY Clock Duty Rate Selector for ADC0/1 (for odd divide factors). The ADC0/1_CLK_DTY field controls the duty
rate of the ADC0/1 clock when the ADC0/1_CLK_PS field is asserted. The generated clock has an odd
number of peripheral clock cycles, therefore this field is used to select a clock duty higher or lower than
50%.
ADC0/1_CLK_SEL Clock Selector for ADC0/1. The ADC0/1_CLK_SEL is used to select between the peripheral clock signal
or the prescaler output signal. The prescaler provides the peripheral clock signal divided by a even factor
from 2 to 64. This is required to permit the ADC to run as fast as possible when the device is in Low Power
Active mode and peripheral clock is around 1 MHz.
Note: The ADC0/1_CLK_SEL bits must only be written when the ADC0/1_EN bit is negated.
ADC0/1_CLK_SEL can be set during the same write cycle used to set ADC0/1_EN.
ADC0/1_CLK_PS Clock Prescaler Field for ADC0/1. The ADC0/1_CLK_PS field controls the peripheral clock divide factor for
[0:4] the ADC0/1 clock as in Table 19-22. See Section 19.7.6.2, “ADC Clock and Conversion Speed,” for details
about how to set ADC0/1_CLK_PS.
Note: The ADC0/1_CLK_PS field must only be written when the ADC0/1_EN bit is negated. This field can
be configured during the same write cycle used to set ADC0/1_EN.
0b00000 2 3
0b00001 4 5
0b00010 6 7
0b00011 8 9
0b00100 10 11
0b00101 12 13
0b00110 14 15
0b00111 16 17
0b01000 18 19
0b01001 20 21
0b01010 22 23
0b01011 24 25
0b01100 26 27
0b01101 28 29
Table 19-22. Peripheral clock Divide Factor for ADC Clock (continued)
0b01110 30 31
0b01111 32 33
0b10000 34 35
0b10001 36 37
0b10010 38 39
0b10011 40 41
0b10100 42 43
0b10101 44 45
0b10110 46 47
0b10111 48 49
0b11000 50 51
0b11001 52 53
0b11010 54 55
0b11011 56 57
0b11100 58 59
0b11101 60 61
0b11110 62 63
0b11111 64 65
Field Description
TBC_CLK_PS[0:3] Time Base Counter Clock Prescaler. The TBC_CLK_PS field contains the peripheral clock divide factor for
the time base counter. It controls the accuracy of the time stamp. The prescaler is disabled when
TBC_CLK_PS is set to 0b0000.
NOTE
If TBC_CLK_PS is not set to disabled, it must not be changed to any other
value besides disabled. If TBC_CLK_PS is set to disabled it can be changed
to any other value.
Field Description
TBC_VALUE[0:15] Time Base Counter value. The TBC_VALUE field contains the current value of the time base counter.
Reading TBC_VALUE returns the current value of time base counter. Writes to TBC_VALUE register load
the written data to the counter. The time base counter counts from 0x0000 to 0xFFFF and wraps when
reaching 0xFFFF.
Field Description
GCC0/1[0:14] Gain calibration constant for ADC0/1. GCC0/1 contains the gain calibration constant used to fine-tune
ADC0/1 conversion results. It is a unsigned 15-bit fixed pointed value. The gain calibration constant is an
unsigned fixed point number expressed in the GCC_INT.GCC_FRAC binary format. The integer part of the
gain constant (GCC_INT) contains a single binary digit while its fractional part (GCC_FRAC) contains
fourteen digits. For details about the GCC data format refer to Section 19.7.6.6.2, “MAC Unit and Operand
Data Format.”
Field Description
OCC0/1[0:13] Offset Calibration Constant of ADC0/1. OCC0/1 contains the offset calibration constant used to fine-tune
ADC0/1 conversion results. Negative values should be expressed using the two’s complement
representation.
ADC0/1 Register Address: 0x30, 0x34, 0x38, 0x3C,... 0x5C, 0x60, 0x64 Access: User read only
R RET_ 0 0 0
DEST FMTA RMSEL RESSEL ATBSEL PRE_GAIN
W INH
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 19-38. Alternate Configuration 1-14 Control Registers (ADC_ACR1-14)
Field Description
RET_INH Result Transfer Inhibit / Decimation Filter Pre-Fill. This bit is used to inhibit the transfer of the result data
from the peripheral module to the result queue. When the module is a Decimation Filter, this bit sets the
filter in a special mode (PRE-FILL) in which it does not generate decimated samples out from the
conversion results received from the EQADC block, but the conversion samples are used by the filter
algorithm. This feature allows a proper initialization of the Decimation Filter without generating any
decimated result. Or this bit is useful for sending the result of the ADC to the STAC bus master but not
putting the result in the result queue.
DEST[0:3] Conversion Result Destination Selection. The DEST[0:3] field selects the Decimation Filter destinations of
the conversion result generated by the Alternate Conversion Command. This field also affects the behavior
of the FMTA bit and the FFMT bit of the conversion command for alternate configurations (see
Section 19.7.2.2.2, “Conversion Command Format for Alternate Configurations).”
Note: When EQADC_MCR[DSM]=0, decimation filter H through L are only accessible from the CPU, and
cannot be accessed by an eQADC. When EQADC_MCR[DSM]=1, the functionality of the DEST field
is defined by Table 19-32.
DEST[0:3] Description
Field Description
FMTA Conversion Data Format for Alternate Configuration. If the DEST field is not 0b000, the FMTA bit specifies
how the 12-bit conversion data returned by the ADCs is formatted into the 16-bit data which is sent to the
parallel side interface.
RMSEL Return Module Selection. The RMSEL bit specifies which eQADC module will receive data returning from
a decimation filter.
Note: A decimation filter may take samples from two eQADCs, allowing double sample rate. If the RMSEL
bits for each are different, the results are sent to just one of the eQADCs.
0 Decimation filter return data is sent to the eQADC that supplied the filter input data.
1 Decimation filter return data is sent to the eQADC that did not supply the filter input data.
ATBSEL Alternate Command Timebase Selector. The ATBSEL field selects the time information to be used as
timestamp.
Note: This selection overrides the corresponding fields ADC0/1_TBSEL in the ADC0/1_CR registers when
the alternate conversion command is used.
ATBSEL[0:11] Description
PRE_GAIN[0:1] ADC Pre-gain control. The PRE_GAIN[0:1] controls the gain of the ADC input stage by changing the
internal ADC iterations in the gain stage.
00 X1 gain
01 X2 gain
10 X4 gain
11 Reserved
Field Description
ALTGCC0/1x[0:14] Alternate Gain Calibration Constant. ALTGCC0/1x[0:14] contain the gain calibration constants used to
fine-tune ADC0/1 conversion results for alternate configurations 1 and 2. The gain calibration constants
are 15-bit unsigned fixed point numbers expressed in the GCC_INT.GCC_FRAC binary format. The integer
part of the gain constants (GCC_INT) contain a single binary digit while their fractional part (GCC_FRAC)
contain fourteen digits. For details about the GCC data format refer to Section 19.7.6.6.2, “MAC Unit and
Operand Data Format.”
Field Description
ALTOCC0/1x[0:13] Alternate Offset Calibration Constant.ALTOCC0/1x[0:13] contain the offset calibration constants used to
fine-tune ADCs conversion results for alternate configurations 1 or 2. Negative values should be expressed
using the two’s complement representation.”
ADC0/1 Register Address: 0x33, 0x37, 0x3B, 0x3F,... 0x5F, 0x63, 0x67 Access: User read/write
R RET_ 0 RMSEL FLEN 0 0
DEST2 FMTA2 2 TEN2 MESSAGE_TAG2
W INH2 2
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 19-41. Extended Alternate Configuration 1-14 Control Registers (ADC_EACR1-14)
Field Description
RET_INH2 Second Result Transfer Inhibit / Decimation Filter Pre-Fill. Same definition as RET_INH field in
EQADC_ACRx but applying to the second destination selected by DEST2.
DEST2[0:3] Second Conversion Result Destination Selection. The DEST2[0:3] field selects the second Decimation
Filter destination of the conversion result generated by the Alternate Conversion Command. In addition,
the eQADC operation due to this field is also affected by the ADC_ACRx DEST field, by the ADC_EACRx
TEN2 field, by MESSAGE_TAG field, by the ADC_EACRx MESSAGE_TAG2 field as defined in
Table 19-32.
FMTA2 Second Conversion Data Format for Alternate Configuration. The FMTA2 bit specifies how the 12-bit
conversion data returned by the ADCs is formatted into the 16-bit data which is sent to the RFIFOs or the
parallel side interface defined by DEST2. Refer to Table 19-32 for more details.
RMSEL2 Second Return Module Selection. The RMSEL bit specifies which eQADC module will receive data
returning from the decimation filter specified by DEST2.
Note: A decimation filter may take samples from two eQADCs, allowing double sample rate. If the RMSEL
bits for each are different, the results are sent to just one of the eQADCs.
0 Decimation filter return data is sent to the eQADC that supplied the filter input data.
1 Decimation filter return data is sent to the eQADC that did not supply the filter input data.
FLEN2 Flush Enable for Second Destination. The FLEN2 bit enables the transfer of the flush command given by
the FFMT field from the alternate conversion command when DEST>0.
TEN2 Enable MESSAGE_TAG2 for Second Destination. This bit specifies if the MESSAGE_TAG2 value should
be used for the second destination result transfer. Refer to Table 19-32 for more details.
0 MESSAGE_TAG2 is disabled.
1 MESSAGE_TAG2 is enabled.
MESSAGE_TAG2 Same as the MESSAGE_TAG field in the Conversion Command as described in "Conversion Command
[0:3] Format for the Standard Configuration".
MESSAGE_TAG2c = MESSAGE_TAGa?
0000b 0001– 0b X X X RFIFO FFMTa N/A Filter module (1–15) FMTA2c None —
(RFIFO) 1111b a
(MESSAGE_TAG specifies c
(DEST2 specifies the module; (FFMTa
(Filter the RFIFO.) MESSAGE_TAGa specifies the is used
module) return RFIFO. RET_INH2c and as the
RMSEL2c control the module.) primary
-destina
1b True Filter module (1–15) tion
(DEST2c specifies the module; format
False specifie
MESSAGE_TAG2c specifies
the return RFIFO. RET_INH2c r)
and RMSEL2c control the
module.)
a
In the alternate conversion command.
b In the associated ADC_ACRx register.
c
In the associated ADC_EACRx register.
d
Considered only when both destinations are RFIFOs. The sample formats are the same: FMTA2c = FFMTa.
e Considered only when both destinations are Decimation filter modules. The sample formats and controls are the same:
(FMTA2c = FMTAb) && (RET_INH2c = RET_INHb) && (RMSEL2c = RMSELb) && (((FLEN2c = 0b) && (FFMTa = 0b)) ||
(FLEN2c = 1b)).
f
The primary-destination result set is sent first, and the secondary-destination result set is sent later.
g The primary- and secondary-destination result sets are sent to the Decimation filter modules simultaneously.
h The order in which processed result sets (returned from the Decimation filter modules) are stored in the RFIFO is not
guaranteed. One filter module may take longer than the other to process its result set, and when two or more modules attempt
to return result sets at the same time, the EQADC responds to the highest-priority module first (module 1 has the highest
priority; module 15 has the lowest priority).
MESSAGE_TAG2c = MESSAGE_TAGa?
0001– 0001– 0b X X False Filter module (1–15) FMTAb FFMTa Filter module (1–15) FMTA2c FFMTa —
1111b 1111b (DESTb specifies the module; (DEST2c specifies the module; when
(Filter (Filter MESSAGE_TAGa specifies the MESSAGE_TAGa specifies the
module) module) FLEN2c
return RFIFO. RET_INHb and return RFIFO. RET_INH2c and
(equal RMSELb control the module.) RMSEL2c control the module.) is 1b
to
DEST) True None
(Two identical result sets would be sent to the same
1b True True
RFIFO, so the secondary destination is ignored.)
MESSAGE_TAG2c = MESSAGE_TAGa?
0001– 0001– 0b X X False Filter module (1–15) FMTAb FFMTa Filter module (1–15) FMTA2c FFMTa f, h
1111b 1111b b
(DEST specifies the module; c
(DEST2 specifies the module; when
(Filter (Filter True FLEN2c g, h
MESSAGE_TAGa specifies the MESSAGE_TAGa specifies the
module) module) return RFIFO. RET_INHb and return RFIFO. RET_INH2c and is 1b
(not RMSELb control the module.) RMSEL2c control the module.)
equal to
DEST) 1b True True Filter module (1–15)
(DEST2c specifies the module;
False f, h
MESSAGE_TAG2c specifies
False X the return RFIFO. RET_INH2c —
and RMSEL2c control the
module.)
a In the alternate conversion command.
b
In the associated ADC_ACRx register.
c
In the associated ADC_EACRx register.
d Considered only when both destinations are RFIFOs. The sample formats are the same: FMTA2c = FFMTa.
e
Considered only when both destinations are Decimation filter modules. The sample formats and controls are the same:
(FMTA2c = FMTAb) && (RET_INH2c = RET_INHb) && (RMSEL2c = RMSELb) && (((FLEN2c = 0b) && (FFMTa = 0b)) ||
(FLEN2c = 1b)).
f The primary-destination result set is sent first, and the secondary-destination result set is sent later.
g
The primary- and secondary-destination result sets are sent to the Decimation filter modules simultaneously.
h
The order in which processed result sets (returned from the Decimation filter modules) are stored in the RFIFO is not
guaranteed. One filter module may take longer than the other to process its result set, and when two or more modules attempt
to return result sets at the same time, the EQADC responds to the highest-priority module first (module 1 has the highest
priority; module 15 has the lowest priority).
Field Description
CH_PULLx[0:1] Channel x Pull Up/Down Control bits. The CH_PULLx[0:1] field controls the pull up/down configuration of
the channel x.
00 No Pull resistors connected to the channel
01 Pull Up resistor connected to the channel
10 Pull Down resistor connected to the channel
11 Pull Up and Pull Down resistors connected to the channel
PULL_STRx[0:1] Pull Up/Down Strength Control bits of channel x. The PULL_STRx[0:1] bit field defines the strength of the
channel x pull up or down resistors.
00 Reserved
01 200 Kohm pull resistor
10 100 Kohm pull resistor
11 5 Kohm (approx.) pull resistor (not available for CH_PULL_x = 0b11)
Field Description
TB_VALUE[0:15] Time Base VALUE Field. Contains the current value of the imported time base.
19.7.1 Overview
The EQADC provides a parallel interface to two on-chip ADCs and a parallel side interface to an on-chip
companion module, like a decimation filter. The two on-chip ADCs are architectured to allow access to all
the analog channels.
Initially, command data is contained in system memory in a user defined data structure which is likely to
be a queue as depicted in Figure 19-21. Command data is moved between the CQueues and CFIFOs by the
1. Command and result data can be stored in the system memory in any user defined data structure. However, in this
document it will be assumed that the data structure of choice is a queue, since it is the most likely data structure to be used
and because queues are the only type of data structure supported by the DMAC.
host CPU or by the DMAC which respond to interrupt and DMA requests generated by the EQADC. The
EQADC supports software and hardware triggers from other blocks or external pins to initiate transfers of
commands from the multiple CFIFOs to the on-chip ADCs.
CFIFOs can be configured in single-scan or continuous-scan mode. When a CFIFO is configured in
single-scan mode, the EQADC scans the CQueue one time. The EQADC stops transferring commands
from the triggered CFIFO after detecting the EOQ bit set in the last transfer. After an EOQ bit is detected,
software involvement is required to rearm the CFIFO so that it can detect new trigger events.
When a CFIFO is configured for continuous-scan mode, the whole CQueue is scanned multiple times.
After the detection of an asserted EOQ bit in the last command transfer, command transfers can continue
or not depending on the mode of operation of the CFIFO.
CFIFO0 has a special configuration option to allow a repetitive sequence of conversion commands
(streaming mode) with high priority characteristics (abort operation) or not. This feature is useful with the
immediate conversion command feature that allows the immediate execution of a conversion command or
a sequence of commands with critical timing even with the possibility of abortion of some current ADC
conversion in progress. The aborted command is stored and executed again as soon as the critical timing
commands have been finished.
The multiple Result FIFOs (RFIFOs) can receive data from the on-chip ADCs or from an on-chip
companion module (decimation filter). Data from the on-chip ADCs can be routed to the side interface,
processed by the on-chip companion module (decimation filter) and then routed back through the side
interface to the RFIFOs.
Priority
Abort
ADC Cont
32 bits
32 bits
NOTE: x=0, 1, 2, 3, 4, 5
y=0, 1, 2, 3, ...
CFIFO Header
Command Message ADC Command
ADC commands sent to the on-chip CBuffers are executed in a first-in-first-out basis with exception when
the immediate conversion command function is enabled. Three types of results can be expected: data read
from an ADC register, a conversion result, or a time stamp.
NOTE
While the EQADC pops commands out from a CFIFO, it also is checking
the number of entries in the CFIFO and generating requests to fill it. The
process of pushing and popping commands to and from a CFIFO can occur
simultaneously. However, this is not true for CFIFO0 when configured to
operate in streaming mode for popping.
The FIFO Control Unit expects all incoming results to be shaped in a predefined Result Message format.
Figure 19-45 shows how result data flows inside the EQADC system. Results generated on the on-chip
ADCs are adjusted considering the selected resolution of the ADC and are formatted into result messages
inside the Result Format and Calibration Sub-Block. This result message can be routed directly to one of
the RFIFOs or to an on-chip companion module (decimation filter) via the parallel side interface. After the
data is processed by the companion module, it can be routed back to one of the RFIFOs via the side
interface with the correct format. A result message is composed of an RFIFO header and an ADC Result.
The FIFO Control Unit decodes the information contained in the RFIFO header to determine the RFIFO
to which the ADC result should be sent. Once in an RFIFO, the ADC result is moved to the corresponding
RQueue by the host CPU or by the DMAC as they respond to interrupt and DMA requests generated by
the EQADC. The EQADC generates these requests whenever an RFIFO has at least one entry.
NOTE
While conversion results are returned, the EQADC is checking the number
of entries in the RFIFO and generating requests to empty it. The process of
pushing and popping ADC results to and from an RFIFO can occur
simultaneously.
Host CPU
or
DMAC
Inside EQADC
System Memory
FIFO Control
Unit
RFIFOx RQueue y
Resolution
Decoder
Result
Format and
Adjust
ADC Calibration
Sub-Block
16 bits 16 bits
EQADC PSI
NOTE: x=0, 1, 2, 3, 4, 5
y=0, 1, 2, 3, ...
On-Chip
Companion
Module
RFIFO Header
Result Message ADC Result
Figure 19-45. Result Flow during EQADC operation
Control Unit to arbitrate which triggered CFIFO will transfer the next command. ADC commands are
encoded inside the least significant 26 bits of the command message.
A Result message is composed of an RFIFO header and an ADC Result. The FIFO Control Unit decodes
the information contained in the RFIFO header to determine the RFIFO to which the ADC result should
be sent. An ADC result is always 16 bits long.
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
CHANNEL_NUMBER 0 0 0 0 0 0 0 0
ADC Command
Figure 19-46. Conversion Command Format for the Standard Configuration
Field Description
EOQ End Of Queue Bit. The EOQ bit is asserted in the last command of a CQueue to indicate to the EQADC
that a scan of the CQueue is completed. EOQ instructs the EQADC to reset its current CFIFO transfer
counter value (TC_CF) to zero. Depending on the CFIFO mode of operation, the CFIFO status will also
change upon the detection of an asserted EOQ bit on the last transferred command - see Section 19.7.4.6,
“CFIFO Scan Trigger Modes,” for details.
0 Not the last entry of the CQueue.
1 Last entry of the CQueue.
Note: If both the PAUSE and EOQ bits are asserted in the same command message the respective flags
are set, but the CFIFO status changes as if only the EOQ bit were asserted.
PAUSE Pause Bit. The Pause bit allows software to create sub-queues within a CQueue. When the EQADC
completes the transfer of a command with an asserted Pause bit, the CFIFO enters the WAITING FOR
TRIGGER state. Refer to Section 19.7.4.7.1, “CFIFO Operation Status,” for a description of the state
transitions. The Pause bit is only valid when CFIFO operation mode is configured to single or
continuous-scan edge trigger mode.
0 Do not enter WAITING FOR TRIGGER state after transfer of the current Command Message.
1 Enter WAITING FOR TRIGGER state after transfer of the current Command Message.
Note: If both the PAUSE and EOQ bits are asserted in the same command message the respective flags
are set, but the CFIFO status changes as if only the EOQ bit were asserted.
Field Description
REP Repeat/loop Start Point Indication Bit. The REP bit is asserted in the command to indicate where is the
start point of the sub-queue to be repeated when the streaming mode is enabled. The PAUSE bit indicates
the end point of the sub-queue. Therefore, both can occur in the same command or in separated ones. If
two or more REP bits are read before a PAUSE bit, this is an error case and the intermediary REP bits are
ignored.
0 It is not the start point of a loop.
1 Indicates the start point of the sub-queue to be repeated.
EB External Buffer Bit. A negated EB bit indicates that the command is sent to an internal CBuffer.
0 Command is sent to an internal buffer.
1 Reserved.
BN Buffer Number Bit. BN indicates which buffer the message will be stored in.
1 Message stored in buffer 1.
0 Message stored in buffer 0.
CAL Calibration Bit. CAL indicates if the returning conversion result must be calibrated.
1 Calibrate conversion result.
0 Do not calibrate conversion result.
MESSAGE_TAG MESSAGE_TAG Field. The MESSAGE_TAG allows the EQADC to separate returning results into
[0:3] different RFIFOs. When the EQADC transfers a command, the MESSAGE_TAG is included as part of the
command. Eventually the on-chip ADC returns the result with the same MESSAGE_TAG. The EQADC
separates incoming messages into different RFIFOs by decoding the MESSAGE_TAG of the incoming
data.
LST[0:1] Long Sampling Time. These two bits determine the duration of the sampling time in ADC clock cycles.
Sampling cycles
LST[0:1]
(ADC Clock Cycles)
0b00 2
0b01 8
0b10 64
0b11 128
TSR Time Stamp Request. TSR indicates the request for a time stamp. When TSR is asserted, the on-chip ADC
Control Logic returns a time stamp for the current conversion command after the conversion result is sent
to the RFIFOs. See Section 19.7.6.3, “Time Stamp Feature,” for details.
0 Return conversion result only.
1 Return conversion time stamp after the conversion result.
Field Description
FMT Conversion Data Format. FMT specifies to the EQADC how to format the 12-bit conversion data returned
by the ADCs into the 16-bit format which is sent to the RFIFOs. See Section 19.7.2.2.5, “ADC Result
Format for On-Chip ADC Operation,” for details.
0 Right justified unsigned.
1 Right justified signed.
CHANNEL_ Channel Number Field. The CHANNEL_NUMBER field selects the analog input channel. The software
NUMBER[0:7] programs this field with the channel number corresponding to the analog input pin to be sampled and
converted. See Section 19.7.7.1, “Channel Assignment,” for details.
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
CHANNEL_NUMBER ALT_CONFIG_SEL
ADC Command
Figure 19-47. Conversion Command Format for Alternate Configurations
Field Description
FFMT Flush or Format. The function of this bit depends on the DEST field of the Alternate Configuration Control
Register. If DEST is equal to 0b000, then FFMT defines the format in which the 12-bit conversion result are
stored in the RFIFOs. If DEST is not equal to 0b000, then the FFMT bit is used to send a flush (soft-reset)
signal through the parallel side interface to the companion module addressed by the DEST field.
In case DEST is not equal to 0b000, the FMTA bit in the Alternate Configuration Control register is used to
define the conversion result format.
0 Conversion Result Format set to right justified unsigned if DEST is equal to 0b000. No flush signal is
sent through the side interface if DEST is not equal to 0b000.
1 Conversion Result Format set to right justified signed if DEST is equal to 0b000. A flush signal is sent
through the side interface if DEST is not equal to 0b000.
Note: The flush signal can be asserted along with a valid conversion result. In this case the companion
module should execute the software-reset first and then consider the conversion result as a valid
data for the filtering algorithm.
ALT_CONFIG_SEL Alternate Configuration Selection. This field selects one of the alternate configurations.
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
ADC Command
Figure 19-48. Write Configuration Command Format for On-Chip ADC Operation
Field Description
EB Must be 0b0
BN Buffer Number Bit. Refer to Section 19.7.2.2.1, “Conversion Command Format for the Standard
Configuration.”
ADC_REGISTER_ ADC Register High Byte Field. REGISTER_HIGH_BYTE is the value to be written into the most significant
HIGH_BYTE[0:7] 8 bits of control/configuration register when the R/W bit is negated.
ADC_REGISTER_ ADC Register Low Byte Field. REGISTER_LOW_BYTE is the value to be written into the least significant
LOW_BYTE[0:7] 8 bits of a control/configuration register when the R/W bit is negated.
ADC_REG_ ADC Register Address. The ADC_REG_ADDRESS field selects a register on the ADC register set to be
ADDRESS[0:7] written or read. Only half-word addresses can be used.
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
RESERVED ADC_REG_ADDRESS
ADC Command
Figure 19-49. Read Configuration Command Format for On-Chip ADC Operation
Field Description
EB Must be 0b0
BN Buffer Number Bit. Refer to Section 19.7.2.2.1, “Conversion Command Format for the Standard
Configuration.”
R/W Read/Write bit. An asserted R/W bit indicates a read configuration command.
0 Write1Read
MESSAGE_ MESSAGE_TAG Field. Refer to Section 19.7.2.2.1, “Conversion Command Format for the
TAG[0:3] Standard Configuration.”
ADC_REG_ ADC Register Address. The ADC_REG_ADDRESS field selects a register on the ADC register set to be
ADDRESS[0:7] written or read. Only half-word addresses can be used.
• A conversion result, coming directly from the ADCs. In this case, the stored 16-bit data contains a
right justified 14-bit result data. The conversion result can be calibrated or not depending on the
status of CAL bit in the command that requested the conversion1. When the CAL bit is negated,
this 14-bit data is obtained by executing a 2-bit left-shift on the 12-bit data resultant from the
resolution adjustment on the 8 or 10 or 12-bit data received from the ADC. The resolution
adjustment consists of changing the conversion result input from 8, 10 or 12 bits right aligned to a
12-bit word left aligned - refer to Section 19.7.6.5, “ADC Resolution Selection Feature,” for
details. When the CAL bit is asserted, this 14-bit data is the result of the calculations performed in
the EQADC MAC unit using the 12-bit data result of the resolution adjustment and the calibration
constants GCC and OCC, or ALTGCC and ALTOCC - refer to Section 19.7.6.6, “ADC Calibration
Feature,” for details. Then, this 14-bit data is further formatted into a 16-bit format according to
the status of the FMT bit in conversion command of the standard configuration or FFMT bit in the
conversion command of the alternate configurations2. When FMT/FFMT is asserted, the 14-bit
result data is reformatted to look as if it was measured against an imaginary ground at VREF/2 (the
MSB bit of the 14-bit result is inverted), and is sign-extended to a 16-bit format as in Figure 19-50.
When FMT/FFMT is negated, the EQADC zero-extends the 14-bit result data to a 16-bit format as
in Figure 19-51. Correspondence between the analog voltage in a channel and the calculated digital
values is shown in Table 19-40.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
ADC Result
Figure 19-50. ADC Result Format when FMT=1 (Right Justified Signed)
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
ADC Result
Figure 19-51. ADC Result Format when FMT=0 (Right Justified Unsigned)
1. In case the conversion result is routed through an on-chip DSP via side interface, the calibration is applied before the data
is sent to the DSP.
2. For simplicity, the following text will refer to FMT only, but when using alternate configurations, refer to Section 19.7.2.2.2,
“Conversion Command Format for Alternate Configurations.”
Field Description
SIGN_EXT[0:1] Sign Extension field. SIGN_EXT only has meaning when FMT is asserted. SIGN_EXT is 0b00 when
CONVERSION_RESULT is positive, and 0b11 when CONVERSION_RESULT is negative.
CONVERSION_ Conversion Result field. CONVERSION_RESULT is a digital value corresponding to the analog input
RESULT[0:13] voltage in a channel when the conversion command was initiated. The two’s complement representation
is used to express negative values.
1
VREF=VRH-VRL=5.12V. Resulting in one 12-bit count (LSB) =1.25mV.
2
The two’s complement representation is used to express negative values.
3
For non-corner voltages (voltages different from VRL and VRH), the maximum quantization error is 0.5 LSB. First
code transition (from 0x000 to 0x001 for unsigned values) happens at +0.5 LSB (V) while the last one (from 0xFFE
to 0xFFF for unsigned values) happens at VREF - 1.5 LSB (V).
4
For non-corner voltages (voltages different from VRL and VRH), the maximum quantization error is 0.5 LSB. First
code transition (from 0x000 to 0x001 for unsigned values) happens at +0.5 LSB (V) while the last one (from 0xFFE
to 0xFFF for unsigned values) happens at VREF - 1.5 LSB (V).
5
For non-corner voltages (voltages different from VRL and VRH), the maximum quantization error is 0.5 LSB. First
code transition (from 0x000 to 0x001 for unsigned values) happens at +0.5 LSB (V) while the last one (from 0xFFE
to 0xFFF for unsigned values) happens at VREF - 1.5 LSB (V).
6
Assuming uncalibrated conversion results.
NOTE
Only whole words must be written to EQADC_CFPR. Writing half-words
or bytes to EQADC_CFPR will still push the whole 32-bit CF_PUSH field
into the corresponding CFIFO, but undefined data will fill the areas of
CF_PUSH that were not specifically designated as target locations for
writing.
Figure 19-52 describes the important components in the CFIFO. Each CFIFO is implemented as a circular
set of registers to avoid the need to move all entries at each push/pop operation. The Push Next Data
Pointer points to the next available CFIFO location for storing data written into the EQADC Command
FIFO Push Register. The Transfer Next Data Pointer points to the next entry to be removed from CFIFOx
when it completes a transfer. The CFIFO Transfer Counter Control Logic counts the number of entries in
the CFIFO and generates DMA or interrupt requests to fill the CFIFO. TNXTPTR in EQADC_FISR,
indicates the index of the entry that is currently being addressed by the Transfer Next Data Pointer, and
CFCTR, in the same register, provides the number of entries stored in the CFIFO. Using TNXTPTR and
CFCTR, the absolute addresses for the entries indicated by the Transfer Next Data Pointer and by the Push
Next Data Pointer can be calculated using the following formulas:
Transfer Next Data Pointer Address = CFIFOx_BASE_ADDRESS + TNXTPTRx*4
Push Next Data Pointer Address = CFIFOx_BASE_ADDRESS +
[(TNXTPTRx+CFCTRx) mod CFIFO_DEPTH] * 4
where
• a mod b returns the remainder of the division of a by b.
• CFIFOx_BASE_ADDRESS is the smallest memory mapped address allocated to a CFIFOx entry.
• CFIFO_DEPTH is the number of entries contained in a CFIFO - four in this implementation.
When CFSx in EQADC_CFSR is TRIGGERED, the EQADC generates the proper control signals for the
transfer of the entry pointed by Transfer Next Data Pointer. CFUFx in EQADC_FISR is set when a
CFIFOx underflow event occurs. A CFIFO underflow occurs when the CFIFO is in TRIGGERED state
and it becomes empty. No commands will be transferred from an underflowing CFIFO, nor will command
transfers from lower priority CFIFOs be blocked. CFIFOx is empty when the Transfer Next Data Pointer
x equals the Push Next Data Pointer x and CFCTRx is zero. CFIFOx is full when the Transfer Next Data
Pointer x equals the Push Next Data Pointer x and CFCTRx is not zero.
When the EQADC completes the transfer of an entry from CFIFOx: the transferred entry is popped from
CFIFOx, the CFIFO counter CFCTR in the EQADC_FISR is decremented by one, and Transfer Next Data
Pointer x is incremented by one (or wrapped around) to point to the next entry in the CFIFO. The transfer
of entries bound for the on-chip ADCs is considered completed when they are stored in the appropriate
CBuffer.
When the EQADC_CFPRx is written and CFIFOx is not full, the CFIFO counter CFCTRx is incremented
by one, and the Push Next Data Pointer x then is incremented by one (or wrapped around) to point to the
next entry in the CFIFO.
When the EQADC_CFPRx is written but CFIFOx is full, the EQADC will not increment the counter value
and will not overwrite any entry in CFIFOx.
Write to slave-bus
interface by CPU or
DMA
CFIFO
Push Register
Control
Signals
The detailed behavior of the Push Next Data Pointer and Transfer Next Data Pointer is described in the
example shown in Figure 19-53 where a CFIFO with 16 entries is shown for clarity of explanation, the
actual hardware implementation has only four entries. In this example, CFIFOx with 16 entries is shown
in sequence after pushing and transferring entries.
Empty Entry
Last In Last In
Push Push
Next Next
Data Data
Pointer Pointer
First In Transfer
Last In Last In Next
Push First In Transfer Push Data
Next Next Next Pointer
Data Data Data
Pointer Pointer Pointer
Last In
First In Transfer Push
Next Next
Data Data
Pointer Pointer
NOTE: x=0, 1, 2, 3, 4, 5
Streaming mode requires 2 trigger inputs. The standard queue 0 trigger, in this mode referred to as Repeat
Trigger and a new internal trigger input to the eQADC called Advance Trigger (no filter available).
CFIFO0 is configured to operate in streaming mode by setting the bit STRME0 as described in
Section 19.6.2.5, “EQADC CFIFO Control Registers (EQADC_CFCR).” CFIFO0 is eight entries deep in
extended mode by setting the bit CFEEE0 in the same EQADC_CFCR register, and each entry is 32 bits
long. This CFIFO0 serves as a local storage of a few commands that need to be executed sequentially as
in a FIFO but can contain sub-queues that need to be executed several times. The CFFF0 bit in
Section 19.6.2.7, “EQADC FIFO and Interrupt Status Registers (EQADC_FISR),” is used to assure the
CFIFO0 is not full and command messages are stored from address 0x0 to 0x7.
Advance trigger is used to advance the pop pointer beyond some loop sub-queue. And it is to disable the
Repeat trigger by executing a Pause without a previous REP bit.
In Streaming mode, the CFIFO0 is filled with CCWs using the DMA as usual. The two triggers are
configured to positive edge and single scan mode.
The SSS bit is asserted and the trigger detector of the Repeat trigger is disabled in the start of the queue.
It is necessary to receive the first Advance trigger to enable the detector of the other trigger. This enable
is useful when the Repeat trigger is received all the time and the trigger signal can be disabled when it is
not desired.
The Advance trigger is received and detected and the Repeat trigger detector is enabled. No commands are
executed until now.
The Repeat trigger is detected and the commands start to be executed in sequence. If a REP bit is decoded
with the PAUSE bit, the loop is configured and the CFIFO0 commands stop to be executed. The next
Repeat trigger is waited to start the execution of the loop again, or the Advance trigger can be detected to
break the loop and advance the queue in CFIFO0. The Repeat trigger detector remains enabled.
If the Advance trigger is received and the next command in the CFIFO0 does not present the REP bit set,
this means the CFIFO0 is not starting a new loop. In this case (outside a loop) if a PAUSE bit is decoded,
this means to disable the Repeat trigger detector. This can be useful if the Repeat trigger is not required for
some interval of time. The Repeat trigger detector is enabled again when the next Advance trigger event
is detected.
Write to slave-bus
interface by CPU or
DMA
CFIFO Repeat
Push Register Pointer
The detailed behavior of the Push Next Data Pointer and Transfer Next Data Pointer is described in the
example shown in Figure 19-55 where a CFIFO with 16 entries is shown for clarity of explanation, the
actual hardware implementation has only four/eight entries. In this example, CFIFO0 with 16 entries is
shown in sequence after pushing and transferring entries.
Pause Pause
Valid Entry Transfer
Next
Data
Pointer
Empty Entry
Last In Last In
Push Push
Next Next
Data Data
Pointer Pointer
CFIFO0 CFIFO0
Push
Next Last In
Data
Pointer
Last In
Repeat Push Repeat
Repeat Repeat
Pointer Next Pointer
Data
Pointer
Pause Pause
Transfer Transfer
Next Next
Data Data
Pointer Pointer
priority CFIFO is always served first. A TRIGGERED, not-underflowing CFIFO will start the transfer of
its commands when:
• its commands are bound for an internal CBuffer that is not full, and it is the highest priority
triggered CFIFO sending commands to that CBuffer.
A triggered CFIFO with commands bound for a certain CBuffer consecutively transfers its commands to
it until:
• an asserted End Of Queue bit is reached, or;
• an asserted Pause bit is encountered and the CFIFO is configured for edge trigger mode, or;
• CFIFO is configured for level trigger mode and a closed gate is detected, or;
• in case its commands are bound for an internal CBuffer, a higher priority CFIFO that uses the same
internal CBuffer is triggered, or;
The prioritization logic of the EQADC, depicted in Figure 19-57, is composed of two independent
sub-blocks: one prioritizing CFIFOs with commands bound for CBuffer0 and another prioritizing CFIFOs
with commands for CBuffer1. As these sub-blocks are independent, simultaneous writes to CBuffer0 and
CBuffer1. The hardware identifies the destination of a command by decoding the BN bit in the command
message - see Section 19.7.2.2, “Message Format in EQADC,” for details.
NOTE
Triggered but empty CFIFOs, underflowing CFIFOs, are not considered for
prioritization. No data from these CFIFOs will be sent to the CBuffers and
nor will they stop lower priority CFIFOs from transferring commands.
Whenever CBuffer0 is able to receive new entries, the prioritization sub-block selects the highest-priority
triggered CFIFO with a command bound for CBuffer0, and writes its command into the buffer. In case
CBuffer0 is able to receive new entries but there are no triggered CFIFOs with commands bound for it,
nothing is written to the buffer. The sub-block prioritizing CBuffer1 usage behaves in the same way.
EQADC
Prioritization Logic
CBuffer0 Abort Command
CFIFO0
(2 entries) Cont0
Prioritization
Command
ADC0 for CBuffer0
Usage
Command CFIFO1
Command CFIFO4
Command CFIFO5
Peripheral Clock
Filtered External
Trigger Signal Trigger Detection Delay
Notes:
1. This delay is about 2 clocks when the filter bypass control is asserted.
rearm the CFIFO to detect new trigger events, upon detection of an asserted EOQ bit in the last transfer.
Refer to Section 19.7.2.2, “Message Format in EQADC,” for details about command formats.
CFIFOs can be configured in single-scan or continuous-scan mode. When a CFIFO is configured in
single-scan mode, the EQADC scans the CQueue one time. The EQADC stops future command transfers
from the triggered CFIFO after detecting the EOQ bit set in the last transfer. After a EOQ bit is detected,
software involvement is required to rearm the CFIFO so that it can detect new trigger events.
When a CFIFO is configured for continuous-scan mode, no software involvement is necessary to rearm
the CFIFO to detect new trigger events after an asserted EOQ is detected. In continuous-scan mode the
whole CQueue is scanned multiple times.
The EQADC also supports different triggering mechanisms for each scan mode. The EQADC will not
transfer commands from a CFIFO until the CFIFO is triggered. The combination of scan modes and
triggering mechanisms allows the support of different requirements for scanning input channels. The scan
mode and trigger mechanism are configured by programming the MODEx field in Section 19.6.2.5,
“EQADC CFIFO Control Registers (EQADC_CFCR).”
Enabled CFIFOs can be triggered by software or external trigger events. The elapsed time from detecting
a trigger to transferring a command is a function of clock frequency, trigger synchronization, trigger
filtering or not, programmable trigger events, command transfer, CFIFO prioritization, CBuffer
availability, etc. Fast and predictable transfers can be achieved by ensuring that the CFIFO is not
underflowing and that the target CBuffer is not full when the CFIFO is triggered.
• The SSS bit in Section 19.6.2.7, “EQADC FIFO and Interrupt Status Registers (EQADC_FISR),”
is negated. The SSS bit can be set even if a “1” is written to the SSE bit in Section 19.6.2.5,
“EQADC CFIFO Control Registers (EQADC_CFCR),” in the same write that the MODEx field is
changed to a value other than disabled.
• The trigger detection hardware is reset. If MODEx is changed from disabled to an edge trigger
mode, a new edge, matching that edge trigger mode, is needed to trigger the command transfers
from the CFIFO.
NOTE
CFIFO fill requests, which generated when CFFF is asserted, are not
automatically halted when MODEx is changed to disabled. CFIFO fill
requests will still be generated until CFFE is cleared in Section 19.6.2.6,
“EQADC Interrupt and DMA Control Registers (EQADC_IDCR).”
The CFIFO commands start to be transferred when the CFIFO becomes the highest priority CFIFO using
a not-full on-chip CBuffer or an not-full external CBuffer.
When an asserted EOQ bit is encountered, the EQADC clears SSS and stops command transfers from the
CFIFO. An asserted SSS bit and a subsequent edge trigger event are required to start the next scan for the
CFIFO. When an asserted Pause bit is encountered, the EQADC stops command transfers from the CFIFO,
but SSS remains set. Another edge trigger event is required for command transfers to continue. A trigger
overrun happens when the CFIFO is in TRIGGERED state and an edge trigger event is detected.
When an EOQ or a Pause is encountered, the EQADC halts command transfers from the CFIFO and, if
enabled, the appropriate interrupt requests are generated. Another edge trigger event is required to resume
command transfers but no software involvement is required to rearm the CFIFO in order to detect such
event.
A trigger overrun happens when the CFIFO is already in TRIGGERED state and a new edge trigger event
is detected.
Requires
Stop on Stop on
Asserted SSS Command Transfer
asserted asserted Other Command Transfer Stop
Trigger Mode to Recognize Start/Restart
EOQ Pause Condition3 4
Trigger Condition
bit1? bit2?
Events?
Single Scan Don’t Care Asserted SSS bit. Yes No None.
Software
Single Scan Yes A corresponding edge Yes Yes None.
Edge occurs.
Single Scan Yes Gate is opened. Yes No EQADC also stops transfers
Level from the CFIFO when CFIFO
status changes from
TRIGGERED due to the
detection of a closed gate.5
Continuous No CFIFO starts No No None.
Scan Software automatically after
being configured into
this mode.
Continuous No A corresponding edge Yes Yes None.
Scan Edge occurs.
Table 19-41. CFIFO Scan Trigger Mode - Command Transfer Start/Stop Summary (continued)
Requires
Stop on Stop on
Asserted SSS Command Transfer
asserted asserted Other Command Transfer Stop
Trigger Mode to Recognize Start/Restart
EOQ Pause Condition3 4
Trigger Condition 1? 2
bit bit ?
Events?
Continuous No Gate is opened. No No EQADC also stops transfers
Scan Level from the CFIFO when CFIFO
status changes from
TRIGGERED due to the
detection of a closed gate.5
1
Refer to Section 19.7.4.7.2, “CQueue Completion Status,” for more information on EOQ.
2
Refer to Section 19.7.4.7.3, “Pause Status,” for more information on Pause.
3
EQADC always stops command transfers from a CFIFO when the CFIFO operation mode is disabled.
4
EQADC always stops command transfers from a CFIFO when a higher priority CFIFO is triggered. Refer to
Section 19.7.4.3, “CFIFO Common Prioritization and Command Transfer,” for information on CFIFO priority.
5
If a closed gate is detected while no command transfers are taking place, it will have immediate effect on the
CFIFO status. If a closed gate is detected during the serial transmission of a command to the external device,
it will have no effect on the CFIFO status until the transmission completes.
2 IDLE
7
4
WAITING 6 TRIGGERED
FOR
TRIGGER 8
9
5
Figure 19-59. State Machine of CFIFO Status
From Current
To New CFIFO
No. CFIFO Status Status Switching Condition
Status (CFS)
(CFS)
1 IDLE (00) IDLE (0b00) — CFIFO Mode is programmed to disabled, OR
— CFIFO Mode is programmed to single-scan edge or level
trigger mode and SSS is negated.
2 WAITING FOR — CFIFO Mode is programmed to continuous-scan edge or
TRIGGER (0b10) level trigger mode, OR
— CFIFO Mode is programmed to single-scan edge or level
trigger mode and SSS is asserted, OR
— CFIFO Mode is programmed to single-scan software trigger
mode.
3 TRIGGERED — CFIFO Mode is programmed to continuous-scan software
(0b11) trigger mode
4 WAITING FOR IDLE (0b00) — CFIFO Mode is modified to disabled mode.
5 TRIGGER (10) WAITING FOR — No trigger occurred.
TRIGGER (0b10)
6 TRIGGERED — Appropriate edge or level trigger occurred, OR
(0b11) — CFIFO Mode is programmed to single-scan software trigger
mode and SSS bit is asserted.
From Current
To New CFIFO
No. CFIFO Status Status Switching Condition
Status (CFS)
(CFS)
7 TRIGGERED (11) IDLE (0b00) — CFIFO in single-scan mode, EQADC detects the EOQ bit
asserted at end of command transfer, and CFIFO Mode is not
modified to disabled.OR
— CFIFO, in single-scan level trigger mode, and the gate
closes while no commands are being transferred from the
CFIFO, and CFIFO Mode is not modified to disabled. OR
— CFIFO, in single-scan level trigger mode, and EQADC
detects a closed gated at end of command transfer, and CFIFO
Mode is not modified to disabled. OR
— CFIFO Mode is modified to disabled mode and CFIFO was
not transferring commands.
—CFIFO Mode is modified to disabled mode while CFIFO was
transferring commands, and CFIFO completes or aborts the
transfer.
8 WAITING FOR — CFIFO in single or continuous-scan edge trigger mode,
TRIGGER (0b10) EQADC detects the Pause bit asserted at the end of command
transfer, the EOQ bit in the same command is negated, and
CFIFO Mode is not modified to disabled, OR
— CFIFO in continuous-scan edge trigger mode, EQADC
detects the EOQ bit asserted at the end of command transfer,
and CFIFO Mode is not modified to disabled, OR
— CFIFO, in continuous-scan level trigger mode, and the gate
closes while no commands are being transferred from the
CFIFO, and CFIFO Mode is not modified to disabled, OR
— CFIFO, in continuous-scan level trigger mode, and EQADC
detects a closed gated at end of command transfer, and CFIFO
Mode is not modified to disabled.
9 TRIGGERED — No event to switch to IDLE or WAITING FOR TRIGGER
(0b11) status has happened.
NOTE
An asserted EOQFx only implies that EQADC has finished transferring a
command with an asserted EOQ bit from CFIFOx. It does not imply that
result data for the current command and for all previously transferred
commands has been returned to the appropriate RFIFO.
NOTE
The trigger overrun flag will not set for CFIFOs configured for software
trigger mode.
Example 1
Example 2
Example 3
CFx_CBa_CMn - Command n in CFIFOx bound for CBuffera
The NCF flag is used to indicate command sequence non-coherency. When the NCFx flag is asserted, it
indicates that the command sequence being transferred through CFIFOx became non-coherent. The NCF
flag only becomes asserted for CFIFOs in TRIGGERED state.
A command sequence is non-coherent when, after transferring the first command of a sequence from a
CFIFO to a CBuffer, it cannot successively send all the other commands of the sequence before any of the
following conditions are true:
• The CFIFO through which commands are being transferred is preempted by a higher priority
CFIFO which sends commands to the same CBuffer. The NCF flag becomes asserted immediately
after the first command transfer from the preempting CFIFO, that is the higher priority CFIFO, to
the CBuffer in use is completed. See Figure 19-61.
Once command transfers restart/continue, the non-coherency hardware will behave as if the command
sequence started from that point. Figure 19-62 depicts how the non-coherency hardware will behave when
a non-coherency event is detected.
NOTE
If MODEx is changed to disabled while a CFIFO is transferring commands,
the NCF flag for that CFIFO will not become asserted.
CFIFO0
0 CF0_CB1_CM0 TNXTPTR *
1 CF0_CB1_CM1
2 CF0_CB1_CM2
CBuffer1 3 CF0_CB1_CM3
0 EMPTY
1 EMPTY CFIFO5
0 CF5_CB1_CM0 TNXTPTR *
1 CF5_CB1_CM1
2 CF5_CB1_CM2
3 CF5_CB1_CM3
(a) CFIFO0 and CFIFO5 both have commands to be sent to CBuffer1, and both are not triggered
CFIFO0
0 CF0_CB1_CM0 TNXTPTR *
1 CF0_CB1_CM1
2 CF0_CB1_CM2
CBuffer1 3 CF0_CB1_CM3
0 CF5_CB1_CM0
1 CF5_CB1_CM1 CFIFO5
0 Sent
1 Sent
2 CF5_CB1_CM2 TNXTPTR *
3 CF5_CB1_CM3
CFIFO0
0 Sent
1 CF0_CB1_CM1 TNXTPTR *
2 CF0_CB1_CM2
CBuffer1 3 CF0_CB1_CM3
0 CF5_CB1_CM1
1 CF0_CB1_CM0 CFIFO5
0 Sent
1 Sent
2 CF5_CB1_CM2 TNXTPTR *
3 CF5_CB1_CM3
(c) CFIFO0 becomes triggered and transfers a command to CBuffer1. The sequence sent through
CFIFO5 becomes non-coherent.
Figure 19-61. Non-Coherency Event when Different CFIFOs use the same CBuffer
CF5_CB1_CM0
CF5_CB1_CM1
CF5_CB1_CM2
CF5_CB1_CM3 Command sequence became non-coherent before command 4
was transferred. Once command transfers are resumed, EQADC
CF5_CB1_CM4 will only check for coherency after command 4.
CF5_CB1_CM5
CF5_CB1_CM6
CF5_CB1_CM7
CF5_CB1_CM8
CF5_CB1_CM9
CF5_CB1_CM10 Command sequence became non-coherent before command 11
was transferred. Once command transfers are resumed, EQADC
CF5_CB1_CM11 will only check for coherency after command 11.
CF5_CB1_CM12
CF5_CB1_CM13
Figure 19-62. Non-coherency Detection when Transfers from a Command Sequence are Interrupted
The Receive Next Data Pointer points to the next available RFIFO location for storing the next incoming
message from the on-chip ADCs. The RFIFO Counter Logic counts the number of entries in RFIFO and
generates interrupt or DMA requests to drain the RFIFO.
POPNXTPTR in Section 19.6.2.7, “EQADC FIFO and Interrupt Status Registers (EQADC_FISR),”
indicates which entry is currently being addressed by the Pop Next Data Pointer, and RFCTR, in the same
register, provides the number of entries stored in the RFIFO. Using POPNXTPTR and RFCTR, the
absolute addresses for Pop Next Data Pointer and Receive Next Data Pointer can be calculated using the
following formulas:
Pop Next Data Pointer Address= RFIFOx_BASE_ADDRESS + POPNXTPTRx*4
Receive Next Data Pointer Address = RFIFOx_BASE_ADDRESS +
[(POPNXTPTRx+RFCTRx) mod RFIFO_DEPTH] * 4
where
• a mod b returns the remainder of the division of a by b.
• RFIFOx_BASE_ADDRESS is the smallest memory mapped address allocated to an RFIFOx
entry.
• RFIFO_DEPTH is the number of entries contained in a RFIFO - four in this implementation.
When a new message arrives and RFIFOx is not full, the EQADC copies its contents into the entry pointed
by the Receive Next Data Pointer. The RFIFO counter RFCTRx in Section 19.6.2.7, “EQADC FIFO and
Interrupt Status Registers (EQADC_FISR),” is incremented by one, and the Receive Next Data Pointer x
is also incremented by one (or wrapped around) to point to the next empty entry in RFIFOx. However, if
the RFIFOx is full, the EQADC sets the RFOF in Section 19.6.2.7, “EQADC FIFO and Interrupt Status
Registers (EQADC_FISR).” The RFIFOx will not overwrite the older data in the RFIFO, the new data will
be ignored, and the Receive Next Data Pointer x is not incremented or wrapped around. RFIFOx is full
when the Receive Next Data Pointer x equals the Pop Next Data Pointer x and RFCTRx is not zero.
RFIFOx is empty when the Receive Next Data Pointer x equals the Pop Next Data Pointer x and RFCTRx
is zero.
When the EQADC RFIFO Pop Register x is read and the RFIFOx is not empty, the RFIFO counter
RFCTRx is decremented by one, and the POP Next Data Pointer is incremented by one (or wrapped
around) to point to the next RFIFO entry.
When the EQADC RFIFO Pop Register x is read and RFIFOx is empty, EQADC will not decrement the
counter value and the POP Next Data Pointer x will not be updated. The read value will be undefined.
Read from
slave-bus interface
by CPU or DMA
RFIFO
Pop Register
Receive Next
Data Pointer *
POP Next
Data Pointer * -------------------- Data from
on-chip
-------------------- ADCs or from
Data Entry 1 parallel
side interface
Data Entry 2
Control
Signals
* All RFIFO entries are memory mapped and the entries addressed by
these pointers can have their absolute addresses calculated using
POPNXTPTR and RFCTR.
The detailed behavior of the Pop Next Data Pointer and Receive Next Data Pointer is described in the
example shown in Figure 19-64 where an RFIFO with 16 entries is shown for clarity of explanation, the
actual hardware implementation has only four entries. In this example, RFIFOx with 16 entries is shown
in sequence after popping or receiving entries.
Empty Entry
First In Pop
Receive Last In Receive Last In Next
Next First In Pop Next Data
Data Next Data Pointer
Pointer Data Pointer
Pointer
Receive Last In
First In Pop Next
Next Data
Data Pointer
Pointer
NOTE: x=0, 1, 2, 3, 4, 5
defining what should be done with the received data. The EQADC hardware decodes the
MESSAGE_TAG / MESSAGE_TAG2 and DEST / DEST2 fields and:
• stores the 16-bit data into the appropriate RFIFO if the MESSAGE_TAG / MESSAGE_TAG2
indicates a valid RFIFO number, or;
• sends the 16-bit data, the MESSAGE_TAG / MESSAGE_TAG2 and the DEST / DEST2 data to an
on-chip companion module (decimation filter), or;
• ignores the data in case of a null or “reserved for customer use” MESSAGE_TAG /
MESSAGE_TAG2.
In general received data is moved into RFIFOs as they become available, while an exception happens when
multiple results from different sources become available at the same time. In that case, result data from
ADC0 is processed first, result data from ADC1 is only process after all ADC0 data is processed, and
finally returned data from the companion module is processed (after all data from ADC0/1 is processed).
When time-stamped results return from the on-chip ADCs, the conversion result and the time stamp are
always moved to the RFIFOs in consecutive clock cycles in order to guarantee they are always stored in
consecutive RFIFO entries.
NOTE
Due to legacy reasons, the EQADC will always wait 120 ADC clocks before
issuing the first conversion command following the enabling of one of
on-chip ADCs, or the exiting of stop mode. There are two independent
counters checking for this delay: one clocked by ADC0_CLK and another
by ADC1_CLK. Conversion commands can start to be executed whenever
one of these counters completes counting 120 ADC clocks.
SystemClockFrequency MHz
ADCClockFrequency = ---------------------------------------------------------------------------------- ; ADCClockFrequency 15MHz
SystemClockDivideFactor
Figure 19-65 depicts how the ADC clocks for ADC0 and ADC1 are generated.
Divide by:
Peripheral Clock 2, 4, 6, .. , 60, 62, 64
ADC0Clock
SEL To ADC0
Peripheral Clock Divider
Divide by:
Peripheral Clock 2, 4, 6, .. , 60, 62, 64
ADC1Clock
SEL To ADC1
Peripheral Clock Divider
The ADC conversion speed (in K samples per second - Ksps) is calculated by the following formula. The
number of sampling cycles is determined by the LST bits in the command message - see Section 19.7.2.2.1,
“Conversion Command Format for the Standard Configuration” - and it can take one of the following
values: 2, 8, 64, or 128 ADC clock cycles. The number of AD conversion cycles is 13 for differential
conversions and 14 for single-ended conversions (12 bits resolution and unitary input gain). The maximum
conversion speed is achieved when the ADC Clock frequency is set to its maximum, the number of
sampling cycles set to its minimum (2 cycles), and the resolution is also set to the minimum (8 bits) with
input unitary gain.
ADCClockFrequency MHz
ADCConversionSpeed = ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------
NumberOfSamplingCycles + NumberOfADConversionCycles
Table 19-43 shows an example of how the ADC0/1_CLK_PS can be set when using a 120 MHz peripheral
clock and the corresponding conversion speeds for all possible ADC clock frequencies. The table also
shows that according to the peripheral clock frequency, certain clock divide factors are invalid (2, 4, 6, 8
clock divide factors in the example) since their use would result in a ADC clock frequency higher than the
maximum one supported by the ADC. In this example, the maximum ADC clock frequency is 15 MHz (12
bits resolution conversions with unitary input gain).
Table 19-43. ADC Clock Configuration Example (Peripheral Clock Frequency=120 MHz)
Differential Single-Ended
Peripheral ADC Clock
Conversion Speed Conversion Speed
ADC0/1_CLK_PS[0:4] Clock Divide (Peripheral
with Default Sampling with Default Sampling
Factor Clock = 120 MHz)
Time (2 cycles) Time (2 cycles)
0b00000 2 N/A N/A N/A
0b00001 4 N/A N/A N/A
0b00010 6 N/A N/A N/A
0b00011 8 15.0 MHz 1.0 Msps 938 Ksps
0b00100 10 12.0 MHz 800 Ksps 750 Ksps
0b00101 12 10.0 MHz 667 Ksps 625 Ksps
0b00110 14 8.57 MHz 571 Ksps 536 Ksps
0b00111 16 7.5 MHz 500 Ksps 469 Ksps
0b01000 18 6.67 MHz 444 Ksps 417 Ksps
0b01001 20 6.0 MHz 400 Ksps 375 Ksps
0b01010 22 5.45 MHz 364 Ksps 341 Ksps
0b01011 24 5.0 MHz 333 Ksps 313 Ksps
0b01100 26 4.62 MHz 308 Ksps 288 Ksps
0b01101 28 4.29 MHz 286 Ksps 268 Ksps
0b01110 30 4.0 MHz 267 Ksps 250 Ksps
0b01111 32 3.75 MHz 250 Ksps 234 Ksps
0b10000 34 3.53 MHz 235 Ksps 221 Ksps
0b10001 36 3.33 MHz 222 Ksps 208 Ksps
0b10010 38 3.16 MHz 211 Ksps 198 Ksps
0b10011 40 3.0 MHz 200 Ksps 188 Ksps
0b10100 42 2.86 MHz 190 Ksps 179 Ksps
Table 19-43. ADC Clock Configuration Example (Peripheral Clock Frequency=120 MHz)
Differential Single-Ended
Peripheral ADC Clock
Conversion Speed Conversion Speed
ADC0/1_CLK_PS[0:4] Clock Divide (Peripheral
with Default Sampling with Default Sampling
Factor Clock = 120 MHz)
Time (2 cycles) Time (2 cycles)
0b10101 44 2.73 MHz 182 Ksps 170 Ksps
0b10110 46 2.61 MHz 174 Ksps 163 Ksps
0b10111 48 2.5 MHz 167 Ksps 156 Ksps
0b11000 50 2.4 MHz 160 Ksps 150 Ksps
0b11001 52 2.31 MHz 154 Ksps 144 Ksps
0b11010 54 2.22 MHz 148 Ksps 139 Ksps
0b11011 56 2.14 MHz 143 Ksps 134 Ksps
0b11100 58 2.07 MHz 138 Ksps 129 Ksps
0b11101 60 2.0 MHz 133 Ksps 125 Ksps
0b11110 62 1.94 MHz 129 Ksps 121 Ksps
0b11111 64 1.88 MHz 125 Ksps 117 Ksps
RedBS2
SRV23 SRV22 SRV21 SRV20
The Red Line data stream is composed by several identified time slots. Each time slot contains a time value
from a specified source. The bits SRV1/2[0:3] in register EQADC_REDLCCR are used to select the
desired time slots of the Red-line bus to be used internally by the EQADC. Figure 19-67 shows a timing
diagram for the REDLC.
Red-line bus (REDLC input) TS[00] TS[01] TS[02] TS[n]1 TS[00] TS[01] TS[02]
Figure 19-67. Timing diagram for the Red Line bus and REDLC output
Every time the selected time slot change, the REDLC outputs are updated. As this time base is an external
data to the EQADC, this output is not affected by the stop or by the debug internal state.
After the slot selection is done and the timebase data is extracted, the REDBS1/2 bits select 16 bits from
the original 24-bit timebase data. These selected bits are the timebase to be used internal to the EQADC.
19.7.6.6.1 Overview
There are three sets of calibration coefficients for each ADC. Each set is composed by a gain factor and
an offset factor: GCCn/OCCn, ALTGCCn1/ALTGCCn1, and ALTGCCn2/ALTGCCn2, where n is the
ADC number 0 or 1. The pair GCCn/OCCn is selected when it is used the normal configuration or the
alternate configurations 3 to 14. The pair ALTGCCn1/ALTGCCn1 is used only when the alternate
configuration 1 is selected. And the pair ALTGCCn2/ALTGCCn2 is for the alternate configuration 2. The
description below is for a generic pair of gain/offset GCC/OCC.
The EQADC provides a calibration scheme to remove the effects of gain and offset errors from the results
generated by the on-chip ADCs. Only results generated by the on-chip ADCs are calibrated. The results
generated by ADCs on the external device are directly sent to RFIFOs unchanged. The main component
of calibration hardware is a Multiply-and-Accumulate (MAC) unit, one per on-chip ADC, that is used to
calculate the following transfer function which relates a calibrated result to a raw, uncalibrated one.
CAL_RES = GCC * RAW_RES + OCC+2;
where:
• CAL_RES is the calibrated result corresponding the input voltage Vi.
• GCC is the gain calibration constant.
• RAW_RES is the raw, uncalibrated result with resolution adjustment corresponding to an specific
input voltage Vi.
• OCC is the offset calibration constant.
• The addition of two reduces the maximum quantization error of the ADC. See Section 19.8.6.3,
“Quantization Error Reduction During Calibration.”
Calibration constants GCC and OCC are determined by taking two samples of known reference voltages
and using these samples to calculate the values for the constants. For details and an example about how to
calculate the calibration constants and use them in result calibration refer to Section 19.8.6, “ADC Result
Calibration.” Once calculated, GCC is stored in the Section 19.6.3.4, “ADC0/1 Gain Calibration Constant
Registers (ADC0_GCCR and ADC1_GCCR),” and OCC in Section 19.6.3.5, “ADC0/1 Offset Calibration
Constant Registers (ADC0_OCCR and ADC1_OCCR),” from where their values are fed to the MAC unit.
The alternate gain values are stored in Section 19.6.3.7, “ADC0/1 Alternate Gain Registers
(ADC0_AGR1-2 and ADC1_AGR1-2),” and the alternate offset values in Section 19.6.3.8, “ADC0/1
Alternate Offset Register (ADC0_AOR1-2 and ADC1_AOR1-2).” Since the analog characteristics of each
on-chip ADCs differs, each ADC has an independent pair of calibration constants.
A conversion result is calibrated according to the status of CAL bit in the command that initiated the
conversion. If the CAL bit is asserted, the EQADC will automatically calculate the calibrated result before
sending the result to the appropriate RFIFO or companion module. If the CAL bit is negated, the result is
not calibrated, it bypasses the calibration hardware, and is directly sent to the appropriate RFIFO or
companion module.
+
Gain Calibration Constant (GCC0/1)
(15-bit fixed point unsigned value
from ADC0/1_GCCR register) 2
MAC Unit
Figure 19-68. MAC Unit Diagram
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14
GCC_INT GCC_FRAC
GCC[1] GCC[2:15]
Figure 19-69. Gain Calibration Constant Format
Gain Constant
Corresponding Decimal Value
(GCC_INT.GCC_FRAC binary format)
0.0000_0000_0000_00 0
... ...
0.1000_0000_0000_00 0.5
... ...
0.1111_1111_1111_11 0.999938...
1.0000_0000_0000_00 1
... ...
1.1100_0000_0000_00 1.75
... ...
1.1111_1111_1111_11 1.999938...
1. The result messages may also be routed to an on-chip companion module via the side interface, and then fed back to the
RFIFOs.
to provide precise conversion intervals, which means the time intervals between two consecutive
conversions are the same. This is important for any digital signal process application.
When the on-chip ADC abort feature is enabled, ADC Commands from CFIFO0 should be considered
immediately, even stopping the execution of some command that is already in ENTRY1. When the abort
request is sent to the ADC, the already stored commands in the CBuffers are copied in a temporary set of
registers. The first ADC command from CFIFO0 is sent after the abort acknowledge indication from ADC.
The process is the same as usual until the transfer of the last command from CFIFO0. Then the temporarily
stored commands that were postponed by the abortion are recovered and they are pipelined for execution.
After the last command from this temporary memory is transferred, the next commands are pipelined from
the CFIFOs.
ENTRY1
ENTRY0
AN0-AN39 LST0 Abort
ADC0 Cont
CBuffer0 32 bits
CBuffer1
MUX 40:1
LST1
ENTRY1
ENTRY0
Result0 Resolution
Adjust
EMUX0 EMUX1 Result1 Resolution
Result
Adjust
Format
CHANNEL_NUMBER0
MUX
CHANNEL_NUMBER1
MA0, MA1, MA2 Control
Logic
ADC0_Result0 RFIFOx
TSR0 ADC1_Result1
TSR1
Time Time Stamp 0
Stamp Time Stamp1 16 bits
Logic
TBC_CLK_PS
PSI
During differential conversions the analog multiplexer passes differential signals to both the positive and
negative terminals of the ADC. The differential conversions can only be initiated on four channels: DAN0,
DAN1, DAN2, and DAN3. For each value of CHANNEL_NUMBER, this table lists the ADCs you can
use to perform conversions for that channel (which you specify using BN), whether external multiplexing
(specified by ADCx_CR[EMUX]) must be disabled or enabled to access the channel, and the assigned
analog input signal and conversion type.
• More than one ADC can access the same analog input, but not at the
same time.
• When one ADC is performing a differential conversion on a pair of pins,
another ADC must not access either of those two pins as single-ended
channels.
•
Table 19-45. Multiplexed and non-multiplexed channel assignments
CHANNEL_NUMBER
Conversion
ADCs (BN) ADCx_CR[EMUX] Analog input signal
type
(b) (d)
CHANNEL_NUMBER
Conversion
ADCs (BN) ADCx_CR[EMUX] Analog input signal
type
(b) (d)
CHANNEL_NUMBER
Conversion
ADCs (BN) ADCx_CR[EMUX] Analog input signal
type
(b) (d)
Channel Number selecting ANR, ANS, ANT, ANU, ANW, ANX, ANY, ANZ
(decimal) MA0 MA1 MA2
ANR ANS ANT ANU ANW ANX ANY ANZ
224 232 240 248 64 72 80 88 0 0 0
225 233 241 249 65 73 81 89 0 0 1
226 234 242 250 66 74 82 90 0 1 0
227 235 243 251 67 75 83 91 0 1 1
228 236 244 252 68 76 84 92 1 0 0
229 237 245 253 69 77 85 93 1 0 1
230 238 246 254 70 78 86 94 1 1 0
231 239 247 255 71 79 87 95 1 1 1
1 ‘0’ means pin is driven LOW and ‘1’ that pin is driven HIGH.
When the external multiplexed mode is selected for either ADC, the EQADC automatically creates the
MA output signals from CHANNEL_NUMBER field of a Command Message. The EQADC also converts
the proper input channel (ANR, ANS, ANT, ANU, ANW, ANX, ANY, and ANZ) by interpreting the
CHANNEL_NUMBER field. As a result, up to 64 externally multiplexed channels appear to the
conversion queues as directly connected signals.
AN64
AN65
AN66 EQADC
AN67 MUX
AN68
AN69
AN70
AN71
MUX 40:1
AN72
AN73 ADC0
AN74
AN75 MUX
AN76 ANW
AN77
AN78 ANX 4
AN79 ANY
ANZ 4
40
AN80
AN81
AN82
AN83 MUX MA0
AN84
AN85 MA1
AN86 MA2
MUX 40:1
AN87
ADC1
AN88
AN89
AN90
AN91 MUX
AN92
AN93
AN94
AN95 MUX Channel Number0/1
AN224 CONTROL
AN225
AN226
AN227 MUX
AN228
AN229
AN230
AN231
NOTE: Limited availability of pins may result in the
sharing of ADC inputs and mux outputs.
AN232
AN233
AN234
AN235 MUX
AN236 ANR
AN237
AN238 ANS
AN239 ANT
ANU
AN240
AN241
AN242
AN243 MUX
AN244
AN245
AN246
AN247
AN248
AN249
AN250
AN251 MUX
AN252
AN253
AN254
AN255
AN0-AN7 32
AN12-AN15
AN20-AN39
Table 19-48 describes a list of methods to generate DMA requests in the EQADC.
Table 19-48. EQADC FIFO DMA Summary1
1
For details refer to Section 19.6.2.7, “EQADC FIFO and Interrupt Status Registers (EQADC_FISR),” and
Section 19.6.2.6, “EQADC Interrupt and DMA Control Registers (EQADC_IDCR).”
RFDEx
DMA Request
RFDFx Generation Logic RFIFO Drain DMA Request
RFDSx
RFDEx
RFDFx RFIFO Drain Interrupt Request
RFDSx
CFFEx
CFFFx DMA Request
CFIFO Fill DMA Request
Generation Logic
CFFSx
CFFEx
CFFFx CFIFO Fill Interrupt Request
CFFSx
NCIEx
Non Coherency Interrupt Request
NCFx
PIEx
Pause Interrupt Request
PFx
EOQIEx
End of Queue Interrupt Request
EOQFx
TORIEx
Trigger Overrun Interrupt Request
TORFx
CFUIEx
CFIFO Underflow Interrupt Request
CFUFx
RFOIEx
RFIFO Overflow Interrupt Request
RFOFx
RSD SINGLE-STAGE
PIPELINE
DIFF
INPUT
sample pipeline_control
The RSD Cyclic ADC consists of two main portions, the analog RSD Stage, and the digital control and
calculation block, as shown in Figure 19-74. To begin an analog to digital conversion, a differential input
is passed into the analog RSD stage. The signal is passed through the RSD stage, and then from the RSD
stage output, back to its input to be passed again. To complete a 12-bit conversion, the signal must pass
through the RSD stage 12 times. For 10-bit and 8-bit resolution, the signal must pass 10 or 8 times through
the RSD. Each time an input signal is read into the RSD stage, a digital sample is taken by the digital
control/calculation block. The digital control/calculation block uses this sample to tell the analog block
how to condition the signal. The digital block also saves each successive sample and adds them according
to the RSD algorithm at the end of the entire conversion cycle.
Input
Voltage Residue Voltage
x2 Sum
-VREF,0,VREF
+
VRH Digital
-
Logic Signal RSD
Control Adder
+
VRL
-
On each pass through the RSD stage, the input signal will be multiplied by exactly two, and summed with
either -VREF, 0, or VREF, depending on the Logic Control. The Logic Control will determine -VREF, 0,
or VREF depending on the two comparator inputs. As the Logic Control sets the summing operation, it
also sends a digital value to the RSD adder. Each time an analog signal passes through the RSD
single-stage, a digital value is collected by the RSD adder. At the end of an entire AD conversion cycle,
the RSD adder uses these collected values to calculate the 12-bit/10-bit/8-bit digital output.
Figure 19-76 shows the transfer function for the RSD stage. Note how the digital value (a, b) is dependent
on the two comparator inputs.
Residue
Voltage
VREF
Vres=2Vin+VREF Vres=2Vin Vres=2Vin-VREF
Input
Voltage
-VREF VL VH VREF
-VREF
In each pass through the RSD stage, the residue will be sent back to be the new input, and the digital
signals, a and b, will be stored. For the 12-bit ADC, input signal is sampled during the input phase, and
after each of the 12 passes through the RSD stage. Thus, 13 total a and b values are collected. Upon
collecting all these values, they will be added according to the RSD algorithm to create the 12-bit digital
representation of the original analog input. The bits are added in the following manner:
carry
a13
b12 a12
b11 a11
b10 ..
.. ...
... a3
b2 a2
+ b1
------------------------------------------
s12 s11 s10 ... ... s2 s1
Number of
CQueue
CQueue Type Running Speed Contiguous Example
Number
Conversions
0 Very fast burst every 2 s for 200 s; 2 Injector current profiling
time-based CQueue pause for 300 s and then
repeat
1 Fast every 900 s 3 Current sensing of PWM
hardware-triggered controlled actuators
CQueue
2 Fast repetitive every 2 ms 8 Throttle position
time-based CQueue
3 Software-triggered every 3.9 ms 3 Command triggered by
CQueue software strategy
4 Repetitive every 625 s 7 Airflow read every 30
angle-based degrees at 8000 RPM
CQueue
5 Slow repetitive every 100 ms 10 Temperature sensors
time-based CQueue
b. Set CFFE0 to enable the EQADC to generate a DMA request to transfer commands from
CQueue0 to CFIFO0; Command transfers from the RAM to the CFIFO0 will start immediately.
c. Set EOQIE0 to enable the EQADC to generate an interrupt after transferring all of the
commands of CQueue0 through CFIFO0.
6. Configure Section 19.6.2.5, “EQADC CFIFO Control Registers (EQADC_CFCR).”
a. Write 0b0001 to the MODE0 field in EQADC_CFCR0 to program CFIFO0 for software
single-scan mode.
b. Write “1” to SSE0 to assert SSS0 and trigger CFIFO0.
7. Since CFIFO0 is in single-scan software mode and it is also the highest priority CFIFO, the EQADC
starts to transfer configuration commands to the on-chip ADCs and to the external device.
8. When all of the configuration commands have been transferred, CF0 in Section 19.6.2.7, “EQADC
FIFO and Interrupt Status Registers (EQADC_FISR),” will be set. The EQADC generates a End of
Queue interrupt. The initialization procedure is complete.
CQueue in
system memory
The initialization procedure described above does not generate ADC clocks that are in phase because the
timing at which the ADC0/1_EN bits, in the Section 19.6.3.1, “ADC0/1 Control Registers (ADC0_CR and
ADC1_CR),” are set is different. Below follows an example on how to simultaneously set these bits so that
in-phase ADC clocks are generated. In this example, ADC0/1_CLK are configured to the same frequency.
1. Push an ADC0_CR write configuration command in CFIFO0 that enables ADC0 (ADC0_EN=1)
and that sets the ADC0_CLK_PS to an appropriate value. For example, 0x80800801.
2. Push an ADC1_CR write configuration command in CFIFO1 that enables ADC1 (ADC1_EN=1)
and that sets the ADC1_CLK_PS to an appropriate value. For example, 0x82800801.
3. Configure CFIFO0 and CFIFO1 to single scan software trigger mode and simultaneously trigger
them by writing 0x04100410 to the EQADC_CFCR0 register - see Section 19.6.2.5, “EQADC
CFIFO Control Registers (EQADC_CFCR).”
the conversion commands will be executed by ADC1. The generated results will be returned to RFIFO3
before being transferred to the RQueues in the RAM by the DMAC.
NOTE
There is no fixed relationship between CFIFOs and RFIFOs with the same
number. The results of commands being transferred through CFIFO1 can be
returned to any RFIFO, regardless of its number. The destination of a result
is determined by the MESSAGE_TAG field of the command that requested
the result. See Section 19.7.2.2, “Message Format in EQADC,” for details.
Step One: Setup the CQueues and RQueues.
1. Load the RAM with configuration and conversion commands. Table 19-50 is an example of how
CQueue1 commands should be set.
a. Each trigger event will cause four commands to be executed. When the EQADC detects the
Pause bit asserted, it will wait for another trigger to restart transferring commands from the
CFIFO.
b. At the end of the CQueue, the “EOQ” bit is asserted as shown in Table 19-50.
c. Results will be returned to RFIFO3 as specified in the MESSAGE_TAG field of commands.
2. Reserve memory space for storing results.
Table 19-50. Example of CQueue Commands1
Bit # 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
Bit
RESERVED
RESERVED
PAUSE
Name
EOQ
MESSAGE
REP
BN
EB
ADC COMMAND
TAG
1
Fields LST, TSR, FMT, and CHANNEL_NUMBER are not showed for clarity. See "Conversion Command Format for the
Standard Configuration",” for details.
2
MESSAGE_TAG field is only defined for read configuration commands.
Step Two: Configure the DMAC to handle data transfers between the CQueues/RQueues in RAM and the
CFIFOs/RFIFOs in the EQADC.
1. For transferring, set the source address of the DMAC to point to the start address of CQueue1. Set
the destination address of the DMAC to point to EQADC_CFPR1. Refer to Section 19.6.2.3,
“EQADC CFIFO Push Registers (EQADC_CFPR).”
2. For receiving, set the source address of the DMAC to point to EQADC_RFPR3. Refer to
Section 19.6.2.4, “EQADC Result FIFO Pop Registers (EQADC_RFPR).” Set the destination
address of the DMAC to point to the starting address of RQueue1.
Step Three: Configure the EQADC Control Registers.
3. Configure Section 19.6.2.6, “EQADC Interrupt and DMA Control Registers (EQADC_IDCR).”
a. Set EOQIE1 to enable the End of Queue Interrupt request.
b. Set CFFS1 and RFDS3 to configure the EQADC to generate DMA requests to push commands
into CFIFO1 and to pop result data from RFIF03.
c. Set CFINV1 to invalidate the contents of CFIFO1.
d. Set RFDE3 and CFFE1 to enable the EQADC to generate DMA requests. Command transfers
from the RAM to the CFIFO1 will start immediately.
e. Set RFOIE3 to indicate if RFIFO3 overflows.
f. Set CFUIE1 to indicate if CFIFO1 underflows.
4. Configure MODE1 to continuous-scan rising edge external trigger mode in Section 19.6.2.5,
“EQADC CFIFO Control Registers (EQADC_CFCR).”
Step Four: Command transfer to ADCs and Result data reception.
When an external rising edge event occurs for CFIFO1, the EQADC automatically will begin
transferring commands from CFIFO1 when it becomes the highest priority CFIFO trying to send
commands to CBuffer1. The received results will be placed in RFIFO3 and then moved to RQueue1
by the DMAC.
Source Address
Destination Address
expected result is written to the RQueue, one of the following actions is recommended. Refer to the DMAC
block guide for details about how this functionality is supported.
• The corresponding DMA channel should be disabled.
• The destination address should be updated to point to the next location where new coming results
are stored, which can be the first entry of the current RQueue (cyclic queue), or the beginning of a
new RQueue.
RQueue in
system memory
Source Address
Destination Address
Message Tag = 0b0101. Refer to Section 19.6.2.3, “EQADC CFIFO Push Registers
(EQADC_CFPR).”
4. Up to four commands can be queued in CFIFO5. Check the CFCTR5 status in EQADC_FISR5
before pushing another command to avoid overflowing the CFIFO. Refer to Section 19.6.2.7,
“EQADC FIFO and Interrupt Status Registers (EQADC_FISR).”
5. When the EQADC receives a conversion result for RFIFO5, it generates an interrupt request.
RFIFO Pop Register 5 (EQADC_RFPR5) can be popped to read the result. Refer to
Section 19.6.2.4, “EQADC Result FIFO Pop Registers (EQADC_RFPR).”
The calibration constants GCC and OCC can be calculated from equation Equation 19-1 provided that two
pairs of expected (CAL_RES) and measured (RAW_RES) result values are available for two different
input voltages. Most likely calibration points to be used are 25% VREF1 and 75% VREF since they are far
apart but not too close to the end points of the full input voltage range. This allows for calculations of more
representative calibration constants. The EQADC provides these voltages via channel numbers 43 and 44.
The raw, uncalibrated results for these input voltages are obtained by converting these channels with
conversion commands that have the CAL bit negated.
The transfer equations for when sampling these reference voltages are:
CAL_RES75%VREF = GCC * RAW_RES75%VREF + OCC+2;
CAL_RES25%VREF = GCC * RAW_RES25%VREF + OCC+2;
Thus;
or
After being calculated, the GCC and OCC values must be written to ADC registers: Section 19.6.3.4,
“ADC0/1 Gain Calibration Constant Registers (ADC0_GCCR and ADC1_GCCR),” and Section 19.6.3.5,
“ADC0/1 Offset Calibration Constant Registers (ADC0_OCCR and ADC1_OCCR),” using write
configuration commands.
The EQADC will automatically calibrate the results, according to equation Equation 19-1, of every
conversion command that has its CAL bit asserted using the GCC and OCC values stored in the ADC
calibration registers.
1. VREF=VRH-VRL
2. Convert channel 43 with a command that has its CAL bit negated and obtain the raw, uncalibrated
result for 75%VREF (RAW_RES75%VREF).
3. Since the expected values for the conversion of these voltages are known (CAL_RES25%VREF and
CAL_RES75%VREF), GCC and OCC values can be calculated from equations Equation 19-2 and
Equation 19-3 using these values, and the ones determined in steps 1 and 2.
4. Reformat GCC and OCC to the proper data formats as specified in Section 19.7.6.6.2, “MAC Unit
and Operand Data Format.” GCC is an unsigned 15-bit fixed point value and OCC is a signed 14-bit
value.
5. Write GCC value to Section 19.6.3.4, “ADC0/1 Gain Calibration Constant Registers
(ADC0_GCCR and ADC1_GCCR),” and OCC value to Section 19.6.3.5, “ADC0/1 Offset
Calibration Constant Registers (ADC0_OCCR and ADC1_OCCR),” using write configuration
commands.
19.8.6.2 Example
The raw results obtained when sampling reference voltages 25%VREF and 75%VREF were, respectively,
3798 and 11592. The results that should have been obtained from the conversion of these reference
voltages are, respectively, 4096 and 12288. Therefore, using equations Equation 19-2 and Equation 19-3,
the gain and offset calibration constants are:
GCC=(12288-4096)/(11592-3798) = 1.05106492-> 1.05102539 = 0x4388
OCC=12288 - 1.05106492*11592 - 2 = 102.06-> 102 = 0x0066
Table 19-51 shows, for this particular case, examples of how the result values change according to GCC
and OCC when result calibration is executed (CAL=1) and when it is not (CAL=0).
Table 19-51. Calibration example
Input
Voltage
1/2 LSB
LSB
0 (12-bit AD resolution)
Quantization
Error Error for Shifted
Transfer Curve
2
1/2 LSB
LSB
Input
0 Voltage
(12-bit AD resolution)
-2
-4
Error for ADC Transfer Curve
Digital Control
Logic for analog Analog to Digital Converter
device
External
Triggers Trigger and
Queue Control
Logic Command Queues Result Queues
Interrupt Request
EQADC
DMA/Interrupt
Requests
System Bus
The EQADC system consists of these parts: queues in RAM, the EQADC, and on-chip ADCs. As
compared with the QADC, the EQADC system requires extra hardware.
1. A DMA or an MCU is required to move data between the EQADC’s FIFOs and Queues in the
system memory.
Since there are only FIFOs inside the EQADC, much of the terminology or use of the register names,
register contents, and signals of the EQADC involve “FIFO” instead of “Queue”. These register names,
register contents, and signals are functionally equivalent to the “Queue” counterparts in the QADC.
Table 19-52 lists how the EQADC register, register contents, and signals are related to QADC.
.
The EQADC and QADC also have similar procedures for the configuration or execution of applications.
Table 19-53 shows the steps required for the QADC versus the steps required for the EQADC system.
20.1 Introduction
The eSCI block is an enhanced SCI block with a LIN master interface layer and DMA support. The LIN
master layer complies with the specifications LIN 1.3, LIN 2.0, and SAE J2602/1.
20.1.1 Bibliography
• LIN Specification Package Revision 1.3; December 12, 2002
• LIN Specification Package Revision 2.0; September 23, 2003
• LIN Network for Vehicle Applications, SAE J2602/1, September 1, 2005
Term Description
eSCI Enhanced SCI block with LIN support and DMA support
LIN PE LIN Protocol Engine, Finite State Machine to control logic of the LIN hardware.
20.1.3 Glossary
Table 20-2. Glossary
Term Definition
Logic level one The voltage that corresponds to Boolean true (1) state.
Logic level zero The voltage that corresponds to Boolean false (0) state.
Term Definition
Set To set a bit or bits means to establish logic level one on the bit or bits.
Clear To clear a bit or bits means to establish logic level zero on the bit or bits.
Asserted A signal that is asserted is in its active state. An active low signal changes from logic level one to logic level
zero when asserted, and an active high signal changes from logic level zero to logic level one.
Preamble The term preamble describes an idle character which is transmitted by the eSCI module.
Bit time Duration of a single bit in a transmitted byte field or character, equivalent to the duration of one transmitter
clock cycle defined in Section 20.4.3.2, “Transmitter Clock”
frame Entity that consists of the start bit followed by payload bits followed by one ore more stop bits
LIN TX frame A LIN frame with the frame header, data byte fields, and checksum field transmitted by the eSCI module
LIN RX frame A LIN frame with the header field transmitted by the eSCI module and the data byte fields and checksum field
received by the eSCI module
module is idle Module is idle, described in Section 20.1.6.1, “Module Idle Condition”
20.1.4 Overview
The eSCI block allows asynchronous serial communications with peripheral devices and other CPUs. It
includes special support to interface to LIN slave devices.
RECEIVE
BUS BAUD RATE RCLK CONTROL
CLK GENERATOR WAKE UP
CONTROL
LIN PE
FRAME FORMAT
CONTROL
CPU INTERRUPT
IRQ GENERATION
TRANSMIT
16 TCLK
CONTROL
TRANSMIT
SHIFT REGISTER
TXD
DMA TX DMA TRANSMIT
CTRL CHANNEL DATA REGISTER
20.1.5 Features
The eSCI block includes these distinctive features:
• Full-duplex operation
• Standard mark/space non-return-to-zero (NRZ) format
• 13-bit baud rate selection
• Programmable frame, payload, and character format
• Support of 2 stop bits in receiver path
• Hardware parity generation and checking
— Programmable even or odd parity
• Programmable polarity of RXD pin
• Separately enabled transmitter and receiver
• Two receiver wake-up methods:
— Idle line wake up
— Address mark wake up
• Interrupt-driven operation with eight flags:
— Transmitter empty
— Transmission complete
— Receiver full
— Idle receiver input
— Receiver overrun
— Noise error
— Framing error
— Parity error
• Receiver framing error detection
• 1/16 bit-time noise detection
• 2 channel DMA interface
• LIN support
— LIN Master Node functionality (master and slave task)
— Compatible with LIN slaves from revisions 1.x and 2.0 of the LIN standard
— Detection of Bit Errors, Physical Bus Errors and Checksum Errors
— All status bit can generate maskable interrupts
— Application layer CRC support
— Programmable CRC polynom
— Detection and generation of wake-up characters
— Programmable wake-up delimiter time
— Programmable slave timeout
— Can be configured to include header bits in checksum
— LIN DMA interface
Offset Register
0x0008 Interrupt Flag and Status Register 1 (eSCI_IFSR1) Interrupt Flag and Status Register 2 (eSCI_IFSR2)
Offset Register
0x001C Reserved
Convention Description
Depending on its placement in the read or write row, indicates that the bit is not readable or not writeable.
FIELDNAME Identifies the field. Its presence in the read or write row indicates that it can be read or written.
rwm A read/write bit that may be modified by a eSCI module in some fashion other than by a reset.
w1c Write one to clear. A flag bit that can be read, is cleared by writing a one, writing 0 has no effect.
Reset Values
0 Resets to zero.
1 Resets to one.
15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R
R SBR
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0
Figure 20-2. Baud Rate Register (eSCI_BRR)
This register provides the control value for the serial baud rate. The baud rate and clock generation is
specified in Section 20.4.3, “Baud Rate and Clock Generation”.
A byte write access to only the upper byte of this register (eSCI_BRR[0:715:8]) will not change the content
of the register, instead, the written byte is stored internally into a shadow register. A subsequent byte write
access to only the lower byte of this register (eSCI_BRR[8:157:0]) updates the lower byte and copies the
content of the shadow register into the upper byte.
A byte write access to only the lower byte of this register (eSCI_BRR[8:157:0]) without a preceding byte
write access to only the upper byte copies a value of all zero into the upper byte.
A word write access to this register updates both the lower and upper byte immediately and is the
recommended write access type for this register.
Table 20-5. eSCI_BRR Field Descriptions
Field Description
R Reserved. These bits are reserved. They are read as 0. Application must not write 1 to these bits.
SBR Serial Baud Rate. This field provides the baud rate control value SBR.
R 0 RWU
R RSRC M WAKE PE PT TIE TCIE RIE ILIE TE RE SBK
W rwm
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 20-3. Control Register 1 (eSCI_CR1)
This register provides bits to configure the functionality of the module, provides the interrupt enable bits
for the interrupt flags provided in Interrupt Flag and Status Register 1 (eSCI_IFSR1) and provides the
control bits for the transmitter and receiver.
Table 20-6. eSCI_CR1 Field Descriptions
Field Description
LOOPS Loop Mode Select. This control bit together with the RSRC control bit defines the receiver source mode. The
mode coding is defined in Table 20-7 and the modes are described in Section 20.4.5.3.2, “Receiver Input Mode
Selection”.
R Reserved. This bit is reserved. It is read as 0. Application must not write 1 to these bits.
RSRC Receiver Source Control. This control bit together with the LOOPS control bit defines the receiver source mode.
The mode coding is defined in Table 20-7 and the modes are described in Section 20.4.5.3.2, “Receiver Input
Mode Selection”.
M Frame Format Mode. This control bit together with the M2 bit of the Control Register 3 (eSCI_CR3) controls the
frame format used. The supported frame formats and the related settings are defines in Section 20.4.2, “Frame
Formats”.
WAKE Receiver Wake-up Condition. This control bit defines the wake-up condition for the receiver. The receiver
wake-up is described in Section 20.4.5.5, “Multiprocessor Communication”.
0 Idle line wake-up.
1 Address mark wake-up
PE Parity Enable. This control bit enables the parity bit generation and checking. The location of the parity bits is
shown in Section 20.4.2, “Frame Formats”.
0 Parity bit generation and checking disabled.
1 Parity bit generation and checking enabled.
PT Parity Type. This control bit defines whether even or odd parity has to be used.
0 Even parity (even number of ones in character clears the parity bit).
1 Odd parity (odd number of ones in character clears the parity bit).
TIE Transmitter Interrupt Enable. This bit controls the eSCI_IFSR1[TRDE] interrupt request generation.
0 TDRE interrupt request generation disabled.
1 TDRE interrupt request generation enabled.
TCIE Transmission Complete Interrupt Enable. This bit controls the eSCI_IFSR1[TC] interrupt request generation.
0 TC interrupt request generation disabled.
1 TC interrupt request generation enabled.
RIE Receiver Full Interrupt Enable. This bit controls the eSCI_IFSR1[RDRF] interrupt request generation.
0 RDRF interrupt request generation disabled.
1 RDRF interrupt request generation enabled.
ILIE Idle Line Interrupt Enable. This bit controls theeSCI_IFSR1[IDLE] interrupt request generation.
0 IDLE interrupt request generation disabled.
1 IDLE interrupt request generation enabled.
TE Transmitter Enable. This control bit enables and disables the transmitter. The control features of the transmitter
are described in Section 20.4.5.2.1, “Transmitter States and Transitions”.
0 Transmitter disabled.
1 Transmitter enabled.
RE Receiver Enable.This control bit enables and disables the receiver. The control features of the receiver are
described in Section 20.4.5.3.1, “Receiver States and Transitions”.
0 Receiver disabled.
1 Receiver enabled.
Field Description
RWU Receiver Wake-Up Mode. This bit controls and indicates the receiver wake-up mode, which is described in
Section 20.4.5.5, “Multiprocessor Communication”.
0 Normal receiver operation.
1 Receiver is in wake-up mode.
Note: This bit should be set in SCI mode only.
SBK Send Break Character. This bit controls the transmission of break characters, which is described in
Section 20.4.5.2.7, “Break Character Transmission”.
0 No break characters will be transmitted.
1 Break characters will be transmitted.
Note: This bit should be set in SCI mode only.
0 1 Reserved
1 0 Loop Mode
RXDMA
TXDMA
RXPOL
R
TXDIR
W MDIS FBR BSTP BRCL BESM BESTP PMSK ORIE NFIE FEIE PFIE
Reset 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 20-4. Control Register 2 (eSCI_CR2)
This register provides bits to configure the functionality of the module, and interrupt enable bits for the
interrupt flags provided in Interrupt Flag and Status Register 1 (eSCI_IFSR1) and control bits for the
transmitter and receiver.
Table 20-8. eSCI_CR2 Field Descriptions
Field Description
MDIS Module Disabled Mode. This bit controls the Module Mode of Operation, which is described in Section 20.1.6,
“Modes of Operation”
0 Module is not in Disabled Mode.
1 Module is in Disabled Mode, if module is idle.
FBR Fast Bit Error Detection. This bit controls the Bit Error Detection mode.
0 Standard Bit error detection performed as described in Section 20.4.6.5.3, “Standard Bit Error Detection”.
1 Fast Bit error detection performed as described in Section 20.4.6.5.4, “Fast Bit Error Detection”.
Note: This bit is used in LIN mode only.
Field Description
BSTP DMA Stop on Bit Error or Physical Bus Error. This bit controls the transmit DMA requests generation in case of
bit errors or physical bus errors. Bit errors are indicated by the BERR flag in the Interrupt Flag and Status Register
1 (eSCI_IFSR1) and physical bus errors are indicated by the PBERR flag in the Interrupt Flag and Status
Register 2 (eSCI_IFSR2).
0 Transmit DMA requests generated regardless of bit errors or physical bus errors.
1 Transmit DMA requests are not generated if eSCI_IFSR1[BERR] flag or eSCI_IFSR2[PBERR] flags are set.
Note: This bit is used in LIN mode only.
BERRIE Bit Error Interrupt Enable. This bit controls the BERR interrupt request generation.
0 BERR interrupt request generation disabled.
1 BERR interrupt request generation enabled.
RXDMA Receive DMA Control. This bit enables the receive DMA feature. When this bit is cleared, a pending receive DMA
request is deasserted.
0 Receive DMA disabled.
1 Receive DMA enabled.
TXDMA Transmit DMA Control. This bit enables the transmit DMA feature. When this bit is cleared, a pending transmit
DMA request is deasserted.
0 Transmit DMA disabled.
1 Transmit DMA enabled.
BRCL Break Character Length. This bit is used to define the length of the break character to be transmitted.
The settings are specified in Section 20.4.2.2, “Break Character Formats”.
TXDIR This bit has no effect. In this device, TXDIR does not control the output driver of the TXD pin in Single Wire Mode.
The function is controlled by the relevant Pad Control Register in the System Integration Unit.
BESM Fast Bit Error Detection Sample Mode. This bit defines the sample point for the Fast Bit Error Detection Mode.
0 Sample point is RS9.
1 Sample point is RS13.
Note: This bit is used in LIN mode only.
BESTP Bit Error Transmit Stop. This control bit defines the behavior of the eSCI Transmit Pin TXD while the bit error flag
eSCI_IFSR1[BERR] is 1.
0 Application Data Values driven onto TXD pin.
1 Recessive Data Value 1 driven onto TXD pin.
Note: This bit is used in LIN mode only.
RXPOL RXD Pin polarity. This bit controls the polarity of the RXD pin. See Section 20.4.2.1.1, “Inverted Data Frame
Formats”
0 Normal Polarity.
1 Inverted Polarity.
PMSK Parity Bit Masking. This bit defines whether the received parity bit is presented in the related bit position in the
SCI Data Register (eSCI_SDR).
0 The received parity bit is presented in the bit position related to the parity bit.
1 The value 0 is presented in the bit position related to the parity bit.
ORIE Overrun Interrupt Enable. This bit controls the eSCI_IFSR1[OR] interrupt request generation.
0 OR interrupt request generation disabled.
1 OR interrupt request generation enabled.
NFIE Noise Interrupt Enable. This bit controls the eSCI_IFSR1[NF] interrupt request generation.
0 NF interrupt request generation disabled.
1 NF interrupt request generation enabled.
Field Description
FEIE Frame Error Interrupt Enable. This bit controls the eSCI_IFSR1[FE] interrupt request generation.
0 FE interrupt request generation disabled.
1 FE interrupt request generation enabled.
PFIE Parity Error Interrupt Enable. This bit controls the eSCI_IFSR1[PF] interrupt request generation.
0 PF interrupt request generation disabled.
1 PF interrupt request generation enabled.
In SCI mode this register is used to provide transmit data and retrieve received data. In LIN mode any write
access to this register is ignored and any read access returns unspecified data. In case of data transmission
this register is used to provide a part of the transmit data. In case of data reception this register provides a
part of the received data and related error information.If the application writes to the lower byte of this
register (eSCI_SDR[7:08:15]), the internal commit flag iCMT, which is not visible to the application, is
set to indicate that the register has been updated and ready to transmit new data.
If the application reads from the lower byte of this register (eSCI_SDR[7:08:15]), a signal is send to the
internal receiver unit to indicate that the register was read and is ready to receive new data. The read access
will not change the content of any register.
Table 20-9. eSCI_SDR Field Descriptions
Field Description
RN Received Most Significant Bit. The semantic of this bit depends on the frame format selected by eSCI_CR3[M2],
eSCI_CR1[M], and eSCI_CR1[PE].
[M2=0,M=1,PE=0]: value of received data bit 8 or address bit.
[M2=0,M=1,PE=1]: value of received parity bit if eSCI_CR2[PMSK]=0, 0 otherwise.
[M2=1,M=0,PE=1]: value of received parity bit if eSCI_CR2[PMSK]=0, 0 otherwise.
[M2=1,M=1,PE=1]: value of received parity bit if eSCI_CR2[PMSK]=0, 0 otherwise.
It is 0 for all other frame formats.
TN Transmit Most Significant Bit. The semantic of this bit depends on the frame format selected by eSCI_CR3[M2],
eSCI_CR1[M], and eSCI_CR1[PE].
[M2=0,M=1,PE=0]: value to be transmitted as data bit 8 or address bit.
It is not used for all other frame formats.
Field Description
ERR Receive Error Bit. This bit indicates the occurrence of the errors selected by the Control Register 3 (eSCI_CR3)
during the reception of the frame presented in SCI Data Register (eSCI_SDR). In case of an overrun error for
subsequent frames this bit is set too.
0 None of the selected errors occured.
1 At least one of the selected errors occured.
RD[11:8] Received Data. The semantic of this field depends on the frame format selected by eSCI_CR3[M2] and
eSCI_CR1[M].
[M2=1,M=1]: value of the received data bits 11:8. (Rx=BITx).
It is all 0 for all other frame formats.
RD[7] Received Bit 7. The semantic of this bit depends on the format selected by eSCI_CR3[M2], eSCI_CR1[M], and
eSCI_CR1[PE].
[M2=0,M=0,PE=0]: value of received BIT7 or ADDR BIT.
[M2=0;M=0,PE=1]: value of received PARITY BIT if eSCI_CR2[PMSK]=0, 0 otherwise.
For all other frame formats it is the value of received BIT7.
TD[7] Transmit Bit 7. The semantic of this bit depends on the format selected by eSCI_CR3[M2], eSCI_CR1[M], and
eSCI_CR1[PE].
[M2=0,M=0,PE=0]: value of transmit BIT7 or ADDR BIT.
[M2=0;M=0,PE=1]: not used. PARITY BIT is generated internally before transmission.
For all other frame formats it is the value of transmit BIT7.
This register provides interrupt flags that indicate the occurrence of module events. The related interrupt
enable bits are located in Control Register 1 (eSCI_CR1) and Control Register 2 (eSCI_CR2).
Table 20-10. eSCI_IFSR1 Field Descriptions
Field Description
TDRE Transmit Data Register Empty Interrupt Flag. This interrupt flag is set when the content of the SCI Data Register
(eSCI_SDR) was transferred into internal shift register.
Note: This flag is set in SCI mode only.
TC Transmit Complete Interrupt Flag. This interrupt flag is set when a frame, break or idle character transmission
has been completed and no data were written into SCI Data Register (eSCI_SDR) after the last setting of the
TDRE flag and the SBK bit in Control Register 1 (eSCI_CR1) is 0.
This flag is set in LIN mode, if the preamble was transmitted after the enabling of the transmitter.
Field Description
RDRF Receive Data Register Full Interrupt Flag. This interrupt flag is set when the payload data of a received frame
was transferred into the SCI Data Register (eSCI_SDR) and the receive DMA is disabled.
Note: This flag is set in SCI mode only.
IDLE Idle Line Interrupt Flag. This interrupt flag is set when an idle character was detected and the receiver is not in
the wake-up state.
Note: This flag is set in SCI mode only.
OR Overrun Interrupt Flag. This interrupt flag is set when an overrun was detected as described in
Section 20.4.5.3.11, “Receiver Overrun”.
Note: This flag is set in SCI mode only.
NF Noise Interrupt Flag. This interrupt flag is set when the receiver has detected noise during the reception of a
frame, as described in Section 20.4.5.3.13, “Bit Sampling”.
FE Framing Error Interrupt Flag. This interrupt flag is set when the payload data of a received frame was transferred
into the SCI Data Register (eSCI_SDR) or LIN Receive Register (eSCI_LRR) and the receiver has detected a
framing error during the reception of that frame, as described in Section 20.4.5.3.17, “Stop Bit Verification”.
PF Parity Error Interrupt Flag. This interrupt flag is set when the payload data of a received frame was transferred
into the SCI Data Register (eSCI_SDR) and the receiver has detected a parity error for the character, as
described in Section 20.4.5.4, “Reception Error Reporting”
Note: This flag is set in SCI mode only.
DACT DMA Active. The status bit is set when a transmit or receive DMA request is pending.
0 No DMA request pending
1 DMA request pending.
BERR Bit Error Interrupt Flag. This flag is set when a bit error was detected as described in Section 20.4.6.5.3,
“Standard Bit Error Detection”.
Note: This flag is set in LIN mode only.
WACT LIN Wake-Up Active. The status bit is set as long as the LIN wakeup engine receives a LIN wake-up signal.
0 No LIN wakeup signal reception in progress.
1 LIN wakeup signal reception in progress.
LACT LIN Active. This status bit is set as long as the LIN protocol engine is about to transmit or receive LIN frames.
0 No LIN frame transmission or reception in progress.
1 LIN frame transmission or reception in progress.
TACT Transmitter Active. This status bit is set as long as the transmission of a frame or special character is ongoing.
0 No transmission in progress.
1 Transmission in progress.
RACT Receiver Active. This status bit is set as long as the receive is active. The set and clear conditions for the SCI
mode are described in Section 20.4.5.3.1, “Receiver States and Transitions”.The set and clear conditions for the
LIN mode are described in Section 20.4.6.2.1, “LIN byte field reception”.
0 No reception in progress.
1 Reception in progress.
CKERR
PBERR
RXRDY
LWAKE
TXRDY
R
STO CERR FRC 0 0 0 0 0 0 UREQ OVFL
W w1c w1c w1c w1c w1c w1c w1c w1c w1c w1c
Reset 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 20-7. Interrupt Flag and Status Register 2 (eSCI_IFSR2)
This register provides interrupt flags that indicate the occurrence of LIN related events. The related
interrupt enable bits are located in LIN Control Register 1 (eSCI_LCR1) and LIN Control Register 2
(eSCI_LCR2). All interrupt flags in this register will be set in LIN mode only.
Table 20-11. eSCI_IFSR2 Field Descriptions
Field Description
RXRDY Receive Data Ready Interrupt Flag. This interrupt flag is set when the payload data of a received frame was
transferred into the LIN Receive Register (eSCI_LRR) and the receive DMA is disabled.
TXRDY Transmit Data Ready Interrupt Flag. This interrupt flag is set when
a) the content of the LIN Transmit Register (eSCI_LTR) was processed by the LIN PE to generate frame header
or frame transmit data, or
b) when the module has transmitted a LIN wakeup signal frame.
LWAKE LIN Wake-up Received Interrupt Flag. This interrupt flag is set when a LIN Wake-up character was received, as
described in Section 20.4.6.6, “LIN Wake Up”.
STO Slave Timeout Interrupt Flag. This interrupt flag is set when a Slave-Not-Responding-Error is detected. A
detailed description is given in Section 20.4.6.5.5, “Slave-Not-Responding-Error Detection”.
PBERR Physical Bus Error Interrupt Flag. This interrupt flag is set when the receiver input remains unchanged for at least
31 RCLK clock cycles after the start of a byte transmission, as described in Section 20.4.6.5, “LIN Error
Reporting”.
CERR CRC Error Interrupt Flag. This interrupt flag is set when an incorrect CRC pattern was detected for a received
LIN frame.
CKERR Checksum Error Interrupt Flag. This interrupt flag is set when a checksum error was detected for a received LIN
frame.
FRC Frame Complete Interrupt Flag. This interrupt flag is set when a LIN TX frame has been completely transmitted
or a LIN RX frame has been completely received.
UREQ Unrequested Data Received Interrupt Flag. This interrupt flag is set when unrequested activity has been
detected on the LIN bus, as described in Section 20.4.6.5, “LIN Error Reporting”.
OVFL Overflow Interrupt Flag. This interrupt flag is set when an overflow as described in Section 20.4.6.5.8, “Overflow
Detection” was detected.
This register provides control bits to control and configure the LIN hardware. This register provides the
interrupt enable bits for the interrupt flags in Interrupt Flag and Status Register 2 (eSCI_IFSR2).
Table 20-12. eSCI_LCR1 Field Descriptions
Field Description
LRES LIN Protocol Engine Stop and Reset. This bit is used to stop and reset the LIN protocol engine as described in
Section 20.4.6.7, “LIN Protocol Engine Stop and Reset”.
0 LIN protocol engine is operational.
1 LIN protocol engine is reset and stopped.
WU LIN Bus Wake-Up Trigger. This bit is used to trigger the generation of a wake-up signal frame on the LIN bus, as
described in Section 20.4.6.6, “LIN Wake Up”.
0 Write has no effect.
1 Write triggers the generation of a wake-up signal.
WUD LIN Bus Wake-Up Delimiter Time. This field determines how long the LIN protocol engine waits after the end of
the transmitted wake-up signal, before starting the next LIN frame transmission.
00 4 bit times.
01 8 bit times.
10 32 bit times.
11 64 bit times.
PRTY Parity Generation Control. This bit controls the generation of the two parity bits in the LIN header.
0 Parity bits generation disabled.
1 Parity bits generation enabled.
LIN LIN Mode Control. This bit controls whether the device is in SCI or LIN Mode.
0 SCI Mode.
1 LIN Mode.
RXIE Receive Data Ready Interrupt Enable. This bit controls the eSCI_IFSR2[RXRDY] interrupt request generation.
0 RXRDY interrupt request generation disabled.
1 RXRDY interrupt request generation enabled.
TXIE Transmit Data Ready Interrupt Enable. This bit controls the eSCI_IFSR2[TXRDY] interrupt request generation.
0 TXRDY interrupt request generation disabled.
1 TXRDY interrupt request generation enabled.
WUIE LIN Wake-up Received Interrupt Enable. This bit controls the eSCI_IFSR2[LWAKE] interrupt request generation.
0 LWAKE interrupt request generation disabled.
1 LWAKE interrupt request generation enabled.
STIE Slave Timeout Flag Interrupt Enable. This bit controls the eSCI_IFSR2[STO] interrupt request generation.
0 STO interrupt request generation disabled.
1 STO interrupt request generation enabled.
Field Description
PBIE Physical Bus Error Interrupt Enable. This bit controls the eSCI_IFSR2[PBERR] interrupt request generation.
0 PBERR interrupt request generation disabled.
1 PBERR interrupt request generation enabled.
CIE CRC Error Interrupt Enable. This bit controls the eSCI_IFSR2[CERR] interrupt request generation.
0 CERR interrupt request generation disabled.
1 CERR interrupt request generation enabled.
CKIE Checksum Error Interrupt Enable. This bit controls the eSCI_IFSR2[CKERR] interrupt request generation.
0 CKERR interrupt request generation disabled.
1 CKERR interrupt request generation enabled.
FCIE Frame Complete Interrupt Enable. This bit controls the eSCI_IFSR2[FRC] interrupt request generation.
0 FRC interrupt request generation disabled.
1 FRC interrupt request generation enabled.
This register provides the interrupt enable bits for the interrupt flags in Interrupt Flag and Status Register
2 (eSCI_IFSR2).
Table 20-13. eSCI_LCR2 Field Descriptions
Field Description
UQIE Unrequested Data Received Interrupt Enable. This bit controls the eSCI_IFSR2[UREQ] interrupt request
generation.
0 UREQ interrupt request generation disabled.
1 UREQ interrupt request generation enabled.
OFIE Overflow Interrupt Enable. This bit controls the eSCI_IFSR2[OVFL] interrupt request generation.
0 OVFL interrupt request generation disabled.
1 OVFL interrupt request generation enabled.
7 6 5 4 3 2 1 0
R DATA
1st W P[1:0] ID[5:0]
2nd W LEN
3rd W CSM CSE CRC TD (=0) TO[11:8]
4th W TO[7:0]
Reset 0 0 0 0 0 0 0 0
Figure 20-11. LIN Transmit Register (eSCI_LTR) - LIN RX frame generation
This register is used by the application to initiate the LIN frame header generation for both LIN TX frames
and LIN RX frames. If a LIN TX frame is generated, this register is used to provide the payload data for
the LIN TX frame.
If the LIN PE is in the idle state (eSCI_LCR1[LRES] = 1) or performs a wakeup, each write access to this
register is ignored.
In case of an read access, the register provides the last data written into this register in the DATA field.
If the application initiates a LIN TX frame transfer, i.e the TD bit is set to 1, the content and usage shown
in LIN Transmit Register (eSCI_LTR) - LIN TX frame generation applies. The initiation and transmit of
a TX frame is described in Section 20.4.6.3, “LIN TX Frame generation”.
If the application initiates an LIN RX frame, i.e the TD bit is set to 0, the content and usage shown in LIN
Transmit Register (eSCI_LTR) - LIN RX frame generation applies. The initiation and transmit of a RX
frame is described in Section 20.4.6.4, “LIN RX frame generation”.
Each successful write access to this register increments the internal write access counter and enables the
writing to the next field. The write access counter is reset if
• the LIN PE is in the idle state (eSCI_LCR1[LRES] = 1)
• a LIN TX frame was completely transmitted (eSCI_IFSR1[FRC] was set to 1)
a LIN RX frame was completely received (eSCI_IFSR1[FRC] was set to 1)
Field Description
P Identifier Parity. This field provides the identifier parity which is used to create the protected identifier if the
automatic identifier parity generation is disabled, i.e the PRTY bit in LIN Control Register 1 (eSCI_LCR1) is 0.
ID Identifier. This field is used for the identifier field in the protected identifier.
LEN Frame Length. This field defines the number of data bytes to be transmitted or received.
CSM Checksum Model. This bit controls the checksum calculation model used.
0 Classic Checksum Model (LIN 1.3).
1 Enhanced Checksum Model (LIN 2.0).
CSE Checksum Enable. This bit control the generation and checking of the checksum byte.
0 No generation and checking of checksum byte.
1 Generation and checking of checksum byte.
CRC CRC Enable. This bit controls the generation of checking standard or enhanced LIN frames, which are described
in Section 20.4.6.2, “LIN frame formats”
0 Standard LIN frame generation and checking.
1 Enhanced LIN frame generation and checking.
TD Transfer Direction. This bit control the transfer direction of the data, crc, and checksum byte fields.
0 Data, CRC, and Checksum byte fields received, described in Section 20.4.6.4, “LIN RX frame generation”.
1 Data, CRC, and Checksum byte fields transmitted, described in Section 20.4.6.3, “LIN TX Frame generation”.
TO Timeout Value. The content of the field depends on the transfer direction.
RX frame: Defines the time available for a complete RX frame transfer, as described in Section , “To calculate
the exact position of the sample point with regard to the RX pin, the delays through the pads and the two Bus
Clock cycle delay through the input synchronizer also needs to be taken into account.”
TX frame: Must be set to 0.
This register provides the data bytes of received in case of an LIN RX frame was initiated.
Field Description
D Receive Data. This field provides the data bytes of received LIN RX frames.
This register provides the CRC polynom for generation and processing of CRC-enhanced LIN frames.
Table 20-16. eSCI_LPR Field Descriptions
Field Description
This register is used to control the frame formats and the generation of the ERR bit in the SCI Data Register
(eSCI_SDR).
Table 20-17. eSCI_CR3 Field Descriptions
Field Description
Field Description
0 Frame Format Mode 2. This control bit together with the M bit of the Control Register 1 (eSCI_CR1) controls the
M2 frame format used. The supported frame formats and the related settings are defines in Section 20.4.2, “Frame
Formats”.
0 0 0 0 1 8 0 0 1
0 0 0 0 1 8 0 0 1
0 0 0 1 1 7 1 0 1
0 0 1 0 1 7 0 1 1
0 1 0 0 1 9 0 0 1
0 1 0 1 1 8 1 0 1
0 1 1 0 1 8 0 1 1
1
The address bit identifies the frame as an address character. See Section 20.4.5.5, “Multiprocessor Communication.”
1 0 1 0 1 8 0 1 2
1 1 1 0 1 12 0 1 2
The structure of the LIN byte fields in normal polarity is shown in Figure 20-15.
START STOP
BIT BIT0 BIT1 BIT2 BIT3 BIT4 BIT5 BIT6 BIT7 BIT
The structures of the supported SCI frame formats with 8 payload bits are shown in Figure 20-16.
START STOP
BIT BIT0 BIT1 BIT2 BIT3 BIT4 BIT5 BIT6 BIT7 BIT
The structures of the supported SCI frame formats with 9 payload bits are shown in Figure 20-17.
START STOP
BIT BIT0 BIT1 BIT2 BIT3 BIT4 BIT5 BIT6 BIT7 BIT8 BIT
The structures of the supported SCI frame formats with 2 stop bits in normal polarity are shown in
Figure 20-18. This frame format is supported for reception only.
START STOP
BIT BIT
0 0 0 1 9 1
0 0 1 1 12 1
0 0 0 1 9 0
0 0 1 1 12 0
0 1 0 1 10 0
0 1 1 1 13 0
1
All codings which are not listed are reserved and must not be used.
The structure and content of the LIN break symbols is shown in Figure 20-20.
START Break
BIT BIT0 BIT1 BIT2 BIT3 BIT4 BIT5 BIT6 BIT7 BIT8 Delemit
START Break
BIT BIT0 BIT1 BIT2 BIT3 BIT4 BIT5 BIT6 BIT7 BIT8 BIT9 BIT10 BIT11 Delemit
The structure and content of the SCI break characters is shown in Figure 20-21.
START
BIT BIT0 BIT1 BIT2 BIT3 BIT4 BIT5 BIT6 BIT7 BIT8
START
BIT BIT0 BIT1 BIT2 BIT3 BIT4 BIT5 BIT6 BIT7 BIT8 BIT9
START
BIT BIT0 BIT1 BIT2 BIT3 BIT4 BIT5 BIT6 BIT7 BIT8 BIT9 BIT10 BIT11
START
BIT BIT0 BIT1 BIT2 BIT3 BIT4 BIT5 BIT6 BIT7 BIT8 BIT9 BIT10 BIT11 BIT12
Control
Idle Character Length
eSCI_CR3[M2] eSCI_CR1[M]
0 0 10
0 1 11
1 0 12
1 1 16
The structure and content of the idle characters is shown in Figure 20-22.
BIT0 BIT1 BIT2 BIT3 BIT4 BIT5 BIT6 BIT7 BIT8 BIT9
BIT0 BIT1 BIT2 BIT3 BIT4 BIT5 BIT6 BIT7 BIT8 BIT9 BIT10
BIT0 BIT1 BIT2 BIT3 BIT4 BIT5 BIT6 BIT7 BIT8 BIT9 BIT10 BIT11
BIT0 BIT1 BIT2 BIT3 BIT4 BIT5 BIT6 BIT7 BIT8 BIT9 BIT10 BIT11 BIT12 BIT13 BIT14 BIT14
eSCI_BRR[SBR] RCLK (Hz) TCLK (Hz) Target Baud Rate Error (%)
RXD
RCLK
RSC 6 7 8 1 2 3 6 7 8 9 10
The maximum tolerance that ensures error free reception can be calculated with the assumption, that RS7
is sampled during the last transmitted payload bit and RS8 is sampled in the stop bit.
For an frame with n payload bits the transmitter starts the transmission of the stop bit
The maximum percent difference between the receiver baud rate and the transmitter baud rate is:
rx STOP – tx STOP
baudrate --------------------------------------- 100 Eqn. 20-6
rx STOP
The maximum percent differences for the supported frames is given in Table 20-23
Table 20-23. Faster Receiver Maximum Tolerance
RXD
RCLK
RSC 6 7 8 1 2 3 8 9 10 11
The maximum tolerance that ensures error free reception can be calculated with the assumption, that RS11
is sampled in the transmitted start bit and RS10 is sampled in the last stop bit.
For an frame with n payload bits and s stop bits, the transmitter starts the transmission of the next start bit
The maximum percent difference between the receiver baud rate and the transmitter baud rate is:
tx START – rx STOP
baudrate ------------------------------------------ 100 Eqn. 20-10
tx START
The maximum percent differences for the supported frames is given in Table 20-24
Table 20-24. Slower Receiver Maximum Tolerance
20.4.5.2 Transmitter
The transmitter supports the transmission of all frame types defined in Table 20-18, of all break characters
defined in Table 20-20, and of all idle characters defined in Table 20-21.
Idle
EN
halt DIS
Stop Ready
EN start
DIS done
Run
The current state of the transmitter can be determined by the TE control bit in the Control
Register 1 (eSCI_CR1) and the TACT status bit in Interrupt Flag and Status Register 1 (eSCI_IFSR1).
Table 20-25. Transmitter States
Indication
State Description
eSCI_CR1[TE] eSCI_IFSR1[TACT]
The application triggers a transition described in Table 20-26 when it issues a command by writing to the
TE bit in the Control Register 1 (eSCI_CR1). The transition is triggered only if the conditions are fulfilled.
As a result of the transition the state of the transmitter is changed as shown in Figure 20-25 and the action
given in Table 20-26 is executed.
Table 20-26. Transmitter Application Transitions
The module transition shown in Table 20-27 are triggered when the described condition or event occurs.
The send break bit SBK in the Control Register 1 (eSCI_CR1) is check for the start condition. The internal
commit bit iCMT, the transmitter active bit TACT in the Interrupt Flag and Status Register 1
(eSCI_IFSR1), the TDRE, and the TC flag in the Interrupt Flag and Status Register 1 (eSCI_IFSR1) are
changed as a action result of the transition.
Table 20-27. Transmitter Module Transitions
When the last stop bit has been transmitted and the application has not disabled the transmitter, the
transmitter returns to the Ready state via the done transition. If no frame or character transmit request is
pending, the transfer complete flag TC in the Interrupt Flag and Status Register 1 (eSCI_IFSR1) is set.
If the application has disabled the transmitter while the frame is transmitted and stop bit has been
transmitted, the transmitter goes into the Idle state via the halt transition. The transfer complete flag TC in
the Interrupt Flag and Status Register 1 (eSCI_IFSR1) is set and the internal commit bit iCMT is cleared.
System Memory
DATA 1 TX DMA
channel
DATA 2 DMA
eSCI
Controller
DATA N
DATA 1 DATA N
20.4.5.3 Receiver
The receiver supports the reception of all data frame types defined in Table 20-18 and Table 20-19, of all
break character defined in Table 20-20, and of all idle characters defined in Table 20-21.
triggered by the module are shown in Table 20-27. The state diagram of the transmitter is shown in
Figure 20-25.
RESET_STATE
Idle
EN
DIS DIS
done
Run Ready
SLP SLP start
wake1 wake0
Wake-Up
The current state of the receiver can be determined by the RE and RWU bit in the Control
Register 1 (eSCI_CR1) and the RACT status bit in Interrupt Flag and Status Register 1 (eSCI_IFSR1).
Table 20-29. Receiver States
Indication
State Description
RE RACT RWU
The application triggers a transition described in Table 20-30 when it issues a command by writing to the
RE bit in the Control Register 1 (eSCI_CR1). The transition is triggered only if the conditions are fulfilled.
As a result of the transition the state of the receiver is changed as shown in Figure 20-27 and the action
given in Table 20-30 is executed.
Table 20-30. Receiver Application Transition
The module transitions shown in Table 20-31 are triggered when the described event occurs.
done (State=Run) RACT:=0 Start Bit not Verified or Idle Character received.
and
(start bit not verified or
idle character received)
RECEIVER RXD
TRANSMITTER TXD
RECEIVER RXD
TRANSMITTER TXD
NOTE
In this device, the TXDIR bit (eSCI_CR2[1]) does not determine whether
the TXD pin is going to be used as an input or an output. The relevant pad
control register in the System Integration Unit must be programmed for
input or output)
RECEIVER RXD
TRANSMITTER TXD
If an idle character has been detected, the IDLE flag in the Interrupt Flag and Status Register 1
(eSCI_IFSR1) is set. If the idle line interrupt enable bit ILIE in the Control Register 1 (eSCI_CR1) is set,
the IDLE interrupt request is generated.
If any of the receiver errors described in Section 20.4.5.4, “Reception Error Reporting” have been
occurred, that corresponding flags will be set.
If the application disabled the receiver by clearing the receiver enable bit RE in the Interrupt Flag and
Status Register 1 (eSCI_IFSR1) the current frame is discarded and no flags will be updated.
System Memory
DATA 1
DATA 2 DMA
eSCI
Controller RX DMA
channel
DATA N
DATA 1 DATA N
Sampled Value 1 1 1 1 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1
RCLK
RSC 6 7 8 9 10 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 1 2
The sampling of the start bit consists of three phases, the start bit qualification, the start bit verification,
and the start bit noise detection.
000 Yes No
011 No No
101 No No
110 No No
111 No No
If the start bit verification was not successful, the receiver activates the start bit qualification. If the start
bit verification was successful, the receiver continues sampling to perform data noise detection on the
samples at RSC8, RSC9, and RSC10. The result of the start bit data noise detection is summarized in
Table 20-33. If noise is detected, the noise flag eSCI_IFSR1[NF] is set.
Table 20-33. Start Bit Noise Detection
000 No
001 Yes
010 Yes
100 Yes
011 Yes
101 Yes
110 Yes
111 Yes
Sampled Value 1 1 1 1 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1
DATA
VOTING
RCLK
RSC 12 13 14 15 16 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 1 2
To determine the value of a data bit and to detect noise, a two out of three majority voting is performed on
the samples RSC8, RSC9, and RSC10. Table 20-34 summarizes the results of the data bit sample. The
receiver detects the number of data bit according to the selected frame format. If noise is detected, the noise
flag eSCI_IFSR1[NF] is set.
Table 20-34. Data Bit Sampling
000 0 No
001 0 Yes
010 0 Yes
100 0 Yes
011 1 Yes
101 1 Yes
110 1 Yes
111 1 No
[RSC8, RSC9, RSC10] Stop Bit Verified Framing Error Detected Noise Detected
000 No Yes No
[RSC8, RSC9, RSC10] Stop Bit Verified Framing Error Detected Noise Detected
111 Yes No No
Address Frame
Receiver Wake Up
3. the start bit start bit qualification pattern has been received (see Section 20.4.5.3.15, “Start Bit
Sampling”).
The RACT flag is cleared if at least one of the following conditions is fulfilled,
1. the receiver is disabled (eSCI_CR1[RE] = 0), or
2. the LIN task is in reset (eSCI_LCR1[LRES] = 1), or
3. the start bit verification fails at sample 7 according to Table 20-32, or
4. the 16-th sample of the stop bit has been received and no start bit qualification pattern has been
detected at or after the 10-th sample.
The CRC Enhanced LIN frames are not part of the LIN standard.
System Memory
DATA N
(eSCI_LRR) and the receive data ready flag RXRDY in the Interrupt Flag and Status Register
2 (eSCI_IFSR2) is set.
The application can retrieve the received data by subsequent read access from LIN Receive Register
(eSCI_LRR) after checking the RXRDY flag. The application should clear the RXRDY flag immediately
after reading the LIN Receive Register (eSCI_LRR).
After the reception of the configured number of data from the slave, the module starts the reception of the
configured CRC and Checksum byte fields. These data are not transferred into the LIN Receive Register
(eSCI_LRR). The CRC and Checksum checking is performed internally. In case of errors, they will be
reported as described in Section 20.4.6.5, “LIN Error Reporting”
After the reception of the checksum field of the LIN RX frame, the FRC interrupt flag in the Interrupt Flag
and Status Register 2 (eSCI_IFSR2) is set.
System Memory
DATA 1
DATA 2
Compare
Bit Error RXD Pin
LIN Bus
Bus Clock
Sample Point
Transmit Shift
Register TXD Pin
If fast bit error detection bit FBR in the Control Register 2 (eSCI_CR2) is set the eSCI will compare the
transmitted and the received data stream while the transmitter is active (not idle). Once a mismatch
between the transmitted data and the received data is detected the following actions are performed the bit
error flag BERR will be set.
To adjust to different bus loads the sample point at which the incoming bit is compared to the one which
was transmitted can be selected with the BESM bit in the Control Register 2 (eSCI_CR2). If
eSCI_CR2[BESM] = 1, the comparison will be performed with sample RS13, otherwise with RS9 (see
Figure 20-41) (also see Section 20.4.5.3.13, “Bit Sampling).
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16
Output Transmit
Shift Register
Input Receive
Shift Register
eSCI_CR2[BESM] = 0 eSCI_CR2[BESM] = 1
NOTE
To calculate the exact position of the sample point with regard to the RX pin,
the delays through the pads and the two Bus Clock cycle delay through the
input synchronizer also needs to be taken into account.
where NDATA is the number of data byte fields of the message frame.
The STO interrupt flag in the Interrupt Flag and Status Register 2 (eSCI_IFSR2) will be set, if an LIN RX
frame was not fully received in the amount of time specified in the timeout value field TO in the LIN
Transmit Register (eSCI_LTR). The time period starts with the falling edge of the transmitted LIN break
character and is specified in units of transmit bits.
To achieve LIN compliant Slave-Not-Responding-Error detection, the timeout value TO in the LIN
Transmit Register (eSCI_LTR) field has to be set to TFRAME_MAX when a LIN RX frame is initiated.
START
BIT BIT0 BIT1 BIT2 BIT3 BIT4 BIT5 BIT6 BIT7 BREAK
The application triggers the transmission of a wake-up signal frame by writing 1 to the LIN bus wake-up
trigger WU in the LIN Control Register 1 (eSCI_LCR1).
The LIN Specification 2.0 requires the generation of LIN wake-up signals as dominant pulses longer than
250 s and shorter than 5 ms. To achieve this, the eSCI module has to programmed to a baud rate between
32 kBaud and 1.6 kBaud. With each of these baud rate settings, the wake-up signal is transmitted as a
dominant pulse longer than 250 s and shorter than 5 ms.
Register 1 (eSCI_IFSR1) are cleared. Theses status bits are cleared within one bit time after assertion of
the LRES bit.
20.4.7 Interrupts
This section describes the interrupt sources and interrupt request generation.
Instructions executed by the eTPU are connected directly to the eTPU timing hardware and allow
parallelism of hardware related actions.
21.1.1 Overview
Figure 21-1 shows a top-level eTPU A/B Module block diagram. It displays a dual eTPU Engine
configuration. The eTPU C Module contains a single eTPU Engine configuration.
HOST CPU
SCM
SHARED CODE MEMORY
SHARED
REGISTERS BIU REGISTERS
STAC Bus STAC Bus
SHARED
Debug If P.RAM Debug If
eTPU Engine A eTPU Engine B
PINS PINS
eTPU Engine is responsible for processing input pin transitions and output pin waveform generation
based on the Time Bases. Each eTPU Engine has its own microprocessor and dedicated hardware for
processing signals on I/O pins and can also interface with external time bases through the STAC bus.
Both eTPU Engine CPUs, hereafter called microengines, fetch microinstructions from a Shared Code
Memory - SCM.
Shared Data Memory - SDM - holds eTPU application parameters and work data. It is accessed by Host
and both microengines.
Bus Interface Unit - BIU - allows Host to access eTPU registers, SCM and SDM.
Each I/O signal pair is associated with a dedicated Channel, which provides hardware for input signal
processing and output signal generation, in relationship with selected Time Bases.
The eTPU, as a microprocessed subsystem, works much like a typical real-time system: it runs
microengine code from instruction memory (SCM) to handle specific events, accessing data memory
(SDM) for parameters, work data and application state info; events may originate from I/O Channels (due
to pin transitions and/or time base matches), Host CPU requests or inter-channel requests; events that call
for local eTPU processing activate the microengine by issuing a Service Request. The Service Request
microcode may set an interrupt to the Host CPU. I/O channel events cannot directly interrupt the Host
CPU.
Each Channel is associated with a Function, which defines its behavior: the Function is a software entity
consisting, within the eTPU, of a set of microengine routines that attend to Service Requests. The Function
routines are also responsible for Channel configuration. Function routines reside in SCM, which may
contain several Functions. A Function may be assigned to several Channels, but a Channel can be
associated with just one Function at a given moment. The association between Functions and Channels is
defined by Host CPU, and is explained in detail in the eTPU Reference manual.
eTPU hardware supplies resource sharing features that support concurrency:
• a hardware Scheduler dispatches the Service Request microengine routines based on a set of
priorities defined by the Host CPU. Each Channel has its associated priority;
• a Service Request routine cannot be interrupted until it ends. This sequence of uninterrupted
instruction execution is called a Thread.
• Channel-specific context (registers and flags) is automatically switched between the end of a
Thread and the beginning of the next one.
• SDM arbitration, a dual-parameter coherency controller and semaphores can be used to ensure
coherent access to eTPU data shared by both eTPU Engines and Host CPU.
IPI
SkyBlue, HOST TIMER
Green INTERFACE SCHEDULER CHANNELS
CONTROL SERVICE REQUESTS
Lines
CHANNEL 0
ENGINE
CHANNEL 1
CONFIGURATION TCR1
CHANNEL
IPI TCRCLK
Indigo TCR2/
PIN ANGLE COUNT
Line TIME BASE
CONFIGURATION IPI
Purple
MICROENGINE Line
CHANNEL FETCH and
IPI CONTROL DECODE
CONTROL CONTROL AND DATA (PINS)
DarkBlue
Line EXECUTION
UNIT
MDU
CONTROL
to NDEDI DEBUG and DATA
INTERFACE
CHANNEL 31
CODE
DATA
SHARED SHARED
PARAMETER CODE
RAM MEMORY
(SDM) (SCM)
Throughout this document, the term “eTPU” is sometimes used in place of “eTPU Engine”.
configuration registers. The eTPU is able to export/import time to/from TCR1 or TCR2 in accordance to
the Red Line bus specification.
The clock for each of TCR1 and TCR2 clock can be independently derived from the eTPU clock or from
an external input via the TCRCLK clock pin. In addition, the TCR2 timebase can be derived from special
angle-clock hardware which enables implementing angle-based functions. This feature is added to support
advanced angle based engine control applications.
For further details refer to Section 21.3.5, “Time Bases.
In addition to the predefined channel configurations above, the user can also program its own channel
configuration, defining how input captures, matches and service-requests are related.
In the Host address space each parameter occupies four bytes. eTPU usage of the upper byte is achieved
by having a 32-bit P register which can access the upper byte, the lower 24 bits or all the 32 bits. The
microcode can switch between access sizes at any time.
Each Function may require a different number of parameters. During the eTPU initialization the Host has
to program channel base addresses, allocating proper parameters for each channel according to its selected
Function.
21.1.1.1.5 Scheduler
Out of reset, all channels are disabled. The Host CPU makes a channel active by assigning it one of three
priorities: high, middle, or low. The Scheduler determines the order in which channels are serviced based
on channel number and assigned priority. The priority mechanism, implemented in hardware, ensures that
all requesting channels are serviced. For additional details refer to Section 21.3.3, “Scheduler.”
21.1.1.1.6 Microengine
eTPU microengine executes each instruction in a microcycle of two system clocks, while prefetching the
next instruction through an instruction pipeline. Instruction execution time is constant unless it gets wait
states from the SDM arbitration. Two eTPU Engines share code memory without having any performance
degradation by interleaving their accesses (the Shared Code Memory has one-clock access time).
Instruction width is 32 bits. The microengine instruction set provides basic arithmetic and logic operations,
flow control (jumps and subroutine calls), SDM access, and Channel configuration and control. The
instruction formats are defined in such a way that allow particular combinations of two or three of these
operations with unconflicting resources to be executed in parallel in the same microcycle.
Microengine has also an independent Multiply/Divide/MAC unit that performs these complex operations
in parallel with other microengine instructions.
Channel functionality is tightly integrated to the instruction set through Channel Control operations and
conditional Branch operations, which support jumps/calls on Channel-specific conditions. This allows
quick and terse Channel configuration and control code, contributing to reduced service time.
21.1.2 Features
— instruction set with embedded Channel support, including specialized Channel control
subinstructions and conditional branching on Channel-specific flags.
— channel-oriented addressing: channel-bound address mode with Host configured Channel Base
Address allows channel data isolation, independent of microengine application code.
— channel-bound data address space of up to 128 32-bit parameters (512 bytes)
— global parameter address mode allows access to common Channel data of up to 256 32-bit
parameters (1024 bytes)
— support for indirect and stacked data access schemes.
— parallel execution of: data access, ALU, Channel control and flow control subinstructions in
selected combinations.
— 32-bit microengine registers and 24-bit resolution ALU, with 1 microcycle addition and
subtraction, absolute value, bitwise logical operations on 24-bit, 16-bit, or byte operands;
single bit manipulation, shift operations, sign extension and conditional execution.
— additional 24-bit Multiply/MAC/Divide unit which supports all signed/unsigned
Multiply/MAC combinations, and unsigned 24-bit Divide. The MAC/Divide unit works in
parallel with the regular microcode commands.
• Resource sharing features support channel sharing of channel registers, memory and microengine
time:
— hardware Scheduler works as a “task management” unit, dispatching event service routines by
predefined, Host-configured priority.
— automatic Channel context switch when a “task switch” occurs, i.e., one Function Thread ends
and another begins to service a request from other Channel: Channel-specific registers, flags
and parameter base address are automatically loaded for the next serviced channel.
— individual channel priority setting in 3 levels: high, middle and low.
— Scheduler priority scheme allows calculation of worst case latency for event servicing and
ensures servicing all channels by preventing permanent blockage.
— SDM shared between Host CPU and both eTPU Engines, supporting communication either
between Channels and Host or inter-channel.
— hardware implementation of 4 Semaphores supports resource sharing between both eTPU
Engines.
— Hardware semaphores directly supported by the microengine instruction set.
— dual parameter coherency hardware support allows atomic (to host) access to 2 parameters by
microengine(s) in back-to-back accesses.
— coherent dual-parameter controller allows atomic (to microengines) accesses to 2 parameters
by the host.
• Development support features:
— Nexus class 3 debug support (optional, associated with the eTPU-Nexus Block NDEDI).
— Software breakpoints.
— Debug interface supporting single-step execution, forced microinstruction execution,
Hardware breakpoints and watchpoints on several conditions.
NOTE
All changes above are backward compatible with the classic eTPU, so that
legacy object code (both Host and microcode) runs on eTPU2 without
modification.
21.2.1 Overview
There are 69 external signals associated with each eTPU Engine: 32 channel input signals, 32 channel
output signals, 4 output disable inputs, and TCRCLK clock input, totalling 138 in a Dual Engine system.
The TCRCLK signal is used to clock TCR1/2 counters or gate the TCR2 clock. In Angle Mode it is used
as tooth signal input.
A/B 0xC3FC_0000
C 0xC3E2_0000
SCM unused area is decoded and returns a fixed opcode defined in the register ETPUSCMOFFDATAR.
Table 21-4. High Level Memory Map
Offset Use
Offset Use
0x00 ETPUMCR - eTPU Module Configuration Register
0x04 ETPUCDCR - eTPU Coherent Dual-Parameter Controller Register
0x08 RESERVED
0x0C ETPUMISCCMPR - eTPU MISC Compare Register
0x10 ETPUSCMOFFDATAR - eTPU SCM Off-range Data Register
0x14 ETPUECR_A - eTPU A Engine Configuration Register
0x18 ETPUECR_B - eTPU B Engine Configuration Register
0x1C RESERVED
0x20 ETPUTBCR_A - eTPU A Time Base Configuration Register
0x24 ETPUTB1R_A - eTPU A Time Base 1
0x28 ETPUTB2R_A - eTPU A Time Base 2
0x2C ETPUREDCR_A - eTPU A STAC Configuration Register
Offset Use
0x30 RESERVED
0x34 RESERVED
0x38 RESERVED
0x3C RESERVED
0x40 ETPUTBCR_B - eTPU B Time Base Configuration Register
0x44 ETPUTB1R_B - eTPU B Time Base 1
0x48 ETPUTB2R_B - eTPU B Time Base 2
0x4C ETPUREDCR_B - eTPU B STAC Configuration Register
0x50 RESERVED
0x54 RESERVED
0x58 RESERVED
0x5C RESERVED
0x60 ETPUWDTR_A - eTPU A Watchdog Timer Register
0x64 RESERVED
0x68 ETPUIDLER_A - eTPU A Idle Counter Register
0x6C RESERVED
0x70 ETPUWDTR_B - eTPU B Watchdog Timer Register
0x74 RESERVED
0x78 ETPUIDLER_B - eTPU B Idle Counter Register
0x7C RESERVED
0x80 - 0xFF RESERVED
0x100 ETPUMECR - eTPU Memory Error Control Register
0x104 ETPUDEIAR - eTPU Data Error Injection Address Register
0x108 ETPUDEIDPR - eTPU Data Error Injection Data Pattern Register
0x10C ETPUDEIPPR - eTPU Data Error Injection Parity Pattern Register
0x110 ETPUDERAR - eTPU Data Error Report Address Register
0x114 ETPUDERDR - eTPU Data Error Report Data Register
0x118 ETPUDERSR - eTPU Data Error Report Syndrome Register
0x11C RESERVED
0x120 ETPUMESR - eTPU Memory Error Status Register
0x124 ETPUCEIAR - eTPU Code Error Injection Address Register
0x128 ETPUCEIDPR - eTPU Code Error Injection Data Pattern Register
0x12C ETPUCEIPPR - eTPU Code Error Injection Parity Pattern Register
0x130 ETPUCERAR - eTPU Code Error Report Address Register
0x134 ETPUCERDR - eTPU Code Error Report Data Register
0x138 ETPUCERSR - eTPU Code Error Report Syndrome Register
0x13C ETPUCEFR - eTPU Code Error Fix Register
0x140 - 0x1FF RESERVED
0x200 ETPUCISR_A - eTPU A Channel Interrupt Status Register
0x204 ETPUCISR_B - eTPU B Channel Interrupt Status Register
0x208 RESERVED
0x20C RESERVED
Offset Use
0x210 ETPUCDTRSR_A - eTPU A Channel Data Transfer Request Status Register
0x214 ETPUCDTRSR_B - eTPU B Channel Data Transfer Request Status Register
0x218 RESERVED
0x21C RESERVED
0x220 ETPUCIOSR_A - eTPU A Channel Interrupt Overflow Status Register
0x224 ETPUCIOSR_B - eTPU B Channel Interrupt Overflow Status Register
0x228 RESERVED
0x22C RESERVED
0x230 ETPUCDTROSR_A - eTPU A Channel Data Transfer Request Overflow Status Register
0x234 ETPUCDTROSR_B - eTPU B Channel Data Transfer Request Overflow Status Register
0x238 RESERVED
0x23C RESERVED
0x240 ETPUCIER_A - eTPU A Channel Interrupt Enable Register
0x244 ETPUCIER_B - eTPU B Channel Interrupt Enable Register
0x248 RESERVED
0x24C RESERVED
0x250 ETPUCDTRER_A - eTPU A Channel Data Transfer Request Enable Register
0x254 ETPUCDTRER_B - eTPU B Channel Data Transfer Request Enable Register
0x258–0x25C RESERVED
0x260 ETPUWDSR_A - eTPU A Watchdog Status Register
0x264 ETPUWDSR_B - eTPU B Watchdog Status Register
0x268–0x27F RESERVED
0x280 ETPUCPSSR_A - eTPU A Channel Pending Service Status Register
0x284 ETPUCPSSR_B - eTPU B Channel Pending Service Status Register
0x288 RESERVED
0x28C RESERVED
0x290 ETPUCSSR_A - eTPU A Channel Service Status Register
0x294 ETPUCSSR_B - eTPU B Channel Service Status Register
0x298 RESERVED
0x29C RESERVED
Offset Use
0x5F0 ETPUC31CR_A - eTPU A Channel 31 Configuration Register
0x5F4 ETPUC31SCR_A - eTPU A Channel 31 Status and Control Register
0x5F8 ETPUC31HSRR_A - eTPU A Channel 31 Host Service Request Register
Offset Use
0x00 ETPUMCR - eTPU Module Configuration Register
0x04 ETPUCDCR - eTPU Coherent Dual-Parameter Controller Register
0x08 RESERVED
0x0C ETPUMISCCMPR - eTPU MISC Compare Register
0x10 ETPUSCMOFFDATAR - eTPU SCM Off-range Data Register
0x14 ETPUECR_C - eTPU C Engine Configuration Register
0x18 RESERVED
0x1C RESERVED
Offset Use
0x20 ETPUTBCR_C - eTPU C Time Base Configuration Register
0x24 ETPUTB1R_C - eTPU C Time Base 1
0x28 ETPUTB2R_C - eTPU C Time Base 2
0x2C ETPUREDCR_C - eTPU C STAC Configuration Register
0x30 RESERVED
0x34 RESERVED
0x38 RESERVED
0x3C RESERVED
0x40 RESERVED
0x44 RESERVED
0x48 RESERVED
0x4C RESERVED
0x50 RESERVED
0x54 RESERVED
0x58 RESERVED
0x5C RESERVED
0x60 ETPUWDTR_C - eTPU C Watchdog Timer Register
0x64 RESERVED
0x68 ETPUIDLER_C - eTPU C Idle Counter Register
0x6C RESERVED
0x70 RESERVED
0x74 RESERVED
0x78 RESERVED
0x7C RESERVED
0x80 - 0xFF RESERVED
0x100 ETPUMECR - eTPU Memory Error Control Register
0x104 ETPUDEIAR - eTPU Data Error Injection Address Register
0x108 ETPUDEIDPR - eTPU Data Error Injection Data Pattern Register
0x10C ETPUDEIPPR - eTPU Data Error Injection Parity Pattern Register
0x110 ETPUDERAR - eTPU Data Error Report Address Register
0x114 ETPUDERDR - eTPU Data Error Report Data Register
0x118 ETPUDERSR - eTPU Data Error Report Syndrome Register
0x11C RESERVED
0x120 ETPUMESR - eTPU Memory Error Status Register
0x124 ETPUCEIAR - eTPU Code Error Injection Address Register
0x128 ETPUCEIDPR - eTPU Code Error Injection Data Pattern Register
0x12C ETPUCEIPPR - eTPU Code Error Injection Parity Pattern Register
0x130 ETPUCERAR - eTPU Code Error Report Address Register
0x134 ETPUCERDR - eTPU Code Error Report Data Register
0x138 ETPUCERSR - eTPU Code Error Report Syndrome Register
0x13C ETPUCEFR - eTPU Code Error Fix Register
0x140 - 0x1FF RESERVED
Offset Use
0x200 ETPUCISR_C - eTPU C Channel Interrupt Status Register
0x204 RESERVED
0x208 RESERVED
0x20C RESERVED
0x210 ETPUCDTRSR_C - eTPU C Channel Data Transfer Request Status Register
0x214 RESERVED
0x218 RESERVED
0x21C RESERVED
0x220 ETPUCIOSR_C - eTPU C Channel Interrupt Overflow Status Register
0x224 RESERVED
0x228 RESERVED
0x22C RESERVED
0x230 ETPUCDTROSR_C - eTPU C Channel Data Transfer Request Overflow Status Register
0x234 RESERVED
0x238 RESERVED
0x23C RESERVED
0x240 ETPUCIER_C - eTPU C Channel Interrupt Enable Register
0x244 RESERVED
0x248 RESERVED
0x24C RESERVED
0x250 ETPUCDTRER_C - eTPU C Channel Data Transfer Request Enable Register
0x254-0x25C RESERVED
0x260 ETPUWDSR_C - eTPU C Watchdog Status Register
0x264-0x27F RESERVED
0x280 ETPUCPSSR_C - eTPU C Channel Pending Service Status Register
0x284 RESERVED
0x288 RESERVED
0x28C RESERVED
0x290 ETPUCSSR_C - eTPU C Channel Service Status Register
0x294 RESERVED
0x298 RESERVED
0x29C RESERVED
Offset Use
.
.
0x5F0 ETPUC31CR_C - eTPU C Channel 31 Configuration Register
0x5F4 ETPUC31SCR_C - eTPU C Channel 31 Status and Control Register
0x5F8 ETPUC31HSRR_C - eTPU C Channel 31 Host Service Request Register
RESERVED
0x5FC - 0x7FF
0x800 RESERVED
0x804 RESERVED
0x808 RESERVED
0x80C RESERVED
0x810 RESERVED
0x814 RESERVED
0x818 RESERVED
0x81C RESERVED
.
.
.
0x9F0 RESERVED
0x9F4 RESERVED
0x9F8 RESERVED
RESERVED
0x9FC - 0x7FFF
Base + 0x000
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 SDM WDTO WDTO MGE MGE ILF1 ILF21 0 0 0 SCMSIZE
ERR 1 21 1 21
W GEC
RESET: 0 0 0 0 0 0 0 0 0 0 0 SCMSIZE
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R 0 0 0 0 SCM SCM SCM SCM 0 VIS 0 0 0 0 0 GTBE
MISC MISF MISE ERR
W SCM N
MISC
C
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
= Unimplemented or Reserved
1
Not present in eTPU C.
Base + 0x004
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R STS CTBASE PBBASE
W
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R PWID PARM0 WR PARM1
W TH
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 21-4. ETPUCDCR Register
WR — Read/Write selection
This bit selects the direction of the coherent data transfer.
1 = Write operation. Data transfer is from the PB to the selected SDM address.
0 = Read operation. Data transfer is from the selected SDM address to the PB.
Base + 0x00C
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R ETPUMISCCMP[0:15]
W
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R ETPUMISCCMP[16:31]
W
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 21-5. ETPUMISCCMPR Register
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R ETPUSCMOFFDATA[16:31]
W
RESET:
1
The reset value is 0xf3775ffb, an instruction that clears MRLEs, MRLs and TDLs, disables channel service requests, ends the
thread and generates an illegal instruction Global Exception when accessed by eTPU.
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R CDFC 0 ERBA SPPD 0 0 ETB
W IS
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
= Unimplemented or Reserved
1 Engine may go to Debug state (halted) soon after reset, depending on the NDEDI configuration (see NDEDI Block Guide).
1. Only on rare occasions (e.g., during a long stall, (see eTPU Reference Manual) FEND can be read as 1, because it negates
as soon as the end begins execution.
2. The Timebase registers can still be read with MDIS=1, but writes are ineffective and a Bus Error is issued. Global Channel
Registers and SDM can be accessed normally.
Sample on eTPU
Filter Control
clock Divided by:
000 2
001 4
010 8
011 16
100 32
101 64
110 128
111 256
A new value written to FPSCK only becomes effective when the filter prescaler finishes the current
count.
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R TCR1CTL TCR1 0 0 0 0 0 TCR1P
W CS
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
= Unimplemented or Reserved
Figure 21-8. ETPUTBCR Register
This field controls the TCRCLK digital filter (see Section 21.3.5.5, “TCRCLK Digital Filter),
determining whether the TCRCLK signal input (after a synchronizer) is filtered with the same filter
clock as the channel input signals (see Section 21.3.4.4, “Enhanced Digital Filter - EDF”) or uses the
eTPU clock divided by 2, and also whether the TCRCLK digital filter works in integrator mode or two
sample mode (see Table 21-10).
Table 21-10. TCRCLK Filter Clock/Mode
01 TCRCLK input 0
Angle Ticks
10 channel 1 input 1
11 channel 2 input 2
If TCR1 or TCR2 is a STAC Bus Client (see Section 21.3.5.3, “STAC Interface”), the EAC operation
is not allowed, and if AM is set the Angle Logic does not work properly.
NOTE
Changing AM may cause spurious transition detections on the channel
selected by AM, depending on the channel mode and state (see eTPU
Reference Manual for details). If AM must be changed with GTBE=1, the
recommended procedure is described in the eTPU Reference Manual.
TCR1CTL is part of the TCR1 clocking system (see Section 21.3.5, “Time Bases). It determines, together
with TCR1CS, the clock source for TCR1. TCR1 can count on detected rising edge of the TCRCLK signal,
the eTPU clock, or the eTPU clock divided by 2 (see Table 21-12). After reset TCRCLK signal is selected
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R TCR1[8:23]
W
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
= Unimplemented or Reserved
Figure 21-9. ETPUTB1R Register
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R TCR2[8:23]
W
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
= Unimplemented or Reserved
Figure 21-10. ETPUTB2R Register
TCR2 value used on matches and captures. See Section 21.3.5, “Time Bases.
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R REN2 RSC2 0 0 SERVER_ID2 0 0 0 0 SRV2
W
RESET: 0 0 0 0 SERVER_ID2 0 0 0 0 0 0 0 0
= Unimplemented or Reserved
Figure 21-11. ETPUREDCR Register
1. resource identifies any parameter that changes along the time and can be exported / imported from other device. In eTPU
context, a resource can be TCR1 or TCR2 (either Time or Angle values).
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R WDCNT[15:0]
W
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
= Unimplemented or Reserved
Figure 21-12. ETPUWDTR Register
00 disabled
01 reserved
10 thread length
11 busy length
NOTE
Before a new mode is configured, all conditions below must apply:
1- all channels must be disabled (ETPUCxCR field CPR=00).
2- no thread must be executing (register ETPUCSSR reads 0).
3- the watchdog must be disabled (WDM=00).
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R IDLE_CNT[15:0]
W ICLR
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
= Unimplemented or Reserved
Figure 21-13. ETPUIDLER Register
Base + 0x100
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R FME 0 0 0 0 0 0 0 0 0 0 0 0 0 0 MECIE
W
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R HDEIE MDEIE 0 0 0 DTEND DRDIS DEDD CEIE 0 0 0 0 CTEND CRDIS CEDD
W
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
= Unimplemented or Reserved
Figure 21-14. ETPUMECR Register
This bit enables error injection into the SDM microengine read path:
1 = SDM error injection enabled for microengine reads
0 = SDM error injection disabled for microengine reads
Register ETPUDEIAR specifies the address where the error is injected, while registers ETPUDEIDPR
and ETPUDEIPPR define the bit flips on data and parity, respectively.
NOTE
Data error injection is also performed when data error detection is disabled
(DEDD=1).
Register ETPUCEIAR specifies the address where the error is injected, while registers ETPUCEIDPR
and ETPUCEIPPR define the bit flips on data and parity, respectively.
NOTE
Code error injection is also performed when code error detection is disabled
(CEDD=1).
Base + 0x104
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
W
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R 0 0 INJ_ADDR[13:2] 0 0
W
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
= Unimplemented or Reserved
Figure 21-15. ETPUDEIAR Register
Base + 0x108
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R DFLIP[31:16]
W
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R DFLIP[15:0]
W
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
= Unimplemented or Reserved
Figure 21-16. ETPUDEIDPR Register
Base + 0x10C
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 0 PFLIP[19:15] 0 0 0 PFLIP[14:10]
W
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R 0 0 0 PFLIP[9:5] 0 0 0 PFLIP[4:0]
W
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
= Unimplemented or Reserved
Figure 21-17. ETPUDEIPPR Register
Base + 0x110
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R ERR_ACC 0 ERR_CHANNEL 0 0 0 0 0 0 0 0
W
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R 0 0 ERR_ADDR[13:2] 0 0
W
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
= Unimplemented or Reserved
Figure 21-18. ETPUDERAR Register
01 Engine 1
10 Engine 2
11 CDC
Base + 0x114
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R DATA[31:16]
W
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R DATA[15:0]
W
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
= Unimplemented or Reserved
Figure 21-19. ETPUDERDR Register
NOTE
Individual data bytes are not meaningful when their respective BE bits in
ETPUDERSR are not asserted.
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R BE1 0 0 SYND1[4:0] BE0 0 0 SYND0[4:0]
W
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
= Unimplemented or Reserved
Figure 21-20. ETPUDERDR Register
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R DNCE 0 0 0 0 0 0 DNCO CNCERR 0 0 0 0 0 0 CNCO
RR VR VR
W DNCE DNC CNCERR CNC
RRC OVRC C OVRC
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
= Unimplemented or Reserved
Figure 21-21. ETPUMESR Register
DNCERR is cleared by writing a 1 at the same position (DNCERRC). DNCERR must be cleared to
allow correctable error updates to registers ETPUDERAR and ETPUDERDR.
Base + 0x124
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
W
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R INJ_ADDR[15:2] 0 0
W
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
= Unimplemented or Reserved
Figure 21-22. ETPUCEIAR Register
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R DFLIP[15:0]
W
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
= Unimplemented or Reserved
Figure 21-23. ETPUCEIDPR Register
Base + 0x12C
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
W
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R 0 0 0 0 0 0 0 0 0 PFLIP[6:0]
W
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
= Unimplemented or Reserved
Figure 21-24. ETPUCEIPPR Register
Base + 0x130
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R ERR_ACC 0 ERR_CHANNEL 0 0 0 0 0 0 0 0
W
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R ERR_ADDR[15:2] 0 0
W
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
= Unimplemented or Reserved
Figure 21-25. ETPUCERAR Register
00 Host
01 Engine 1
10 Engine 2
11 MISC
Base + 0x134
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R CODE[31:16]
W
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R CODE[15:0]
W
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
= Unimplemented or Reserved
Figure 21-26. ETPUCERDR Register
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R 0 0 0 0 0 0 0 0 0 SYND[6:0]
W
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
= Unimplemented or Reserved
Figure 21-27. ETPUCERSR Register
SYND holds the syndrome of an error detected in the SCM read data path, as defined in
Section 21.3.6.2.1, “Error Correction Code (ECC) and Syndrome Definition”. The field is meaningless
if both CNCERR and CCERR are 0. For more information on error detection, see Section 21.3.6.2,
“Memory Error Support”.
Base + 0x13C
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R CFIXM 0 0 0 0 0 0 0 0 0 0 0 0 0 0
W
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R CFIX_ADDR[15:2] 0 0
W
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
= Unimplemented or Reserved
Figure 21-28. ETPUCEFR Register
Valu
Mode Description
e
11 Automatic The MISC logic rewrites the code word value read
(already fixed by the error correction mechanism)
into the same address whenever it finds a correctable error.
This field is used for hardware debug purposes. CFIX_ADDR may change its contents and must not
be written in automatic mode. For more information on error detection and correction, see
Section 21.3.6.2, “Memory Error Support”.
0x200
Global Channel Registers
0x26C
RESERVED
0x400
Engine 1 Channel Registers
0x600
RESERVED
0x800
Engine 2 Channel Registers
0xA00
RESERVED
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R CIS1 CIS1 CIS1 CIS1 CIS1 CIS1 CIS9 CIS8 CIS7 CIS6 CIS5 CIS4 CIS3 CIS2 CIS1 CIS0
5 4 3 2 1 0
W CIC1 CIC1 CIC1 CIC1 CIC1 CIC1 CIC9 CIC8 CIC7 CIC6 CIC5 CIC4 CIC3 CIC2 CIC1 CIC0
5 4 3 2 1 0
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
For details about interrupts see the eTPU Reference Manual for details.
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R DTRS DTRS DTRS DTRS DTRS DTRS DTRS DTRS DTRS DTRS DTRS DTRS DTRS DTRS DTRS DTRS
15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
W DTR DTR DTR DTR DTR DTR DTR DTR DTR DTR DTR DTR DTR DTR DTR DTR
C C C C C C C C C C C C C C C C
15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R CIOS CIOS CIOS CIOS CIOS CIOS CIOS CIOS CIOS CIOS CIOS CIOS CIOS CIOS CIOS CIOS
15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
W CIOC CIOC CIOC CIOC CIOC CIOC CIOC CIOC CIOC CIOC CIOC CIOC CIOC CIOC CIOC CIOC
15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
For details about interrupt overflow, see Section 21.3.2.2.2, “Interrupt and Data Transfer Request
Overflow.
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R DTR DTR DTR DTR DTR DTR DTR DTR DTR DTR DTR DTR DTR DTR DTR DTR
OS OS OS OS OS OS OS OS OS OS OS OS OS OS OS OS
15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
W DTR DTR DTR DTR DTR DTR DTR DTR DTR DTR DTR DTR DTR DTR DTR DTR
OC OC OC OC OC OC OC OC OC OC OC OC OC OC OC OC
15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R CIE CIE CIE CIE CIE CIE CIE CIE CIE CIE CIE CIE CIE CIE CIE CIE
W 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
= Unimplemented or Reserved
Figure 21-34. ETPUCIER Register
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R DTRE DTRE DTRE DTRE DTRE DTRE DTRE DTRE DTRE DTRE DTRE DTRE DTRE DTRE DTRE DTRE
W 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
= Unimplemented or Reserved
Figure 21-35. ETPUCDTRER Register
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R WDS WDS WDS WDS WDS WDS WDS WDS WDS WDS WDS WDS WDS WDS WDS WDS
15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
W WDS WDS WDS WDS WDS WDS WDS WDS WDS WDS WDS WDS WDS WDS WDS WDS
C C C C C C C C C C C C C C C C
15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R SR15 SR14 SR13 SR12 SR11 SR10 SR9 SR8 SR7 SR6 SR5 SR4 SR3 SR2 SR1 SR0
W
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
= Unimplemented or Reserved
Figure 21-37. ETPUCPSSR Register
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R SS15 SS14 SS13 SS12 SS11 SS10 SS9 SS8 SS7 SS6 SS5 SS4 SS3 SS2 SS1 SS0
W
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
= Unimplemented or Reserved
Figure 21-38. ETPUCSSR Register
Channel
Register Name
Offset
0x00 ETPUCxCR - eTPU Channel Configuration Register
0x04 ETPUCxSCR - eTPU Channel Status/Control Register
0x08 ETPUCxHSRR - eTPU Channel Host Service Request Register
0x0C RESERVED
One contiguous area is used to map all channel registers of each eTPU engine as shown inTable 21-19.
Table 21-19. Channel Registers Map
There are 64 structures defined, one for each available channel in the eTPU System (32 for each Engine).
The base address for the structure presented can be calculated by using the following equation:
Channel_Register_Base = ETPU_Engine_Channel_Base + (channel_number * 0x10)
where:
ETPU_Engine_Channel_Base = ETPU_Base + 0x400 for Engine 1
ETPU_Engine_Channel_Base = ETPU_Base + 0x800 for Engine 2
Channel_Register_Base + 0x0
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R CIE DTRE CPR 0 0 ETPD ETCS 0 0 0 CFS
W
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R ODIS OPO 0 0 0 CPBA
W L
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
= Unimplemented or Reserved
Figure 21-39. ETPUCxCR Register
NOTE
The fields ETCS, CFS and CPBA must only be changed while the channel
is disabled (field CPR=00).
CPR Priority
00 Disabled
01 Low
10 Middle
CPR Priority
11 High
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R IPS OPS OBE 0 0 0 0 0 0 0 0 0 0 0 FM
W
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
= Unimplemented or Reserved
Figure 21-40. ETPUCxSCR Register
1. These bits are equivalent to the TPU/TPU2/TPU3 Host Sequence (HSQ) bits.
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R 0 0 0 0 0 0 0 0 0 0 0 0 0 HSR
W
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
= Unimplemented or Reserved
Figure 21-41. ETPUCxHSRR Register
21.3.1 Watchdog
Each engine has a watchdog mechanism to prevent a thread or a sequence of threads from running too long,
impacting the latency of the other channel services. The watchdog is configured through the register
ETPUWDTR (see Section 21.2.7.1, “ETPUWDTR - eTPU Watchdog Timer Register”). When the
watchdog is enabled, an internal counter increments on each microcycle when a thread is executing. If the
count is greater than the value specified in the ETPUWDTR field WDCNT and a thread is still executing,
the watchdog:
1. forces an END of the thread
2. sets the WDS status bit of the serviced channel in the ETPUWDSR register (see Section 21.2.10.7,
“ETPUWDSR - eTPU Watchdog Status Register”). The channel is disabled, not initiating any
thread until its WDS bit is cleared (its CPR field in ETPUCxCR is not changed, however).
3. issues a Global Exception and sets the ETPUMCR bit WDTO (see Section 21.2.5.1, “ETPUMCR
- eTPU Module Configuration Register”).
The watchdog can be configured in one of the following modes, defining how the internal watchdog count
is reset:
• Thread Length Mode: the watchdog count is reset at the end of each thread.
• Busy Length Mode: the watchdog count is reset when the microengine goes idle. A sequence of
threads, one right after another, keeps the count running. The counter is also reinitialized when a
thread is forced to end, so that a new count begins if another TST initiates at the following
microcycle.
The following applies to the watchdog mechanism:
• microcycles during TST and SDM access wait-states (on TST or instruction execution) are
counted.
• if the watchdog count equals WDCNT in the last microinstruction (with SDM wait-states or not)
of a thread servicing a channel, its WDS bit is not set.
• if the watchdog count expires (gets greater than WDCNT) during the TST, the thread is forced end
on its first instruction.
• the watchdog count does not wrap, so that a thread (in thread length mode) or a thread sequence
(in busy length mode) that lasts for more than the maximum value of WDCNT does get a forced
end.
NOTE
Watchdog must not be enabled when the microengine enters halt mode. The
counter does not run when the engine is stopped, and resets when the
watchdog is disabled.
NOTE
Interrupt and Data Transfer requests can be cleared even when Engines are
in Module Disable Mode, through the Global Channel Registers, and also
DMA completion for Data Transfer requests.
Channel Interrupts and Data Transfer Requests can only be issued by eTPU microcode, through one of the
Channel Control instruction fields (see the eTPU Reference Manual for details).
Both Channel Interrupt and Data Transfer requests can be individually enabled for each channel.
eTPU Interrupt and Data Transfer Registers are mirrored in two organizations: grouped by Channel and
grouped by type (interrupt status, interrupt enable, data transfer status, data transfer enable). This allows
either “channel-oriented” or “bundled channel” Host interrupt service schemes, or a combination of them.
For a detailed description, refer to Section 21.2.9, “Channel Registers Layout” and Section 21.2.10,
“Global Channel Registers.”
eTPU can also assert a Global Exception interrupt indicating a global illegal state. There are five possible
sources for a Global Exception:
• Execution of an illegal instruction by the microengine (see the eTPU Reference Manual for
details). This Global Exception source is flagged by the bits ILF1 and ILF2 in register ETPUMCR.
• An SCM signature mismatch detected by the Multiple Input Signature Calculator - MISC. See
Section 21.3.6.1, “SCM Test - Multiple Input Signature Calculator. This source is flagged by the
bit SCMMISF in register ETPUMCR.
• Microcode request, through microinstruction field CIRC (see the eTPU Reference Manual for
details). This Global Exception source is flagged by bits MGE1(Engine A/C) and MGE2(Engine
B) in register ETPUMCR. The cause of this illegal state is application-dependent. The microcode
may write an error code into the SDM to indicate the cause of the exception, for instance.
• An SDM or SCM non-correctable error on a microengine or host access, flagged by the
ETPUMCR bits SDMERR and SCMERR, respectively (see Section 21.3.6.2, “Memory Error
Support”).
Global Exceptions cannot be directly disabled within eTPU, except by disabling its sources (Memory
Error, MISC and microcode), and it is cleared by writing 1 to the GEC bit in ETPUMCR. Clearing Global
Exception clears all Global Exception source status bits (ILF1, ILF2, SCMMISF, MGE1, MGE2,
SCMERR, SDMERR). If GEC is written 1 at the same time any of the sources issues a Global Exception,
both the interrupt and the status bit of that source remains asserted. The assertion of Global Exception by
one of the sources above does not prevent the others from asserting it too, so any number of them, in any
combination, can be flagged.
NOTE
There can be a race between the clear of a Global Exception and occurrence
of a new set condition, such that the set happens just before the clear and
cannot be sensed by the Host. Therefore, Global Exception cannot be used
as a normal interrupt source: it should only be used for emergency
procedures.
• Writes: the most significant byte of the parameters is not written, and the SDM retains the old byte
value, regardless of the Host access size.
• Reads: the most significant bit of the 24-bit parameter (that is, the msbit of the second most
significant 32-bit parameter byte) is repeated in the 8 most significant bits of the read value on all
32-bit reads and most significant 16- and 8-bit reads.
The same parameters written in the standard SDM address space are read from the PSE area with the same
offsets, and vice-versa.
This feature reliefs the Host from extending the signal of 24-bit eTPU parameters before calculations, and
from read-modify-write accesses to modify 24-bit parameters at the SDM.
HOST
ETPUC0CR[CPBA]->0x014 ETPUC0CR[CPBA]->0x010
ETPUC1CR[CPBA]->0x018 ETPUC1CR[CPBA]->0x150
ETPUC2CR[CPBA]->0x168 ETPUC2CR[CPBA]->0x160
0x6C0 ETPU2 Channel 31 Parameters 0x1B0
ETPUC3CR[CPBA]->0x172 ETPUC3CR[CPBA]->0x00A
0xB00 0x2C0
ETPUC30CR[CPBA]->0x180 ETPU2 Channel 2 Parameters ETPUC30CR[CPBA]->0x100
ETPUC31CR[CPBA]->0x16E 0xB40 0x2D0 ETPUC31CR[CPBA]->0x0D8
ETPU1 Channel 2 Parameters
0xB70 ETPU1 Channel 31 Parameters 0x2DC
0xB90 ETPU1 Channel 3 Parameters 0x2E4
0xC00 0x300
Engine 1 ETPU1 Channel 30 Parameters Engine 2
Single-engine eTPU or dual eTPU system may require less parameters than the maximum number
provided by the SDM. Since the SDM partition is fully dynamic, there is no limitation of fixed channel
addresses, and the reduced array can be fully utilized.
NOTE
It is necessary to turn VIS bit on to set software breakpoints (see the eTPU
Reference Manual for details).
1. only part of these suggested operations can be parallelized in a single instruction, see the eTPU Reference Manual for
details.
21.3.3 Scheduler
Every Function is composed of one or more Threads. A Thread consists of a group of instructions that,
once begins execution, cannot be interrupted by host or channel events. Each active channel intents to be
serviced, being granted time for Thread execution. Since one microengine handles several channels
operating concurrently, the Function threads must be executed serially.
The task of the Scheduler is to recognize and prioritize the channels needing service and to grant execution
time to each channel. The time given to an individual Thread for execution or service is called a Time Slot.
The duration of a time slot is determined by the number of instructions executed in the Thread plus SDM
wait-states received, and varies in length.
At any time, an arbitrary number of channels can require service. To request service, channel logic, eTPU
microcode or Host application notifies the Scheduler by issuing a Service Request.
1. grant bits are also cleared in the next clock, when the service channel is chosen, or when the microengine is idle, using
the same scheme.
2. Priority inversion would occur in the following situation: no channel is requesting service, and the current time slot is
primarily assigned to a low-priority channel. If the Scheduler was not reset to time slot one and two channels requested
service at the same time, one with high priority and the other with low priority, the channel to be serviced would be the
low-priority channel.
A B
1 2 3 4 5 6 7 1 2 3 4 5
H M H L H M H H M H L H
HIGH
MIDDLE
LOW
When priority is passed to another level, that level is serviced and the fixed-priority-level sequence is
resumed with the next time slot.
Reset Slot
Number
Cycle A Cycle B Cycle C (truncated) Cycle D
SLOT Number 6 7 1 2 3 4 5 6 7 1 2 3 1 1 2 3 1
2 2 1
High Pend Count 0 2 1 0 2 1 0 1 0
Service High
1 2 1 1
Middle Pend Count 1 0 1 0 2 1 0 1 0 1 0
Service Middle
2 2
Low Pend Count 0 2 1 0 2 1 0
Service Low
SLOT ASSIGNMENTS:
DH, DH, DL - Default Service High, Middle or Low
X H>L, H>M, M>H, M>L - Priority Passing Scheme
- X New Service Requests Arrive at a Specific Priority Level
ID - Idle (no service request)
Examples of priority passing are shown in Figure 21-44. Each cycle contains seven time slots (or less if
no service request exist). In cycle B, no high-level or middle-level service requests are present before time
slot three which is assigned by default to high-level priority. Thus, time slot three is passed to the low level.
In cycle B there are also no middle-level service requests before time slot six, so it passes the priority to a
requesting high-level channel. During time slot six no more high level requests are left, but two new
middle-level requests arrive, and there are also three low level pending service requests. Thus, time slot
seven of cycle B and time slot one of cycle C are passed to the middle-level which is the next priority level
after high. Time slots two and three of cycle C are passed to the low level which contains the three
remaining channel service requests. At time slot three of cycle C the last low level request is serviced, and
the Scheduler passes to idle state. At this point the cycle C is truncated and the Scheduler passes to time
slot one of cycle D.
else else
servicin if any
At the end service if any service if any service
g request
of time slot it on time slot request it on time slot request it on time slot
priority of priority
of priority of priority
An example of the priority passing disabling scheme is illustrated in Figure 21-45. The sequence of service
requests is the same as in the example of Figure 21-44, and although the time slot incrementing differs, the
priorities granted are the same for cycle B. Cycle C has one of the low priority channels serviced before
the second middle one. Cycle D, however, no longer has the priority inversion.
In cycle B, after the time slot 2 only a low priority request remains, so the time slot count advances directly
to 4, which has a low priority assigned. Time slot keeps on 4 for the next service, as only a low priority
request remains also, and only time slot 4 is assigned to low. Two high priority services contend for the
next time slot 5 (assigned to High). The second high priority channel is serviced on the next time slot,
jumped to 7 because there is no middle request, ending cycle B. Cycle C starts with time slot 2, as there
are no high priority requests and two middle and two low ones. After the first middle service, time slot
count skips 3 assigned to high (no high requests), and services a low priority channel on time slot 4. It
follows the same scheme until there are no other requests and cycle C is truncated, resetting the time slot
counter to 1.
Cycle D begins with a middle request, jumping to time slot 2. During this service two requests arrive, one
high and one middle. Unlike what happened with priority passing, the next serviced is the high priority
channel, as the time slot increments to 3. The second middle priority channel request in cycle D is finally
serviced next, on time slot 6.
Reset Slot
Number
Cycle A Cycle B Cycle C (truncated) Cycle D
SLOT Number 6 7 1 2 4 4 5 7 2 4 6 4 1 2 3 6 1
2 2 1
High Pend Count 0 2 1 0 2 1 0 1 0
Service High
1 2 1 1
Middle Pend Count 1 0 1 0 2 1 0 1 0 1 0
Service Middle
2 2
Low Pend Count 0 2 1 0 2 1 0
Service Low
Slot Assignment DM DH DH DM DL DL DH DH DM DL DM DL ID DM DH DM ID
SLOT ASSIGNMENTS:
DH, DH, DL - Default Service High, Middle or Low
X
- X New Service Requests Arrive at a Specific Priority Level
ID - Idle (no service request)
Microcycles
Time Slot 1 2 3 4 5 6
For parameters shared by both Engines, eTPU provides hardware semaphores. Coherency is assured
given the semaphores are used to prevent concurrent access to the changing parameters. Microengine can
request semaphores using specific microinstructions.
Neither Host nor CDC have access to the hardware semaphores, but they can be combined with microcode
transfer mechanisms if Host must coherently access parameters which are also shared by both Engines.
1. a microengine access to the SDM in the moment CDC is performing the transfer may suffer a maximum of two wait-states.
1. The maximum number of Host wait states on CDC occurs when both microengines overlap their TSTs, delayed 3 eTPU
clocks from each other.
2. One microcycle takes two eTPU clocks. Microengines get wait-states in multiples of microcycles, while Host and CDC
wait-states are multiples of eTPU clocks.
NOTE
SDM memory error detection and correction does not affect the number of
wait-states to host due to CDC (see Section 21.3.6.2, “Memory Error
Support”).
CDC can be used to atomically fix SDM soft errors. For more details, see
Section 21.3.6.2.3, “Error Fixing”.
1. if microengine tries to access the SDM in the following microcycles, the third and fourth consecutive accesses are
considered the first and second of a new back-to-back dual access.
b. the SDM was not accessed during the last arbitration slot for the microengine and the host does
not loose the access to the other engine in the current arbitration slot1.
c. CDC is transferring data, after its first (read) access. Note that the CDC can be in middle of a
data transfer of another pair of parameters, unrelated to the ones that microengine tries to
access.
3. The eTPU microengine takes priority for SDM accesses under either of the following conditions:
a. the Host CPU or CDC has done a data transfer during the last access arbitration slot for the
engine1. Also, the Host CPU does not hold a pending access against the other eTPU
microengine.
b. the microengine is arbitrating for the access of its second parameter in a back-to-back access1.
All pairs of back-to-back parameter accesses are coherent with respect to Host and CDC (not
to the other microengine).
The direction (read or write) of any individual access by Host or microengine is irrelevant to the
arbitration. The use of Normal or PSE SDM area by the Host is also irrelevant to the arbitration.
The first parameter preloading in a TST is considered first access by the arbiter, regardless of any access
made at the END microinstruction of the previous thread, i.e.: the last access of a thread and the first
preload are never considered a back-to-back access. On the other hand, the TST preload accesses are
considered back-to-back and are, therefore, atomic with respect to Host or CDC.
NOTE
The Zero SDM operation (see the eTPU Reference Manual for details) is
considered an SDM access for arbitration purposes both on writes and reads;
the fact that read SDM data is discarded is irrelevant for arbitration.
ETPUECR - Engine Configuration Register (see Section 21.2.5.5, “ETPUECR - eTPU Engine
Configuration Register). The EDF compares two consecutive samples. If both samples have the same
value, the input signal state is updated. Note that when the FPSCK field selects the eTPU clock divided by
two, the EDF works like the TPU1 four-clock digital filter.
sample digital filter must sample two points in the pulse to detect it. Table 21-24 shows the minimum
guaranteed detected pulse width and the maximum filtered noise pulse width. The table refers only to the
digital filter operation. The external pulses may have to be wider (to ensure detection) or narrower (to
ensure filtering) depending on the rise/fall delay differences in the MCU receivers and internal logic.
Delays introduced by synchronizer, filter and edge detection logic are explained in the eTPU Reference
Manual.
NOTE
If the ETPUTBCR field TCRCF selects the filter clock of the channels (see
Section 21.2.6.1, “ETPUTBCR - eTPU Time Base Configuration Register),
the TCRCLK filter will be clocked as if FCSS=0, always dividing eTPU
clock /2 using FPSCK, regardless if FCSS is 0 or 1.
SYSTEM FILTER
CLOCK/2 CLOCK
GEN. eTPU ANGLE
to all channel filter
clocks COUNTER
(EAC)
ETPUTBCR[TCRCF1]
ETPUTBCR[TCRCF0] 0 1 ETPUTBCR ETPUTBCR
[TCR2CTL] [TCR2P]
FILTER CLOCK
3 6
Integr.
PROGRAMMABLE 1 Angle Mode
TCRCLK DIGITAL
Pin SYNC. 2 samp 011 ETPUTBCR[AM]
FILTER 0
010
TCR2 0 23
001 PRESC. 1
TCR2
000 1, 2, . . . , 64 0
SYSTEM CLK / 8
100
STAC bus
no clock 111
The TCRCLK signal input is passed through a synchronizer and a programmable digital filter. In Angle
Mode with AM=01, synchronizer and filter are also used in Channel 0, replacing its input synchronizer
and filter, to get the same timing in the EAC and Channel 0. The TCRCLK synchronizer is an improved
filter that provides best latency while maintaining proper noise filtering (see Section 21.2.6.1,
“ETPUTBCR - eTPU Time Base Configuration Register field TCRCF[0:1] — TCRCLK Signal Filter
Control).
The TCR2 bus runs through all the local engine channels
The TCR2 value is readable to the host through the ETPUTB2R register (refer to Section 21.2.6.3,
“ETPUTB2R - eTPU Time Base 2 (TCR2) Visibility Register). When the TCR2 bus value is imported
from the STAC bus (STAC client mode), TCR2 is not writable by the microcode, and read access from
the microcode or from the host reflect the imported TCR2 value.
Note that when TCR2 works in Angle Mode, it does not count directly from the TCR2 clock input which
indicates tooth signal transition. Its Angle counter is controlled by the Count Control and High Rate logic
(see the eTPU Reference Manual for details), which provides the interpolated pin position, and handle
cases of missing tooth, acceleration, de-acceleration and mechanical corrections.
The EAC uses the TCRCLK signal to get the tooth transition indications. The TCR2CTL field in
ETPUTBCR has to be set for the appropriate tooth edge detection rise, fall, “rise-and-fall” or none. TCR2
count clock comes from the EAC control and not directly from the physical tooth. This way the EAC
control processes the signal transitions and handles missing teeth and flywheel mechanical corrections.
Note that when TCR2CTL selects “none” for tooth edge selection, the TCR2 is not necessarily frozen, but
can still be incremented by the EAC logic.
In Angle Mode, eTPU channel 0, 1 or 2 operation is combined with the EAC operation. When channel 0
is selected for EAC operation, the TCRCLK digital filter is used both by the EAC and by channel 0 to get
full synchronization between the two logics.
The eTPU Angle Counter (EAC) logic runs continuously and updates the TCR2 Angle counter,
eliminating the microcode latency in updating the TCR2 value.
Note that Angle Mode is not available for STAC bus clients: configuring both at the same time brings
unspecified results. When TCR2 is a stand-alone counter or a STAC Bus server, the same value that is
driven to the internal TCR2 bus is also exported to the STAC bus (either Time Count or Angle).
STAC bus configuration is provided by the ETPUREDCR bits REN1/2 and RSC1/2. REN1/2 enable the
STAC interface to interact with the resource (either TCR1 or TCR2 bus). RSC1/2 configure the resource
(either TCR1 or TCR2 bus) as Server or Client.
Each time base / angle count resource from each engine receives a unique 4-bit hard-wired address that
identifies it as a potential server. This address is used by the STAC Controller to coordinate which resource
will drive the bus at a given STAC time-slot. For any time-slot there is a server driving the bus upon
selection of the STAC Controller, and there may be a client linked to that server by the ETPUREDCR bits
SRV1/2 on each Engine. When the server address on the STAC bus matches the value in SRV1/2, the client
will load the STAC information into the appropriate resource. For information on eTPU STAC Bus
configuration refer to Section 21.2.6.4, “ETPUREDCR - eTPU STAC Configuration Register.
The eTPU does not include a STAC Controller module, which is instantiated once in the system
integration.
NOTE
Setting a timebase as client of itself is not allowed.
eTPU A and B
ETPUMCR[GTBE]
etpu_gtbe_in etpu_gtbe_out
eTPU C
eMIOS
ETPUMCR[GTBE]
Memory Error support features comprises SCM and/or SDM error detection, correction, report, and soft
error fix.
A complete description of the signature calculation procedure can be found in Section 21.4.4, “MISC
Algorithm.
Once started by the Host the MISC runs continuously, restarting after the completion of each cycle, when
it sets the ETPUMCR register flag SCMMISC (see Section 21.2.5.1, “ETPUMCR - eTPU Module
Configuration Register). The average time for a MISC calculation can be measured by checking
SCMMISC state at regular intervals, incrementing a counter and clearing SCMMISC if it is set.
MISC accesses to the SCM array are executed if none of the engines is accessing the SCM, to avoid
degradation of the microengine performance: it happens while no channel is being serviced. An ongoing
MISC operation can be aborted by writing 0 to SCMMISEN.
The Host must load the register ETPUMISCCMPR (see Section 21.2.5.3, “ETPUMISCCMPR - eTPU
MISC Compare Register) with the expected value to be found at the end of the MISC cycle, and then start
the signature calculation writing bit SCMMISEN=1 in register ETPUMCR (see Section 21.2.5.1,
“ETPUMCR - eTPU Module Configuration Register). MISC zeroes the signature accumulator and starts
reading SCM data and calculating the signature. After last SCM position is read, MISC compares the value
in signature accumulator against the value in ETPUMISCCMPR: if there is a mismatch MISC stops, a
Global Exception is issued and the bit SCMMISF in register ETPUMCR assumes value 1. If no mismatch
is found, MISC repeats the procedure automatically. When signature is being calculated, SCM address
starts at the last SCM address and counts down to 0. The conditions for executing a MISC operation are
(see also Table 21-21):
• Both microengines in idle state (no channel is being serviced) or stopped, in any combination (e.g.,
engine 1 idle with engine 2 stopped).
• ETPUMCR bit VIS = 0.
• ETPUMCR bit SCMMISEN=1.
Note that MISC can run regardless of SCM implementation type (RAM or ROM).
If SCMMISEN=0 or VIS=1, the MISC logic stays at its initial state, with address counter pointing to the
last SCM position and accumulator reset.
MISC can also be used to perform single-bit error fixes in the SCM. For more details, see
Section 21.3.6.2.3, “Error Fixing”).
1. one wait-state more, compared with eTPU versions before eTPU2 and previous eTPU2 without ECC support.
“ETPUCERDR - eTPU Code Error Report Data Register”). The occurrence of a non-correctable error
overwrites the report register values from a correctable error, either on SDM (DCERR=1) or SCM
(CCERR=1).
The last address, syndrome and data of a correctable SDM access can also be sampled into registers
ETPUDERAR, ETPUDERSR and ETPUDERDR, but only if the ETPUMESR bit DNCERR is 0. That
prevents access address, syndrome and data from a correctable error to overwrite the same information
from a non-correctable access. Similarly, the last address, syndrome and data from a correctable SCM
access are stored in registers ETPUCERAR, ETPUCERSR and ETPUCERDR only if ETPUMESR bit
CNCERR is 0. For either SDM or SCM, a new correctable error overwrites the report registers’ values
from an earlier correctable error, but report values from a non-correctable error are not overwritten, as long
as bit DNCERR/CNCERR is asserted, neither by a new correctable error nor by a non-correctable one.
The sampling of SDM and SCM error report registers can be disabled through the ETPUMECR bits
DRDIS and CRDIS, respectively. When DRDIS (CRDIS) is asserted, the update of the SDM (SCM) error
report registers is disabled, but not of ETPUMESR bits DCERR, DNCERR (CCERR, CNCERR). DRDIS,
CRDIS must be set before reading the respective report registers to assure their coherent reading,
preventing them to be updated between reads.
For microengine accesses, the Global Exception interrupt asserts whenever a non-correctable error is
detected, either on SCM or SDM (see Section 21.3.2.2, “Interrupts and Data Transfer Requests”). These
errors are flagged by ETPUMCR bits SCMERR and SDMERR, respectively (see Section 21.2.5.1,
“ETPUMCR - eTPU Module Configuration Register”). Single bit errors are corrected and do not generate
Global Exceptions.
For host accesses a bus error is issued whenever a non-correctable error is detected, either on SCM or
SDM (but not through the CDC) and it also generates a Global Exception. Single bit errors are corrected
(if the error correction feature is available) and do not cause bus transfer errors.
NOTE
Error detection also works for host accesses to the PSE area (see
Section 21.3.2.3.4, “Parameter Sign Extension Area”). In this case, error is
not detected in the most significant byte (bits 0:7). Also, because of sign
extension, error is always detected on the bits 8:15, regardless if they are
selected, whenever the most significant byte is read.
Correctable errors, either on SDM or SCM, can also be monitored by polling of the ETPUMESR bits
DCERR and CCERR.
The error detection logic in SDM and SCM can be disabled by setting the ETPUMECR bits DEDD and
CEDD, respectively. The disabled state turns ineffective any action due to error detection, including error
correction.
SCM error detection and correction also works for MISC accesses, which are considered microengine
accesses for all purposes.
The executing thread is affected by a non-correctable error as follows:
• if ETPUMECR bit DTEND=1: on SDM errors due to a read operation, if the instruction is not
also an END, the following instruction automatically executes an END, and its operations may be
executed, totally or partially. On SDM errors during the TST preload, the thread automatically ends
on the first instruction, if the error occurs on a preload parameter selected by the entry point bit PP
(see the eTPU Reference Manual for details). The first instruction may be executed totally or
partially. Data read into P or DIOB may be corrupted in either case.
• if ETPUMECR bit DTEND=0: the TST or thread continues the execution flow normally. Data
read into P or DIOB may be corrupted in either case.
• if ETPUMECR bit CTEND=1: on SCM errors, the corrupted instruction is not executed, instead
replaced by a simple END. Due to instruction prefetching, an error may be detected and yet not
affect the thread execution. However, an error detected in a prefetched instruction may cause error
report and global interrupts, even if not executed. If a non-correctable error occurs on the entry
table read during TST (see the eTPU Reference Manual for details), the first instruction in the
thread is replaced with a simple END, a global exception is issued and the reports and flags are
normally updated.
• if ETPUMECR bit CTEND=0: the execution flow continues normally, and the results depend on
the particular instruction corruption.
SYNDn[4:0] SYNDn[4:0]
Result Result
(hex) (hex)
Table 21-27 shows the definition of the SCM syndrome field as it reads on the ETPUCERSR register (see
Section 21.2.8.14, “ETPUCERSR - eTPU Code Error Report Syndrome Register”).
SYND[6:0] SYND[6:0]
Result Result
(hex) (hex)
Similarly, SCM errors can be injected into the SCM read data path through the registers ETPUCEIAR,
ETPUCEIDPR and ETPUCEIPPR, enabled by the ETPUMECR bit CEIE (see Section 21.2.8.9,
“ETPUCEIAR - eTPU Code Error Injection Address Register”, Section 21.2.8.10, “ETPUCEIDPR -
eTPU Code Error Injection Data Pattern Register” and Section 21.2.8.11, “ETPUCEIPPR - eTPU Code
Error Injection Parity Pattern Register”). Errors are injected on host accesses to the address specified in
ETPUCEIAR when ETPUMCR bit VIS=1, or on microengine and MISC accesses when VIS=0.
Worst-case latency for a channel depends both on the function running on that channel and on the activity
on other channels. Since the 32 eTPU channels must all share the same execution unit, execution speed of
a particular function varies with each system. The PWM thread response is faster if there are no other
active channels than if other channels are also active. In addition, changing the priority scheme and
channel number assignments can change performance for a function even if the same set of functions are
still active.
Each function is divided into treads, as shown in Figure 21-51 (see also the eTPU Reference Manual for
details). The eTPU Microengine executes one thread of a function at a time. For example, the Microengine
might execute thread 1 of PWM, then thread 3 of DIO, then thread 2 of PWM, then thread 2 of SM, and
so on. The amount of time the eTPU Microengine grants a function to execute a thread varies with the
number of microcode instructions in the thread.
Since there is only one eTPU Microengine (in each eTPU Engine), the eTPU cannot actually execute the
software for multiple functions simultaneously. However, the hardware for each of the channels is
independent. This means that, for example, all 32 channel signals can change thread at the same moment,
provided that the function software sets up the channel hardware to do so beforehand.
With Host CPU code, the system designer assigns functions to channels and initializes the functions. After
initialization, functions typically run without Host intervention, except for eTPU channel interrupts to the
Host to give or receive information. Most functions can run continuously with periodic servicing from the
eTPU Microengine. As required, the channels request service from the eTPU Microengine, and the eTPU
Scheduler determines the order in which the channels are serviced. Worst-case latency for a channel can
be derived from the details of the priority scheme that the scheduler uses (see Section 21.3.3, “Scheduler).
S1 S1
S2 S3 S4 S2 S3 S4
S5 S6 S5 S6
S2 S3 S4
SM Function Threads
H M H L H M H
Time Slots of
Varying Lengths
This sequence scheme gives higher-priority channels more service time than lower-priority channels.
High-priority channels are allocated four of seven time slots, middle-priority channels are allocated two
of seven time slots, and low-priority channels are allocated one of seven time slots.
H M H L H M H H M H L H M H H M H
This implies that single parameter Microengine to Microengine communication does not affect the
performance. The Microengine which waits for the semaphore will loop until it is freed by the other
Microengine. This time depends on the eTPU application. The system designer should estimate the
percentage of Microengine to Microengine coherent parameter communication that will result in eTPU
semaphore loops, and multiply it with the average number of eTPU clocks the Microengine loops for each
such transfer. This percentage is called CCR (Communication Collision Rate).
A 100% collision rate for a system is the theoretical worst case. In many systems, however, the RCR,
CPCR and CCR would be very low, sometimes even near 0%. This is because the eTPU is an independent
processor capable of servicing most function needs, so that the Host rarely needs to access the eTPU SDM.
Also coherent Microengine to Microengine communication of more than one parameter may be rare. To
find a realistic RCR, CPCR the system designer should evaluate the Host code and find the percentage of
time it accesses the eTPU SDM with or without using the CDC. This percentage gives a good RCR and
CPCR. The eTPU application provides a good estimation of CCR.
NOTE
The programming practice of polling a flag in the eTPU SDM causes a very
high RCR and should be avoided in high-performance systems.
After the collision rate for a system is found, it can be applied to the WCL calculations for each channel.
The system designer can use the collision percentage and the number of SDM accesses (with and without
semaphores) to estimate the eTPU loop time for a function. Note that in old TPU functions CPCR and CCR
are both zero.
The estimation of eTPU wait time is as follows:
Variables:
N1 = Number of simple RAM accesses in the longest thread
RCRWait = Maximal eTPU clocks wait time for simple RAM collision = 2
CPCRWait = Average eTPU clocks for Coherent Parameter Transfer (using CDC).
N2 = Number of eTPU-eTPU semaphore RAM accesses in the longest thread
CCRWait = Average eTPU clocks for Microengine-Microengine communication transfer.
Estimated Wait Time:
Function eTPU maximal wait time =
N1 *(RCR * RCRWait + CPCR * CPCRWait) + N2* CCR * CCRWait
Channel X Channel X
Serviced Serviced Next
Table 21-28. Longest Threads and RAM Accesses for old TPU Functions
Table 21-28. Longest Threads and RAM Accesses for old TPU Functions
H M H L H M H H
CHANNEL 0 CHANNEL 0
SERVICED SERVICED
= 10-CYCLE TIME SLOT TRANSITION CHANNEL 1
SERVICED
= 4-CYCLE NOP INSTRUCTION
Channel 1 will be serviced in the middle-priority time slot before channel 0 is serviced again.
3. Add time for the six-clock CPU time-slot transitions. See Figure 21-55 and Table 21-30.
A four-clock NOP occurs after each channel is serviced since there is one channel in each priority
level, i.e., a new cycle for a priority level is started after each channel is serviced. Time-slot
transitions occur after each time slot.
H M H L H M H H
Channel 0 will be serviced twice and channel 2 once before channel 1 is serviced again.
3. Add time for the six-clock CPU time-slot transitions. See Figure 21-56 and Table 21-31.
H M H L H M H H M H L H
Channel 0 will be serviced four times and channel 1 twice before channel 2 is serviced again.
3. Add time for the ten-clock CPU time-slot transitions and the four-clock NOPs. See Figure 21-57
and Table 21-32.
Table 21-32. Worst Case Latency for Channel 2
Four Channel 0 worst-case service times 100 clocks
Two Channel 1 worst-case service time 92 clocks
Channel 2 worst-case service time 11 clocks
Seven 6-clock time-slot transitions 42 clocks
Total clocks 245 clocks
Note that DIO function optimized for eTPU hardware can use double transition mode to measure
two pin transitions at a time and reduce the service time, improving the overall system performance
and latency.
achieve a high time and low time of 2475 ns under worst-case conditions. This was derived using
the longest PWM thread of 24 CPU clocks. This longest thread is actually thread 2, the thread that
is entered after the pin has just gone high. Thread 3, the thread that is entered after the pin has just
gone low, requires only 2 CPU clocks. Therefore, in the first-pass example, the high time was
correctly derived, but the low time is actually shorter than was estimated.
With this system configuration, worst-case service time for each active channel is determined as follows:
a. Longest thread of PWM is 24 CPU clocks with four RAM accesses.
24 + ((4 RAM accesses+1) * 0 * 2 CPU clock waits) = 24 CPU clocks
Channels 0-2 worst-case service time = 24 CPU clocks.
b. Longest thread of PPWA in mode 0 is 44 CPU clocks with nine RAM accesses.
44 + ((9 RAM accesses +1)* 0 * 2 CPU clock waits) = 44 CPU clocks
Channel 8 worst-case service time = 44 CPU clocks.
c. Longest thread of DIO is ten CPU clocks with four RAM accesses.
10 + ((4 RAM accesses+1) * 0 * 2 CPU clock waits) = 10 CPU clocks
Channel 15 worst-case service time = 10 CPU clocks.
To find the WCL for channel 0, assume channel 0 has just finished service.
Map the channels in the H-M-H-L-H-M-H sequence. See Figure 21-58.
H M H L H M H H M H L
Conclusion: with this system configuration, worst-case latencies for channels 0 and 1 are too
high (WCL for channel 1 is the same as WCL for channel 0). Try a different system
configuration.
To find the WCL for channel 0, assume channel 0 has just finished service. Map the channels in the
H-M-H-L-H-M-H sequence. See Figure 21-59.
H M H L H M H H M H L
Conclusion: with this system configuration, the WCL of both channel 0 and channel 1 is 3.85 ms, which
is within the limit of 4 ms needed for a 50-kHz PWM.
Next, find the WCL for channel 2. Assume channel 2 has just finished service. Map the channels in the
H-M-H-L-H-M-H sequence. See Figure 21-60.
H M H L H M H H M H L
Conclusion: with this system configuration, the WCL for channels 2 and 8 is 4.7 ms, which is within the
40 and 80 ms WCL requirements.
Notice that channels 2 and 8 are well within their WCL requirements. The system could be reconfigured
as shown in Table 21-35 to give channels 0 and 1 a larger margin while still keeping channels 2, 8 and 15
within their WCL requirements.
5. identify the error source (host, microengine or MISC/CDC) by checking the field ERR_ACC in the
register(s) ETPUCERAR/ETPUDERAR; take or schedule the appropriate application-dependent
recover actions.
6. update error statistics as needed; it may include recording the access source, address, data and
syndrome from the registers ETPUCERAR/ETPUDERAR, ETPUCERDR/ETPUDERDR,
ETPUCERSR/ETPUDERSR.
7. save the status of non-correctable error overflows flagged in the ETPUMESR bit(s)
CNCOVR/DNCOVR.
8. set the ETPUMECR bit(s) CRDIS/DRDIS to the state(s) saved in the step 2. That assures the
access coherency of a preempted Correctable Error Service Procedure (which may have set
CRDIS/DRDIS before this procedure) is not disturbed.
9. clear ETPUMESR bits CNCOVR/DNCOVR and CNCERR/DNCERR at once, in a single write to
ETPUMESR.
10. use the overrun status saved on step 7 to update the error statistics, as needed.
11. check the other Global Exception flags in ETPUMCR; take or schedule the appropriate
(application dependent) recover actions.
12. clear the Global Exception, writing ETPUMCR bit GEC=1.
The MISC signature generation starts by clearing the MISC Accumulator value to 0 and preloading the
MISC Counter with the highest SCM address. It then steps through each address decrementing the counter,
reading 32 bit values and following the algorithm below:
If the least significant bit in MISC is 1 then
MISC = MISC right shifted by 1 bit
MISC = MISC XOR 0x80400007
else
MISC = MISC right shifted by 1 bit
end if
MISC = MISC XOR RAM data
The code example below shows an excerpt of C code that calculates the MISC signature for a given array
of data, based on the previous algorithm:
#define SCM_size (MAX_SCM_ADDRESS / 4) /* last byte address - converted to 32-bit word */
#define POLY 0x80400007 /* G(x) = 1 + x1 + x2 + x22 + x31 */
/*******************************************************************************
FUNCTION : void calc_misc()
PURPOSE : This function calculates the MISC value.
INPUTS NOTES : none
RETURNS NOTES : MISC value
GENERAL NOTES : the array ’unsigned int data[]’ represents the actual memory
array, organized in 32-bit words.
*******************************************************************************/
unsigned int calc_misc (void)
{
int j; /* loop counter */
for (j = (SCM_size-1); j >= 0 ; j--) { /* SCM_size has the number of 32-bit words in SCM */
};
The value calculated by this algorithm must be loaded into register ETPUMISCCMPR prior to activating
the SCM MISC calculator in eTPU. Once the MISC calculator is activated (bit SCMMISEN in register
ETPUMCR is written to 1) eTPU itself will start this procedure1 reading the SCM whenever allowed by
microengine. At the end of the cycle, when all the array has been read and the SCM signature is calculated,
the Host CPU can be notified via Global Exception if the MISC Accumulator does not match the value in
ETPUMISCCMPR.
The average time taken by MISC to complete the signature of the whole SCM can be given by the formula:
Average MISC period = S / (4 * f * (1 - L))
where f is clock frequency, S is SCM size in bytes and L is eTPU load (as a percentage of execution clocks
over a period of time, including TST clocks).
Further detail on MISC calculation can be found on Section 21.3.6.1, “SCM Test - Multiple Input
Signature Calculator.” The application note AN2192 - Detecting Errors in the Dual Port RAM
(DPTRAM) Module is also a good source of information (although it refers to TPU) on MISC signature.
1. eTPU MISC hardware is optimized to read 32-bit words from memory and to calculate this CRC in parallel, rather than
shifting one bit at a time. The actual implementation inside eTPU, although bringing to the same results, does not match
exactly the algorithm shown here.
22.1.1 Features
The ECSM has this major feature:
• Registers for capturing information on memory errors.
Offset from
Reset
ECSM_BASE_ADDR Register Size Access Section/Page
Value1
(0xFFF4_0000)
0x0010-0x0023 Reserved
0x0007–0x3FFF Reserved
1
Please refer to the register definition. U = undefined at reset.
Field Description
Field Description
REV[15:0] Revision
The REV[15:0] field is specified by an input signal to define a software-visible revision number.
Field Description
Field Description
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R MC[16:31]
W
Reset 1 1 1 0 1 1 0 0 0 0 0 0 0 0 0 0
Field Description
0 1 2 3 4 5 6 7
W
Reset 0 1 0 0 0 0 0 0
Field Description
0 Power-on Reset
POR 1 Last recorded event was caused by a power-on reset (based on a device input signal)
1 Device-input Reset
DIR 1 Last recorded event was a reset caused by a device input reset.
3–7 Reserved
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Field Description
NOTE
The SRAM_WS bit must remain at 1 when the platform, flash, and
peripheral clock frequency is greater than 60 MHz.
Field Description
0–1 Reserved
The occurrence of a single-bit RAM correction generates an ECSM ECC interrupt request as signalled by the
assertion of ECSM_ESR[R1BC]. The address, attributes and data are also captured in the ECSM_REAR,
ECSM_RESR, ECSM_REMR, ECSM_REAT and ECSM_REDR registers.
The occurrence of a single-bit flash correction generates a MCM ECC interrupt request as signalled by the assertion
of ECSM_ESR[F1BC]. The address, attributes and data are also captured in the ECSM_FEAR, ECSM_FEMR,
ECSM_FEAT and ECSM_FEDR registers.
4–5 Reserved
6 Enable RAM Non-Correctable Reporting. The occurrence of a non-correctable multi-bit RAM error generates an
ERNCR ECSM ECC interrupt request as signaled by the assertion of ECSM_ESR[RNCE]. The faulting address, attributes,
and data in either the 512 KB or 80 KB array are also captured in the ECSM_REAR, ECSM_RESR, ECSM_REMR,
ECSM_REAT, and ECSM_REDR registers.
0 Reporting of non-correctable RAM errors is disabled.
1 Reporting of non-correctable RAM errors is enabled.
7 Enable Flash Non-Correctable Reporting. The occurrence of a non-correctable multi-bit flash error generates an
EFNCR ECSM ECC interrupt request as signaled by the assertion of ECSM_ESR[FNCE]. The faulting address, attributes,
and data are also captured in the ECSM_FEAR, ECSM_FEMR, ECSM_FEAT, and ECSM_FEDR registers.
0 Reporting of non-correctable flash errors is disabled.
1 Reporting of non-correctable flash errors is enabled.
interrupt and another properly-enabled ECC event occurs, the ECSM hardware automatically handles the
ECSM_ESR reporting, clearing the previous data and loading the new state and thus guaranteeing that
only a single flag is asserted.
To maintain the coherent software view of the reported event, the following sequence in the ECSM error
interrupt service routine is suggested:
1. Read the ECSM_ESR and save it.
2. Read and save all the address and attribute reporting registers.
3. Re-read the ECSM_ESR and verify the current contents matches the original contents. If the two
values are different, repeat from step one.
4. When the values are identical, write a 1 to the asserted ECSM_ESR flag to negate the interrupt
request.
See Figure 22-9 and Table 22-10 for the ECC status register definition.
Offset: ECSM_BASE_ADDR + 0x0047 Access: User read/write
0 1 2 3 4 5 6 7
R 0 0 R1BC F1BC 0 0 RNCE FNCE
W w1c w1c w1c w1c
Reset 0 0 0 0 0 0 0 0
Field Description
0–1 Reserved
2 RAM 1-bit Correction. This bit can only be set if ECSM_ECR[EPR1BR] is asserted. The occurrence of a
R1BC properly-enabled single-bit RAM correction generates an ECSM ECC interrupt request. The address, attributes
and data are also captured in the ECSM_REAR, ECSM_RESR, ECSM_REMR, ECSM_REAT and ECSM_REDR
registers. To clear this interrupt flag, write a 1 to this bit. Writing a 0 has no effect
Field Description
6 RAM Non-Correctable Error. The occurrence of a properly-enabled non-correctable RAM error generates an
RNCE ECSM ECC interrupt request. The faulting address, attributes, and data in either the 512K or 80K array are also
captured in the ECSM_REAR, ECSM_RESR, ECSM_REMR, ECSM_REAT, and ECSM_REDR registers. To
clear this interrupt flag, write a 1 to this bit. Writing a 0 has no effect.
0 No reportable non-correctable RAM error has been detected.
1 A reportable non-correctable RAM error has been detected.
7 Flash Non-Correctable Error. The occurrence of a properly-enabled non-correctable flash error generates an
FNCE ECSM ECC interrupt request. The faulting address, attributes and data are also captured in the ECSM_FEAR,
ECSM_FEMR, ECSM_FEAT, and ECSM_FEDR registers. To clear this interrupt flag, write a 1 to this bit. Writing
a 0 has no effect.
0 No reportable non-correctable flash error has been detected.
1 A reportable non-correctable flash error has been detected.
If both a flash and RAM non-correctable error occur at the same time, the ECSM records the event with
the highest priority, RNCE, and finally FNCE. If both a 512K and 80K RAM non-correctable error occur
at the same time, the ECSM records the event with the 512K array.
Field Description
In LSM, the system is seen as having only one core. In DPM, only the core in lake_A, which is core_0, can perform
inversions by setting this bit.
The reset value of the bit is 0 and as a result, RAM data inversions can be requested from any master module.
Software must ensure the proper setting of this bit.
1 Reserved
Field Description
2 Force RAM Continuous 1-Bit Data Inversions. The assertion of this bit forces the RAM controller to create 1-bit data
FRC1BI inversions, as defined by the bit position specified in ERRBIT, continuously on every write operation.
The normal ECC generation takes place in the RAM controller, but then the polarity of the bit position defined by
ERRBIT is inverted to introduce a 1-bit ECC event in the RAM.
After this bit has been enabled to generate another continuous 1-bit data inversion, it must be cleared before being
set again to properly re-enable the error generation logic.
The normal ECC generation takes place in the RAM controller, but then the polarity of the bit position defined by
ERRBIT is inverted to introduce a 1-bit ECC event in the RAM.
After this bit has been enabled to generate a single 1-bit data inversion, it must be cleared before being set again
to properly re-enable the error generation logic.
6 Force RAM Continuous Non-correctable Data Inversions. The assertion of this bit forces the RAM controller to
FRCNCI create 2-bit data inversions, as defined by the bit position specified in ERRBIT and the overall odd parity bit,
continuously on every write operation.
After this bit has been enabled to generate another continuous non-correctable data inversion, it must be cleared
before being set again to properly re-enable the error generation logic.
The normal ECC generation takes place in the RAM controller, but then the polarity of the bit position defined by
ERRBIT and the overall odd parity bit are inverted to introduce a 2-bit ECC error in the RAM.
0 No RAM continuous 2-bit data inversions are generated.
1 2-bit data inversions in the RAM are continuously generated.
7 Force RAM One Non-correctable Data Inversions. The assertion of this bit forces the RAM controller to create one
FR1NC 2-bit data inversion, as defined by the bit position specified in ERRBIT and the overall odd parity bit, on the first write
operation after this bit is set.
The normal ECC generation takes place in the RAM controller, but then the polarity of the bit position defined by
ERRBIT and the overall odd parity bit are inverted to introduce a 2-bit ECC error in the RAM.
After this bit has been enabled to generate a single 2-bit error, it must be cleared before being set again to properly
re-enable the error generation logic.
0 No RAM single 2-bit data inversions are generated.
1 One 2-bit data inversion in the RAM is generated.
Field Description
8 Reserved
9–15 Error Bit Position. The vector defines the bit position which is complemented to create the data
ERRBIT inversion on the write operation. For the creation of 2-bit data inversions, the bit specified by this field plus the odd
parity bit of the ECC code are inverted. The platform RAM controller follows a vector bit ordering scheme where LSB
= 0. Errors in the ECC syndrome bits can be generated by setting this field to a value greater than the RAM width.
For example, consider a 64-bit RAM implementation.
The following association between the ERRBIT field and the corrupted memory bit is defined:
if ERRBIT = 0, then RAM[0] is inverted.
if ERRBIT = 1, then RAM[1] is inverted.
. . .
if ERRBIT = 63, then RAM[63] is inverted.
if ERRBIT = 64,then ECC Parity[0] is inverted.
if ERRBIT = 65,then ECC Parity[1] is inverted.
. . .
if ERRBIT = 70,then ECC Parity[6] is inverted.
if ERRBIT = 71,then ECC Parity[7] of the even bank is inverted.
For ERRBIT values between 72 and 98, no bit position is inverted. To accommodate
address bus
inversions, the ERRBIT values start at 99 as defined:
if ERRBIT = 99, then ADDR[3] is inverted.
if ERRBIT = 100, then ADDR[4] is inverted.
. . .
if ERRBIT = 126, then ADDR[30] is inverted.
if ERRBIT = 127, then ADDR[31] is inverted.
NOTE
If an attempt to force a non-correctable inversion by asserting
ECSM_EEGR[FRCNCI] or ECSM_EEGR[FRC1NCI], and
ECSM_EEGR[ERRBIT] equals 64, no data inversion is generated.
The only allowable values for the 4 control bit enables {FR11BI, FRC1BI,
FRCNCI, FR1NCI} are {0,0,0,0}, {1,0,0,0}, {0,1,0,0}, {0,0,1,0} and
{0,0,0,1}. All other values result in undefined behavior.
Inversions of the address bus must be configured as non-correctable for the
inversion to properly function. Address bus inversions defined as 1-bit
inversions are ignored.
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R FEAR
W
Reset U U U U U U U U U U U U U U U U
Field Description
0–15 Flash ECC Address Register. Contains the faulting access address of the last, properly enabled flash ECC event.
FEAR
Field Description
0–7 Flash CC Master Number Register. Contains the XBAR bus master number of the faulting access of the last,
FEMR properly enabled flash ECC event.
Field Description
0 0 Read access.
WRITE 1 Write access.
4–7 Cache:
PROTECTION 0xxx Non-cacheable
1xxx Cacheable
Buffer:
x0xx Non-bufferable
x1xx Bufferable
Mode:
xx0x User mode
xx1x Supervisor mode
Type:
xxx0 I-Fetch
xxx1 Data
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R FEDR[16:31]
W
Reset U U U U U U U U U U U U U U U U
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R FEDR[48:63]
W
Reset U U U U U U U U U U U U U U U U
Field Description
0–63 Flash ECC Data Register. Contains the data associated with the faulting access of the last properly enabled flash
FEDR ECC event. The register contains the data value taken directly from the platform data bus.
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R REAR
W
Reset U U U U U U U U U U U U U U U U
Field Description
0–31 RAM ECC Address Register. Contains the faulting access address of the last, properly-enabled RAM ECC event.
REAR
Field Description
0–7 RAM ECC Syndrome Register. This 8-bit syndrome field includes 7 bits of Hamming decoded parity plus an
RESR odd-parity bit for the entire 72-bit (64-bit data + 8 ECC) code word. The upper 7 bits of the syndrome specify the
exact bit position in error for single-bit correctable codewords, and the combination of a non-zero 7-bit syndrome
plus overall incorrect parity bit signal a multi-bit, non-correctable error.
For correctable single-bit errors, the mapping shown inTable 22-18 associates the upper 7 bits of the syndrome with
the data bit in error.
PRESR[7:0] Data Bit in Error PRESR[7:0] Data Bit in Error PRESR[7:0] Data Bit in Error
Table 22-18. RAM Syndrome Mapping for Single-Bit Correctable Errors (continued)
PRESR[7:0] Data Bit in Error PRESR[7:0] Data Bit in Error PRESR[7:0] Data Bit in Error
Field Description
0–7 RAM ECC Master Number Register. Contains the XBAR bus master number of the faulting access of the last,
REMR properly-enabled RAM ECC event.
Field Description
0 0 Read access.
WRITE 1 Write access.
4–7 Cache:
PROTECTION 0xxx Non-cacheable.
1xxx Cacheable.
Buffer:
x0xx Non-bufferable.
x1xx Bufferable.
Mode:
xx0x User mode.
xx1x Supervisor mode.
Type:
xxx0 I-Fetch.
xxx1 Data.
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R REDR[16:31]
W
Reset U U U U U U U U U U U U U U U U
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R REDR[48:63]
W
Reset U U U U U U U U U U U U U U U U
Field Description
0–63 RAM ECC Data Register. Contains the data associated with the faulting access of the last properly enabled platform
REDR RAM ECC event. The register contains the data value taken directly from the platform data bus.
23.1.1 Overview
The External Bus Interface (EBI) handles the transfer of information between the internal busses and the
memories or peripherals in the external address space. The EBI includes a memory controller that
generates interface signals to support a variety of external memories. This includes Single Data Rate
(SDR) burst mode flash, SRAM, and asynchronous memories. It supports up to 4 regions (via chip selects),
each with its own programmed attributes.
NOTE
The External Bus Interface is implemented differently on the MPC5676R in
comparison to the MPC55xx family.
On the MPC5676R, references to the External Bus Interface (EBI) or
Calibration Bus Interface (CBI) refer to the same single bus interface, as
described in this chapter.
23.1.2 Features
• 22-Bit Address bus with transfer size indication
• 16-Bit Data bus (32-bit Data Bus in muxed mode)
• Multiplexed Address on Data pins
• Memory controller with support for various memory types:
— synchronous burst SDR flash and SRAM
— asynchronous/legacy flash and SRAM
• Burst support (wrapped only)
• Bus monitor
• Port size configuration per chip select (16 or 32 bits)
• Configurable wait states
• Configurable internal or external transfer acknowledge (D_TA) per chip select
• Support for Dynamic Calibration with up to 4 chip-selects
• Four Write/Byte Enable (D_WE[0:3]) signals
• Slower-speed clock modes
• Stop and Module Disable Modes for power savings
Equivalent Chip-level
Generic Signal Name I/O Type Function
Signal Name1
CS — —
D_CS[0:3]
CAL_CS Output Chip Selects
NOTES:
1 This pin function may not be the pins primary function, Refer to the Signals chapter for muxing information.
2
The D_CLKOUT signal is driven by the System Clock Block outside the EBI.
3
In Address/Data multiplexing modes, Data will also show the address during the address phase.
external bus in this mode; therefore, it acts as a parked master and does not have to arbitrate for the bus
before starting each cycle. Single Master Mode is entered when MDIS=0 in the EBI_MCR.
fperiph
CLKOUT
ALE
TS
There are at least two timing requirements that relate to external components for multiplexed addr/data bus
in systems using ALE. These are not EBI specs. The two are
• ALE - minimum high time
• ALE negated to ADDR invalid
These values depend on maximum clkout frequency and the actual clock tree insertion on the ALE clock
gate.
Typical values should be calculated (and specified) as:
tALEhigh = f(Clkout) / 2 -1nS (rise/fall uncertainty)
23.2.1 Overview
Table 23-2 lists the external pins used by the EBI.
Table 23-2. Signal Properties
D_ADD[16:30]1 D_ADD_DAT
Mode D_WE[0:3] D_ADD[9:15] D_CS23
D_ADD_DAT[16:30]2 [0:15]
Non-muxed 16-bit mode write/byte enable [0:1] Address 9:15 Address 16:30 Data 0:15 Address 31
NOTES:
1
D_ADD[16:30] SIU PCR functionality must be selected in non-multiplexed mode (AD_MUX = 0)
2
D_ADD_DAT[16:30] SIU PCR functionality must be selected in multiplexed mode (AD_MUX = 1)
3
D_CS2 is the primary function. Secondary function is EBI data only in non-mux mode and address/data in mux mode.
D_TA is driven by the EBI when the access is controlled by the chip selects (and SETA=0). Otherwise,
D_TA is driven by the slave device to which the current transaction was addressed.
See Section 23.4.2.8, “Termination Signals Protocol for more details.
Signal Output
D_ADD[9:30] Enabled
D_BDIP Enabled
CAL_CS[0:3] Enabled
D_OE Enabled
D_RD_WR Enabled
D_TA Only enabled during chip-select SETA=0 access
D_TS Enabled
D_WE[0:3] Enabled
D_ALE Enabled
Address Use
EBI_BASE+0x4 Reserved
EBI_BASE+0x8 EBI Transfer Error Status Register (EBI_TESR)
EBI_BASE+0x10 –
Reserved
EBI_BASE+0x3C
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R 0 0 0 1 0 0 0 0 0 0 0
ACGE MDIS D16_31 AD_MUX DBM
W
RESET: 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0
= Unimplemented or Reserved
Figure 23-2. EBI Module Configuration Register (EBI_MCR)
The EBI Module Configuration Register contains bits which configure various attributes associated with
EBI operation.
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R 0 0 0 0 0 0 0 0 0 0 0 0 0 0 TEAF BMTF
W
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
= Unimplemented or Reserved
Figure 23-3. EBI Transfer Error Status Register (EBI_TESR)
The EBI Transfer Error Status Register contains a bit for each type of transfer error on the external bus. A
bit set to logic 1 indicates what type of transfer error occurred since the last time the bits were cleared.
Each bit can be cleared by reset or by writing a 1 to it. Writing a 0 has no effect. This register cannot be
written when the MDIS bit is set in the EBI_MCR.
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R 0 0 0 0 0 0 0
BMT BME
W
RESET: 1 1 1 1 1 1 1 1 1 0 0 0 0 0 0 0
= Unimplemented or Reserved
Figure 23-4. EBI Bus Monitor Control Register (EBI_BMCR)
The EBI Bus Monitor Control Register controls the timeout period of the bus monitor and whether it is
enabled or disabled.
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R 0 0 AD_
BA LWRN PS EOE SBL BL WEBS TBDIP GCSN SETA BI V
W MUX
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0
= Unimplemented or Reserved
NOTES:
1
BA[0:2] is fixed as 0b001.
Figure 23-5. EBI Base Registers (EBI_CAL_BR0-3)
The EBI Base Registers are used to define the base address and other attributes for the corresponding chip
select.
BA — Base Address
These bits are compared to the corresponding unmasked address signals among D_ADD[0:16] of the
internal address bus to determine if a memory bank controlled by the memory controller is being
accessed by an internal bus master.
PS — Port Size
The PS bit determines the data bus width of transactions to this chip-select bank.
NOTE
In the case where the DBM bit in EBI_MCR is set for 16-bit Data Bus
Mode, the PS bit value is ignored and is always treated as a ‘1’ (16-bit port).
1 = 16-bit port
0 = 32-bit port
EOE — Early OE
The EOE field determines the timing of OE signal assertion for a read transfer. When
EBI_BR[ADMUX]=1, the EOE value is ignored and treated as 0b00 (in order to avoid contention on
shared address/data bus for muxed transfers).
BL — Burst Length
The BL bit (along with SBL bit) determines the amount of data transferred in a burst for this chip
select, measured in 32-bit words. When SBL=0, the number of beats in a burst is automatically
determined by the EBI to be 4, 8, or 16 according to the Port Size (PS bit) so that the burst fetches the
number of words chosen by BL. When SBL=1, the BL bit value is a don’t care. See Table 23-7 for SBL
and BL encodings.
Value Burst
PS # Beats in Burst2
SBL BL Length1
0 (32-bit) 8
0 0 8-word3
1 (16-bit) 16
0 (32-bit) 4
0 1 4-word
1 (16-bit) 8
0 (32-bit) 2
1 X 2 word3
1 (16-bit) 4
NOTES:
1
Total amount of data fetched in a burst transfer, measured in 32-bit words.
2 Number of external data beats used in external burst transfer. The size of each
beat is determined by PS value.
3 A word always refers to 32-bits of data, regardless of PS.
BI — Burst Inhibit
This bit determines whether or not burst read accesses are allowed for this chip-select bank. The BI bit
is ignored (treated as 1) for chip-select accesses with external D_TA (SETA=1).
1 = Disable burst accesses for this bank. This is the default value out of reset (or when SETA=1).
0 = Enable burst accesses for this bank
V — Valid bit
The user writes this bit to indicate that the contents of this Base Register and Option Register pair are
valid. The appropriate CS signal does not assert unless the corresponding V-bit is set.
1 = This bank is valid
0 = This bank is not valid
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R 0 0 0 0 0 0 0 0 0
AM SCY BSCY
W
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
= Unimplemented or Reserved
NOTES:
1
AM[0:2] is set to a fixed value of 0b111.
Figure 23-6. EBI Option Registers (EBI_CAL_OR0-3)
The EBI Option Registers are used to define the address mask and other attributes for the corresponding
chip select.
AM — Address Mask
This field allows masking of any corresponding bits in the associated Base Register. Masking the
address independently allows external devices of different size address ranges to be used. Any clear
bit masks the corresponding address bit. Any set bit causes the corresponding address bit to be used in
comparison with the address pins. Address mask bits can be set or cleared in any order in the field,
allowing a resource to reside in more than one area of the address map. This field can be read or written
at any time.
Value Meaning
00 0-clock cycle wait states (1 clock per data beat)
01 1-clock cycle wait states (2 clocks per data beat)
10 2-clock cycle wait states (3 clocks per data beat)
11 3-clock cycle wait states (4 clocks per data beat)
23.4.1.2 32-Bit Data Bus (16-bit Data Bus Mode also supported)
The entire 32-bit data bus is available (through muxing) for external memory accesses. There is also a
16-bit Data Bus Mode available via the DBM bit in EBI_MCR. See Section 23.1.4.5, “16-Bit Data Bus
Mode.
1. #beats is the number of beats (4,8,16) determined by BL and PS bits in Base Register.
defined for this bank in its BR and OR are used to control the memory access. If a match is found in more
than one bank, the lowest bank matched handles the memory access (e.g., bank 0 is selected over bank 1).
This means chip select 0 has the highest priority and chip select 3 the lowest.
BA BA BA BA BA BA BA AM AM AM AM AM AM AM AM
[0] [1] [2] [3] [4] [15] [16] [0] [1] [2] [3] [4] [5] [6] [16]
A[0:16]
AM[0:16]
Match
When a match is found on one of the chip-select banks, all its attributes (from the appropriate Base and
Option Registers) are selected for the functional operation of the external memory access, such as:
• Number of wait states for a single memory access, and for any beat in a burst access
• Burst enable
• Port size for the external accessed device
See Section 23.3.1.4, “EBI Base Registers (EBI_CAL_BR0-3) and Section 23.3.1.5, “EBI Option
Registers (EBI_CAL_OR0-3) for a full description of all chip-select attributes.
When no match is found on any of the chip-select banks, the default transfer attributes shown in Table 23-9
are used.
Table 23-9. Default Attributes for Non-Chip-Select Transfers
0 0 X X
0 1 X X
Byte
1 0 X X
1 1 X X
0 0 X X X X
16-bit
1 0 X X X X
32-bit 0 0 X X X X X3 X3
Burst 0 0 X X X X X X
NOTES:
1
This table applies to aligned internal master transfers only. In the case of a misaligned internal master
transfer that is split into multiple aligned external transfers, not all of the write enables X’d in the table
will necessarily assert. See Section 23.4.2.10, “Misaligned Access Support.
2
Also applies when DBM=1 for 16-bit data bus mode.
3 This case consists of two 16-bit external transactions, but for both transactions the D_WE[0:1] signals
are the only D_WE signals affected.
23.4.2.2 Reset
Upon detection of internal reset assertion, the EBI immediately ends all transactions (abruptly, not through
normal termination protocol), and ignores any transaction requests that take place while reset is asserted.
The arbitration phase is where bus ownership is requested and granted. This phase is not needed in Single
Master Mode because the EBI is the permanent bus owner in this mode.
The address transfer phase specifies the address for the transaction and the transfer attributes that describe
the transaction. The signals related to the address transfer phase are D_TS, D_ADD (or D_ADD_DAT if
Address/Data multiplexing is used), CS[0:3], D_RD_WR, and D_BDIP. The address and its related signals
(with the exception of D_TS, D_BDIP) are driven on the bus with the assertion of the D_TS signal, and
kept valid until the bus master receives D_TA asserted (the EBI holds them one cycle beyond D_TA for
writes and external D_TA accesses). Note that for writes with internal D_TA, D_RD_WR is not held one
cycle past D_TA.
The data transfer phase performs the transfer of data, from master to slave (in write cycles) or from slave
to master (on read cycles), if any is to be transferred. The data phase may transfer a single beat of data (1-4
bytes) for non-burst operations or a 2-beat (special DBM=1 case only), 4-beat, 8-beat, or 16-beat burst of
data (2 or 4 bytes per beat depending on Port Size) when burst is enabled. On a write cycle, the master
must not drive write data until after the address transfer phase is complete. This is to avoid electrical
contentions when switching between drivers. The master must start driving write data one cycle after the
address transfer cycle. The master can stop driving the data bus as soon as it samples the D_TA line
asserted on the rising edge of D_CLKOUT. To facilitate asynchronous write support, the EBI keeps
driving valid write data on the data bus until 1 clock after the rising edge where D_RD_WR and WE are
negated (for chip-select accesses only). See Figure 23-16 for an example of write timing. On a read cycle,
the master accepts the data bus contents as valid on the rising edge of the D_CLKOUT in which the D_TA
signal is sampled asserted. See Figure 23-10 for an example of read timing.
The termination phase is where the cycle is terminated by the assertion of either D_TA (normal
termination) or D_TEA (termination with error). Termination is discussed in detail in Section 23.4.2.8,
“Termination Signals Protocol.
receives address
drives data
yes
CS access & !SETA?
no
receives data
D_CLKOUT
D_ADD[9:30]
D_RD_WR
D_BDIP
D_TS
D_ADD_DAT[0:15]
D_TA
D_ADD_DAT is valid
CS[n]
D_OE
Figure 23-10. Single Beat 16-bit Read Cycle, CS Access, Zero Wait States
D_CLKOUT
D_ADD[9:30]
D_RD_WR
D_BDIP
D_TS
D_ADD_DAT[0:15]
D_OE
Figure 23-11. Single Beat 32-bit Read Cycle, CS Access, One Wait State
D_CLKOUT
D_ADD[9:30] *
D_RD_WR
D_BDIP
D_TS
D_ADD_DAT[0:15]
D_TA (input)
D_ADD_DAT is valid
CSx
D_OE
* The EBI drives address and control signals an extra cycle because it uses a latched version
of the external D_TA (1 cycle delayed) to terminate the cycle.
Figure 23-12. Single Beat 16-bit Read Cycle, CS Access, SETA=1, Zero Wait States
D_CLKOUT
D_ADD[9:30] *
D_RD_WR
D_BDIP
D_TS
D_ADD_DAT[0:15]
D_TA(input)
D_ADD_DAT is valid
CS[n]
D_OE
* The EBI drives address and control signals an extra cycle because it uses a latched
version of the external D_TA (1 cycle delayed) to terminate the cycle.
Figure 23-13. Single Beat 16-bit Read Cycle, Non-CS Access, Zero Wait States
D_CLKOUT
D_ADD[9:30]
D_RD_WR
D_BDIP
D_TS
D_ADD_DAT[0:15]
D_TA
DATA is valid
CSx
D_OE * **
* When EBI_CAL_BRn[EOE]=0b01 (or 0b10 in 1:1 bus speed mode), D_OE asserts around the same tim
as TS (could be slightly before or after D_TS, order of D_TS/D_OE assertion is not guaranteed).
** When EBI_CAL_BRn[EOE]=0b10 (and not in 1:1 bus speed mode), D_OE asserts 1 internal system clo
(partial CLKOUT cycle) later as compared to D_TS.
Figure 23-14. Single Beat 16-bit Read Cycle, CS Access, Zero Wait States (EOE=0b01, 0b10)
MASTER SLAVE
receives address
drives data
receives data
yes
CS access & ! SETA?
no
waits 1 clock
stops driving data
D_CLKOUT
D_ADD[9:30]
D_RD_WR
D_BDIP
D_TS
D_ADD_DAT is valid
D_ADD_DAT[0:15]
D_TA
CS[n]
D_WE[0:3]
Figure 23-16. Single Beat 16-bit Write Cycle, CS Access, Zero Wait States
D_CLKOUT
D_ADD[9:30]
D_RD_WR
D_BDIP
D_TS
D_ADD_DAT is valid
D_ADD_DAT[0:15]
CS[n]
D_WE[0:3]
Figure 23-17. Single Beat 32-bit Write Cycle, CS Access, One Wait State
D_CLKOUT
D_ADD[9:30] *
D_RD_WR
D_BDIP
D_TS
D_ADD_DAT is valid
D_ADD_DAT[0:15]
D_TA (input)
CSx
D_WE[0:3]
* The EBI drives address and control signals an extra cycle because it uses a latched version
of the external D_TA (1 cycle delayed) to terminate the cycle.
Figure 23-18. Single Beat 16-bit Write Cycle, CS Access, SETA=1, Zero Wait States
D_CLKOUT
D_ADD[9:30] *
D_RD_WR
D_BDIP
D_TS
D_ADD_DAT is valid
D_ADD_DAT[0:15]
D_TA (Input)
D_ADD_DAT is valid
CS[n]
WE[0:3]
* The EBI drives address and control signals an extra cycle because it uses a latched
version of the external D_TA (1 cycle delayed) to terminate the cycle.
Figure 23-19. Single Beat 16-bit Write Cycle, Non-CS Access, Zero Wait States
D_CLKOUT
D_ADD[9:30]
D_RD_WR *
D_BDIP
D_TS
D_ADD_DAT is valid
D_ADD_DAT[0:15]
D_TA
CSx
D_WE[0:3]
Figure 23-20. Single Beat 16-bit Write Cycle, CS Access, Zero Wait States, LWRN=1
D_CLKOUT
D_ADD[9:30]
D_RD_WR
D_BDIP
D_TS
D_ADD_DAT[0:15]
D_TA
D_ADD_DAT is valid D_ADD_DAT is valid
CS[n]
D_OE
D_CLKOUT
D_ADD[9:30]
D_RD_WR
D_BDIP
D_TS
D_ADD_DAT[0:15]
D_TA
D_ADD_DAT is valid D_ADD_DAT is valid
CS[n]
CS[y]
D_OE
D_CLKOUT
D_ADD[9:30]
D_RD_WR
D_BDIP
D_TS
D_ADD_DAT is valid
D_ADD_DAT[0:15]
D_TA
D_ADD_DAT is valid
CSx
D_WE
D_CLKOUT
D_ADD[9:30]
D_RD_WR ** **
D_BDIP
D_TS *
D_ADD_DAT[0:15]
D_TA
CSx
D_WE
* Timing shown applies when EBI_BR[GCSN]=0. When EBI_BR[GCSN]=1, the 2nd TS assertion
is delayed by 1 cycle and CS negates between the two transfers.
D_CLKOUT
D_ADD[9:30]
D_RD_WR ** **
D_BDIP
D_TS
DATA is valid DATA is valid
D_ADD_DAT[0:15]
D_TA
CSx
D_WE
D_CLKOUT
D_ADD[9:30]
D_RD_WR **
D_BDIP
*
D_TS
DATA is valid
D_ADD_DAT[0:15]
D_TA
DATA is valid
CSx
D_WE
* Timing shown applies when EBI_BR[GCSN]=0. When EBI_BR[GCSN]=1, the 2nd TS assertion
is delayed by 1 cycle and CS negates between the two transfers.
** Timing shown applies when EBI_BR[LWRN]=0. When EBI_BR[LWRN]=1, RD_WR negation
is delayed by 1 cycle.
D_CLKOUT
D_ADD[9:30]
D_RD_WR **
D_BDIP
D_TS
DATA is valid
D_ADD_DAT[0:15]
D_TA
DATA is valid
CSx
D_WE
D_CLKOUT
D_ADD[9:30]
D_RD_WR ** **
D_BDIP
D_TS
D_ADD_DAT[0:15]
D_TA
CSx
CSy
D_WE
D_CLKOUT
D_ADD[9:30]
** **
D_RD_WR
D_BDIP
D_TS
DATA is valid DATA is valid
D_ADD_DAT[0:15]
D_TA
CSx
CSy
D_WE
D_CLKOUT
D_ADD[9:30]
D_RD_WR **
D_BDIP
D_TS
D_ADD_DAT[0:15]
D_TA
CSx
CSy
D_WE
D_OE
D_CLKOUT
D_ADD[9:30]
D_RD_WR
D_BDIP
D_ADD_DAT[0:15]
D_TA
CS[n]
WE
D_CLKOUT
D_ADD[9:30]
D_RD_WR
D_BDIP
D_TS
D_ADD_DAT is valid
D_ADD_DAT[0:15]
D_TA
D_ADD_DAT is valid
CSx
WE
The general case of burst transfers assumes that the external memory has 32-bit port size and 8-word burst
length. The EBI can also burst from 16-bit port size memories, taking twice as many external beats to fetch
the data as compared to a 32-bit port with the same burst length. The EBI can also burst from 16-bit or
32-bit memories that have a 4-word burst length (BL=1 in the appropriate Base Register). In this case, two
external 4-word burst transfers (wrapping on 4-word boundary) are performed to fulfill the internal 8-word
request2. This operation is considered atomic by the EBI, so the EBI does not allow other unrelated master
accesses or bus arbitration to intervene between the transfers.
During burst cycles, the D_BDIP (Burst Data In Progress) signal is used to indicate the duration of the
burst data. During the data phase of a burst read cycle, the EBI receives data from the addressed slave. If
the EBI needs more than one data, it asserts the D_BDIP signal. Upon receiving the data prior to the last
data, the EBI negates D_BDIP. Thus, the slave stops driving new data after it receives the negation of
D_BDIP on the rising edge of the clock. Some slave devices have their burst length and timing
configurable internally and thus may not support connecting to a D_BDIP pin. In this case, D_BDIP is
driven by the EBI normally, but the output is ignored by the memory and the burst data behavior is
1. Except for the special case of a 32-bit non-chip-select access in 16-bit data bus mode. See Section 23.4.2.9,
“Non-Chip-Select Burst in 16-bit Data Bus Mode.”
2. This case (of 2 external burst transfers being required) applies only to AMBA data bus width of 64 bits.
determined by the internal configuration of the EBI and slave device. When the TBDIP bit is set in the
appropriate Base Register, the timing for D_BDIP is altered. See Section 23.4.2.5.1, “TBDIP Effect on
Burst Transfer for this timing.
Since burst writes are not supported by the EBI1, the EBI negates D_BDIP during write cycles.
1. Except for the special case of a 32-bit non-chip-select access in 16-bit data bus mode. See Section 23.4.2.9,
“Non-Chip-Select Burst in 16-bit Data Bus Mode.
MASTER SLAVE
receives address
drives data
receives data
assert D_BDIP
next to last data beat?
no
yes
negate D_BDIP
D_CLKOUT
D_RD_WR
D_TS
Expects more data
D_BDIP
D_ADD_DAT[0:15]
D_ADD_DAT is valid
D_TA
CS[n]
D_OE
D_CLKOUT
D_RD_WR
D_TS
Expects more data
D_BDIP
D_ADD_DAT[0:15]
D_ADD_DAT is valid
D_TA
Wait state
CS[n]
D_OE
Figure 23-35. Burst 16-bit Read Cycle, One Initial Wait State
D_CLKOUT
D_RD_WR
D_TS
Expects more data
D_BDIP
D_ADD_DAT[0:31]
D_ADD_DAT is valid
D_TA
Wait state
CS[n] Wait state Wait state Wait state
D_OE
Figure 23-36. Burst 32-bit Read Cycle, One Wait State between Beats, TBDIP=0
When using TBDIP=1, the D_BDIP behavior changes to toggle between every beat when BSCY is a
non-zero value. Figure 23-37 shows an example of the TBDIP=1 timing for the same 4-beat burst shown
in Figure 23-36.
D_CLKOUT
D_RD_WR
D_BDIP
D_ADD_DAT[0:31]
D_ADD_DAT is valid
D_TA
Wait state
CS[n] Wait state Wait state Wait state
D_OE
Figure 23-37. Burst 32-bit Read Cycle, One Wait State between Beats, TBDIP=1
23.4.2.6 Small Accesses (Small Port Size and Short Burst Length)
In this context, a small access refers to an access whose burst length and port size (BL, PS bits in Base
Register for chip-select access or default burst disabled, 32-bit port for non-chip-select access) are such
that the number of bytes requested by the internal master cannot all be fetched (or written) in one external
transaction. If this is the case, the EBI initiates multiple transactions until all the requested data is
transferred. It should be noted that all the transactions initiated to complete the data transfer are considered
as an atomic transaction, so the EBI does not allow other unrelated master accesses to intervene between
the transfers.
Table 23-12 shows all the combinations of burst length, port size, and requested byte count that cause the
EBI to run multiple external transactions to fulfill the request.
Table 23-12. Small Access Cases
Byte Count
# External Accesses
Requested by internal Burst Length Port Size
to Fulfill Request
master
Non-Burstable Chip-Select Banks (BI=1) or Non-Chip-Select Access
4 1 beat 16-bit 2/11
8 1 beat 32-bit 2
8 1 beat 16-bit 4
32 1 beat 32-bit 8
32 1 beat 16-bit 16
Burstable Chip-Select Banks (BI=0)
16-bit (8 beats), 32-bit (4
32 4 words 2
beats)
NOTES:
1
In 32-bit data bus mode (DBM=0 in EBI_MCR), two accesses are performed. In 16-bit data bus mode
(DBM=1), one 2-beat burst access is performed and this is not considered a “small access” case.
See Section 23.4.2.9, “Non-Chip-Select Burst in 16-bit Data Bus Mode for this special DBM=1 case.
In most cases, the timing for small accesses is the same as for normal single-beat and burst accesses, except
that multiple back-to-back external transfers are executed for each internal request. These transfers have
no additional dead cycles in-between that are not present for back-to-back stand-alone transfers except for
the case of writes with an internal request size of >64 bits.
The following sections show a few examples of small accesses. The timing for the remaining cases in
Table 23-12 can be extrapolated from these and the other timing diagrams in this document.
D_CLKOUT
D_ADD[9:30] A A+2
D_RD_WR
D_BDIP
D_TA
CS[n]
WE
Figure 23-38. Single Beat 32-bit Write Cycle, 16-bit Port Size, Basic Timing
D_CLKOUT
D_RD_WR
D_BDIP
D_TS ** ** **
D_ADD_DAT[0:15]
ABCD EFGH IJKL MNOP
D_TA
CSx
D_WE
** Timing shown applies when EBI_BR[GCSN]=0. When EBI_BR[GCSN]=1, the 2nd-4th D_TS assertions
are each delayed by 1 cycle and CS negates between each transfer.
Figure 23-39. Single Beat 64-bit Read Cycle, 16-bit Port Size, Basic Timing
Even though misaligned non-burst transfers from internal masters are supported, the EBI naturally aligns
the accesses when it sends them out to the external bus, splitting them into multiple aligned accesses if
necessary. See Section 23.4.2.10, “Misaligned Access Support for these cases.
Natural alignment for the EBI means:
• Byte access can have any address
• 16-bit access, address bit 31 must be 0
• 32-bit access, address bits 30-31 must be 0
• For burst accesses of any size, address bits 29-31 must be 0
The EBI requires that the portion of the data bus used for a transfer to/from a particular port size be fixed.
A 32-bit port must reside on data bus bits 0-31,and a 16-bit port must reside on bits 0-15.
In the following figures and tables the following convention is adopted:
• The most significant byte of a 32-bit operand is OP0, and OP3 is the least significant byte.
• The two bytes of a 16-bit operand are OP0 (most significant) and OP1, or OP2 (most significant)
and OP3, depending on the address of the access.
• The single byte of a byte-length operand is OP0, OP1, OP2, or OP3, depending on the address of
the access.
This can be seen in Figure 23-40.
0 31
OP0 OP1
OP0
OP1 BYTE
OP2
OP3
OP0 OP1
16-bit port size
OP2 OP3
Table 23-16 lists the bytes required on the data bus for read cycles. The bytes indicated as ‘-’ are not
required during that read cycle.
0 0 OP0 — — — OP0 —
0 1 — OP1 — — — OP1
Byte
1 0 — — OP2 — OP2 —
1 1 — — — OP3 — OP3
0 0 OP0 OP1 — — OP0 OP1
16-bit
1 0 — — OP2 OP3 OP2 OP3
4
32-bit 0 0 OP0 OP1 OP2 OP3 OP0 or OP2 OP1 or OP3
NOTES:
1
Also applies when DBM=1 for 16-bit data bus mode.
2 For address/data muxed transfers, D_ADD_DAT[16:23] are used externally, not D_ADD_DAT[0:7].
3
For address/data muxed transfers, D_ADD_DAT[24:31] are used externally, not D_ADD_DAT[8:15].
4
This case consists of two 16-bit external transactions, the first fetching OP0 and OP1, the second fetching OP2 and
OP3.
Table 23-17 lists the patterns of the data transfer for write cycles when accesses are initiated by the MCU.
The bytes indicated as ‘-’ are not driven during that write cycle.
Table 23-17. Data Bus Contents for Write Cycles
0 0 OP0 — — — OP0 —
0 1 OP1 OP1 — — — OP1
Byte
1 0 OP2 — OP2 — OP2 —
1 1 OP3 OP3 — OP3 — OP3
0 0 OP0 OP1 — — OP0 OP1
16-bit
1 0 OP2 OP3 OP2 OP3 OP2 OP3
32-bit 0 0 OP0 OP1 OP2 OP3 OP0 or OP2 4 OP1 or OP3
NOTES:
1
Also applies when DBM=1 for 16-bit data bus mode.
2
For address/data muxed transfers, D_ADD_DAT[16:23] are used externally, not D_ADD_DAT[0:7].
3
For address/data muxed transfers, D_ADD_DAT[24:31] are used externally, not D_ADD_DAT[8:15].
4
This case consists of two 16-bit external transactions, the first writing OP0 and OP1, the second writing OP2 and OP3.
NOTE
For the cases discussed above where D_TEA “could be ignored”, this is not
gauranteed. For some small access cases (which always use chip-select and
internally-driven D_TA), a D_TEA that occurs 1 cycle before or during the
D_TA cycle or for SCY=0 may in fact lead to terminating the cycle with
error. However, proper error termination is not guaranteed for these cases,
so D_TEA must always be asserted at least 2 cycles before an
internally-driven D_TA cycle for proper error termination.
External D_TEA assertion that occurs during the same cycle that D_TS is asserted by the EBI is always
treated as an error (terminating the access) regardless of SCY.
Table 23-18 summarizes how the EBI recognizes the termination signals provided from an external device.
Figure 23-42 shows an example of the termination signals protocol for back-to-back reads to two different
slave devices who properly “take turns” driving the termination signals. This assumes a system using slave
devices that drive termination signals.
D_CLKOUT
D_RD_WR
D_TS **
D_ADD_DAT[0:15]
D_TA, D_TEA
* The EBI drives address and control signals an extra cycle because it uses a latched version of D_TA
(1 cycle delayed) to terminate the cycle. An external master is not required to do this.
** is is the earliest that the EBI can start another transfer, in the case of continuing a set of small accesses.
Th
For all other cases, an extra cycle is needed before the EBI can start another D_TS.
D_CLKOUT
D_ADD[9:30]
D_RD_WR
D_BDIP
D_TS (output)
D_ADD_DAT[0:15]
D_TA (input)
D_CLKOUT
D_ADD[9:30]
D_RD_WR
D_BDIP
D_TS (output)
D_ADD_DAT is valid
D_ADD_DAT is valid
D_ADD_DAT[0:15]
D_TA (input)
Minimum
3 wait states
Table 23-19. Misalignment Cases Supported by a 64 bit AMBA EBI (internal bus) (continued)
Table 23-20 shows which external transfers are generated by the EBI for the misaligned access cases in
Table 23-19, for each port size.
The number of external transfers for each internal AHB master request is determined by the HSIZE value
for that request relative to the port size. For example, a half-word write to @011 (misaligned case #2) with
16-bit port size results in 4 external 16-bit transfers because the HSIZE is 64-bits. For cases where two or
more external transfers are required for one internal transfer request, these external accesses are considered
part of a “small access” set, as described in Section 23.4.2.6, “Small Accesses (Small Port Size and Short
Burst Length).
Since all transfers are aligned on the external bus, normal timing diagrams and protocol apply.
Table 23-20. Misalignment Cases Supported by a 64 bit AMBA EBI (external bus)
Program Size
No.1 PS2 D_ADD[29:31]3 D_WE[0:3]4
and byte offset
0 000 1001
1 Half @0x1,0x9 000 1011
1
010 0111
000 1110
0
100 0111
2 Half @0x3,0xB
010 1011
1
100 0111
0 100 1001
3 Half @0x5,0xD 100 1011
1
110 0111
Table 23-20. Misalignment Cases Supported by a 64 bit AMBA EBI (external bus) (continued)
Program Size
No.1 PS2 D_ADD[29:31]3 D_WE[0:3]4
and byte offset
4 1115 1110
0
- Half @0x7,0xF 000 0111
4 (2 AHB transfers) 110 1011
1
- 000 0111
000 1000
0
100 0111
5 Word @0x1,0x9 000 1011
1 010 0011
100 0111
000 1100
0
100 0011
6 Word @0x2,0xA
010 0011
1
100 0011
000 1110
0
100 0001
7 Word @0x3,0xB 010 1011
1 100 0011
110 0111
8 100 1000
0
- 000 0111
Word @0x5,0xD
(2 AHB transfers) 100 1011
8
1 110 0011
- 000 0111
9 1106 1100
0
- Word @0x6,0xE 000 0011
9 (2 AHB transfers) 1106 0011
1
- 000 0011
10 1115 1110
0
11 000 0001
Word @0x7,0xF
10 (2 AHB transfers) 1115 1011
1 000 0011
11
010 0111
12 1007 0000
0
- 000 0000
Doubleword
@0x4,0xC 1007 0011
12
(2 AHB transfers) 110 0011
1
000 0011
-
010 0011
000 1100
13
0 100 0000
- Doubleword 000 0011
@0x2,0xA 010 0011
13 (2 AHB transfers) 100 0011
1 110 0011
- 000 0011
Table 23-20. Misalignment Cases Supported by a 64 bit AMBA EBI (external bus) (continued)
Program Size
No.1 PS2 D_ADD[29:31]3 D_WE[0:3]4
and byte offset
14 1106 1100
0 000 0000
15
Doubleword 100 0011
14 @0x6,0xE 1106 0011
(2 AHB transfers)
1 000 0011
15 010 0011
100 0011
NOTES:
1 Misaligned case number, from Table 23-19.
2
Port size; 0=32 bits, 1=16 bits.
3
External D_ADD pins, not necessarily the address on internal master
AHB bus.
4
External D_WE pins. Note that these pins have negative polarity,
opposite of the internal byte strobes in Table 23-19.
5
Treated as 1-byte access.
6
Treated as 2-byte access.
7 Treated as 4-byte access.
D_CLKOUT
D_RD_WR
D_BDIP
Clock Gap
D_TS
D_TA
DATA is valid
DATA is valid
***
CSx
D_OE
* While the EBI drives all of ADDR[3:31] to valid address, typically only ADDR[3:15] (or less) are used in the
system, as D_ADD_DATA[16:31] (or D_ADD_DATA[0:15]) would be used for address and data on an external mux
** Or D_ADD_DATA[0:15], based on D16_31 bit in EBI_MCR.
Figure 23-45. Small access (32-bit read to 16-bit port) on Address/Data multiplexed bus
D_CLKOUT
D_RD_WR
D_BDIP
D_TS
D_TA
D_ADD_DAT is valid
CSx
D_OE
D_CLKOUT CK
MCU SDR Burstable
CS0 CE
Flash or SRAM
D_TS ADV
D_BDIP BAA*
D_WE0 WE**
D_ADD_DAT[9:30] A[0:21]
D_ADD_DAT[0:15] D[0:15]
D_OE OE
NOTE
An external latch may be required to hold Address bus signals during the
bus access if the memory does not support Address changing on the Data
phase of the bus access. In this case, the ALE signal should be used to signal
when the address bus should be latched.
Refer to Figure 23-34 for an example of the timing of a typical Burst Read operation to an SDR burst
memory. Refer to Figure 23-16 for an example of the timing of a typical Single Write operation to SDR
memory.
MCU Asynchronous
CS0 CE
Memory
D_WE0 WE*
D_ADD[9:30] A[0:21]
D_ADD_DAT[0:15] D[0:15]
D_OE OE
* Flash memories typically use one WE signal as shown, RAMs use 2 or 4 (16-bit or 32-bit)
Figure 23-49 shows a timing diagram of a read operation to a 16-bit asynchronous memory using 3 wait
states.
Figure 23-50 shows a timing diagram of a write operation to a 16-bit asynchronous memory using 3 wait
states.
D_CLKOUT
CSx
D_TS
D_ADD[9:30]
D_OE
WE[0:1]
D_ADD_DAT[0:15]
D_TA
D_ADD_DAT is valid
3 Wait States
Figure 23-49. Read Operation to Asynchronous Memory, Three Initial Wait States
D_CLKOUT
CSx
D_TS
D_ADD[9:30]
WE[0:1]
D_OE
D_ADD_DAT is valid
D_ADD_DAT[0:15]
D_TA
3 Wait States
Figure 23-50. Write Operation to Asynchronous Memory, Three Initial Wait States
D_CLKOUT CK
MCU SDR Memory
CS0 CE
D_TS ADV
D_WE0 WE**
D_ADD_DAT[9:30] A[0:21]
D_ADD_DAT[0:15] D[0:15]
D_OE OE
D_BDIP BAA*
CK
A[0:21]
D_WE1 WE**
BAA*
D[0:15]
OE
1 x 256 KB 1 x 256 KB
1 x 256 KB 1 x 256 KB
1 x 256 KB 1 x 256 KB
1 x 256 KB 1 x 256 KB
1 x 256 KB 1 x 256 KB
1 x 256 KB 1 x 256 KB
1 x 256 KB 1 x 256 KB
1 x 256 KB 1 x 256 KB
1 x 256 KB 1 x 256 KB
Note: The High Address space blocks are interleaved on every 16 byte address boundary; the first 16 bytes of
every 32 bytes are located in Flash_A array, and the second 16 bytes are located in Flash_B array.
PBRIDGE_A
Flash_B Array
Flash memory
Slave Port 3 Port 1 interface
(MI)
Control/status
registers
Flash core
selectively enabled or disabled for allocation by instruction and data prefetch. Access protections may be
applied on a per-master basis for both reads and writes to support security and privilege mechanisms.
FBIU
Port 0 Data
128 bit Read Buffers x 4 Flash_A Data
128
Flash_B Data
128
256 bit Read Buffers x 4 A+B
Port 1 Data
128 bit Read Buffers x 4
CONTROL LOGIC
Port 0 buffer hit logic Flash_A
CONTROL LOGIC
buffer hit logic Flash_B
Port 1
access protect logic Address,
Address, Data,
Data, addr generation Control
Control
{ARB,PRI}
24.1.2 Features
The flash memory module has these major features:
• Support for a 64-bit data bus for instruction fetch.
• Two 64 bit slave ports to accelerate concurrent access by two bus masters.
• Support for a 32-bit data bus for CPU loads and DMA access. Byte, halfword, word and
doubleword reads are supported. Only aligned word and doubleword writes are supported.
• Configurable read buffering and line prefetch support. Two sets of buffers (one for 128-bit accesses
and one for 256-bit accesses) per port and a prefetch controller are used to support single-cycle read
responses for hits in the buffers.
• Hardware and software configurable read and write access protections on a per-master basis.
• Interface to the flash array controller is pipelined with a depth of 1, allowing overlapped accesses
to proceed in parallel.
• Configurable access timing allowing use in a wide range of system frequencies.
• Multiple-mapping support and mapping-based block access timing (0-31 additional cycles)
allowing use for emulation of other memory types.
• Software programmable block program/erase restriction control for low, mid and high address
spaces.
• Erase of selected block(s).
• Read page size of 128 bits (low/mid-address space) and 256 bits (for high-address space).
• Support for concurrent dual port access to low/mid-address space of Flash_A and Flash_B.
• ECC with single-bit correction, single-bit detection, and double-bit detection.
• Minimum program size is 2 consecutive 32 bit words, aligned on a 0-modulo-8 byte address, due
to ECC.
• Embedded hardware program and erase algorithm.
• Read while Write with multiple partitions.
• Erase suspend, program suspend and erase-suspended program.
• Automotive flash which meets automotive endurance and reliability requirements.
• Shadow information stored in non-volatile shadow block.
• Independent program/erase of the shadow block.
Table 24-2 shows the shadow block space. The 16K region of the Shadow Block for Flash B space mirrors
from 0x00E0_0000 to 0x00EF_FFFF and Shadow A mirrors every 16K from 0x00F0_0000 through
0x00FF_FFFF. Mirrored operation is not guaranteed
Flash_A and Flash_B arrays have separate configuration and control registers for programming and erase
operations. Flash bus configuration registers are common to both arrays.
Table 24-2. Shadow Block Memory Map
Offset from
Shadow
FLASH_BASE Use
Block
(0x0000_0000)
Offset from
Shadow
FLASH_BASE Use
Block
(0x0000_0000)
Offset from
FLASH_REGS_
Register Bits Access Reset Value1 Section/Page
BASE
(0xC3F8_8000)
Offset from
FLASH_REGS_
Register Bits Access Reset Value1 Section/Page
BASE
(0xC3F8_8000)
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
Reset 0 0 0 0 0 1 1 1 0 —1 —1 —1 0 0 0 —1
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
Reset 0 0 0 0 0 1 1 0 0 0 0 0 0 0 0 0
1
See register description below.
Field Description
0–4 Reserved
5–7 Array Space Size. The value of the SIZE field is dependent upon the size of the flash array. SIZE is read
SIZE only.
111 3.0 MB. (256 KB of LAS, 256 KB of MAS, and 2.5MB of HAS) (Both Flash_A and Flash_B)
All others are Reserved.
8 Reserved
9–11 Low Address Space. The value of the LAS field corresponds to the configuration of the Low Address
LAS[2:0] Space. LAS is read only.
000 One 256 KB Blocks. (Flash_B)
100 Eight 16 KB, two 64 KB Blocks. (Flash_A)
All others are Reserved.
12–14 Reserved
15 Mid Address Space. The value of the MAS field corresponds to the configuration of the Mid Address
MAS Space. MAS is read only.
0 Two 128 KB Blocks. (Flash_A)
1 One 256 KB Blocks. (Flash_B)
16 ECC Event Error. EER provides information on previous reads. If a double bit detection occurred, the EER
EER bit is set to a 1. This bit must then be cleared, or a reset must occur before this bit returns to a 0 state.
This bit may not be set by the user. In the event of a single bit detection and correction, this bit is not be
set. If EER is not set, or remains 0, this indicates that all previous reads (from the last reset, or clearing of
EER) are correct. Since this bit is an error flag, it must be cleared to a 0 by writing a 1 to the register
location. A write of 0 has no effect.
0 Reads are occurring normally.
1 An ECC Error occurred during a previous read.
Field Description
17 Read While Write Event Error. RWE provides information on previous RWW reads. If a Read While Write
RWE error occurs, this bit is set to 1. This bit must then be cleared, or a reset must occur before this bit returns
to a 0 state. This bit may not be written to a 1 by the user. If RWE is not set, or remains 0, this indicates
that all previous RWW reads (from the last reset, or clearing of RWE) are correct. Since this bit is an error
flag, it must be cleared to a 0 by writing a 1 to the register location. A write of 0 has no effect.
0 Reads are occurring normally.
1 A Read While Write Error occurred during a previous read.
18 Single Bit Correction. SBC provides information on previous reads provided the FLASH_x_UT0[SPCE] is
SBC set. If a single bit correction occurred, the SBC bit is set to a 1. This bit must then be cleared, or a reset
must occur before this bit returns to a 0 state. If SBC is not set, or remains 0, this indicates that all previous
reads (from the last reset, or clearing of SBC) did not require a correction. Since this bit is an error flag,
it must be cleared to a 0 by writing a 1 to the register location. A write of 0 has no effect.
0 Reads are occurring without corrections.
1 A Single Bit Correction occurred during a previous read.
19 Reserved
20 Program/Erase Access Space. PEAS is used to indicate which space is valid for program and erase
PEAS operations, either main array space or shadow space. PEAS = 0 indicates that the main address space is
active for all FC program and erase operations. PEAS = 1 indicates the shadow address space is active
for program/erase. The value in PEAS is captured and held when the shadow block is enabled with the
first interlock write done for program or erase operations. The value of PEAS is retained between sampling
events (i.e. subsequent first interlock writes). The value in PEAS may be changed during
erase-suspended program, and reverts back to its’ original state once the erase-suspended program is
completed. PEAS is read only.
0 Shadow address space is disabled for program/erase and main address space enabled.
1 Shadow address space is enabled for program/erase and main address space disabled.
21 State Machine Status. DONE indicates if the flash module is performing a high voltage operation. DONE
DONE is set to a 1 on termination of the flash module reset. DONE is read only. DONE is cleared within Tdone
of a 0 to 1 transition of EHV which initiates a high voltage operation. DONE is cleared within Tres of
resuming a suspended operation. DONE is set to a 1 at the end of program and erase high voltage
sequences. DONE is set to a 1 within Tdones of a 1 to 0 transition of EHV which aborts a high voltage
operation.
0 Flash is executing a high voltage operation.
1 Flash is not executing a high voltage operation.
22 Program/Erase Good. The PEG bit indicates the completion status of the last flash program or erase
PEG sequence for which high voltage operations were initiated. The value of PEG is updated automatically
during the program and erase high voltage operations. Aborting a program/erase high voltage operation
causes PEG to be cleared, indicating the sequence failed. PEG is set to a 1 when the module is reset.
PEG is read only.
The value of PEG is valid only when PGM = 1 and/or ERS = 1 and after DONE transitions from 0 to 1 due
to an abort or the completion of a program/erase operation. PEG is valid until PGM/ERS makes a 1 to 0
transition or EHV makes a 0 to 1 transition. The value in PEG is not valid after a 0 to 1 transition of DONE
caused by PSUS or ESUS being set to logic 1. If PGM and ERS are both 1 when DONE makes a qualifying
0 to 1 transition the value of PEG indicates the completion status of the PGM sequence. This happens in
an erase-suspended program operation.
0 Program or erase operation failed.
1 Program or erase operation successful.
Note: If program or erases are attempted on blocks that are locked, the response from flash is PEG = 1,
indicating that the operation was successful, and the contents of the block are properly protected
from the program or erase operation.
Field Description
23–26 Reserved
27 Program. PGM is used to set up flash for a program operation. A 0 to 1 transition of PGM initiates a
PGM program sequence. A 1 to 0 transition of PGM ends the program sequence. PGM can be set only under
one of the following conditions:
• User mode read (ERS is low and UTE is low).
• Erase suspend (ERS and ESUS are 1) with EHV low.
PGM can be cleared by the user only when PSUS and EHV are low and DONE is high. PGM is cleared
on reset.
0 Flash is not executing a program sequence.
1 Flash is executing a program sequence.
Note: In an erase-suspended program, programming Flash locations in blocks which were being operated
on in the erase may corrupt FC data. This should be avoided due to reliability implications.
28 Program Suspend. PSUS is used to indicate the flash module is in program suspend or in the process of
PSUS entering a suspend state. The module is in program suspend when PSUS = 1 and DONE = 1. PSUS can
be set high only when PGM and EHV are high. A 0 to 1 transition of PSUS starts the sequence which sets
DONE and places the flash module in program suspend. The module enters suspend within Tpsus of this
transition.
PSUS can be cleared only when DONE and EHV are high. A 1 to 0 transition of PSUS with EHV = 1 starts
the sequence which clears DONE and returns the flash module to program. The module cannot exit
program suspend and clear DONE while EHV is low. PSUS is cleared on reset.
0 Program sequence is not suspended.
1 Program sequence is suspended.
29 Erase. ERS is used to set up flash for an erase operation. A 0 to 1 transition of ERS initiates an erase
ERS sequence. A 1 to 0 transition of ERS ends the erase sequence. ERS can only be set only in user mode
read (PGM is low and UTE is low). ERS can be cleared by the user only when ESUS and EHV are low
and DONE is high. ERS is cleared on reset.
0 Flash is not executing an erase sequence.
1 Flash is executing an erase sequence.
Field Description
30 Erase Suspend. ESUS is used to indicate that the flash module is in erase suspend or in the process of
ESUS entering a suspend state. The module is in erase suspend when ESUS = 1 and DONE = 1. ESUS can be
set high only when ERS and EHV are high and PGM is low. A 0 to 1 transition of ESUS starts the sequence
which sets DONE and places the flash in erase suspend. The flash module enters suspend within Tesus
of this transition.
ESUS can be cleared only when DONE and EHV are high and PGM is low. A 1 to 0 transition of ESUS
with EHV = 1 starts the sequence which clears DONE and returns the module to erase. The flash module
cannot exit erase suspend and clear DONE while EHV is low. ESUS is cleared on reset.
0 Erase sequence is not suspended.
1 Erase sequence is suspended.
31 Enable High Voltage. The EHV bit enables the flash module for a high voltage program/erase operation.
EHV EHV is cleared on reset. EHV must be set after an interlock write to start a program/erase sequence. EHV
may be set, initiating a program/erase, after an interlock under one of the following conditions:
• Erase (ERS = 1, ESUS = 0).
• Program (ERS = 0, ESUS = 0, PGM = 1, PSUS = 0).
• Erase-suspended program (ERS = 1, ESUS = 1, PGM = 1, PSUS = 0).
If a program operation is to be initiated while an erase is suspended the user must clear EHV while in erase
suspend before setting PGM.
In normal operation, a 1 to 0 transition of EHV with DONE high, PSUS and ESUS low terminates the
current program/erase high voltage operation.
When an operation is aborted, there is a 1 to 0 transition of EHV with DONE low and the suspend bit for
the current program/erase sequence low. An abort causes the value of PEG to be cleared, indicating a
failed program/erase; address locations being operated on by the aborted operation contain indeterminate
data after an abort.
A suspended operation cannot be aborted. EHV may be written during suspend. EHV must be high for the
flash module to exit suspend. EHV may not be written after a suspend bit is set high and before DONE
transitions high. EHV may not be set low after the current suspend bit is set low and before DONE
transitions low.
0 Flash is not enabled to perform a high voltage operation.
1 Flash is enabled to perform a high voltage operation.
Note: Aborting a high voltage operation leaves FC addresses in an indeterminate data state. This may
be recovered by executing an erase on the affected blocks.
If the user attempts to write two or more FLASH_x_MCR bits simultaneously then only the bit with the
lowest priority level is written. Setting two bits with the same priority level is prevented by existing write
locks or do not put the flash in an illegal state.
For example, setting ERS and PGM simultaneously results in only ERS being set. Attempting to clear
EHV while setting PSUS results in EHV being cleared, while PSUS is unaffected.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R LME 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
SLOCK MLOCK LLOCK
W
Reset 0 0 0 0 0 0 0 0 0 0 0 1* 0 0 1* 1* 0 0 0 0 0 0 1* 1* 1* 1* 1* 1* 1* 1* 1* 1*
Field Description
0 Low/Mid Address Lock Enable. This bit is used to enable the Lock registers (SLOCK, MLOCK and
LME LLOCK) to be set or cleared by register writes. This bit is a status bit only, and may not be written or
cleared, and the reset value is 0. The method to set this bit is to write a password, and if the password
matches, the LME bit is set to reflect the status of enabled, and is enabled until a reset operation occurs.
For LME, the password 0xA1A1_1111 must be written to the FLASH_x_LMLR register.
0 Low/Mid Address Locks are disabled, and can not be modified.
1 Low/Mid Address Locks are enabled to be written.
1–10 Reserved
11 Shadow Lock. This bit is used to lock the shadow block from programs and erases. A value of 1 in the
SLOCK SLOCK register signifies that the shadow block is locked for program and erase. A value of 0 in the
SLOCK register signifies that the shadow block is available to receive program and erase pulses. The
SLOCK register is not writable once an interlock write is completed until FLASH_x_MCR[DONE] is set
at the completion of the requested operation. Likewise, SLOCK register is not writable if a high voltage
operation is suspended. SLOCK is also not writeable during UTest operations, when AIE is high.
Upon reset, information from the shadow block is loaded into the SLOCK register. The SLOCK bit may
be written as a register. Reset causes the bits to go back to their shadow block value. The default value
of the SLOCK bits (assuming erased shadow location) is locked.
SLOCK is not writable unless LME is high.
12–13 Reserved
14–15 Mid Address Space Block Lock. A value of 1 in a bit of the lock register signifies that the corresponding
MLOCK[1:0] block is locked for program and erase. A value of 0 in the lock register signifies that the corresponding
block is available to receive program and erase pulses.
The block numbering for Mid Address Space is given in the table below, and is different for Flash_A and
Flash_B.
0 M0 M0
1 M1 none
The lock register is not writable once an interlock write is completed until FLASH_x_MCR[DONE] is set
at the completion of the requested operation. Likewise, the lock register is not writable if a high voltage
operation is suspended. MLOCK is also not writeable during UTest operations, when AIE is high.
Upon reset, information from the shadow block is loaded into the block registers. The LOCK bits may
be written as a register. Reset causes the bits to go back to their shadow block value. The default value
of the LOCK bits (assuming erased shadow location) is locked.
In the event that blocks are not present (due to configuration or total memory size), the LOCK bits
default to be locked, and are not writable. The reset value is always 1 (independent of the shadow
block), and register writes have no effect.
Field Description
16–21 Reserved
22–31 Low Address Space Block Lock. A value of 1 in a bit of the lock register signifies that the corresponding
LLOCK block is locked for program and erase. A value of 0 in the lock register signifies that the corresponding
block is available to receive program and erase pulses. The block numbering for Low Address Space is
given in the table below, and is different for Flash_A and Flash_B.
0 L0 L0
1 L1 none
2 L2 none
3 L3 none
4 L4 none
5 L5 none
6 L6 none
7 L7 none
8 L8 none
9 L9 none
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R HB
0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
E HLOCK
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1* 1* 1* 1* 1* 1* 1* 1* 1* 1*
Field Description
0 High Address Lock Enable This bit is used to enable the Lock registers (HLOCK) to be set or cleared
HBE by register writes. This bit is a status bit only, and may not be written or cleared, and the reset value is
0. The method to set this bit is to provide a password, and if the password matches, the HBE bit is set
to reflect the status of enabled, and is enabled until a reset operation occurs. For HBE, the password
0xB2B2_2222 must be written to the FLASH_x_HLR register.
0 High Address Locks are disabled, and can not be modified.
1 High Address Locks are enabled to be written.
1–21 Reserved
22–31 High Address Space Block Lock. HLOCK has the same characteristics as LLOCK. Please see this
HLOCK description for more information. The block numbering for High Address Space is given in the table
below, and is the same for Flash_A and Flash_B.
0 H0 H0
1 H1 H1
2 H2 H2
3 H3 H3
4 H4 H4
5 H5 H5
6 H6 H6
7 H7 H7
8 H8 H8
9 H9 H9
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R SLE 0 0 0 0 0 0 0 0 0 0
SS
0 0
SM
0 0 0 0 0 0
SLLOCK
LOCK LOCK
W
Reset 0 0 0 0 0 0 0 0 0 0 0 1* 0 0 1* 1* 0 0 0 0 0 0 1* 1* 1* 1* 1* 1* 1* 1* 1* 1*
NOTE
Writing the password 0xC3C3_3333 to this register does not modify the
SSLOCK, SMLOCK, or SLLOCK fields. Only the SLE bit changes.
FLASH_x_SLMLR register functions, as shown in Table 24-8.
Table 24-8. FLASH_x_SLMLR Field Descriptions
Field Description
0 Secondary Low/Mid Address Lock Enable. This bit is used to enable the Lock registers (SSLOCK,
SLE SMLOCK, and SLLOCK) to be set or cleared by register writes. This bit is a status bit only, and may
not be written or cleared, and the reset value is 0. The method to set this bit is to provide a password,
and if the password matches, the SLE bit is set to reflect the status of enabled, and is enabled until
a reset operation occurs. For SLE, the password 0xC3C3_3333 must be written to the
FLASH_x_SLMLR register
0 Secondary Low/Mid Address Locks are disabled, and can not be modified.
1 Secondary Low/Mid Address Locks are enabled to be written.
1–10 Reserved
11 Secondary Shadow Lock. This bit is an alternative method that may be used to lock the shadow block
SSLOCK from programs and erases. SSLOCK has the same description as SLOCK in the FLASH_x_LMLR
register (see Figure 24-5). SSLOCK is not writable unless SLE is high.
12–13 Reserved
Field Description
14–15 Secondary Mid Address Block Lock. This bit is an alternative method that may be used to lock the
SMLOCK Mid Address Space blocks from programs and erases. SMLOCK has the same description as
MLOCK in the FLASH_x_LMLR register. SMLOCK is not writable unless SLE is high.
16–21 Reserved
22–31 Secondary Low Address Block Lock. This bit is an alternative method that may be used to lock the
SLLOCK Low Address Space blocks from programs and erases. SLLOCK has the same description as
LLOCK in the FLASH_x_LMLR register. SLLOCK is not writable unless SLE is high.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
MSEL LSEL
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Field Description
0–13 Reserved
14–15 Mid Address Space Block Select. A value of 1 in the select register signifies that the block is selected for
MSEL erase. A value of 0 in the select register signifies that the block is not selected. The reset value for the
select registers is 0, or un-selected.
The blocks must be selected (or un-selected) before doing an erase interlock write as part of the erase
sequence. The select register is not writable once an interlock write is completed until
FLASH_x_MCR[DONE] is set at the completion of the requested operation, or if a high voltage operation
is suspended. MSEL is also not writeable during UTest operations, when AIE is high.
In the event that blocks are not present (due to configuration or total memory size), the corresponding
select bits default to un-selected, and are not writable. The reset value is always 0, and register writes
have no effect.
MSEL bits are mapped to block numbers in the same way as described for the MLOCK bits of the
FLASH_x_LMLR register.
Field Description
16–21 Reserved
22–31 Low Address Space Block Select. A value of 1 in the select register signifies that the block is selected
LSEL[9:0] for erase. A value of 0 in the select register signifies that the block is not selected. The reset value for the
select registers is 0, or un-selected.
The blocks must be selected (or un-selected) before doing an erase interlock write as part of the erase
sequence. The select register is not writable once an interlock write is completed until
FLASH_x_MCR[DONE] is set at the completion of the requested operation, or if a high voltage operation
is suspended. LSEL is also not writeable during UTest operations, when AIE is high.
In the event that blocks are not present (due to configuration or total memory size), the corresponding
select bits default to un-selected, and are not writable. The reset value is always 0, and register writes
have no effect.
LSEL bits are mapped to block numbers in the same way as described for the LLOCK bits of the
FLASH_x_LMLR register.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
HSEL
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Field Description
0–21 Reserved
22–31 High Address Space Block Select. High Address Block Select has the same characteristics as LSEL.
HSEL[5:0]
The following field and bit descriptions fully define the FLASH_x_AR (Figure 24-10).
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R SAD 0 0 0 0 0 0 0 0 0 0 0 0 0 ADDR 0 0 0
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Field Description
0 Shadow Address. The SAD bit qualifies the address captured during an ECC Event Error, Single Bit
SAD Correction, or State Machine operation.
The SAD register is not writable.
0 Address Captured is from Main Array Space.
1 Address Captured is from Shadow Array Space.
1–13 Reserved
14–28 Address. The FLASH_x_AR provides the first failing address in the event of ECC event error
ADDR[17:3] (FLASH_x_MCR[EER] set), single bit correction (FLASH_x_MCR[SBC] set), as well as providing the
address of a failure that may have occurred in a state machine operation (FLASH_x_MCR[PEG]
cleared). ECC event errors take priority over single bit corrections, which take priority over state
machine errors. This is especially valuable in the event of a RWW operation, where the read senses an
ECC error or single bit correction, and the state machine fails simultaneously. This address is always a
Double Word address that selects 64 bits.
The FLASH_x_AR is writable, and can be used in the UTEST ECC Logic Check. If the ECC logic check
is enabled (FLASH_x_UT0[EIE] = 1) then the FLASH_x_AR will not update for ECC event error, single
bit correction or state machine errors.
If FLASH_x_MCR[EER] or FLASH_x_MCR[SBC] are set, the FLASH_x_AR is locked from writing.
FLASH_x_MCR[PEG] does not affect the writability of the FLASH_x_AR.
29–31 Reserved
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R 0
APC WWSC RWSC DPFEN ARB IFPFEN PRI PFLIM BFEN
W
Reset 1 1 1 1 1 1 1 1 0 0 0 0 0 0 0 0
Figure 24-11. Flash Bus Interface Configuration Register (FLASH_BIUCR)
Field Description
0–15 Master n prefetch enable, where n represents the master ID number in the table below. These bits are used
MnPFE to control whether prefetching may be triggered based on the master ID of a requesting master. These bits
are cleared by hardware reset.
0 No prefetching may be triggered by this master
1 Prefetching may be triggered by this master
Note: These bits refer to the master ID, not the master port number, as shown in the following:
Master ID Module
0 Z7 Core
1 – reserved –
2 – reserved –
3 – reserved –
4 eDMA_A
5 eDMA_B
6 FlexRay
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R 1 1 1 1 1 1
M6AP M5AP M4AP M1AP M0AP
W
Reset 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1
Figure 24-12. Flash Bus Interface Access Protection Register (FLASH_BIUAPR)
Field Description
0–11 Reserved
16–17
24–27
12–15 Master n Access Protection, where n represents the master ID number in the table below. These fields are
18–23 used to control whether read and write accesses to the flash are allowed based on the master ID of a
28–31 requesting master.
MnAP 00 No accesses may be performed by this master
01 Only read accesses may be performed by this master
10 Only write accesses may be performed by this master
11 Both read and write accesses may be performed by this master
Note: These bits refer to the master ID, not the master port number, as shown in the following:
Master ID Module
0 Core 0
1 Core 1
2 – reserved –
3 – reserved –
4 eDMA_A
5 eDMA_B
6 FlexRay
7 Reserved for EBI test
(not for customer use)
8 Core 0 Nexus
9 Core 1 Nexus
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
W
Reset 1* 1* 1* 1* 1* 1* 1* 1* 1* 1* 1* 1* 1* 1* 1* 1*
Figure 24-13. Flash Bus Interface Configuration Register 2 (FLASH_BIUCR2)
Field Description
0–1 Line Buffer Configuration. This field controls the configuration of all the line buffers in the flash bus interface
LBCFG_P0 unit attached to crossbar slave port 0. The buffers can be organized as a “pool” of available resources, or
with a fixed partition between instruction and data buffers.
In all cases, when a buffer miss occurs, it is allocated to the least-recently-used buffer within the group and
the just-fetched entry then marked as most-recently-used. If the flash access is for the next-sequential line,
the buffer is not marked as most-recently-used until the given address produces a buffer hit.
This field is initialized by hardware reset to the value contained in address0x00FF_FE00 of the shadow block
of the flash array. The initial value is given in Table 24-2.
This field controls the configuration of both the 4 x 128 and 4 x 256 line buffers.
00 All four buffers are available for any flash access, i.e., there is no partitioning of the buffers based on the
access type.
01 Reserved
10 The buffers are partitioned into two groups with buffers 0 and 1 allocated for instruction fetches and
buffers 2 and 3 for data accesses.
11 The buffers are partitioned into two groups with buffers 0,1,2 allocated for instruction fetches and buffer
3 for data accesses.
Field Description
2–3 Line Buffer Configuration. This field controls the configuration of all the line buffers in the flash bus interface
LBCFG_P1[1:0] unit attached to crossbar slave port 3. The buffers can be organized as a “pool” of available resources, or
with a fixed partition between instruction and data buffers.
In all cases, when a buffer miss occurs, it is allocated to the least-recently-used buffer within the group and
the just-fetched entry then marked as most-recently-used. If the flash access is for the next-sequential line,
the buffer is not marked as most-recently-used until the given address produces a buffer hit.
This field is initialized by hardware reset to the value contained in address 0x00FF_FE00 of the shadow block
of the flash array. The initial value is given in Table 24-2.
This field controls the configuration of both the 4 x 128 and 4 x 256 line buffers.
00 All four buffers are available for any flash access, i.e., there is no partitioning of the buffers based on the
access type.
01 Reserved
10 The buffers are partitioned into two groups with buffers 0 and 1 allocated for instruction fetches and
buffers 2 and 3 for data accesses.
11 The buffers are partitioned into two groups with buffers 0,1,2 allocated for instruction fetches and buffer
3 for data accesses.
4–31 Reserved
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R 0 0 0 0 0 0
DPFEN IFPFEN PFLIM BFEN
W
Reset 1* 1* 1* 1* 1* 1* 1* 1* 1* 1* 1* 1* 1* 1* 1* 1*
Figure 24-14. Flash Bus Interface Configuration Register 3 (FLASH_BIUCR3)
Field Description
MnPFE Master n prefetch enable, where n represents the master ID number in the table below. These bits are used to
control whether prefetching may be triggered based on the master ID of a requesting master. These bits are
cleared by hardware reset.
0 No prefetching may be triggered by this master
1 Prefetching may be triggered by this master
Note: These bits refer to the master ID, not the master port number, as shown in the following:
Master ID Module
0 – reserved –
1 Core 1
2 – reserved –
3 – reserved –
4 eDMA_A
5 eDMA_B
6 FlexRay
7 Reserved for EBI test
(not for customer use)
8 – reserved –
9 Core 1Nexus
DPFEN Data Prefetch Enable - This field enables or disables prefetching initiated by a data read access. This field is
cleared by hardware reset.
0 No prefetching is triggered by a data read access
1 Prefetching may be triggered by any data read access
IPFEN Instruction Prefetch Enable - This bit enables or disables prefetching initiated by an instruction read access. This
field is cleared by hardware reset.
0 No prefetching is triggered by an instruction read access
1 Prefetching may be triggered by any instruction read access
PFLIM[1:0] Flash Prefetch Limit - This field controls the prefetch algorithm used by the flash prefetch controller. This field
defines a limit on the maximum number of sequential prefetches which will be attempted between buffer misses.
In all situations when enabled, only a single prefetch is initiated on each buffer miss or hit. This field is cleared
by hardware reset.
00 No prefetching or buffering is performed.
01 The referenced line is prefetched on a buffer miss, i.e., prefetch on miss.
1x The referenced line is prefetched on a buffer miss, or the next sequential line is prefetched on a buffer hit (if
not already present), i.e., prefetch on miss or hit.
BFEN Flash Line Read Buffers Enable - This bit enables or disables line read buffer hits. It is also used to invalidate the
buffers. This bit is cleared by hardware reset.
0 The line read buffers are disabled from satisfying read requests, and all buffer valid bits are cleared.
1 The line read buffers are enabled to satisfy read requests on hits. Buffer valid bits may be set when the buffers
are successfully filled.
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R 0 0 0 0 0 0 0 0 0 AID
EA MRE MRV EIE AIS AIE
W
Reset 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 1
Figure 24-15. User Test Register 0 (FLASH_x_UT0)
Field Description
0 UTest Enable. This status bit gives indication when UTest is enabled. All bits in FLASH_x_UT0, FLASH_x_UT1,
UTE FLASH_x_UT2 are locked when this bit is 0. This bit is not writeable to a 1, but may be cleared. The reset value
is 0. The method to set this bit is to provide a password, and if the password matches, the UTE bit is set to reflect
the status of enabled, and is enabled until it is cleared by a register write. The UTE password will only be
accepted if FLASH_x_MCR[PGM] = 0 and FLASH_x_MCR [ERS] = 0 (program and erase are not being
requested). UTE can only be cleared if FLASH_x_UT0[AID] = 1, FLASH_x_UT0[AIE] and
FLASH_x_UT0[EIE] = 0. While clearing UTE, writes to set AIE or set EIE will be ignored. For UTE, the password
0xF9F9_9999 must be written to the FLASH_x_UT0 register.
1 Single Bit Correction Enable. SBC enables Single Bit Correction results to be observed in FLASH_x_MCR[SBC].
SCBE Also is used as an enable for interrupt signals created by the c90fl module (see c90fl Integration Guide). ECC
corrections that occur when SBCE is cleared will not be logged.
0 Single Bit Corrections observation is disabled.
1 Single Bit Correction observation is enabled.
2–7 Reserved
8–15 Data Syndrome Input. These bits enable checks of ECC logic by allowing check bits to be input into the ECC
DSI logic and then read out by doing array reads or array integrity checks. The DSI[7:0] correspond to the 8 ECC
check bits on a double word.
16–23 Reserved
24 ECC Algorithm. EA is a status bit that provides information about the ECC algorithm used within the Flash. Either
EA a modified Hamming code is used, or a modified Hsiao code is used.
0 ECC is implemented with a modified Hamming algorithm.
1 ECC is implemented with a modified Hsiao algorithm.
25 Reserved
26 Margin Read Enable. MRE combined with MRV enables Factory Margin Reads to be done. Margin reads are only
MRE active during Array Integrity Checks. Normal user reads are not affected by MRE. MRE is not writable if AID is low.
0 Margin reads are not enabled.
1 Margin reads are enabled during Array Integrity Checks.
Field Description
27 Margin Read Value. MRV selects the margin level that is being checked. Margin can be checked to an erased
MRV level (MRV = 1) or to a programmed level (MRV = 0). In order for this value to be valid, MRE must also be set.
MRV is not writable if AID is low.
0 Zero’s margin reads are requested.
1 One’s margin reads are requested.
28 ECC Data Input Enable. EIE enables the input registers (DSI and DAI) to be the source of data for the array. This
EIE is useful in the ECC logic check. If this bit is set, data read through a BIU read request will be from the DSI and
DAI registers when an address match is achieved to the FLASH_x_AR. EIE is not simultaneously writable to a 1
as UTI is being cleared to a 0.
0 Data read is from the flash array.
1 Data read is from the DSI and DAI registers.
29 Array Integrity Sequence. AIS determines the address sequence to be used during array integrity checks. The
AIS default sequence (AIS = 0) is meant to replicate sequences normal “user” code follows, and thoroughly checks
the read propagation paths. This sequence is proprietary. The alternative sequence (AIS = 1) is just logically
sequential.
It should be noted that the time to run a sequential sequence is significantly shorter than the time to run the
proprietary sequence. If MRE is set, AIS has no effect.
0 Array integrity sequence is proprietary sequence.
1 Array integrity sequence is sequential.
30 Array Integrity Enable. AIE set to one starts the array integrity check done on all selected and unlocked blocks.
AIE The address sequence selected is determined by AIS, and the MISR (UM0 through UM4) can be checked after
the operation is complete, to determine if a correct signature is obtained. Once an Array Integrity operation is
requested (AIE = 1), it may be terminated by clearing AIE if the operation has finished (AID = 1) or aborted by
clearing AIE if the operation is ongoing (AID = 0). AIE is not simultaneously writable to a 1 as UTI is being cleared
to a 0.
0 Array integrity checks are not enabled.
1 Array integrity checks are enabled.
31 Array Integrity Done. AID is cleared upon an Array integrity check being enabled (to signify the operation is
AID ongoing). Once completed, AID is set to indicate that the array integrity check is complete. At this time the MISR
(UMR registers) can be checked. AID can not be written, and is status only.
0 Array integrity check is ongoing.
1 Array integrity check is done.
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R
DAI
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 24-16. User Test Register 1 (FLASH_x_UT1)
Field Description
0–31 Data Array Input. These bits enable checks of ECC logic by allowing data bits to be input into the ECC logic
DAI and then read out by doing array reads or array integrity checks. The DAI[31:0] correspond to the 32 Array
bits representing Word 0 of the double word selected in the FLASH_x_AR.
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R
DAI
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 24-17. User Test Register 2 (FLASH_x_UT2)
Field Description
0–31 Data Array Input. These bits enable checks of ECC logic by allowing data bits to be input into the ECC logic
DAI and then read out by doing array reads or array integrity checks. The DAI[63:32] correspond to the 32 Array
bits representing Word 1of the double word selected in the FLASH_x_AR.
A software mechanism is provided to independently lock or unlock each block in high-, mid-, and
low-address space against program and erase. Two hardware locks are also provided to enable/disable the
FC for program/erase. See Section 24.3.4.1, “Software Locking”, for more information.
The first write after a program is initiated determines the page address to be programmed. Program may
be initiated with the 0 to 1 transition of the FLASH_x_MCR[PGM] bit or by clearing the
FLASH_x_MCR[EHV] bit at the end of a previous program. This first write is referred to as an interlock
write. If the program is not an erase-suspended program, the interlock write determines if the shadow or
normal array space will be programmed and causes FLASH_x_MCR[PEAS] to be set/cleared.
NOTE
Only the first write after a program is initiated does the interlock write and
all later writes only look at bits 2 and 3 of the address so be careful that all
writes after the interlock write are for that same 128 bit section.
In the case of an erase-suspended program, the value in FLASH_x_MCR[PEAS], is retained from the
erase.
An interlock write must be performed before setting FLASH_x_MCR[EHV]. The user may terminate a
program sequence by clearing FLASH_x_MCR[PGM] prior to setting FLASH_x_MCR[EHV].
If multiple writes are done to the same location the data for the last write is used in programming.
While FLASH_x_MCR[DONE] is low, FLASH_x_MCR[EHV] is high, and FLASH_x_MCR[PSUS] is
low, the user may clear FLASH_x_MCR[EHV], resulting in a program abort. A program abort forces the
module to step 8 of the program sequence. An aborted program will result in FLASH_x_MCR[PEG] being
set low, indicating a failed operation. The data space being operated on before the abort will contain
indeterminate data. The user may not abort a program sequence while in program suspend.
NOTE
Aborting a program operation will leave the flash core addresses being
programmed in an indeterminate data state. This may be recovered by
executing an erase on the affected blocks.
No
Step 3 Last write
?
Yes
PGM = 0 User mode read state
Step 4 Write MCR
or erase suspend
EHV = 1
WRITE
Step 5 PSUS = 1 DONE = 1
High voltage active Read MCR
Access MCR
Abort PSUS = 0 Program suspend
WRITE EHV = 1
EHV = 0 Write MCR
DONE = 0
DONE
? Note: PSUS cannot be cleared while
PEG = 0 PEG valid period DONE = 1 EHV = 0. PSUS and EHV cannot
both be changed in a single
write operation.
Step 6 Read MCR
Success Failure
PEG = 1 PEG PEG = 0
value
?
Step 7
Write MCR
EHV = 0
PGM = 0
0 ESUS 1
?
User mode read state Erase suspend
NOTE
Lock and select are independent. If a block is selected and locked, no erase
will occur. See Section 24.2.2.2, “Low/Mid Address Space Block Locking
Register (FLASH_x_LMLR)”, Section 24.2.2.3, “High Address Space
Block Locking Register (FLASH_x_HLR)”, and Section 24.2.2.4,
“Secondary Low/Mid Address Space Block Locking Register
(FLASH_x_SLMLR)”, for more information.
3. Write to any address in flash within the flash array A or B (i.e. if you intend to erase a B block, you
need to make sure the address is in array B). This is referred to as an erase interlock write.
4. Write a logic 1 to the FLASH_x_MCR[EHV] bit to start an internal erase sequence or skip to step
9 to terminate.
5. Wait until the FLASH_x_MCR[DONE] bit goes high.
6. Confirm FLASH_x_MCR[PEG] = 1.
7. Write a logic 0 to the FLASH_x_MCR[EHV] bit.
8. If more blocks are to be erased, return to step 2.
9. Write a logic 0 to the FLASH_x_MCR[ERS] bit to terminate the erase.
The erase sequence is presented graphically in Figure 24-19. The erase suspend operation detailed in
Figure 24-19 is discussed in section Section 24.3.5.1, “Flash Erase Suspend/Resume”.
After setting FLASH_x_MCR[ERS], one write (referred to as an interlock write) must be performed
before FLASH_x_MCR[EHV] can be set to a 1. Data words written during erase sequence interlock writes
are ignored. The user may terminate the erase sequence by clearing FLASH_x_MCR[ERS] before setting
FLASH_x_MCR[EHV].
An erase operation may be aborted by clearing FLASH_x_MCR[EHV] assuming
FLASH_x_MCR[DONE] is low, FLASH_x_MCR[EHV] is high, and FLASH_x_MCR[ESUS] is low. An
erase abort forces the module to step 8 of the erase sequence. An aborted erase will result in
FLASH_x_MCR[PEG] being set low, indicating a failed operation. The blocks being operated on before
the abort contain indeterminate data. The user may not abort an erase sequence while in erase suspend.
NOTE
Aborting an erase operation will leave the flash core blocks being erased in
an indeterminate data state. This may be recovered by executing an erase on
the affected blocks.
ERS = 0
Step 4 Write MCR User mode read state
EHV = 1
WRITE
Step 5 ESUS = 1 DONE = 1
High voltage active Read MCR
Access MCR
Abort ESUS = 0 Erase suspend
WRITE EHV = 1
EHV = 0 Write MCR
DONE = 0
DONE EHV = 0
?
Write MCR
PEG = 0 PEG Valid Period DONE = 1
PGM = 1
ERS = 0
NOTE
If an erase of user space is requested, and a suspend is done with attempts
to erase suspend program shadow space, this attempted program will be
directed to user space as dictated by the state of FLASH_x_MCR[PEAS].
Likewise an attempted erase suspended program of user space, while the
shadow space is being erased, will be directed to shadow space as dictated
by the state of FLASH_x_MCR[PEAS].
The shadow block cannot use the RWW feature. After an operation is started in the shadow block, a read
cannot be done to the shadow block, or any other block. Likewise, after an operation is started in a block
in low-/mid-/high-address space, a read cannot be done in the shadow block.
The shadow block contains information about how the lock registers are reset.
The shadow block may be locked/unlocked against program or erase by using the FLASH_x_LMLR or
FLASH_x_SLMLR discussed in Section 24.2.2, “Register Descriptions”.
WARNING
If the shadow flash block is erased without reprogramming a new valid
password and censorship control word before a reset occurs it will contain
an illegal password and the debug port will be inaccessible. Also, if code
does not exist in the first bootable region of the internal flash to reprogram
the shadow flash with the proper censorship control word and password, the
device will be in a censored state and may no longer be usable.
Programming the shadow row has similar restrictions to programming the array in terms of how ECC is
calculated. See Section 24.3.4, “Flash Programming”, for more information. Only one program is allowed
per 64 bit ECC segment between erases. Erase of the shadow row is done similarly as an array erase. See
section Section 24.3.5, “Flash Erase”, for more information.
Message CAN
MB63 Protocol
Buffer
Management Interface
MB62
RXIMR63
RXIMR62 max MB # CAN Tx
(0–63)
Message CAN Rx
ID Mask Buffer
Storage Storage
64/128/256- 288/544/1056-
byte RAM byte RAM
RXIMR1
RXIMR0
MB1
25.1.1 Overview
The CAN protocol was primarily, but not only, designed to be used as a vehicle serial data bus, meeting
the specific requirements of this field: real-time processing, reliable operation in the EMI environment of
a vehicle, cost-effectiveness and required bandwidth. The FlexCAN module is a full implementation of the
CAN protocol specification, Version 2.0 B [Ref. 1], which supports both standard and extended message
frames. The FlexCAN modules on the MPC5676R supports 64 message buffers. The Message Buffers are
stored in an embedded RAM dedicated to the FlexCAN module.
The CAN Protocol Interface (CPI) sub-module manages the serial communication on the CAN bus,
requesting RAM access for receiving and transmitting message frames, validating received messages and
performing error handling. The Message Buffer Management (MBM) sub-module handles Message
Buffer selection for reception and transmission, taking care of arbitration and ID matching algorithms. The
Bus Interface Unit (BIU) sub-module controls the access to and from the internal interface bus, in order to
establish connection to the CPU and to other blocks. Clocks, address and data buses, interrupt outputs and
test signals are accessed through the Bus Interface Unit.
25.2.1 Overview
The FlexCAN module has two I/O signals connected to the external MCU pins. These signals are
summarized in Table 25-1 and described in more detail in the next subsections.
Table 25-1. FlexCAN Signals
25.2.2.1 CAN Rx
This pin is the receive pin from the CAN bus transceiver. Dominant state is represented by logic level ‘0’.
Recessive state is represented by logic level ‘1’.
25.2.2.2 CAN Tx
This pin is the transmit pin to the CAN bus transceiver. Dominant state is represented by logic level ‘0’.
Recessive state is represented by logic level ‘1’.
registers are provided for backwards compatibility, and are not used when the MBFEN bit in
FLEXCAN_x_MCR is asserted.
The address ranges 0x0060–0x047F and 0x0880–0x097F are occupied by two separate embedded
memories. These two ranges are completely occupied by RAM (1056 and 256 bytes, respectively) only
when FlexCAN is configured with 64 MBs. When it is configured with 16 MBs, the memory sizes are 288
and 64 bytes, so the address ranges 0x0180–0x047F and 0x08C0–0x097F are considered reserved space.
When it is configured with 32 MBs, the memory sizes are 544 and 128 bytes, so the address ranges
0x0280–0x047F and 0x0900–0x097F are considered reserved space. Furthermore, if the MBFEN bit in
FLEXCAN_x_MCR is negated, then the whole Rx Individual Mask Registers address range
(0x0880–0x097F) is considered reserved space.
Affected Affected
Address1 Register Bits Access Reset Value by Hard by Soft Section/Page
Reset Reset
Base + 0x0000 FLEXCAN_x_MCR—Module 32 S 0x5990_000F Yes Yes 25.3.4.1/14
Configuration
Base + 0x0004 FLEXCAN_x_CTRL—Control 32 S 0x0000_0000 Yes No 25.3.4.2/18
Register
Base + 0x0008 FLEXCAN_x_TIMER—Free 32 S 0x0000_0000 Yes Yes 25.3.4.3/21
Running Timer
Base + 0x000C Reserved
Base + 0x0010 FLEXCAN_x_RXGMASK—Rx 32 S 0xFFFF_FFFF Yes No 25.3.4.4/22
Global Mask
Base + 0x0014 FLEXCAN_x_RX14MASK—Rx 32 S 0xFFFF_FFFF Yes No 25.3.4.5/22
Buffer 14 Mask
Base + 0x0018 FLEXCAN_x_RX15MASK—Rx 32 S 0xFFFF_FFFF Yes No 25.3.4.6/23
Buffer 15 Mask
Base + 0x001C FLEXCAN_x_ECR—Error 32 S 0x0000_0000 Yes Yes 25.3.4.7/23
Counter Register
Base + 0x0020 FLEXCAN_x_ESR—Error and 32 S 0x0000_0000 Yes Yes 25.3.4.8/25
Status Register
Base + 0x0024 FLEXCAN_x_IMASK2—Interrupt 32 S 0x0000_0000 Yes Yes 25.3.4.9/28
Masks 2
Base + 0x0028 FLEXCAN_x_IMASK1—Interrupt 32 S 0x0000_0000 Yes Yes 25.3.4.10/28
Masks 1
Base + 0x002C FLEXCAN_x_IFLAG2—Interrupt 32 S 0x0000_0000 Yes Yes 25.3.4.11/29
Flags 2
Base + 0x0030 FLEXCAN_x_IFLAG1—Interrupt 32 S 0x0000_0000 Yes Yes 25.3.4.12/30
Flags 1
Base + Reserved
0x0034–0x005F
Base + Reserved
0x0060–0x007F
Base + Message Buffers MB0–MB15 — S — No No —
0x0080–0x017F
Base + Message Buffers MB16–MB31 — S — No No —
0x0180–0x027F
Base + Message Buffers MB32–MB63 — S — No No —
0x0280–0x047F
Base + Reserved
0x0480-087F
Base + RXIMR0-RXIMR15—Rx Individual S No No 25.3.4.13/32
0x0880-0x08BF Mask Registers
Base + RXIMR16-RXIMR31—Rx S No No 25.3.4.13/32
0x08C0-0x08FF Individual Mask Registers
Base + RXIMR32-RXIMR63—Rx S No No 25.3.4.13/32
0x0900-0x097F Individual Mask Registers
NOTES:
1
FLEXCAN_A = 0xFFFC_0000
FLEXCAN_B = 0xFFFC_4000
FLEXCAN_C = 0xFFFC_8000
FLEXCAN_D = 0xFFFC_C000
The FlexCAN module stores CAN messages for transmission and reception using a Message Buffer
structure. Each individual MB is formed by 16 bytes mapped in memory as described in Table 25-3.
Table 25-3 shows a Standard/Extended Message Buffer (MB0) memory map, using 16 bytes total
(0x80–0x8F space).
Table 25-3. Message Buffer MB0 Memory Mapping
S I R
0x0 CODE R D T LENGTH TIME STAMP
R E R
= Unimplemented or Reserved
Field Description
Rx Code Rx Code
BEFORE Description AFTER Comment
Rx New Frame Rx New Frame
0000 INACTIVE: MB is not active. – MB does not participate in the matching
process.
0100 EMPTY: MB is active and 0010 MB participates in the matching process. When
empty. a frame is received successfully, the code is
automatically updated to FULL.
0010 FULL: MB is full. 0010 The act of reading the C/S word followed by
unlocking the MB does not make the code
return to EMPTY. It remains FULL. If a new
frame is written to the MB after the C/S word
was read and the MB was unlocked, the code
still remains FULL.
0110 If the MB is FULL and a new frame is
overwritten to this MB before the CPU had time
to read it, the code is automatically updated to
OVERRUN. Refer to Section 25.4.5, “Matching
Process”, for details about overrun behavior.
0110 OVERRUN: a frame was 0010 If the code indicates OVERRUN but the CPU
overwritten into a full buffer. reads the C/S word and then unlocks the MB,
when a new frame is written to the MB the code
returns to FULL.
0110 If the code already indicates OVERRUN, and
yet another new frame must be written, the MB
will be overwritten again, and the code will
remain OVERRUN. Refer to Section 25.4.5,
“Matching Process”, for details about overrun
behavior.
0XY11 BUSY: Flexcan is updating the 0010 An EMPTY buffer was written with a new frame
contents of the MB. The CPU (XY was 01).
must not access the MB. 0110 A FULL/OVERRUN buffer was overwritten (XY
was 11).
NOTES:
1
Note that for Tx MBs (see Table 25-6), the BUSY bit should be ignored upon read, except when AEN bit is set
in the FLEXCAN_x_MCR register.
Table 25-6. Message Buffer Code for Tx buffers
Code after
Initial Tx
RTR successful Description
code
transmission
X 1000 – INACTIVE: MB does not participate in the arbitration process.
X 1001 – ABORT: MB was configured as Tx and CPU aborted the
transmission. This code is only valid when AEN bit in
FLEXCAN_x_MCR is asserted. MB does not participate in the
arbitration process.
0 1100 1000 Transmit data frame unconditionally once. After transmission, the
MB automatically returns to the INACTIVE state.
1 1100 0100 Transmit remote frame unconditionally once. After transmission,
the MB automatically becomes an Rx MB with the same ID.
Code after
Initial Tx
RTR successful Description
code
transmission
0 1010 1010 Transmit a data frame whenever a remote request frame with the
same ID is received. This MB participates simultaneously in both
the matching and arbitration processes. The matching process
compares the ID of the incoming remote request frame with the ID
of the MB. If a match occurs this MB is allowed to participate in the
current arbitration process and the Code field is automatically
updated to ‘1110’ to allow the MB to participate in future arbitration
runs. When the frame is eventually transmitted successfully, the
Code automatically returns to ‘1010’ to restart the process again.
0 1110 1010 This is an intermediate code that is automatically written to the MB
by the MBM as a result of match to a remote request frame. The
data frame will be transmitted unconditionally once and then the
code will automatically return to ‘1010’. The CPU can also write
this code with the same effect.
S I R
0x80 R D T LENGTH TIME STAMP
R E R
0x84 ID (Standard/Extended) ID (Extended)
0x88 Data Byte 0 Data Byte 1 Data Byte 2 Data Byte 3
0x8C Data Byte 4 Data Byte 5 Data Byte 6 Data Byte 7
0x90
to Reserved
0xDC
0xE0 ID Table 0
0xE4 ID Table 1
0xE8 ID Table 2
0xEC ID Table 3
0xF0 ID Table 4
0xF4 ID Table 5
0xF8 ID Table 6
0xFC ID Table 7
= Unimplemented or Reserved
0 3 4 7 9 10 11 12 15 16 23 24 31
R E RXIDA
A E X (Standard = 29-19, Extended = 29-1)
M T
R E RXIDB_0 R E RXIDB_1
B E X (Standard = 29-19, Extended = 29-16) E X (Standard = 13-3, Extended = 13-0)
M T M T
= Unimplemented or Re-
served
Field Description
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R 0 0 LPRI 0 0 0 0
AEN IDAM MAXMB
W O_EN
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 1 1 1 1
Figure 25-5. Module Configuration Register (FLEXCAN_x_MCR)
Field Description
0 Module Disable
MDIS This bit controls whether FlexCAN is enabled or not. When disabled, FlexCAN shuts down the clocks to
the CAN Protocol Interface and Message Buffer Management sub-modules. This is the only bit in
FLEXCAN_x_MCR not affected by soft reset. See Section 25.4.9.2, “Module Disable Mode”, for more
information.
0 Enable the FlexCAN module
1 Disable the FlexCAN module
1 Freeze Enable
FRZ The FRZ bit specifies the FlexCAN behavior when the HALT bit in the FLEXCAN_x_MCR Register is set
or when Debug Mode is requested at MCU level. When FRZ is asserted, FlexCAN is enabled to enter
Freeze Mode. Negation of this bit field causes FlexCAN to exit from Freeze Mode.
0 Not enabled to enter Freeze Mode
1 Enabled to enter Freeze Mode
2 FIFO Enable
FEN This bit controls whether the FIFO feature is enabled or not. When FEN is set, MBs 0 to 7 cannot be used
for normal reception and transmission because the corresponding memory region (0x80-0xFF) is used
by the FIFO engine. See Section 25.3.3, “Rx FIFO Structure”, and Section 25.4.7, “Rx FIFO”, for more
information.
0 FIFO not enabled
1 FIFO enabled
Field Description
3 Halt FlexCAN
HALT Assertion of this bit puts the FlexCAN module into Freeze Mode. The CPU should clear it after initializing
the Message Buffers and Control Register. No reception or transmission is performed by FlexCAN before
this bit is cleared. While in Freeze Mode, the CPU has write access to the Error Counter Register, that is
otherwise read-only. Freeze Mode can not be entered while FlexCAN is in any of the low power modes.
See Section 25.4.9.1, “Freeze Mode”, for more information.
0 No Freeze Mode request.
1 Enters Freeze Mode if the FRZ bit is asserted.
5 Reserved
6 Soft Reset
SOFT_RST When this bit is asserted, FlexCAN resets its internal state machines and some of the memory mapped
registers. The following registers are reset: FLEXCAN_x_MCR (except the MDIS bit),
FLEXCAN_x_TIMER, FLEXCAN_x_ECR, FLEXCAN_x_ESR, FLEXCAN_x_IMASK1,
FLEXCAN_x_IMASK2, FLEXCAN_x_IFLAG1, FLEXCAN_x_IFLAG2. Configuration registers that control
the interface to the CAN bus are not affected by soft reset. The following registers are unaffected:
• FLEXCAN_x_CTRL
• RXIMR0–RXIMR63
• FLEXCAN_x_RXGMASK, FLEXCAN_x_RX14MASK, FLEXCAN_x_RX15MASK
• all Message Buffers
The SOFT_RST bit can be asserted directly by the CPU when it writes to the FLEXCAN_x_MCR Register,
but it is also asserted when global soft reset is requested at MCU level. Since soft reset is synchronous
and has to follow a request/acknowledge procedure across clock domains, it may take some time to fully
propagate its effect. The SOFT_RST bit remains asserted while reset is pending, and is automatically
negated when reset completes. Therefore, software can poll this bit to know when the soft reset has
completed.
Soft reset cannot be applied while clocks are shut down in any of the low power modes. The module
should be first removed from low power mode, and then soft reset can be applied.
0 No reset request
1 Resets the registers marked as “affected by soft reset” in Table 25-2.
7 Freeze Mode Acknowledge
FRZ_ACK This read-only bit indicates that FlexCAN is in Freeze Mode and its prescaler is stopped. The Freeze
Mode request cannot be granted until current transmission or reception processes have finished.
Therefore the software can poll the FRZ_ACK bit to know when FlexCAN has actually entered Freeze
Mode. If Freeze Mode request is negated, then this bit is negated once the FlexCAN prescaler is running
again. If Freeze Mode is requested while FlexCAN is in any of the low power modes, then the FRZ_ACK
bit will only be set when the low power mode is exited. See Section 25.4.9.1, “Freeze Mode”, for more
information.
0 FlexCAN not in Freeze Mode, prescaler running
1 FlexCAN in Freeze Mode, prescaler stopped
Field Description
8 Supervisor Mode
SUPV Although the FlexCAN module provides a differentiation between Supervisor and User access types, all
accesses will be always considered of the Supervisor type. As a consequence, the SUPV bit in the
Module Configuration Register (FLEXCAN_x_MCR) has no effect on the module behavior.
.
1 Affected registers are in Supervisor memory space. Any access without supervisor permission
behaves as though the access was done to an unimplemented register location
9 Reserved
12 Reserved
0 FlexCAN is not enabled to enter low power mode when Doze Mode is requested
15 Message buffer filter enable. This bit provides the capability of enabling either individual masking of every
MBFEN message buffer, or global masking of message buffers.
This bit is provided to support backwards compatibility with previous FlexCAN versions. When this bit is
negated, the following configuration is applied:
• Individual Rx ID masking is disabled. Instead of individual ID masking per MB, FlexCAN uses its
previous masking scheme with FLEXCAN_x_RXGMASK, FLEXCAN_x_RX14MASK and
FLEXCAN_x_RX15MASK.
• The reception queue feature is disabled. Upon receiving a message, if the first MB with a matching ID
that is found is still occupied by a previous unread message, FlexCAN will not look for another matching
MB. It will override this MB with the new message and set the CODE field to ‘0110’ (overrun).
Upon reset this bit is negated, allowing legacy software to work without modification.
0 Individual Rx masking and queue feature are disabled.
1 Individual Rx masking and queue feature are enabled.
16–17 Reserved
Field Description
19 Abort Enable
AEN This bit is supplied for backwards compatibility reasons. When asserted, it enables the Tx abort feature.
This feature guarantees a safe procedure for aborting a pending transmission, so that no frame is sent in
the CAN bus without notification.
0 Abort disabled
1 Abort enabled
20–21 Reserved
24–25 Reserved
Note: MAXMB must be programmed with a value smaller or equal to the number of available Message
Buffers, otherwise FlexCAN can transmit and receive wrong messages.
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R
BOFF ERR_ CLK_
TWR RWR 0 0 BOFF
LPB N_MS N_MS SMP TSYN LBUF LOM PROPSEG
W _MSK MSK SRC _REC
K K
RE-
0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
SET:
= Unimplemented or Reserved
Figure 25-6. Control Register (FLEXCAN_x_CTRL)
Field Description
Field Description
17 Error Mask
ERR_MSK This bit provides a mask for the Error Interrupt.
0 Error interrupt disabled
1 Error interrupt enabled
18 CAN Engine Clock Source
CLK_SRC This bit selects the clock source to the CAN Protocol Interface (CPI) to be either the system clock (driven by the
PLL) or the crystal oscillator clock (direct feed from the oscillator pin EXTAL). The selected clock is the one fed to
the prescaler to generate the Serial Clock (Sclock). In order to guarantee reliable operation, this bit should only be
changed while the module is in Disable Mode. See Section 25.4.8.4, “Protocol Timing”, for more information.
0 The CAN engine clock source is the oscillator clock
1 The CAN engine clock source is the bus clock
19 Tx Warning Interrupt Mask
TWRN_MS This bit provides a mask for the Tx Warning Interrupt associated with the TWRN_INT flag in the Error and Status
K Register. This bit has no effect if the WRN_EN bit in FLEXCAN_x_MCR is negated and it is read as zero when
WRN_EN is negated.
0 Tx Warning Interrupt disabled
1 Tx Warning Interrupt enabled
20 Rx Warning Interrupt Mask
RWRN_MS This bit provides a mask for the Rx Warning Interrupt associated with the RWRN_INT flag in the Error and Status
K Register. This bit has no effect if the WRN_EN bit in FLEXCAN_x_MCR is negated and it is read as zero when
WRN_EN is negated.
0 Rx Warning Interrupt disabled
1 Rx Warning Interrupt enabled
21 Loop Back
LPB This bit configures FlexCAN to operate in Loop-Back Mode. In this mode, FlexCAN performs an internal loop back
that can be used for self test operation. The bit stream output of the transmitter is fed back internally to the receiver
input. The Rx CAN input pin is ignored and the Tx CAN output goes to the recessive state (logic ‘1’). FlexCAN
behaves as it normally does when transmitting, and treats its own transmitted message as a message received from
a remote node. In this mode, FlexCAN ignores the bit sent during the ACK slot in the CAN frame acknowledge field,
generating an internal acknowledge bit to ensure proper reception of its own message. Both transmit and receive
interrupts are generated.
0 Loop Back disabled
1 Loop Back enabled
22–23 Reserved
24 Sampling Mode
SMP This bit defines the sampling mode of CAN bits at the Rx input.
0 Just one sample is used to determine the bit value
1 Three samples are used to determine the value of the received bit: the regular one (sample point) and 2
preceding samples, a majority rule is used
Field Description
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R
TIMER
W
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
= Unimplemented or Reserved
Figure 25-7. Free Running Timer (FLEXCAN_x_TIMER)
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R
MI15 MI14 MI13 MI12 MI11 MI10 MI9 MI8 MI7 MI6 MI5 MI4 MI3 MI2 MI1 MI0
W
RESET: 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1
= Unimplemented or Reserved
Figure 25-8. Rx Global Mask Register (FLEXCAN_x_RXGMASK)
Field Description
a stream of less than 11 consecutive recessive bits, the internal counter resets itself to zero without
affecting the Tx_Err_Counter value.
• If during system start-up, only one node is operating, then its Tx_Err_Counter increases in each
message it is trying to transmit, as a result of acknowledge errors (indicated by the ACK_ERR bit
in the Error and Status Register). After the transition to ‘Error Passive’ state, the Tx_Err_Counter
does not increment anymore by acknowledge errors. Therefore the device never goes to the ‘Bus
Off’ state.
• If the Rx_Err_Counter increases to a value greater than 127, it is not incremented further, even if
more errors are detected while being a receiver. At the next successful message reception, the
counter is set to a value between 119 and 127 to resume to ‘Error Active’ state.
Base + 0x001C
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
W
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R
Rx_Err_Counter Tx_Err_Counter
W
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
= Unimplemented or Reserved
Figure 25-9. Error Counter Register (FLEXCAN_x_ECR)
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
BIT1_ BIT0_ ACK_ CRC_ FRM_ STF_ TX_W RX_
R IDLE TXRX FLT_CONF 0 BOFF ERR_ 0
ERR ERR ERR ERR ERR ERR RN WRN
_INT INT
W
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
= Unimplemented or Reserved
Figure 25-10. Error and Status Register
Field Description
0–13 Reserved
14 Tx Warning Interrupt Flag
TWRN_INT If the WRN_EN bit in FLEXCAN_x_MCR is asserted, the TWRN_INT bit is set when the TX_WRN flag transition
from ‘0’ to ‘1’, meaning that the Tx error counter reached 96. If the corresponding mask bit in the Control
Register (TWRN_MSK) is set, an interrupt is generated to the CPU. This bit is cleared by writing it to ‘1’. Writing
‘0’ has no effect.
0 No such occurrence
1 The Tx error counter transition from < 96 to 96
15 Rx Warning Interrupt Flag
RWRN_INT If the WRN_EN bit in FLEXCAN_x_MCR is asserted, the RWRN_INT bit is set when the RX_WRN flag
transition from ‘0’ to ‘1’, meaning that the Rx error counters reached 96. If the corresponding mask bit in the
Control Register (RWRN_MSK) is set, an interrupt is generated to the CPU. This bit is cleared by writing it to
‘1’. Writing ‘0’ has no effect.
0 No such occurrence
1 The Rx error counter transition from < 96 to 96
16 Bit1 Error
BIT1_ERR This bit indicates when an inconsistency occurs between the transmitted and the received bit in a message.
0 No such occurrence
1 At least one bit sent as recessive is received as dominant
Note: This bit is not set by a transmitter in case of arbitration field or ACK slot, or in case of a node sending a
passive error flag that detects dominant bits.
Field Description
17 Bit0 Error
BIT0_ERR This bit indicates when an inconsistency occurs between the transmitted and the received bit in a message.
0 No such occurrence
1 At least one bit sent as dominant is received as recessive
18 Acknowledge Error
ACK_ERR This bit indicates that an Acknowledge Error has been detected by the transmitter node, i.e., a dominant bit has
not been detected during the ACK SLOT.
0 No such occurrence
1 An ACK error occurred since last read of this register
19 Cyclic Redundancy Check Error
CRC_ERR This bit indicates that a CRC Error has been detected by the receiver node, i.e., the calculated CRC is different
from the received.
0 No such occurrence
1 A CRC error occurred since last read of this register.
20 Form Error
FRM_ERR This bit indicates that a Form Error has been detected by the receiver node, i.e., a fixed-form bit field contains
at least one illegal bit.
0 No such occurrence
1 A Form Error occurred since last read of this register
21 Stuffing Error
STF_ERR This bit indicates that a Stuffing Error has been detected.
0 No such occurrence.
1 A Stuffing Error occurred since last read of this register.
22 TX Error Counter
TX_WRN This bit indicates when repetitive errors are occurring during message transmission.
0 No such occurrence
1 TX_Err_Counter 96
23 Rx Error Counter
RX_WRN This bit indicates when repetitive errors are occurring during message reception.
0 No such occurrence
1 Rx_Err_Counter 96
24 CAN bus IDLE state
IDLE This bit indicates when CAN bus is in IDLE state.
0 No such occurrence
1 CAN bus is now IDLE
25 Current FlexCAN status (transmitting/receiving)
TXRX This bit indicates if FlexCAN is transmitting or receiving a message when the CAN bus is not in IDLE state. This
bit has no meaning when IDLE is asserted.
0 FlexCAN is receiving a message (IDLE=0)
1 FlexCAN is transmitting a message (IDLE=0)
26–27 Fault Confinement State
FLT_CONF This 2-bit field indicates the Confinement State of the FlexCAN module, as shown below. If the LOM bit in the
Control Register is asserted, the FLT_CONF field will indicate “Error Passive”. Since the Control Register is not
affected by soft reset, the FLT_CONF field will not be affected by soft reset if the LOM bit is asserted.
00 Error Active
01 Error Passive
1X Bus Off
Field Description
28 Reserved
29 ‘Bus Off’ Interrupt
BOFF_INT This bit is set when FlexCAN enters ‘Bus Off’ state. If the corresponding mask bit in the Control Register
(BOFF_MSK) is set, an interrupt is generated to the CPU. This bit is cleared by writing it to ‘1’. Writing ‘0’ has
no effect.
0 No such occurrence
1 FlexCAN module entered ‘Bus Off’ state
30 Error Interrupt
ERR_INT This bit indicates that at least one of the Error Bits (bits 16-21) is set. If the corresponding mask bit in the Control
Register (ERR_MSK) is set, an interrupt is generated to the CPU. This bit is cleared by writing it to ‘1’.Writing
‘0’ has no effect.
0 No such occurrence
1 Indicates setting of any Error Bit in the Error and Status Register
31 Reserved
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R BUF BUF BUF BUF BUF BUF BUF BUF BUF BUF BUF BUF BUF BUF BUF BUF
W 47M 46M 45M 44M 43M 42M 41M 40M 39M 38M 37M 36M 35M 34M 33M 32M
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 25-11. Interrupt Masks 2 Register (FLEXCAN_x_IMASK2)
Field Description
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R BUF BUF BUF BUF BUF BUF BUF BUF BUF BUF BUF BUF BUF BUF BUF BUF
W 15M 14M 13M 12M 11M 10M 9M 8M 7M 6M 5M 4M 3M 2M 1M 0M
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 25-12. Interrupt Masks 1 Register (FLEXCAN_x_IMASK1)
Field Description
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R BUF BUF BUF BUF BUF BUF BUF BUF BUF BUF BUF BUF BUF BUF BUF BUF
W 47I 46I 45I 44I 43I 42I 41I 40I 39I 38I 37I 36I 35I 34I 33I 32I
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 25-13. Interrupt Flags 2 Register (FLEXCAN_x_IFLAG2)
Field Description
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R BUF BUF BUF BUF BUF BUF BUF BUF BUF BUF BUF BUF BUF BUF BUF BUF
W 15I 14I 13I 12I 11I 10I 9I 8I 7I 6I 5I 4I 3I 2I 1I 0I
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 25-14. Interrupt Flags 1 Register (FLEXCAN_x_IFLAG1)
Field Description
Field Description
MI31 MI30 MI29 MI28 MI27 MI26 MI25 MI24 MI23 MI22 MI21 MI20 MI19 MI18 MI17 MI16
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
MI15 MI14 MI13 MI12 MI11 MI10 MI9 MI8 MI7 MI6 MI5 MI4 MI3 MI2 MI1 MI0
Field Description
25.4.1 Overview
The FlexCAN module is a CAN protocol engine with a very flexible mailbox system for transmitting and
receiving CAN frames. The mailbox system is composed by a set of 64 Message Buffers (MB) that store
configuration and control data, time stamp, message ID and data (see Section 25.3.2, “Message Buffer
Structure”). The memory corresponding to the first 8 MBs can be configured to support a FIFO reception
scheme with a powerful ID filtering mechanism, capable of checking incoming frames against a table of
IDs (up to 8 extended IDs or 16 standard IDs or 32 8-bit ID slices), each one with its own individual mask
register. Simultaneous reception through FIFO and mailbox is supported. For mailbox reception, a
matching algorithm makes it possible to store received frames only into MBs that have the same ID
programmed on its ID field. A masking scheme makes it possible to match the ID programmed on the MB
with a range of IDs on received CAN frames. For transmission, an arbitration algorithm decides the
prioritization of MBs to be transmitted based on the message ID (optionally augmented by 3 local priority
bits) or the MB ordering.
Before proceeding with the functional description, an important concept must be explained. A Message
Buffer is said to be “active” at a given time if it can participate in the matching and arbitration algorithms
that are happening at that time. An Rx MB with a ‘0000’ code is inactive (refer to Table 25-5). Similarly,
a Tx MB with a ‘1000’ or ‘1001’ code is also inactive (refer to Table 25-6). An MB not programmed with
‘0000’, ‘1000’ or ‘1001’ will be temporarily deactivated (will not participate in the current arbitration or
matching run) when the CPU writes to the C/S field of that MB (see Section 25.4.6.2, “Message Buffer
Deactivation”).
1. Actually, if LBUF is negated, the arbitration considers not only the ID, but also the RTR and IDE bits placed inside the ID
at the same positions they are transmitted in the CAN frame.
Once the MB is activated in the third step, it will be able to receive frames that match the programmed ID.
At the end of a successful reception, the MB is updated by the MBM as follows:
• The value of the Free Running Timer is written into the Time Stamp field
• The received ID, Data (8 bytes at most) and Length fields are stored
• The Code field in the Control and Status word is updated (see Table 25-5 and Table 25-6 in
Section 25.3.2, “Message Buffer Structure”)
• A status flag is set in the Interrupt Flag Register and an interrupt is generated if allowed by the
corresponding Interrupt Mask Register bit
Upon receiving the MB interrupt, the CPU should service the received frame using the following
procedure:
• Read the Control and Status word (mandatory – activates an internal lock for this buffer)
• Read the ID field (optional – needed only if a mask was used)
• Read the Data field
• Read the Free Running Timer (optional – releases the internal lock)
Upon reading the Control and Status word, if the BUSY bit is set in the Code field, then the CPU should
defer the access to the MB until this bit is negated. Reading the Free Running Timer is not mandatory. If
not executed the MB remains locked, unless the CPU reads the C/S word of another MB. Note that only a
single MB is locked at a time. The only mandatory CPU read operation is the one on the Control and Status
word to assure data coherency (see Section 25.4.6, “Data Coherence”).
The CPU should synchronize to frame reception by the status flag bit for the specific MB in one of the
IFLAG Registers and not by the Code field of that MB. Polling the Code field does not work because once
a frame was received and the CPU services the MB (by reading the C/S word followed by unlocking the
MB), the Code field will not return to EMPTY. It will remain FULL, as explained in Table 25-5. If the
CPU tries to workaround this behavior by writing to the C/S word to force an EMPTY code after reading
the MB, the MB is actually deactivated from any currently ongoing matching process. As a result, a newly
received frame matching the ID of that MB may be lost. In summary: never do polling by reading directly
the C/S word of the MBs. Instead, read the IFLAG registers.
Note that the received ID field is always stored in the matching MB, thus the contents of the ID field in an
MB may change if the match was due to masking. Note also that FlexCAN does receive frames transmitted
by itself if there exists an Rx matching MB, provided the SRX_DIS bit in the FLEXCAN_x_MCR is not
asserted. If SRX_DIS is asserted, FlexCAN will not store frames transmitted by itself in any MB, even if
it contains a matching MB, and no interrupt flag or interrupt signal will be generated due to the frame
reception.
To be able to receive CAN frames through the FIFO, the CPU must enable and configure the FIFO during
Freeze Mode (see Section 25.4.7, “Rx FIFO”). Upon receiving the frames available interrupt from FIFO,
the CPU should service the received frame using the following procedure:
• Read the Control and Status word (optional – needed only if a mask was used for IDE and RTR
bits)
The matching algorithm described above can be changed to be the same one used in previous versions of
the FlexCAN module. When the MBFEN bit in FLEXCAN_x_MCR is negated, the matching algorithm
stops at the first MB with a matching ID that it founds, whether this MB is free or not. As a result, the
message queueing feature does not work if the MBFEN bit is negated.
Matching to a range of IDs is possible by using ID Acceptance Masks. FlexCAN supports individual
masking per MB. Please refer to Section 25.3.4.13, “Rx Individual Mask Registers
(RXIMR0–RXIMR63)”.” During the matching algorithm, if a mask bit is asserted, then the corresponding
ID bit is compared. If the mask bit is negated, the corresponding ID bit is “don’t care”. Please note that the
Individual Mask Registers are implemented in RAM, so they are not initialized out of reset. Also, they can
only be programmed if the MBFEN bit is asserted and while the module is in Freeze Mode.
FlexCAN also supports an alternate masking scheme with only three mask registers (RGXMASK,
FLEXCAN_x_RX14MASK and FLEXCAN_x_RX15MASK) for backwards compatibility. This
alternate masking scheme is enabled when the MBFEN bit in the FLEXCAN_x_MCR Register is negated.
If the CPU writes the abort code before the transmission begins internally, then the write operation is not
blocked, therefore the MB is updated and no interrupt flag is set. In this way the CPU just needs to read
the abort code to make sure the active MB was deactivated. Although the AEN bit is asserted and the CPU
wrote the abort code, in this case the MB is deactivated and not aborted, because the transmission did not
start yet. One MB is only aborted when the abort request is captured and kept pending until one of the
previous conditions are satisfied.
The abort procedure can be summarized as follows:
• CPU writes 1001 into the code field of the C/S word
• CPU reads the CODE field and compares it to the value that was written
• If the CODE field that was read is different from the value that was written, the CPU must read the
corresponding IFLAG to check if the frame was transmitted or it is being currently transmitted. If
the corresponding IFLAG is set, the frame was transmitted. If the corresponding IFLAG is reset,
the CPU must wait for it to be set, and then the CPU must read the CODE field to check if the MB
was aborted (CODE=1001) or it was transmitted (CODE=1000).
NOTE
An abort request to a TxMB can block any write operation into its CODE
field. Therefore, the TxMB cannot be aborted or deactivated until it
completes a transmission by winning the CAN bus arbitration.
an MB with ID that may not be the lowest at the time because a lower ID might be present in one
of the MBs that it had already scanned before the deactivation.
• There is a point in time until which the deactivation of a Tx MB causes it not to be transmitted (end
of move-out). After this point, it is transmitted but no interrupt is issued and the Code field is not
updated. In order to avoid this situation, the abort procedures described in Section 25.4.6.1,
“Transmission Abort Mechanism”, should be used.
1. In previous FlexCAN versions, reading the C/S word locked the MB even if it was EMPTY. This behavior will be honoured
when the MBFEN bit is negated.
25.4.7 Rx FIFO
The receive-only FIFO is enabled by asserting the FEN bit in the FLEXCAN_x_MCR. The reset value of
this bit is zero to maintain software backwards compatibility with previous versions of the module that did
not have the FIFO feature. When the FIFO is enabled, the memory region normally occupied by the first
8 MBs (0x80-0xFF) is now reserved for use of the FIFO engine (see Section 25.3.3, “Rx FIFO Structure”).
Management of read and write pointers is done internally by the FIFO engine. The CPU can read the
received frames sequentially, in the order they were received, by repeatedly accessing a Message Buffer
structure at the beginning of the memory.
The FIFO can store up to 6 frames pending service by the CPU. An interrupt is sent to the CPU when new
frames are available in the FIFO. Upon receiving the interrupt, the CPU must read the frame (accessing an
MB in the 0x80 address) and then clear the interrupt. The act of clearing the interrupt triggers the FIFO
engine to replace the MB in 0x80 with the next frame in the queue, and then issue another interrupt to the
CPU. If the FIFO is full and more frames continue to be received, an OVERFLOW interrupt is issued to
the CPU and subsequent frames are not accepted until the CPU creates space in the FIFO by reading one
or more frames. A warning interrupt is also generated when 5 frames are accumulated in the FIFO.
A powerful filtering scheme is provided to accept only frames intended for the target application, thus
reducing the interrupt servicing work load. The filtering criteria is specified by programming a table of 8
32-bit registers that can be configured to one of the following formats (see also Section 25.3.3, “Rx FIFO
Structure”):
• Format A: 8 extended or standard IDs (including IDE and RTR)
• Format B: 16 standard IDs or 16 extended 14-bit ID slices (including IDE and RTR)
• Format C: 32 standard or extended 8-bit ID slices
NOTE
A chosen format is applied to all 8 registers of the filter table. It is not
possible to mix formats within the table.
The eight elements of the filter table are individually affected by the first eight Individual Mask Registers
(RXIMR0 - RXIMR7), allowing very powerful filtering criteria to be defined. The rest of the RXIMR,
starting from RXIM8, continue to affect the regular MBs, starting from MB8. If the MBFEN bit is negated
(or if the RXIMR are not available for the particular MCU), then the FIFO filter table is affected by the
legacy mask registers as follows: element 6 is affected by FLEXCAN_x_RX14MASK, element 7 is
affected by FLEXCAN_x_RX15MASK and the other elements (0 to 5) are affected by
FLEXCAN_x_RXGMASK.
25.4.7.1 Precautions when using Global Mask and Individual Mask registers
Mask filtering alignment is affected based on the setting of the FEN and MBFEN of MCR. Table 25-18
table shows recommended actions depending on FEN and MBFEN settings.
MCR[FEN] MCR[MBFEN]
Case Notes
RxFIFO Rx Individual Mask
Case 1 FEN = 0 MBFEN = 0 RXGMASK, RX14MASK, and RX15MASK can safely be used.
This allows backwards compatibility to older devices (e.g.,
devices without the individual masks feature). In this case,
individual masks are not used.
Case 2 FEN = 1 MBFEN = 0 1st alternative:
Do not use RXGMASK, RX14MASK, and RX15MASK in this
case, leave the masks in their reset state.
Case 3 FEN = 1 MBFEN = 0 2nd alternative:
Do not configure any MB as Rx (i.e., let all MBs as either Tx or
inactive).
In this case, RXGMASK, RX14MASK, and RX15MASK can be
used to affect ID Tables without affecting the filtering process
for Rx MBs.
Case 4 Don’t care MBFEN = 1 If MCR[MBFEN] = 1, then the RXIMRs are enabled. Thus,
RXGMASK, RX14MASK, and RX15MASK are not used.
Particularly, when MCR[FEN] = 0, RxFIFO is disabled;
RXGMASK, RX14MASK, and RX15MASK do not affect
filtering. Individual masks are used.
• Detection of a dominant bit at the 7th bit (last) of End of Frame field (Rx frames)
• Detection of a dominant bit at the 8th bit (last) of Error Frame Delimiter or Overload Frame
Delimiter
The crystal oscillator clock should be selected whenever a tight tolerance (up to 0.1%) is required in the
CAN bus timing. The crystal oscillator clock has better jitter performance than PLL generated clocks.
The FlexCAN module supports a variety of means to setup bit timing parameters that are required by the
CAN protocol. The Control Register has various fields used to control bit timing parameters: PRESDIV,
PROPSEG, PSEG1, PSEG2 and RJW. See Section 25.3.4.2, “Control Register (FLEXCAN_x_CTRL)”.”
The PRESDIV field controls a prescaler that generates the Serial Clock (Sclock), whose period defines the
‘time quantum’ used to compose the CAN waveform. A time quantum is the atomic unit of time handled
by the CAN engine.
f CANCLK
f Tq = -------------------------------------------------------
Prescaler Þ V alue
A bit time is subdivided into three segments1 (reference Figure 25-17 and Table 25-19):
• SYNC_SEG: This segment has a fixed length of one time quantum. Signal edges are expected to
happen within this section
• Time Segment 1: This segment includes the Propagation Segment and the Phase Segment 1 of the
CAN standard. It can be programmed by setting the PROPSEG and the PSEG1 fields of the
FLEXCAN_x_CTRL Register so that their sum (plus 2) is in the range of 4 to 16 time quanta
• Time Segment 2: This segment represents the Phase Segment 2 of the CAN standard. It can be
programmed by setting the PSEG2 field of the FLEXCAN_x_CTRL Register (plus 1) to be 2 to 8
time quanta long
f Tq
Bit Þ Rate = ----------------------------------------------------------------------------------------
-
number Þ of Þ Time Þ Quanta
NRZ Signal
1 4 ... 16 2 ... 8
Syntax Description
SYNC_SEG System expects transitions to occur on the bus during this period.
Transmit Point A node in transmit mode transfers a new value to the CAN bus at this point.
Sample Point A node samples the bus at this point. If the three samples per bit option is
selected, then this point marks the position of the third sample.
Table 25-20 gives an overview of the CAN compliant segment settings and the related parameter values.
1. For further explanation of the underlying concepts please refer to ISO/DIS 11519–1, Section 10.3. Reference also the
Bosch CAN 2.0A/B protocol specification dated September 1991 for bit timing.
Re-synchronization
Time Segment 1 Time Segment 2
Jump Width
5 .. 10 2 1 .. 2
4 .. 11 3 1 .. 3
5 .. 12 4 1 .. 4
6 .. 13 5 1 .. 4
7 .. 14 6 1 .. 4
8 .. 15 7 1 .. 4
9 .. 16 8 1 .. 4
NOTE
It is the user’s responsibility to ensure the bit time settings are in compliance
with the CAN standard. For bit time calculations, use an IPT (Information
Processing Time) of 2, which is the value implemented in the FlexCAN
module.
Start Move
(bit 6)
Move
Matching/Arbitration Window (24 bits) Window
When doing matching and arbitration, FlexCAN needs to scan the whole Message Buffer memory during
the available time slot. In order to have sufficient time to do that, the following requirements must be
observed:
• A valid CAN bit timing must be programmed, as indicated in Table 25-20.
• The peripheral clock frequency can not be smaller than the oscillator clock frequency, i.e. the PLL
can not be programmed to divide down the oscillator clock.
• There must be a minimum ratio between the peripheral clock frequency and the CAN bit rate, as
specified in Table 25-21.
Table 25-21. Minimum Ratio Between Peripheral Clock Frequency and CAN Bit Rate
Number of Message
Minimum Ratio
Buffers
16 8
32 8
64 16
A direct consequence of the first requirement is that the minimum number of time quanta per CAN bit must
be 8, so the oscillator clock frequency should be at least 8 times the CAN bit rate. The minimum frequency
ratio specified in Table 25-21 can be achieved by choosing a high enough peripheral clock frequency when
compared to the oscillator clock frequency, or by adjusting one or more of the bit timing parameters
(PRESDIV, PROPSEG, PSEG1, PSEG2). As an example, taking the case of 64 MBs, if the oscillator and
peripheral clock frequencies are equal and the CAN bit timing is programmed to have 8 time quanta per
bit, then the prescaler factor (PRESDIV + 1) should be at least 2. For prescaler factor equal to one and
CAN bit timing with 8 time quanta per bit, the ratio between peripheral and oscillator clock frequencies
should be at least 2.
25.4.10 Interrupts
The module can generate up to 69 interrupt sources (64 interrupts due to message buffers and 5 interrupts
due to ORed interrupts from MBs, Bus Off, Error, Tx Warning, and Rx Warning). The number of actual
sources depends on the configured number of Message Buffers.
Each one of the message buffers can be an interrupt source, if its corresponding IMASK bit is set. There
is no distinction between Tx and Rx interrupts for a particular buffer, under the assumption that the buffer
is initialized for either transmission or reception. Each of the buffers has assigned a flag bit in the IFLAG
Registers. The bit is set when the corresponding buffer completes a successful transmission/reception and
is cleared when the CPU writes it to ‘1’ (unless another interrupt is generated at the same time).
NOTE
It must be guaranteed that the CPU only clears the bit causing the current
interrupt. For this reason, bit manipulation instructions (BSET) must not be
used to clear interrupt flags. These instructions may cause accidental
clearing of interrupt flags which are set after entering the current interrupt
service routine.
If the Rx FIFO is enabled (bit FEN on FLEXCAN_x_MCR set), the interrupts corresponding to MBs 0 to
7 have a different behavior. Bit 7 of the FLEXCAN_x_IFLAG1 becomes the “FIFO Overflow” flag; bit 6
becomes the FIFO Warning flag, bit 5 becomes the “Frames Available in FIFO flag” and bits 4-0 are
unused. See Section 25.3.4.12, “Interrupt Flags 1 Register (FLEXCAN_x_IFLAG1)”, for more
information.
A combined interrupt for all MBs is also generated by an Or of all the interrupt sources from MBs. This
interrupt gets generated when any of the MBs generates an interrupt. In this case the CPU must read the
IFLAG Registers to determine which MB caused the interrupt.
The other 4 interrupt sources (Bus Off, Error, Tx Warning, and Rx Warning) generate interrupts like the
MB ones, and can be read from the Error and Status Register. The Bus Off, Error, Tx Warning and Rx
Warning interrupt mask bits are located in the Control Register.
26.1 Introduction
26.1.1 Reference
The following documents are referenced.
• FlexRay Communications System Protocol Specification, Version 2.1 Rev A1
• FlexRay Communications System Electrical Physical Layer Specification, Version 2.1 Rev A
26.1.2 Glossary
This section provides a list of terms used in this chapter.
Table 26-1. List of Terms
Term Definition
BCU Buffer Control Unit. Handles message buffer access.
BMIF Bus Master Interface. Provides master access to FlexRay memory area.
CC Communication Controller
CDC Clock Domain Crosser
CHI Controller Host Interface
Cycle length in T The actual length of a cycle in T for the ideal controller (±0 ppm)
EBI External Bus Interface
FlexRay Memory Area Memory area to store the physical message buffer payload data, frame header, frame and
slot status, and synchronization frame related tables.
System Memory Memory that is contains the FlexRay Memory Area.
System Bus Bus that connects the controller and System Memory
FSS Frame Start Sequence
HIF Host Interface. Provides host access to controller.
Host The FlexRay CC host MCU
LUT Look Up Table. Stores message buffer header index value.
LRAM Look Up Table RAM. Module internal memory to store message buffer configuration data
and data field offsets for individual message buffers and receive shadow buffers.
MB Message Buffer
1. The FlexRay Specifications have been developed for automotive applications.The FlexRay Specifications have been neither
developed nor tested for non-automotive applications.
Term Definition
MBIDX Message Buffer Index: the position of a header field entry within the header area. If the
header area is accessed as an array, this is the same as the array index of the entry.
MBNum Message Buffer Number: Position of message buffer configuration registers within the
register map. For example, Message Buffer Number 5 corresponds to the MBCCS5
register.
MCU Microcontroller Unit
T Microtick
MT Macrotick
MTS Media Access Test Symbol
NIT Network Idle Time
PE Protocol Engine
POC Protocol Operation Control. Each state of the POC is denoted by POC:state
Rx Reception
SEQ Sequencer Engine
TCU Time Control Unit
Tx Transmission
sync frame null frame or message frame with Sync Frame Indicator set to 1
startup frame null frame or message frame with both Sync Frame Indicator and Startup Frame Indicator
set to 1
normal frame null frame or message frame with both Sync Frame Indicator and Startup Frame Indicator
set to 0
null frame frame with Null Frame Indicator set to 0
message frame frame with Null Frame Indicator set to 1
26.1.4 Overview
The CC is a FlexRay communication controller that implements the FlexRay Communications System
Protocol Specification, Version 2.1 Rev A.
The CC has three main components:
• Controller host interface (CHI)
• Protocol engine (PE)
• Clock domain crossing unit (CDC)
A block diagram of the CC with its surrounding modules is given in Figure 26-1.
FLEXRAY
FR_A_RX
Peripheral CHI PE
Bridge B FR_A_TX
config
HIF SEQ FR_A_TX_EN
The protocol engine has two transmitter units TxA and TxB and two receiver units RxA and RxB for
sending and receiving frames through the two FlexRay channels. The time control unit (TCU) is
responsible for maintaining global clock synchronization to the FlexRay network. The overall activity of
the PE is controlled by the sequencer engine (SEQ).
The controller host interface provides host access to the module’s configuration, control, and status
registers, as well as to the message buffer configuration, control, and status registers. The message buffers
themselves, which contain the frame header and payload data received or to be transmitted, and the slot
status information, are stored in the flexray memory area.
The clock domain crossing unit implements signal crossing from the CHI clock domain to the PE clock
domain and vice versa, to allow for asynchronous PE and CHI clock domains.
The CC stores the frame header and payload data of frames received or of frames to be transmitted in the
flexray memory area. The application accesses the flexray memory area to retrieve and provide the frames
to be processed by the CC. In addition to the frame header and payload data, the CC stores the
synchronization frame related tables in the flexray memory area for application processing.
The flexray memory area is located in the system memory of the MCU. The CC has access to the flexray
memory area via its bus master interface (BMIF). The host provides the start address of the flexray
memory area within the system memory by programming the System Memory Base Address Register
(FR_SYMBADR). All flexray memory area related offsets are stored in offset registers. The physical
address pointer into the flexray memory area is calculated using the offset values the flexray memory base
address.
NOTE
The CC does not provide a memory protection scheme for the flexray
memory area.
26.1.5 Features
The CC provides the following features:
• FlexRay Communications System Protocol Specification, Version 2.1 Rev A compliant protocol
implementation
• FlexRay Communications System Electrical Physical Layer Specification, Version 2.1 Rev A
compliant bus driver interface
• single channel support
— FlexRay Port A can be configured to be connected either to physical FlexRay channel A or
physical FlexRay channel B.
• FlexRay bus data rates of 10 Mbit/s, 8 Mbit/s, 5 Mbit/s, and 2.5 Mbit/s supported
• 128 configurable message buffers with
— individual frame ID filtering
— individual channel ID filtering
— individual cycle counter filtering
• message buffer header, status and payload data stored in dedicated flexray memory area
— allows for flexible and efficient message buffer implementation
— consistent data access ensured by means of buffer locking scheme
— application can lock multiple buffers at the same time
• size of message buffer payload data section configurable from 0 up to 254 bytes
• two independent message buffer segments with configurable size of payload data section
— each segment can contain message buffers assigned to the static segment and message buffers
assigned to the dynamic segment at the same time
• zero padding for transmit message buffers in static segment
— applied when the frame payload length exceeds the size of the message buffer data section
• transmit message buffers configurable with state/event semantics
• message buffers can be configured as
— receive message buffer
— transmit message buffer
• individual message buffer reconfiguration supported
— means provided to safely disable individual message buffers
— disabled message buffers can be reconfigured
• two independent receive FIFOs
— one receive FIFO per channel
— up to 255 entries for each FIFO
— global frame ID filtering, based on both value/mask filters and range filters
— global channel ID filtering
— global message ID filtering for the dynamic segment
• 4 configurable slot error counters
• 4 dedicated slot status indicators
— used to observe slots without using receive message buffers
• measured value indicators for the clock synchronization
— internal synchronization frame ID and synchronization frame measurement tables can be
copied into the flexray memory area
• fractional macroticks are supported for clock correction
• maskable interrupt sources provided via individual and combined interrupt lines
• 1 absolute timer
• 1 timer that can be configured to absolute or relative
• SECDED for protocol engine data ram
• SEDDED for chi lookup table ram
Convention Description
Depending on its placement in the read or write row, indicates that the bit is not readable or not writeable.
R* Reserved bit or field, will not be changed. Application must not write any value different from the reset value.
FIELDNAME Identifies the field. Its presence in the read or write row indicates that it can be read or written.
rwm A read/write bit that may be modified by a hardware in some fashion other than by a reset.
w1c Write one to clear. A flag bit that can be read, is cleared by writing a one, writing 0 has no effect.
Reset Value
0 Resets to zero.
1 Resets to one.
Condition Description
Protocol RUN Command The register field is reset when the application writes to RUN command “0101” to the
POCCMD field in the Protocol Operation Control Register (FR_POCR).
Message Buffer Disable The register field is reset when the application has disabled the message buffer.
This happens when the application writes 1 to the message buffer disable trigger bit
FR_MBCCSRn[EDT] while the message buffer is enabled (FR_MBCCSRn[EDS] = 1) and
the CC grants the disable to the application by clearing the FR_MBCCSRn[EDS] bit.
fulfilled.The condition term [A and B] indicates that the register or field can be written to if both conditions
are fulfilled.
Table 26-6. Register Write Access Restrictions
Base + 0x0000
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R CHIVER PEVER
Reset 1 0 1 0 0 1 0 0 0 1 1 0 1 0 0 0
This register provides the CC version number. The module version number is derived from the CHI version
number and the PE version number.
Table 26-7. FR_MVR Field Descriptions
Field Description
CHIVER CHI Version Number — This field provides the version number of the controller host interface.
PEVER PE Version Number — This field provides the version number of the protocol engine.
Base + 0x0002 Write: MEN, SBFF, SCM, CHB, CHA, ECCE, FUM, FAM, CLKSEL, BITRATE: Disabled Mode
SFFE: Disabled Mode or POC:config
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 CLK 0
MEN SBFF SCM CHB CHA SFFE ECCE R* FUM FAM BITRATE
W SEL
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Field Description
MEN Module Enable — This bit indicates whether or not the CC is in the Disabled Mode. The application requests
the CC to leave the Disabled Mode by writing 1 to this bit Before leaving the Disabled Mode, the application must
configure the SCM, SBFF, CHB, CHA, TMODE, BITRATE values. For details see Section 26.1.6, “Modes of
Operation”.
0 Write: ignored, CC disable not possible
Read: CC disabled
1 Write: enable CC
Read: CC enabled
Note: If the CC is enabled it cannot be disabled.
SBFF System Bus Failure Freeze — This bit controls the behavior of the CC in case of a system bus failure.
0 Continue normal operation
1 Transition to freeze mode
SCM Single Channel Device Mode — This control bit defines the channel device mode of the CC as described in
Section 26.6.10, “Channel Device Modes”.
0 CC works in dual channel device mode
1 CC works in single channel device mode
SFFE Synchronization Frame Filter Enable — This bit controls the filtering for received synchronization frames. For
details see Section 26.6.15, “Sync Frame Filtering”.
0 Synchronization frame filtering disabled
1 Synchronization frame filtering enabled
Field Description
ECCE ECC Functionality Enable — This bit controls the ecc memory error detection functionality. For details see
Section 26.6.24, “Memory Content Error Detection”.
0 ECC functionality (injection, detection, reporting, response) disabled
1 ECC functionality enabled
FUM FIFO Update Mode — This bit controls the FIFO update behavior when the interrupt flags FR_GIFER[FAFAIF]
and FR_GIFER[FAFBIF] are written by the application (see Section 26.6.9.8, “FIFO Update”)
0 FIFOA/FIFOB is updated on writing 1 to FR_GIFER[FAFAIF] /FR_GIFER[FAFBIF]
1 FIFOA/FIFOB) is not updated on writing 1 to FR_GIFER[FAFAIF]/FR_GIFER[FAFBIF]
FAM FIFO Address Mode — This bit controls the location of the system memory base address for the FIFOs. (see
Section 26.6.9.2, “FIFO Configuration”)
0 FIFO Base Address located in System Memory Base Address Register (FR_SYMBADR)
1 FIFO Base Address located in Receive FIFO System Memory Base Address Register (FR_RFSYMBADR)
CLKSEL Protocol Engine Clock Source Select — This bit is used to select the clock source for the protocol engine.
0 PE clock source is generated by on-chip crystal oscillator.
1 PE clock source is generated by on-chip PLL.
BITRATE FlexRay Bus Bit Rate — This bit field defines the FlexRay Bus Bit Rate.
000 10.0 Mbit/sec
001 5.0 Mbit/sec
010 2.5 Mbit/sec
011 8.0 Mbit/sec
100 reserved
101 reserved
110 reserved
111 reserved
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R
SMBA[31:16]
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 0 0
SMBA[15:4]
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
NOTE
The system memory base address must be set before the CC is enabled.
The system memory base address registers define the base address of the flexray memory area within the
system memory. The base address is used by the BMIF to calculate the physical memory address for
system memory accesses.
Table 26-10. FR_SYMBADR Field Descriptions
Field Description
SMBA System Memory Base Address — This is the value of the system memory base address for the individual
message buffers and sync frame table. This is the value of the system memory base address for the receive
FIFO if the FIFO address mode bit FR_MCR[FAM] is set to 1. It is defines as a byte address.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 0 0 0 0 0 0 0
SEL ENB STBPSEL
W WMD
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
This register is used to assign the individual protocol timing related strobe signals given in Table 26-12 to
the external strobe ports. Each strobe signal can be assigned to at most one strobe port. Each write access
to registers overwrites the previously written ENB and STBPSEL values for the signal indicated by SEL.
If more than one strobe signal is assigned to one strobe port, the current values of the strobe signals are
combined with a binary OR and presented at the strobe port. If no strobe signal is assigned to a strobe port,
the strobe port carries logic 0. For more detailed and timing information refer to Section 26.6.16, “Strobe
Signal Support”.
NOTE
In single channel device mode, channel B related strobe signals are
undefined and should not be assigned to the strobe ports.
Table 26-11. FR_STBSCR Field Descriptions
Field Description
WMD Write Mode — This control bit defines the write mode of this register.
0 Write to all fields in this register on write access.
1 Write to SEL field only on write access.
SEL Strobe Signal Select — This control field selects one of the strobe signals given in Table 26-12 to be enabled
or disabled and assigned to one of the four strobe ports given in Table 26-12.
ENB Strobe Signal Enable — The control bit is used to enable and to disable the strobe signal selected by
STBSSEL.
0 Strobe signal is disabled and not assigned to any strobe port.
1 Strobe signal is enabled and assigned to the strobe port selected by STBPSEL.
STBPSEL Strobe Port Select — This field selects the strobe port that the strobe signal selected by the SEL is assigned
to. All strobe signals that are enabled and assigned to the same strobe port are combined with a binary OR
operation.
00 assign selected signal to FR_DBG[0]
01 assign selected signal to FR_DBG[1]
10 assign selected signal to FR_DBG[2]
11 assign selected signal to FR_DBG[3]
.;
SEL
Description Channel Type Offset1 Reference
dec hex
0 0x0 arm - value +1 MT start
1 0x1 mt - value +1 MT start
2 0x2 cycle start - pulse 0 MT start
3 0x3 minislot start - pulse 0 MT start
4 0x4 slot start A pulse 0 MT start
5 0x5 B
6 0x6 receive data after glitch filtering A value +4 FR_A_RX
7 0x7 B FR_B_RX
8 0x8 channel idle indicator A level +5 FR_A_RX
9 0x9 B FR_B_RX
10 0xA syntax error detected A pulse +4 FR_A_RX
11 0xB B FR_B_RX
12 0xC content error detected A level +4 FR_A_RX
13 0xD B FR_B_RX
SEL
Description Channel Type Offset1 Reference
dec hex
14 0xE receive FIFO almost-full interrupt signals A value n.a. RX FIFO A
Almost Full
Interrupt
15 0xF RX FIFO B
B Almost Full
Interrupt
1
Given in PE clock cycles
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0
MBSEG2DS MBSEG1DS
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
This register defines the size of the message buffer data section for the two message buffer segments in a
number of two-byte entities.
The CC provides two independent segments for the individual message buffers. All individual message
buffers within one segment have to have the same size for the message buffer data section. This size can
be different for the two message buffer segments.
Table 26-13. FR_MBDSR Field Descriptions
Field Description
MBSEG2DS Message Buffer Segment 2 Data Size — The field defines the size of the message buffer data section in
two-byte entities for message buffers within the second message buffer segment.
MBSEG1DS Message Buffer Segment 1 Data Size — The field defines the size of the message buffer data section in
two-byte entities for message buffers within the first message buffer segment.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0
LAST_MB_SEG1 LAST_MB_UTIL
W
Reset 0 1 1 1 1 1 1 1 0 1 1 1 1 1 1 1
Figure 26-8. Message Buffer Segment Size and Utilization Register (FR_MBSSUTR)
This register is used to define the last individual message buffer that belongs to the first message buffer
segment and the number of the last used individual message buffer.
Table 26-14. FR_MBSSUTR Field Descriptions
Field Description
LAST_MB_SEG1 Last Message Buffer In Segment 1 — This field defines the message buffer number of the last individual
message buffer that is assigned to the first message buffer segment. The individual message buffers in the
first segment correspond to the message buffer control registers FR_MBCCSRn, FR_MBCCFRn,
FR_MBFIDRn, FR_MBIDXRn with n <= LAST_MB_SEG1. The first message buffer segment contains
LAST_MB_SEG1+1 individual message buffers.
Note: The first message buffer segment contains at least one individual message buffer.
The individual message buffers in the second message buffer segment correspond to the message buffer
control registers FR_MBCCSRn, FR_MBCCFRn, FR_MBFIDRn, FR_MBIDXRn with LAST_MB_SEG1 < n
< 128.
Note: If LAST_MB_SEG1 = 127 all individual message buffers belong to the first message buffer segment
and the second message buffer segment is empty.
LAST_MB_UTIL Last Message Buffer Utilized — This field defines the message buffer number of last utilized individual
message buffer. The message buffer search engine examines all individual message buffer with a message
buffer number n <= LAST_MB_UTIL.
Note: If LAST_MB_UTIL=LAST_MB_SEG1 all individual message buffers belong to the first message
buffer segment and the second message buffer segment is empty.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R DAD
INST ADDR
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
This register is used to trigger write and read operations on the PE data memory (PE DRAM). These
operations are used for memory error injection and memory error observation.
Each write access to this registers initiates a read or write operation on the PE DRAM. The access done
status bit DAD is cleared after the write access and is set if the PE DRAM access has been finished.
In case of an PE DRAM write access, the data provided in PE DRAM Data Register (FR_PEDRDR) are
written into the PE DRAM, read back from the PE DRAM and are stored into the PE DRAM Data Register
(FR_PEDRDR).
In case of an PE DRAM read access, the requested data are read from PE DRAM and stored into the PE
DRAM Data Register (FR_PEDRDR).
For a detailed description refer to Section 26.6.24, “Memory Content Error Detection”
Field Description
INST PE DRAM Access Instruction — This field defines the operation to be executed on the PE DRAM.
0011 PE DRAM write: Write FR_PEDRDR[DATA] to PE DRAM address ADDR (16 bit)
0101 PE DRAM read: Read Data from PE DRAM address ADDR (16 bit) into FR_PEDRDR[DATA]
other reserved
ADDR PE DRAM Access Address — This field defines the address in the PE DRAM to be written to or read from.
DAD PE DRAM Access Done — This status bit is cleared when the application has written to this register and is
set when the PE DRAM access has finished.
0 PE DRAM access running
1 PE DRAM access done
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R
DATA
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
This register provides the data to be written to or read from the PE DRAM by the access initiated by write
access to the PE DRAM Access Register (FR_PEDRAR).
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 0 0 BSY 0 0 0
EOC_AP ERC_AP POCCMD
W WME WMC
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
External clock correction commands are issued by writing to the EOC_AP and ERC_AP fields. For more
information on external clock correction, refer to Section 26.6.11, “External Clock Synchronization”.
Table 26-16. FR_POCR Field Descriptions
Field Description
WME Write Mode External Correction — This bit controls the write mode of the EOC_AP and ERC_AP fields.
0 Write to EOC_AP and ERC_AP fields on register write.
1 No write to EOC_AP and ERC_AP fields on register write.
EOC_AP External Offset Correction Application — This field is used to trigger the application of the external offset
correction value defined in the Protocol Configuration Register 29 (FR_PCR29).
00 do not apply external offset correction value
01 reserved
10 subtract external offset correction value
11 add external offset correction value
ERC_AP External Rate Correction Application — This field is used to trigger application of the external rate correction
value defined in the Protocol Configuration Register 21 (FR_PCR21)
00 do not apply external rate correction value
01 reserved
10 subtract external rate correction value
11 add external rate correction value
BSY Protocol Control Command Write Busy — This status bit indicates the acceptance of the protocol control
command issued by the application via the POCCMD field. The CC sets this status bit when the application has
issued a protocol control command via the POCCMD field. The CC clears this status bit when protocol control
command was accepted by the PE.When the application issues a protocol control command while the BSY bit
is asserted, the CC ignores this command, sets the protocol command ignored error flag PCMI_EF in the CHI
Error Flag Register (FR_CHIERFR), and will not change the value of the POCCMD field.
0 Command write idle, command accepted and ready to receive new protocol command.
1 Command write busy, command not yet accepted, not ready to receive new protocol command.
Write Mode Command — This bit controls the write mode of the POCCMD field.
WMC
0 Write to POCCMD field on register write.
1 Do not write to POCCMD field on register write.
POCCMD Protocol Control Command — The application writes to this field to issue a protocol control command to the
PE. The CC sends the protocol command to the PE immediately. While the transfer is running, the BSY bit is set.
0000 ALLOW_COLDSTART — Immediately activate capability of node to cold start cluster.
0001 ALL_SLOTS — Delayed1 transition to the all slots transmission mode.
0010 CONFIG — Immediately transition to the POC:config state.
0011 FREEZE — Immediately transition to the POC:halt state.
0100 READY, CONFIG_COMPLETE — Immediately transition to the POC:ready state.
0101 RUN — Immediately transition to the POC:startup start state.
0110 DEFAULT_CONFIG — Immediately transition to the POC:default config state.
0111 HALT — Delayed transition to the POC:halt state
1000 WAKEUP — Immediately initiate the wakeup procedure.
1001 reserved
1010 reserved
1011 reserved
1100 reserved
1101 reserved
1110 reserved
1111 reserved
1 Delayed means on completion of current communication cycle.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
This register provides the means to control some of the interrupt request lines and provides the
corresponding interrupt flags. The interrupt flags MIF, PRIF, CHIF, RBIF, and TBIF are the outcome of a
binary OR of the related individual interrupt flags and interrupt enables. The generation scheme for these
flags is depicted in Figure 26-157. For more details on interrupt generation, see Section 26.6.20, “Interrupt
Support. These flags are cleared automatically when all of the corresponding interrupt flags or interrupt
enables in the related interrupt flag and enable registers are cleared by the application.
Table 26-17. FR_GIFER Field Descriptions (Sheet 1 of 3)
Field Description
MIF Module Interrupt Flag — This interrupt flag is set if at least one of the other interrupt flags in this register and
the related interrupt enable bit are set.
0 No interrupt flag and related interrupt enable bit are set
1 At least one of the other interrupt flags in this register and the related interrupt bit are set.
PRIF Protocol Interrupt Flag — This interrupt flag is set if at least one of the individual flags in the Protocol Interrupt
Flag Register 0 (FR_PIFR0) and Protocol Interrupt Flag Register 1 (FR_PIFR1) and the related interrupt enable
bit are set.
0 No individual protocol interrupt flag and related interrupt enable bit are set.
1 At least one of the individual protocol interrupt flags and the related interrupt enable bit are set.
CHIF CHI Interrupt Flag — This interrupt flag is set if at least one of the error flags in the CHI Error Flag Register
(FR_CHIERFR) and the chi error interrupt enable bit FR_GIFER[CHIE] are set.
0 All CHI error flags are equal to 0 or the chi error interrupt is disabled.
1 At least one CHI error flag and the chi error interrupt enable are is set.
WUPIF Wakeup Interrupt Flag — This interrupt flag is set when the CC has received a wakeup symbol on the FlexRay
bus. The application can determine on which channel the wakeup symbol was received by reading the related
wakeup flags WUB and WUA in the Protocol Status Register 3 (FR_PSR3).
0 No Wakeup symbol received on FlexRay bus
1 Wakeup symbol received on FlexRay bus
FAFBIF Receive FIFO Channel B Almost Full Interrupt Flag — This interrupt flag is set when one of the following
events occurs
a) the current number of FIFO B entries is equal to or greater than the watermark defined by the WM field in the
Receive FIFO Watermark and Selection Register (FR_RFWMSR), and the CC writes a received message into
the FIFO B, or
b) the current number of FIFO B entries is at least 1 and the periodic timer as defined by Receive FIFO Periodic
Timer Register (FR_RFPTR) expires.
0 no such event
1 FIFO B almost full event has occurred
Field Description
FAFAIF Receive FIFO Channel A Almost Full Interrupt Flag — This interrupt flag is set when one of the following
events occurs
a) the current number of FIFO A entries is equal to or greater than the watermark defined by the WM field in the
Receive FIFO Watermark and Selection Register (FR_RFWMSR), and the CC writes a received message into
the FIFO A, or
b) the current number of FIFO B entries is at least 1 and the periodic timer as defined by Receive FIFO Periodic
Timer Register (FR_RFPTR) expires.
0 no such event
1 FIFO A almost full event has occurred
RBIF Receive Message Buffer Interrupt Flag — This interrupt flag is set if for at least one of the individual receive
message buffers (FR_MBCCSRn[MTD] = 0) both the interrupt flag MBIF and the interrupt enable bit MBIE in the
corresponding Message Buffer Configuration, Control, Status Registers (FR_MBCCSRn) are asserted. The
application cannot clear this interrupt flag directly, instead it is cleared by the CC when all of the interrupt flags
MBIF of the individual receive message buffers are cleared by the application or if the application has cleared
the related interrupt enables bit MBIE.
0 None of the individual receive message buffers has the MBIF and MBIE flag set.
1 At least one individual receive message buffer has the MBIF and MBIE flag set.
TBIF Transmit Message Buffer Interrupt Flag — This flag is set if for at least one of the individual message buffers
(FR_MBCCSRn[MTD] = 1) both the interrupt flag MBIF and the interrupt enable bit MBIE in the corresponding
Message Buffer Configuration, Control, Status Registers (FR_MBCCSRn) are equal to 1. The application cannot
clear this interrupt flag directly, instead, this interrupt flag is cleared by the CC when either all of the individual
interrupt flags MBIF of the individual transmit message buffers are cleared by the application or the application
has cleared the related interrupt enables bit MBIE.
0 None of the individual transmit message buffers has the MBIF and MBIE flag set.
1 At least one individual transmit message buffer has the MBIF and MBIE flag set.
MIE Module Interrupt Enable — This bit controls if the Module Interrupt line is asserted when the MIF flag is set.
0 Disable interrupt line
1 Enable interrupt line
PRIE Protocol Interrupt Enable — This bit controls if the Protocol Interrupt line is asserted when the PRIF flag is set.
0 Disable interrupt line
1 Enable interrupt line
CHIE CHI Interrupt Enable — This bit controls if the CHI Interrupt line is asserted when the CHIF flag is set.
0 Disable interrupt line
1 Enable interrupt line
WUPIE Wakeup Interrupt Enable — This bit controls if the Wakeup Interrupt line is asserted when the WUPIF flag is
set.
0 Disable interrupt line
1 Enable interrupt line
FAFBIE Receive FIFO Channel B Almost Full Interrupt Enable — This bit controls if the RX FIFO B Almost Full
Interrupt line is asserted when the FAFBIF flag is set.
0 Disable interrupt line
1 Enable interrupt line
FAFAIE Receive FIFO Channel A Almost Full Interrupt Enable — This bit controls if the RX FIFO A Almost Full
Interrupt line is asserted when the FAFAIF flag is set.
0 Disable interrupt line
1 Enable interrupt line
Field Description
RBIE Receive Message Buffer Interrupt Enable — This bit controls if the Receive Message Buffer Interrupt line is
asserted when the RBIF flag is set.
0 Disable interrupt line
1 Enable interrupt line
TBIE Transmit Message Buffer Interrupt Enable — This bit controls if the Transmit Message Buffer Interrupt line is
asserted when the TBIF flag is set.
0 Disable interrupt line
1 Enable interrupt line
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R FATL INTL ILCF CSA MRC MOC CCL MXS MTX LTXB LTXA TBVB TBVA TI2 TI1 CYS
_IF _IF _IF _IF _IF _IF _IF _IF _IF _IF _IF _IF _IF _IF _IF _IF
W w1c w1c w1c w1c w1c w1c w1c w1c w1c w1c w1c w1c w1c w1c w1c w1c
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
The register holds one set of the protocol-related individual interrupt flags.
Table 26-18. FR_PIFR0 Field Descriptions (Sheet 1 of 3)
Field Description
FATL_IF Fatal Protocol Error Interrupt Flag — This flag is set when the protocol engine has detected a fatal protocol
error. In this case, the protocol engine goes into the POC:halt state immediately. The fatal protocol errors are:
1) pLatestTx violation, as described in the MAC process of the FlexRay protocol
2) transmission across slot boundary violation, as described in the FSP process of the FlexRay protocol
0 No such event.
1 Fatal protocol error detected.
INTL_IF Internal Protocol Error Interrupt Flag — This flag is set when the protocol engine has detected an internal
protocol error. In this case, the protocol engine goes into the POC:halt state immediately. An internal protocol
error occurs when the protocol engine has not finished a calculation and a new calculation is requested. This
can be caused by a hardware error.
0 No such event.
1 Internal protocol error detected.
ILCF_IF Illegal Protocol Configuration Interrupt Flag — This flag is set when the protocol engine has detected an
illegal protocol configuration parameter setting. In this case, the protocol engine goes into the POC:halt state
immediately.
The protocol engine checks the listen_timeout value programmed into the Protocol Configuration Register 14
(FR_PCR14) and Protocol Configuration Register 15 (FR_PCR15) when the CONFIG_COMPLETE command
was sent by the application via the Protocol Operation Control Register (FR_POCR). If the value of
listen_timeout is equal to zero, the protocol configuration setting is considered as illegal.
0 No such event.
1 Illegal protocol configuration detected.
Field Description
CSA_IF Cold Start Abort Interrupt Flag — This flag is set when the configured number of allowed cold start attempts
is reached and none of these attempts was successful. The number of allowed cold start attempts is configured
by the coldstart_attempts field in the Protocol Configuration Register 3 (FR_PCR3).
0 No such event.
1 Cold start aborted and no more coldstart attempts allowed.
MRC_IF Missing Rate Correction Interrupt Flag — This flag is set when an insufficient number of measurements is
available for rate correction at the end of the communication cycle.
0 No such event
1 Insufficient number of measurements for rate correction detected
MOC_IF Missing Offset Correction Interrupt Flag — This flag is set when an insufficient number of measurements is
available for offset correction. This is related to the MISSING_TERM event in the CSP process for offset
correction in the FlexRay protocol.
0 No such event.
1 Insufficient number of measurements for offset correction detected.
CCL_IF Clock Correction Limit Reached Interrupt Flag — This flag is set when the internal calculated offset or rate
calculation values have reached or exceeded its configured thresholds as given by the offset_coorection_out
field in the Protocol Configuration Register 9 (FR_PCR9) and the rate_correction_out field in the Protocol
Configuration Register 14 (FR_PCR14).
0 No such event.
1 Offset or rate correction limit reached.
MXS_IF Max Sync Frames Detected Interrupt Flag — This flag is set when the number of synchronization frames
detected in the current communication cycle exceeds the value of the node_sync_max field in the Protocol
Configuration Register 30 (FR_PCR30).
0 No such event.
1 More than node_sync_max sync frames detected.
Note: Only synchronization frames that have passed the synchronization frame acceptance and rejection filters
are taken into account.
MTX_IF Media Access Test Symbol Received Interrupt Flag — This flag is set when the MTS symbol was received
on channel A or channel B.
0 No such event.
1 MTS symbol received.
LTXB_IF pLatestTx Violation on Channel B Interrupt Flag — This flag is set when the frame transmission on channel B
in the dynamic segment exceeds the dynamic segment boundary. This is related to the pLatestTx violation, as
described in the MAC process of the FlexRay protocol.
0 No such event.
1 pLatestTx violation occurred on channel B.
LTXA_IF pLatestTx Violation on Channel A Interrupt Flag — This flag is set when the frame transmission on channel A
in the dynamic segment exceeds the dynamic segment boundary. This is related to the pLatestTx violation as
described in the MAC process of the FlexRay protocol.
0 No such event.
1 pLatestTx violation occurred on channel A.
TBVB_IF Transmission across boundary on channel B Interrupt Flag — This flag is set when the frame transmission
on channel B crosses the slot boundary. This is related to the transmission across slot boundary violation as
described in the FSP process of the FlexRay protocol.
0 No such event.
1 Transmission across boundary violation occurred on channel B.
Field Description
TBVA_IF Transmission across boundary on channel A Interrupt Flag — This flag is set when the frame transmission
on channel A crosses the slot boundary. This is related to the transmission across slot boundary violation as
described in the FSP process of the FlexRay protocol.
0 No such event.
1 Transmission across boundary violation occurred on channel A.
TI2_IF Timer 2 Expired Interrupt Flag — This flag is set whenever timer 2 expires.
0 No such event.
1 Timer 2 has reached its time limit.
TI1_IF Timer 1 Expired Interrupt Flag — This flag is set whenever timer 1 expires.
0 No such event
1 Timer 1 has reached its time limit
CYS_IF Cycle Start Interrupt Flag — This flag is set when a communication cycle starts.
0 No such event
1 Communication cycle started.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R EMC IPC PECF PSC SSI3 SSI2 SSI1 SSI0 EVT ODT
0 0 0 0 0 0
_IF _IF _IF _IF _IF _IF _IF _IF _IF _IF
W w1c w1c w1c w1c w1c w1c w1c w1c w1c w1c
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
The register holds one set of the protocol-related individual interrupt flags.
Table 26-19. FR_PIFR1 Field Descriptions (Sheet 1 of 2)
Field Description
EMC_IF Error Mode Changed Interrupt Flag — This flag is set when the value of the ERRMODE bit field in the Protocol
Status Register 0 (FR_PSR0) is changed by the CC.
0 No such event.
1 ERRMODE field changed.
IPC_IF Illegal Protocol Control Command Interrupt Flag — This flag is set when the PE tries to execute a protocol
control command, which was issued via the POCCMD field of the Protocol Operation Control Register
(FR_POCR), and detects that this protocol control command is not allowed in the current protocol state. In this
case the command is not executed. For more details, see Section 26.7.6, “Protocol Control Command
Execution”.
0 No such event.
1 Illegal protocol control command detected.
PECF_IF Protocol Engine Communication Failure Interrupt Flag — This flag is set if the CC has detected a
communication failure between the PE and the CHI.
0 No such event.
1 Protocol Engine Communication Failure detected.
Field Description
PSC_IF Protocol State Changed Interrupt Flag — This flag is set when the protocol state in the PROTSTATE field in
the Protocol Status Register 0 (FR_PSR0) has changed.
0 No such event.
1 Protocol state changed.
SSI3_IF Slot Status Counter Incremented Interrupt Flag — Each of these flags is set when the SLOTSTATUSCNT
SSI2_IF field in the corresponding Slot Status Counter Registers (FR_SSCR0–FR_SSCR3) is incremented.
SSI1_IF 0 No such event.
SSI0_IF 1 The corresponding slot status counter has incremented.
EVT_IF Even Cycle Table Written Interrupt Flag — This flag is set if the CC has written the sync frame measurement
/ ID tables into the flexray memory area for the even cycle.
0 No such event.
1 Sync frame measurement table written
ODT_IF Odd Cycle Table Written Interrupt Flag — This flag is set if the CC has written the sync frame measurement
/ ID tables into the flexray memory area for the odd cycle.
0 No such event.
1 Sync frame measurement table written
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R FATL INTL ILCF CSA MRC MOC CCL MXS MTX LTXB LTXA TBVB TBVA TI2 TI1 CYS
W _IE _IE _IE _IE _IE _IE _IE _IE _IE _IE _IE _IE _IE _IE _IE _IE
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
This register defines whether or not the individual interrupt flags defined in the Protocol Interrupt Flag
Register 0 (FR_PIFR0) can generate a protocol interrupt request.
Table 26-20. FR_PIER0 Field Descriptions
Field Description
FATL_IE Fatal Protocol Error Interrupt Enable — This bit controls FATL_IF interrupt request generation.
0 interrupt request generation disabled
1 interrupt request generation enabled
INTL_IE Internal Protocol Error Interrupt Enable — This bit controls INTL_IF interrupt request generation.
0 interrupt request generation disabled
1 interrupt request generation enabled
ILCF_IE Illegal Protocol Configuration Interrupt Enable — This bit controls ILCF_IF interrupt request generation.
0 interrupt request generation disabled
1 interrupt request generation enabled
Field Description
CSA_IE Cold Start Abort Interrupt Enable — This bit controls CSA_IF interrupt request generation.
0 interrupt request generation disabled
1 interrupt request generation enabled
MRC_IE Missing Rate Correction Interrupt Enable — This bit controls MRC_IF interrupt request generation.
0 interrupt request generation disabled
1 interrupt request generation enabled
MOC_IE Missing Offset Correction Interrupt Enable — This bit controls MOC_IF interrupt request generation.
0 interrupt request generation disabled
1 interrupt request generation enabled
CCL_IE Clock Correction Limit Reached Interrupt Enable — This bit controls CCL_IF interrupt request generation.
0 interrupt request generation disabled
1 interrupt request generation enabled
MXS_IE Max Sync Frames Detected Interrupt Enable — This bit controls MXS_IF interrupt request generation.
0 interrupt request generation disabled
1 interrupt request generation enabled
MTX_IE Media Access Test Symbol Received Interrupt Enable — This bit controls MTX_IF interrupt request
generation.
0 interrupt request generation disabled
1 interrupt request generation enabled
LTXB_IE pLatestTx Violation on Channel B Interrupt Enable — This bit controls LTXB_IF interrupt request generation.
0 interrupt request generation disabled
1 interrupt request generation enabled
LTXA_IE pLatestTx Violation on Channel A Interrupt Enable — This bit controls LTXA_IF interrupt request generation.
0 interrupt request generation disabled
1 interrupt request generation enabled
TBVB_IE Transmission across boundary on channel B Interrupt Enable — This bit controls TBVB_IF interrupt request
generation.
0 interrupt request generation disabled
1 interrupt request generation enabled
TBVA_IE Transmission across boundary on channel A Interrupt Enable — This bit controls TBVA_IF interrupt request
generation.
0 interrupt request generation disabled
1 interrupt request generation enabled
TI2_IE Timer 2 Expired Interrupt Enable — This bit controls TI1_IF interrupt request generation.
0 interrupt request generation disabled
1 interrupt request generation enabled
Field Description
TI1_IE Timer 1 Expired Interrupt Enable — This bit controls TI1_IF interrupt request generation.
0 interrupt request generation disabled
1 interrupt request generation enabled
CYS_IE Cycle Start Interrupt Enable — This bit controls CYC_IF interrupt request generation.
0 interrupt request generation disabled
1 interrupt request generation enabled
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R EMC IPC PECF PSC SSI3 SSI2 SSI1 SSI0 0 0 EVT ODT 0 0 0 0
W _IE _IE _IE _IE _IE _IE _IE _IE _IE _IE
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
This register defines whether or not the individual interrupt flags defined in Protocol Interrupt Flag
Register 1 (FR_PIFR1) can generate a protocol interrupt request.
Table 26-21. FR_PIER1 Field Descriptions
Field Description
EMC_IE Error Mode Changed Interrupt Enable — This bit controls EMC_IF interrupt request generation.
0 interrupt request generation disabled
1 interrupt request generation enabled
IPC_IE Illegal Protocol Control Command Interrupt Enable — This bit controls IPC_IF interrupt request generation.
0 interrupt request generation disabled
1 interrupt request generation enabled
PECF_IE Protocol Engine Communication Failure Interrupt Enable — This bit controls PECF_IF interrupt request
generation.
0 interrupt request generation disabled
1 interrupt request generation enabled
PSC_IE Protocol State Changed Interrupt Enable — This bit controls PSC_IF interrupt request generation.
0 interrupt request generation disabled
1 interrupt request generation enabled
SSI3_IE Slot Status Counter Incremented Interrupt Enable — This bit controls SSI[3:0]_IF interrupt request
SSI2_IE generation.
SSI1_IE 0 interrupt request generation disabled
SSI0_IE 1 interrupt request generation enabled
Field Description
EVT_IE Even Cycle Table Written Interrupt Enable — This bit controls EVT_IF interrupt request generation.
0 interrupt request generation disabled
1 interrupt request generation enabled
ODT_IE Odd Cycle Table Written Interrupt Enable — This bit controls ODT_IF interrupt request generation.
0 interrupt request generation disabled
1 interrupt request generation enabled
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R FRLB FRLA PCMI FOVB FOVA MBS MBU LCK SBCF FID DPL SPL NML NMF ILSA
0
_EF _EF _EF _EF _EF _EF _EF _EF _EF _EF _EF _EF _EF _EF _EF
W w1c w1c w1c w1c w1c w1c w1c w1c w1c w1c w1c w1c w1c w1c w1c
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
This register holds the CHI related error flags. The interrupt generation for each of these error flags is
controlled by the CHI interrupt enable bit CHIE in the Global Interrupt Flag and Enable Register
(FR_GIFER).
Table 26-22. FR_CHIERFR Field Descriptions (Sheet 1 of 2)
Field Description
FRLB_EF Frame Lost Channel B Error Flag — This flag is set if a complete frame was received on channel B but could
not be stored in the selected individual message buffer because this message buffer is currently locked by the
application. In this case, the frame and the related slot status information are lost.
0 No such event
1 Frame lost on channel B detected
FRLA_EF Frame Lost Channel A Error Flag — This flag is set if a complete frame was received on channel A but could
not be stored in the selected individual message buffer because this message buffer is currently locked by the
application. In this case, the frame and the related slot status information are lost.
0 No such error
1 Frame lost on channel A detected
PCMI_EF Protocol Command Ignored Error Flag — This flag is set if the application has issued a POC command by
writing to the POCCMD field in the Protocol Operation Control Register (FR_POCR) while the BSY flag is equal
to 1. In this case the command is ignored by the CC and is lost.
0 No such error
1 POC command ignored
FOVB_EF Receive FIFO Overrun Channel B Error Flag — This flag is set when an overrun of the FIFO for channel B
occurred. This error occurs if a semantically valid frame was received on channel B and matches the all criteria
to be appended to the FIFO for channel B but the FIFO is full. In this case, the received frame and its related slot
status information is lost.
0 No such error
1 FIFO overrun on channel B has been detected
Field Description
FOVA_EF Receive FIFO Overrun Channel A Error Flag — This flag is set when an overrun of the FIFO for channel A
occurred. This error occurs if a semantically valid frame was received on channel A and matches the all criteria
to be appended to the FIFO for channel A but the FIFO is full. In this case, the received frame and its related slot
status information is lost.
0 No such error
1 FIFO overrun on channel B has been detected
MBS_EF Message Buffer Search Error Flag — This flag is set if at least one of the following events occurs:
a) The message buffer search engine is still running while the next search must be started due to the FlexRay
protocol timing.
b) A message buffer index greater than 131 is detected in the FR_MBIDXR[MBIDX] field of an found message
buffer or in one of the FR_RSBIR[RSBIDX] fields.
Refer to Section 26.6.7.4, “Message Buffer Search Error” for details.
0 No such event
1 Search engine active while search start appears or illegal message buffer index detected
MBU_EF Message Buffer Utilization Error Flag — This flag is asserted if the application writes to a message buffer control
field that is beyond the number of utilized message buffers programmed in the Message Buffer Segment Size
and Utilization Register (FR_MBSSUTR).
If the application writes to a FR_MBCCSRn register with n > LAST_MB_UTIL, the CC ignores the write attempt
and asserts the message buffer utilization error flag MBU_EF in the CHI Error Flag Register (FR_CHIERFR).
0 No such event
1 Non-utilized message buffer enabled
LCK_EF Lock Error Flag — This flag is set if the application tries to lock a message buffer that is already locked by the
CC due to internal operations. In that case, the CC does not grant the lock to the application. The application
must issue the lock request again.
0 No such error
1 Lock error detected
SBCF_EF System Bus Communication Failure Error Flag — This flag is set if a system bus access was not finished
within the required amount of time (see Section 26.6.19.1.2, “System Bus Access Timeout”).
0 No such event
1 System bus access not finished in time
FID_EF Frame ID Error Flag — This flag is set if the frame ID stored in the message buffer header area differs from the
frame ID stored in the message buffer control register.
0 No such error occurred
1 Frame ID error occurred
DPL_EF Dynamic Payload Length Error Flag — This flag is set if the payload length written into the message buffer
header field of a transmit message buffer assigned to the dynamic segment is greater than the maximum
payload length for the dynamic segment as it is configured in the corresponding protocol configuration register
field max_payload_length_dynamic in the Protocol Configuration Register 24 (FR_PCR24).
0 No such error occurred
1 Dynamic payload length error occurred
SPL_EF Static Payload Length Error Flag — This flag is set if the payload length written into the message buffer header
field of a transmit message buffer assigned to the static segment is different from the payload length for the static
segment as it is configured in the corresponding protocol configuration register field payload_length_static in the
Protocol Configuration Register 19 (FR_PCR19).
0 No such error occurred
1 Static payload length error occurred
Field Description
NML_EF Network Management Length Error Flag — This flag is set if the payload length written into the header
structure of a receive message buffer assigned to the static segment is less than the configured length of the
Network Management Vector as configured in the Network Management Vector Length Register (FR_NMVLR).
In this case the received part of the Network Management Vector will be used to update the Network
Management Vector.
0 No such error occurred
1 Network management length error occurred
NMF_EF Network Management Frame Error Flag — This flag is set if a received message in the static segment with a
Preamble Indicator flag PP asserted has its Null Frame indicator flag NF asserted as well. In this case, the Global
Network Management Registers (see Network Management Vector Registers (FR_NMVR0–FR_NMVR5)) are
not updated.
0 No such error occurred
1 Network management frame error occurred
ILSA_EF Illegal System Bus Address Error Flag — This flag is set if the external system bus subsystem has detected
an access to an illegal system bus address from the CC (see Section 26.6.19.1.1, “System Bus Illegal Address
Access”).
0 No such event
1 Illegal system bus address accessed
Base + 0x0022
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 TBIVEC 0 RBIVEC
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
This register indicates the lowest numbered receive message buffer and the lowest numbered transmit
message buffer that have their interrupt status flag MBIF and interrupt enable MBIE bits asserted. This
means that message buffers with lower message buffer numbers have higher priority.
Table 26-23. FR_MBIVEC Field Descriptions
Field Description
TBIVEC Transmit Buffer Interrupt Vector — This field provides the number of the lowest numbered enabled transmit
message buffer that has its interrupt status flag MBIF and its interrupt enable bit MBIE set. If there is no transmit
message buffer with the interrupt status flag MBIF and the interrupt enable MBIE bits asserted, the value in this
field is set to 0.
RBIVEC Receive Buffer Interrupt Vector — This field provides the message buffer number of the lowest numbered
receive message buffer which has its interrupt flag MBIF and its interrupt enable bit MBIE asserted. If there is
no receive message buffer with the interrupt status flag MBIF and the interrupt enable MBIE bits asserted, the
value in this field is set to 0.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R STATUS_ERR_CNT
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
This register provides the channel status error counter for channel A. The protocol engine generates a slot
status vector for each static slot, each dynamic slot, the symbol window, and the NIT. The slot status vector
contains the four protocol related error indicator bits vSS!SyntaxError, vSS!ContentError, vSS!BViolation,
and vSS!TxConflict. The CC increments the status error counter by 1 if, for a slot or segment, at least one
error indicator bit is set to 1. The counter wraps around after it has reached the maximum value. For more
information on slot status monitoring, see Section 26.6.18, “Slot Status Monitoring”.
Table 26-24. FR_CASERCR Field Descriptions
Field Description
STATUS_ERR_CNT Channel Status Error Counter — This field provides the current value channel status error counter. The
counter value is updated within the first macrotick of the following slot or segment.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R STATUS_ERR_CNT
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
This register provides the channel status error counter for channel B. The protocol engine generates a slot
status vector for each static slot, each dynamic slot, the symbol window, and the NIT. The slot status vector
contains the four protocol related error indicator bits vSS!SyntaxError, vSS!ContentError, vSS!BViolation,
and vSS!TxConflict. The CC increments the status error counter by 1 if, for a slot or segment, at least one
error indicator bit is set to 1. The counter wraps around after it has reached the maximum value. For more
information on slot status monitoring see Section 26.6.18, “Slot Status Monitoring”.
Table 26-25. FR_CBSERCR Field Descriptions
Field Description
STATUS_ERR_CNT Channel Status Error Counter — This field provides the current channel status error count. The counter
value is updated within the first macrotick of the following slot or segment.
Base + 0x0028
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Field Description
ERRMODE Error Mode — protocol related variable: vPOC!ErrorMode. This field indicates the error mode of the protocol.
00 ACTIVE
01 PASSIVE
10 COMM_HALT
11 reserved
SLOTMODE Slot Mode — protocol related variable: vPOC!SlotMode. This field indicates the slot mode of the protocol.
00 SINGLE
01 ALL_PENDING
10 ALL
11 reserved
PROTSTATE Protocol State — protocol related variable: vPOC!State. This field indicates the state of the protocol.
000 POC:default config
001 POC:config
010 POC:wakeup
011 POC:ready
100 POC:normal passive
101 POC:normal active
110 POC:halt
111 POC:startup
Field Description
STARTUP Startup State — protocol related variable: vPOC!StartupState. This field indicates the current sub-state of the
STATE startup procedure.
0000 reserved
0001 reserved
0010 POC:coldstart collision resolution
0011 POC:coldstart listen
0100 POC:integration consistency check
0101 POC:integrationi listen
0110 reserved
0111 POC:initialize schedule
1000 reserved
1001 reserved
1010 POC:coldstart consistency check
1011 reserved
1100 reserved
1101 POC:integration coldstart check
1110 POC:coldstart gap
1111 POC:coldstart join
WAKEUP Wakeup Status — protocol related variable: vPOC!WakeupStatus. This field provides the outcome of the
STATUS execution of the wakeup mechanism.
000 UNDEFINED
001 RECEIVED_HEADER
010 RECEIVED_WUP
011 COLLISION_HEADER
100 COLLISION_WUP
101 COLLISION_UNKNOWN
110 TRANSMITTED
111 reserved
Base + 0x002A Additional Reset: CSAA, CSP, CPN: RUN Command Write: Normal Mode
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
W w1c
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Field Description
CSAA Cold Start Attempt Aborted Flag — protocol related event: ‘set coldstart abort indicator in CHI’
This flag is set when the CC has aborted a cold start attempt.
0 No such event
1 Cold start attempt aborted
CSP Leading Cold Start Path — This status bit is set when the CC has reached the POC:normal active state via the
leading cold start path. This indicates that this node has started the network
0 No such event
1 POC:normal active reached from POC:startup state via leading cold start path
CPN Leading Cold Start Path Noise — protocol related variable: vPOC!ColdstartNoise
This status bit is set if the CC has reached the POC:normal active state via the leading cold start path under
noise conditions. This indicates there was some activity on the FlexRay bus while the CC was starting up the
cluster.
0 No such event
1 POC:normal active state was reached from POC:startup state via noisy leading cold start path
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R NBVB NSEB STCB SBVB SSEB MTB NBVA NSEA STCA SBVA SSEA MTA CLKCORRFAILCNT
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
This register provides a snapshot of status information about the Network Idle Time NIT, the Symbol
Window and the clock synchronization. The NIT related status bits NBVB, NSEB, NBVA, and NSEA are
updated by the CC after the end of the NIT and before the end of the first slot of the next communication
cycle. The Symbol Window related status bits STCB, SBVB, SSEB, MTB, STCA, SBVA, SSEB, and
MTA are updated by the CC after the end of the symbol window and before the end of the current
communication cycle. If no symbol window is configured, the symbol window related status bits remain
in their reset state. The clock synchronization related CLKCORRFAILCNT is updated by the CC after the
end of the static segment and before the end of the current communication cycle.
Table 26-28. FR_PSR2 Field Descriptions (Sheet 1 of 2)
Field Description
NBVB NIT Boundary Violation on Channel B — protocol related variable: vSS!BViolation for NIT on channel B
This status bit is set when there was some media activity on the FlexRay bus channel B at the end of the NIT.
0 No such event
1 Media activity at boundaries detected
NSEB NIT Syntax Error on Channel B — protocol related variable: vSS!SyntaxError for NIT on channel B
This status bit is set when a syntax error was detected during NIT on channel B.
0 No such event
1 Syntax error detected
STCB Symbol Window Transmit Conflict on Channel B — protocol related variable: vSS!TxConflict for symbol
window on channel B
This status bit is set if there was a transmission conflict during the symbol window on channel B.
0 No such event
1 Transmission conflict detected
SBVB Symbol Window Boundary Violation on Channel B — protocol related variable: vSS!BViolation for symbol
window on channel B
This status bit is set if there was some media activity on the FlexRay bus channel B at the start or at the end of
the symbol window.
0 No such event
1 Media activity at boundaries detected
SSEB Symbol Window Syntax Error on Channel B — protocol related variable: vSS!SyntaxError for symbol window
on channel B
This status bit is set when a syntax error was detected during the symbol window on channel B.
0 No such event
1 Syntax error detected
MTB Media Access Test Symbol MTS Received on Channel B — protocol related variable: vSS!ValidMTS for
Symbol Window on channel B
This status bit is set if the Media Access Test Symbol MTS was received in the symbol window on channel B.
0 No such event
1 MTS symbol received
NBVA NIT Boundary Violation on Channel A — protocol related variable: vSS!BViolation for NIT on channel A
This status bit is set when there was some media activity on the FlexRay bus channel A at the end of the NIT.
0 No such event
1 Media activity at boundaries detected
NSEA NIT Syntax Error on Channel A — protocol related variable: vSS!SyntaxError for NIT on channel A
This status bit is set when a syntax error was detected during NIT on channel A.
0 No such event
1 Syntax error detected
Field Description
STCA Symbol Window Transmit Conflict on Channel A — protocol related variable: vSS!TxConflict for symbol
window on channel A
This status bit is set if there was a transmission conflicts during the symbol window on channel A.
0 No such event
1 Transmission conflict detected
SBVA Symbol Window Boundary Violation on Channel A — protocol related variable: vSS!BViolation for symbol
window on channel A
This status bit is set if there was some media activity on the FlexRay bus channel A at the start or at the end of
the symbol window.
0 No such event
1 Media activity at boundaries detected
SSEA Symbol Window Syntax Error on Channel A — protocol related variable: vSS!SyntaxError for symbol window
on channel A
This status bit is set when a syntax error was detected during the symbol window on channel A.
0 No such event
1 Syntax error detected
MTA Media Access Test Symbol MTS Received on Channel A — protocol related variable: vSS!ValidMTS for
symbol window on channel A
This status bit is set if the Media Access Test Symbol MTS was received in the symbol window on channel A.
1 MTS symbol received
0 No such event
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 WUB ABVB AACB ACEB ASEB AVFB 0 0 WUA ABVA AACA ACEA ASEA AVFA
W w1c w1c w1c w1c w1c w1c w1c w1c w1c w1c w1c w1c
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
This register provides aggregated channel status information as an accrued status of channel activity for
all communication slots, regardless of whether they are assigned for transmission or subscribed for
reception. It provides accrued information for the symbol window, the NIT, and the wakeup status.
Field Description
WUB Wakeup Symbol Received on Channel B — This flag is set when a wakeup symbol was received on
channel B.
0 No wakeup symbol received
1 Wakeup symbol received
ABVB Aggregated Boundary Violation on Channel B — This flag is set when a boundary violation has been
detected on channel B. Boundary violations are detected in the communication slots, the symbol window, and
the NIT.
0 No boundary violation detected
1 Boundary violation detected
AACB Aggregated Additional Communication on Channel B — This flag is set when at least one valid frame was
received on channel B in a slot that also contained an additional communication with either syntax error, content
error, or boundary violations.
0 No additional communication detected
1 Additional communication detected
ACEB Aggregated Content Error on Channel B — This flag is set when a content error has been detected on
channel B. Content errors are detected in the communication slots, the symbol window, and the NIT.
0 No content error detected
1 Content error detected
ASEB Aggregated Syntax Error on Channel B — This flag is set when a syntax error has been detected on
channel B. Syntax errors are detected in the communication slots, the symbol window and the NIT.
0 No syntax error detected
1 Syntax errors detected
AVFB Aggregated Valid Frame on Channel B — This flag is set when a syntactically correct valid frame has been
received in any static or dynamic slot through channel B.
1 At least one syntactically valid frame received
0 No syntactically valid frames received
WUA Wakeup Symbol Received on Channel A — This flag is set when a wakeup symbol was received on
channel A.
0 No wakeup symbol received
1 Wakeup symbol received
ABVA Aggregated Boundary Violation on Channel A — This flag is set when a boundary violation has been
detected on channel A. Boundary violations are detected in the communication slots, the symbol window, and
the NIT.
0 No boundary violation detected
1 Boundary violation detected
AACA Aggregated Additional Communication on Channel A — This flag is set when a valid frame was received in
a slot on channel A that also contained an additional communication with either syntax error, content error, or
boundary violations.
0 No additional communication detected
1 Additional communication detected
ACEA Aggregated Content Error on Channel A — This flag is set when a content error has been detected on
channel A. Content errors are detected in the communication slots, the symbol window, and the NIT.
0 No content error detected
1 Content error detected
Field Description
ASEA Aggregated Syntax Error on Channel A — This flag is set when a syntax error has been detected on channel
A. Syntax errors are detected in the communication slots, the symbol window, and the NIT.
0 No syntax error detected
1 Syntax errors detected
AVFA Aggregated Valid Frame on Channel A — This flag is set when a syntactically correct valid frame has been
received in any static or dynamic slot through channel A.
0 No syntactically valid frames received
1 At least one syntactically valid frame received
Base + 0x0030
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 MTCT
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
This register provides the macrotick count of the current communication cycle.
Table 26-30. FR_MTCTR Field Descriptions
Field Description
Base + 0x0032
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 0 0 0 0 0 0 0 0 CYCCNT
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Field Description
Base + 0x0034
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 0 0 0 SLOTCNTA
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
This register provides the number of the current slot in the current communication cycle for channel A.
Table 26-32. FR_SLTCTAR Field Descriptions
Field Description
SLOTCNTA Slot Counter Value for Channel A — protocol related variable: vSlotCounter for channel A
This field provides the number of the current slot in the current communication cycle.
Base + 0x0036
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 0 0 0 SLOTCNTB
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
This register provides the number of the current slot in the current communication cycle for channel B.
Table 26-33. FR_SLTCTBR Field Descriptions
Field Description
SLOTCNTA Slot Counter Value for Channel B — protocol related variable: vSlotCounter for channel B
This field provides the number of the current slot in the current communication cycle.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R RATECORR
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
This register provides the sign extended rate correction value in microticks as it was calculated by the clock
synchronization algorithm. The CC updates this register during the NIT of each odd numbered
communication cycle.
Table 26-34. FR_RTCORVR Field Descriptions
Field Description
RATECORR Rate Correction Value — protocol related variable: vRateCorrection (before value limitation and external rate
correction)
This field provides the sign extended rate correction value in microticks as it was calculated by the clock
synchronization algorithm. The value is represented in 2’s complement format. This value does not include the
value limitation and the application of the external rate correction. If the magnitude of the internally calculated
rate correction value exceeds the limit given by rate_correction_out in the Protocol Configuration Register 13
(FR_PCR13), the clock correction reached limit interrupt flag CCL_IF is set in the Protocol Interrupt Flag
Register 0 (FR_PIFR0).
Note: If the CC was not able to calculate a new rate correction term due to a lack of synchronization frames, the
RATECORR value is not updated.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R OFFSETCORR
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
This register provides the sign extended offset correction value in microticks as it was calculated by the
clock synchronization algorithm. The CC updates this register during the NIT.
Field Description
OFFSET- Offset Correction Value — protocol related variable: vOffsetCorrection (before value limitation and external
CORR offset correction)
This field provides the sign extended offset correction value in microticks as it was calculated by the clock
synchronization algorithm. The value is represented in 2’s complement format. This value does not include the
value limitation and the application of the external offset correction. If the magnitude of the internally calculated
rate correction value exceeds the limit given by offset_correction_out field in the Protocol Configuration Register
29 (FR_PCR29), the clock correction reached limit interrupt flag CCL_IF is set in the Protocol Interrupt Flag
Register 0 (FR_PIFR0).
Note: If the CC was not able to calculate an new offset correction term due to a lack of synchronization frames,
the OFFSETCORR value is not updated.
Base + 0x003C
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
This register provides five combined interrupt flags and a copy of three individual interrupt flags. The
combined interrupt flags are the result of a binary OR of the values of other interrupt flags regardless of
the state of the interrupt enable bits. The generation scheme for the combined interrupt flags is depicted in
Figure 26-160. The individual interrupt flags WUPIF, FAFBIF, and FAFAIF are copies of corresponding
flags in the Global Interrupt Flag and Enable Register (FR_GIFER) and are provided here to simplify the
application interrupt flag check. To clear the individual interrupt flags, the application must use the Global
Interrupt Flag and Enable Register (FR_GIFER).
NOTE
The meanings of the combined status bits MIF, PRIF, CHIF, RBIF, and
TBIF are different from those mentioned in the Global Interrupt Flag and
Enable Register (FR_GIFER).
Field Description
MIF Module Interrupt Flag — This flag is set if there is at least one interrupt source that has its interrupt flag
asserted.
0 No interrupt source has its interrupt flag asserted
1 At least one interrupt source has its interrupt flag asserted
PRIF Protocol Interrupt Flag — This flag is set if at least one of the individual protocol interrupt flags in the Protocol
Interrupt Flag Register 0 (FR_PIFR0) or Protocol Interrupt Flag Register 1 (FR_PIFR1) is equal to 1.
0 All individual protocol interrupt flags are equal to 0
1 At least one of the individual protocol interrupt flags is equal to 1
CHIF CHI Interrupt Flag — This flag is set if at least one of the individual CHI error flags in the CHI Error Flag Register
(FR_CHIERFR) is equal to 1.
0 All CHI error flags are equal to 0
1 At least one CHI error flag is equal to 1
FAFBIF Receive FIFO Channel B Almost Full Interrupt Flag — Provides the same value as FR_GIFER[FAFBIF]
FAFAIF Receive FIFO Channel A Almost Full Interrupt Flag — Provides the same value as FR_GIFER[FAFAIF]
RBIF Receive Message Buffer Interrupt Flag — This flag is set if for at least one of the individual receive message
buffers (FR_MBCCSRn[MTD] = 0) the interrupt flag MBIF in the corresponding Message Buffer Configuration,
Control, Status Registers (FR_MBCCSRn) is equal to 1.
0 None of the individual receive message buffers has the MBIF flag asserted.
1 At least one individual receive message buffers has the MBIF flag asserted.
TBIF Transmit Message Buffer Interrupt Flag — This flag is set if for at least one of the individual transmit message
buffers (FR_MBCCSRn[MTD] = 1) the interrupt flag MBIF in the corresponding Message Buffer Configuration,
Control, Status Registers (FR_MBCCSRn) is equal to 1.
0 None of the individual transmit message buffers has the MBIF flag asserted.
1 At least one individual transmit message buffers has the MBIF flag asserted.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 0 0 0 0 0 0
TIMEOUT
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 0
Field Description
TIMEOUT System Memory Access Time-Out — This value defines when a system bus access timeout is detected. For
a detailed description see Section 26.7.1.1, “Configure System Memory Access Time-Out Register
(FR_SYMATOR)” and Section 26.6.19.1.2, “System Bus Access Timeout”.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
This register provides the number of synchronization frames that are used for clock synchronization in the
last even and in the last odd numbered communication cycle. This register is updated after the start of the
NIT and before 10 MT after offset correction start.
NOTE
If the application has locked the even synchronization table at the end of the
static segment of an even communication cycle, the CC will not update the
fields SFEVB and SFEVA.
If the application has locked the odd synchronization table at the end of the
static segment of an odd communication cycle, the CC will not update the
values SFODB and SFODA.
Table 26-38. FR_SFCNTR Field Descriptions
Field Description
SFEVB Sync Frames Channel B, even cycle — protocol related variable: size of (vsSyncIdListB for even cycle)
This field provides the size of the internal list of frame IDs of received synchronization frames used for clock
synchronization.
SFEVB Sync Frames Channel A, even cycle — protocol related variable: size of (vsSyncIdListA for even cycle)
This field provides the size of the internal list of frame IDs of received synchronization frames used for clock
synchronization.
SFODB Sync Frames Channel B, odd cycle — protocol related variable: size of (vsSyncIdListB for odd cycle)
This field provides the size of the internal list of frame IDs of received synchronization frames used for clock
synchronization.
SFODA Sync Frames Channel A, odd cycle — protocol related variable: size of (vsSyncIdListA for odd cycle)
This field provides the size of the internal list of frame IDs of received synchronization frames used for clock
synchronization.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0
SFT_OFFSET[15:1]
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
This register defines the flexray memory area related offset for sync frame tables. For more details, see
Section 26.6.12, “Sync Frame ID and Sync Frame Deviation Tables”.
Table 26-39. FR_SFTOR Field Description
Field Description
SFT_OFFSE Sync Frame Table Offset — The offset of the Sync Frame Tables in the flexray memory area. This offset is
T required to be 16-bit aligned. Thus STF_OFFSET[0] is always 0.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 26-35. Sync Frame Table Configuration, Control, Status Register (FR_SFTCCSR)
This register provides configuration, control, and status information related to the generation and access
of the clock sync ID tables and clock sync measurement tables. For a detailed description, see
Section 26.6.12, “Sync Frame ID and Sync Frame Deviation Tables”.
Table 26-40. FR_SFTCCSR Field Descriptions
Field Description
ELKT Even Cycle Tables Lock/Unlock Trigger — This trigger bit is used to lock and unlock the even cycle tables.
0 No effect
1 Triggers lock/unlock of the even cycle tables.
OLKT Odd Cycle Tables Lock/Unlock Trigger — This trigger bit is used to lock and unlock the odd cycle tables.
0 No effect
1 Triggers lock/unlock of the odd cycle tables.
CYCNUM Cycle Number — This field provides the number of the cycle in which the currently locked table was
recorded. If none or both tables are locked, this value is related to the even cycle table.
Field Description
ELKS Even Cycle Tables Lock Status — This status bit indicates whether the application has locked the even
cycle tables.
0 Application has not locked the even cycle tables.
1 Application has locked the even cycle tables.
OLKS Odd Cycle Tables Lock Status — This status bit indicates whether the application has locked the odd cycle
tables.
0 Application has not locked the odd cycle tables.
1 Application has locked the odd cycle tables.
EVAL Even Cycle Tables Valid — This status bit indicates whether the Sync Frame ID and Sync Frame Deviation
Tables for the even cycle are valid. The CC clears this status bit when it starts updating the tables, and sets
this bit when it has finished the table update.
0 Tables are not valid (update is ongoing)
1 Tables are valid (consistent).
OVAL Odd Cycle Tables Valid — This status bit indicates whether the Sync Frame ID and Sync Frame Deviation
Tables for the odd cycle are valid. The CC clears this status bit when it starts updating the tables, and sets
this bit when it has finished the table update.
0 Tables are not valid (update is ongoing)
1 Tables are valid (consistent).
OPT One Pair Trigger — This trigger bit controls whether the CC writes continuously or only one pair of Sync
Frame Tables into the flexray memory area.
If this trigger is set to 1 while SDVEN or SIDEN is set to 1, the CC writes only one pair of the enabled Sync
Frame Tables corresponding to the next even-odd-cycle pair into the flexray memory area. In this case, the
CC clears the SDVEN or SIDEN bits immediately.
If this trigger is set to 0 while SDVEN or SIDEN is set to 1, the CC writes continuously the enabled Sync
Frame Tables into the flexray memory area.
0 Write continuously pairs of enabled Sync Frame Tables into flexray memory area.
1 Write only one pair of enabled Sync Frame Tables into flexray memory area.
SDVEN Sync Frame Deviation Table Enable — This bit controls the generation of the Sync Frame Deviation Tables.
The application must set this bit to request the CC to write the Sync Frame Deviation Tables into the flexray
memory area.
0 Do not write Sync Frame Deviation Tables
1 Write Sync Frame Deviation Tables into flexray memory area
Note: If SDVEN is set to 1, then SIDEN must also be set to 1.
SIDEN Sync Frame ID Table Enable — This bit controls the generation of the Sync Frame ID Tables. The
application must set this bit to 1 to request the CC to write the Sync Frame ID Tables into the flexray memory
area.
0 Do not write Sync Frame ID Tables
1 Write Sync Frame ID Tables into flexray memory area
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 0 0 0 0
SYNFRID
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
This register defines the Sync Frame Rejection Filter ID. The application must update this register outside
of the static segment. If the application updates this register in the static segment, it can appear that the CC
accepts the sync frame in the current cycle.
Table 26-41. FR_SFIDRFR Field Descriptions
Field Description
SYNFRID Sync Frame Rejection ID — This field defines the frame ID of a frame that must not be used for clock
synchronization. For details see Section 26.6.15.2, “Sync Frame Rejection Filtering”.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 0 0 0 0
FVAL
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
This register defines the sync frame acceptance filter value. For details on filtering, see Section 26.6.15,
“Sync Frame Filtering”.
Table 26-42. FR_SFIDAFVR Field Descriptions
Field Description
FVAL Filter Value — This field defines the value for the sync frame acceptance filtering.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 0 0 0 0
FMSK
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
This register defines the sync frame acceptance filter mask. For details on filtering see Section 26.6.15.1,
“Sync Frame Acceptance Filtering”.
Table 26-43. FR_SFIDAFMR Field Descriptions
Field Description
FMSK Filter Mask — This field defines the mask for the sync frame acceptance filtering.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R NMVP[15:8] NMVP[7:0]
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Each of these six registers holds one part of the Network Management Vector. The length of the Network
Management Vector is configured in the Network Management Vector Length Register (FR_NMVLR). If
FR_NMVLR is programmed with a value that is less than 12 bytes, the remaining bytes of the Network
Management Vector Registers (FR_NMVR0–FR_NMVR5), which are not used for the Network
Management Vector accumulating, will remain 0.
The NMVR provides accrued information over all received NMVs in the last communication cycle. All
NMVs received in one cycle are ORed into the NMVR. The NMVR is updated at the end of the
communication cycle.
Field Description
NMVP Network Management Vector Part — The mapping between the Network Management Vector Registers
(FR_NMVR0–FR_NMVR5) and the receive message buffer payload bytes in NMV[0:11] is depicted in
Table 26-45.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 0 0 0 0 0 0 0 0 0 0
NMVL
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
This register defines the length of the network management vector in bytes.
Table 26-46. FR_NMVLR Field Descriptions
Field Description
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
This register is used to configure and control the two timers T1 and T2. For timer details, see
Section 26.6.17, “Timer Support”. The Timer T1 is an absolute timer. The Timer T2 can be configured as
an absolute or relative timer.
Table 26-47. FR_TICCR Field Descriptions
Field Description
T2_CFG Timer T2 Configuration — This bit configures the timebase mode of Timer T2.
0 T2 is absolute timer.
1 T2 is relative timer.
T2_REP Timer T2 Repetitive Mode — This bit configures the repetition mode of Timer T2.
0 T2 is non repetitive
1 T2 is repetitive
T2SP Timer T2 Stop — This trigger bit is used to stop timer T2.
0 no effect
1 stop timer T2
T2TR Timer T2 Trigger — This trigger bit is used to start timer T2.
0 no effect
1 start timer T2
T2ST Timer T2 State — This status bit provides the current state of timer T2.
0 timer T2 is idle
1 timer T2 is running
T1_REP Timer T1 Repetitive Mode — This bit configures the repetition mode of timer T1.
0 T1 is non repetitive
1 T1 is repetitive
T1SP Timer T1 Stop — This trigger bit is used to stop timer T1.
0 no effect
1 stop timer T1
T1TR Timer T1 Trigger — This trigger bit is used to start timer T1.
0 no effect
1 start timer T1
T1ST Timer T1 State — This status bit provides the current state of timer T1.
0 timer T1 is idle
1 timer T1 is running
NOTE
Both timers are deactivated immediately when the protocol enters a state
different from POC:normal active or POC:normal passive.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 0 0
T1_CYC_VAL T1_CYC_MSK
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
This register defines the cycle filter value and the cycle filter mask for timer T1. For a detailed description
of timer T1, refer to Section 26.6.17.1, “Absolute Timer T1”.
Table 26-48. FR_TI1CYSR Field Descriptions
Field Description
T1_CYC_VAL Timer T1 Cycle Filter Value — This field defines the cycle filter value for timer T1.
T1_CYC_MSK Timer T1 Cycle Filter Mask — This field defines the cycle filter mask for timer T1.
NOTE
If the application modifies the value in this register while the timer is
running, the change becomes effective immediately and timer T1 will expire
according to the changed value.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0
T1_MTOFFSET
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
This register holds the macrotick offset value for timer T1. For a detailed description of timer T1, refer to
Section 26.6.17.1, “Absolute Timer T1”.
Table 26-49. FR_TI1MTOR Field Descriptions
Field Description
T1_MTOFFSET Timer 1 Macrotick Offset — This field defines the macrotick offset value for timer 1.
NOTE
If the application modifies the value in this register while the timer is
running, the change becomes effective immediately and timer T1 will expire
according to the changed value.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R
R* T2_CYC_VAL R* T2_CYC_MSK
W
R
T2_MTCNT[31:16]
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
The content of this register depends on the value of the T2_CFG bit in the Timer Configuration and Control
Register (FR_TICCR). For a detailed description of timer T2, refer to Section 26.6.17.2, “Absolute /
Relative Timer T2”.
Table 26-50. FR_TI2CR0 Field Descriptions
Field Description
T2_CYC_VAL Timer T2 Cycle Filter Value — This field defines the cycle filter value for timer T2.
T2_CYC_MSK Timer T2 Cycle Filter Mask — This field defines the cycle filter mask for timer T2.
T2_MTCNT[31:16] Timer T2 Macrotick High Word — This field defines the high word of the macrotick count for timer T2.
NOTE
If timer T2 is configured as an absolute timer and the application modifies
the values in this register while the timer is running, the change becomes
effective immediately and timer T2 will expire according to the changed
values.
If timer T2 is configured as a relative timer and the application changes the
values in this register while the timer is running, the change becomes
effective when the timer has expired according to the old values.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R
R* T2_MTOFFSET
W
R
T2_MTCNT[15:0]
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
The content of this register depends on the value of the T2_CFG bit in the Timer Configuration and Control
Register (FR_TICCR). For a detailed description of timer T2, refer to Section 26.6.17.2, “Absolute /
Relative Timer T2”.
Table 26-51. FR_TI2CR1 Field Descriptions
Field Description
T2_MTOFFSET Timer T2 Macrotick Offset — This field holds the macrotick offset value for timer T2.
T2_MTCNT[15:0] Timer T2 Macrotick Low Word — This field defines the low word of the macrotick value for timer T2.
NOTE
If timer T2 is configured as an absolute timer and the application modifies
the values in this register while the timer is running, the change becomes
effective immediately and the timer T2 will expire according to the changed
values.
If timer T2 is configured as a relative timer and the application changes the
values in this register while the timer is running, the change becomes
effective when the timer has expired according to the old values.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 0
SEL SLOTNUMBER
W WMD
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
This register is used to access the four internal non-memory mapped slot status selection registers
FR_SSSR0 to FR_SSSR3. Each internal register selects a slot, or symbol window/NIT, whose status
vector will be saved in the corresponding Slot Status Registers (FR_SSR0–FR_SSR7) according to
Table 26-53. For a detailed description of slot status monitoring, refer to Section 26.6.18, “Slot Status
Monitoring”.
Table 26-52. FR_SSSR Field Descriptions
Field Description
WMD Write Mode — This control bit defines the write mode of this register.
0 Write to all fields in this register on write access.
1 Write to SEL field only on write access.
SEL Selector — This field selects one of the four internal slot status selection registers for access.
00 select FR_SSSR0.
01 select FR_SSSR1.
10 select FR_SSSR2.
11 select FR_SSSR3.
SLOTNUMBER Slot Number — This field specifies the number of the slot whose status will be saved in the corresponding
slot status registers.
Note: If this value is set to 0, the related slot status register provides the status of the symbol window after the
NIT start, and provides the status of the NIT after the cycle start.
Write the Slot Status of the Slot Selected by FR_SSSRn for each
Internal Slot
Even Communication Cycle Odd Communication Cycle
Status Selection
Register For Channel B For Channel A For Channel B For Channel A
to to to to
FR_SSSR0 FR_SSR0[15:8] FR_SSR0[7:0] FR_SSR1[15:8] FR_SSR1[7:0]
FR_SSSR1 FR_SSR2[15:8] FR_SSR2[7:0] FR_SSR3[15:8] FR_SSR3[7:0]
FR_SSSR2 FR_SSR4[15:8] FR_SSR4[7:0] FR_SSR5[15:8] FR_SSR5[7:0]
FR_SSSR3 FR_SSR6[15:8] FR_SSR6[7:0] FR_SSR7[15:8] FR_SSR7[7:0]
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 0
SEL CNTCFG MCY VFR SYF NUF SUF STATUSMASK[3:0]
W WMD
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
This register is used to access and program the four internal non-memory mapped Slot Status Counter
Condition Registers FR_SSCCR0 to FR_SSCCR3. Each of these four internal slot status counter condition
registers defines the mode and the conditions for incrementing the counter in the corresponding Slot Status
Counter Registers (FR_SSCR0–FR_SSCR3). The correspondence is given in Table 26-55. For a detailed
description of slot status counters, refer to Section 26.6.18.4, “Slot Status Counter Registers”.
Table 26-54. FR_SSCCR Field Descriptions
Field Description
WMD Write Mode — This control bit defines the write mode of this register.
0 Write to all fields in this register on write access.
1 Write to SEL field only on write access.
SEL Selector — This field selects one of the four internal slot counter condition registers for access.
00 select FR_SSCCR0.
01 select FR_SSCCR1.
10 select FR_SSCCR2.
11 select FR_SSCCR3.
CNTCFG Counter Configuration — These bit field controls the channel related incrementing of the slot status counter.
00 increment by 1 if condition is fulfilled on channel A.
01 increment by 1 if condition is fulfilled on channel B.
10 increment by 1 if condition is fulfilled on at least one channel.
11 increment by 2 if condition is fulfilled on both channels channel.
increment by 1 if condition is fulfilled on only one channel.
MCY Multi Cycle Selection — This bit defines whether the slot status counter accumulates over multiple
communication cycles or provides information for the previous communication cycle only.
0 The Slot Status Counter provides information for the previous communication cycle only.
1 The Slot Status Counter accumulates over multiple communication cycles.
VFR Valid Frame Restriction — This bit is used to restrict the counter to received valid frames.
0 The counter is not restricted to valid frames only.
1 The counter is restricted to valid frames only.
SYF Sync Frame Restriction — This bit is used to restrict the counter to received frames with the sync frame
indicator bit set to 1.
0 The counter is not restricted with respect to the sync frame indicator bit.
1 The counter is restricted to frames with the sync frame indicator bit set to 1.
NUF Null Frame Restriction — This bit is used to restrict the counter to received frames with the null frame
indicator bit set to 0.
0 The counter is not restricted with respect to the null frame indicator bit.
1 The counter is restricted to frames with the null frame indicator bit set to 0.
SUF Startup Frame Restriction — This bit is used to restrict the counter to received frames with the startup frame
indicator bit set to 1.
0 The counter is not restricted with respect to the startup frame indicator bit.
1 The counter is restricted to received frames with the startup frame indicator bit set to 1.
STATUS Slot Status Mask — This bit field is used to enable the counter with respect to the four slot status error
MASK[3:0] indicator bits.
STATUSMASK[3] – This bit enables the counting for slots with the syntax error indicator bit set to 1.
STATUSMASK[2] – This bit enables the counting for slots with the content error indicator bit set to 1.
STATUSMASK[1] – This bit enables the counting for slots with the boundary violation indicator bit set to 1.
STATUSMASK[0] – This bit enables the counting for slots with the transmission conflict indicator bit set to 1.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R VFB SYB NFB SUB SEB CEB BVB TCB VFA SYA NFA SUA SEA CEA BVA TCA
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Each of these eight registers holds the status vector of the slot specified in the corresponding internal slot
status selection register, which can be programmed using the Slot Status Selection Register (FR_SSSR).
Each register is updated after the end of the corresponding slot as shown in Figure 26-155. The register
bits are directly related to the protocol variables and described in more detail in Section 26.6.18, “Slot
Status Monitoring”.
Table 26-56. FR_SSR0–FR_SSR7 Field Descriptions
Field Description
SYB Sync Frame Indicator Channel B — protocol related variable: vRF!Header!SyFIndicator channel B
0 vRF!Header!SyFIndicator = 0
1 vRF!Header!SyFIndicator = 1
NFB Null Frame Indicator Channel B — protocol related variable: vRF!Header!NFIndicator channel B
0 vRF!Header!NFIndicator = 0
1 vRF!Header!NFIndicator = 1
SUB Startup Frame Indicator Channel B — protocol related variable: vRF!Header!SuFIndicator channel B
0 vRF!Header!SuFIndicator = 0
1 vRF!Header!SuFIndicator = 1
Field Description
SYA Sync Frame Indicator Channel A — protocol related variable: vRF!Header!SyFIndicator channel A
0 vRF!Header!SyFIndicator = 0
1 vRF!Header!SyFIndicator = 1
NFA Null Frame Indicator Channel A — protocol related variable: vRF!Header!NFIndicator channel A
0 vRF!Header!NFIndicator = 0
1 vRF!Header!NFIndicator = 1
SUA Startup Frame Indicator Channel A — protocol related variable: vRF!Header!SuFIndicator channel A
0 vRF!Header!SuFIndicator = 0
1 vRF!Header!SuFIndicator = 1
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R SLOTSTATUSCNT
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Each of these four registers provides the slot status counter value for the previous communication cycle(s)
and is updated at the cycle start. The provided value depends on the control bits and fields in the related
internal slot status counter condition register FR_SSCCRn, which can be programmed by using the Slot
Status Counter Condition Register (FR_SSCCR). For more details, see Section 26.6.18.4, “Slot Status
Counter Registers”.
NOTE
If the counter has reached its maximum value 0xFFFF and is in the
multicycle mode (FR_SSCCRn[MCY] = 1), the counter is not reset to
0x0000. The application can reset the counter by clearing the
FR_SSCCRn[MCY] bit and waiting for the next cycle start, when the CC
clears the counter. Subsequently, the counter can be set into the multicycle
mode again.
Table 26-57. FR_SSCR0–FR_SSCR3 Field Descriptions
Field Description
SLOTSTATUSCNT Slot Status Counter — This field provides the current value of the Slot Status Counter.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 0
MTE CYCCNTMSK CYCCNTVAL
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
This register controls the transmission of the Media Access Test Symbol MTS on channel A. For more
details, see Section 26.6.13, “MTS Generation”.
Field Description
MTE Media Access Test Symbol Transmission Enable — This control bit is used to enable and disable the
transmission of the Media Access Test Symbol in the selected set of cycles.
0 MTS transmission disabled
1 MTS transmission enabled
CYCCNTMSK Cycle Counter Mask — This field provides the filter mask for the MTS cycle count filter.
CYCCNTVAL Cycle Counter Value — This field provides the filter value for the MTS cycle count filter.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 0
MTE CYCCNTMSK CYCCNTVAL
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
This register controls the transmission of the Media Access Test Symbol MTS on channel B. For more
details, see Section 26.6.13, “MTS Generation”.
Table 26-59. MTSBCFR Field Descriptions
Field Description
MTE Media Access Test Symbol Transmission Enable — This control bit is used to enable and disable the
transmission of the Media Access Test Symbol in the selected set of cycles.
0 MTS transmission disabled
1 MTS transmission enabled
CYCCNTMSK Cycle Counter Mask — This field provides the filter mask for the MTS cycle count filter.
CYCCNTVAL Cycle Counter Value — This field provides the filter value for the MTS cycle count filter.
Base + 0x0084 16-bit write access required Write: WMD, SEL: Any Time
RSBIDX: POC:config
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 0 0 0 0 RSBIDXA1/RSBIDXA2
SEL
W WMD RSBIDXB1/RSBIDXB2
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
This register is used to provide and retrieve the indices of the message buffer header fields currently
associated with the receive shadow buffers. For more details on the receive shadow buffer concept, refer
to Section 26.6.6.3.5, “Receive Shadow Buffers Concept”.
Table 26-60. FR_RSBIR Field Descriptions
Field Description
WMD Write Mode — This bit controls the write mode for this register.
0 update SEL and RSBIDX field on register write
1 update only SEL field on register write
SEL Selector — This field is used to select the internal receive shadow buffer index register for access.
00 FR_RSBIR_A1 — receive shadow buffer index register for channel A, segment 1
01 FR_RSBIR_A2 — receive shadow buffer index register for channel A, segment 2
10 FR_RSBIR_B1 — receive shadow buffer index register for channel B, segment 1
11 FR_RSBIR_B2 — receive shadow buffer index register for channel B, segment 2
RSBIDXA1 Receive Shadow Buffer Index — This field contains the current index of the message buffer header field of the
RSBIDXA2 receive shadow message buffer selected by the SEL field. The CC uses this index to determine the physical
RSBIDXB1 location of the shadow buffer header field in the flexray memory area. The CC will update this field during receive
RSBIDXB2 operation.The application provides initial message buffer header index value in the configuration phase.
CC: Updates the message buffer header index after successful reception.
Application: Provides initial message buffer header index.
Legal Values are 0 <= i <= 131. Illegal values will be detected during the message buffer search.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R
SDOA/SDOB
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Field Description
SDOA Start Data Field Offset — This field defines the data field offset of the header field of the first message buffer
SDOB of the selected FIFO. The CC uses the value of the SDO field to determine the physical location of the receiver
FIFO’s first message buffer header field. For configuration constraints see Section 26.7.1.2, “Configure Data
Field Offsets”.
NOTE
Since all data fields of the FIFO are of equal length and are located at
subsequent system memory addresses the content of the FR_RFSDOR
register corresponds to the start address of payload area of the selected
FIFO.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R
SMBA[31:16]
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 26-54. Receive FIFO System Memory Base Address High Register (FR_RFSYMBADHR)
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 0 0
SMBA[15:4]
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 26-55. Receive FIFO System Memory Base Address Low Register (FR_RFSYMBADLR)
These registers define the system memory base address for the receive FIFO if the FIFO address mode bit
FR_MCR[FAM] is set to 1. The system memory base address is used by the BMIF to calculate the physical
memory address for system memory accesses for the FIFOs.
Table 26-62. FR_RFSYMBADR Field Descriptions
Field Description
SMBA System Memory Base Address — This is the value of the system memory base address for the receive FIFO
if the FIFO address mode bit FR_MCR[FAM] is set to 1. It is defines as a byte address.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0
PTD
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
This register holds periodic timer duration for the periodic FIFO timer. The periodic timer applies to both
FIFOs (see Section 26.6.9.3, “FIFO Periodic Timer”).
Field Description
PTD Periodic Timer Duration — This value defines the periodic timer duration in terms of macroticks.
0000 timer stays expired
3FFF timer never expires
other timer expires after specified number of macroticks, expires and is restarted at each cycle start
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 0 0 0 0 0
WMA//WMB SEL
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Register
Receive FIFO Start Index Register (FR_RFSIR)
Receive FIFO Depth and Size Register (RFDSR)
Receive FIFO Message ID Acceptance Filter Value Register (FR_RFMIDAFVR)
Receive FIFO Message ID Acceptance Filter Mask Register (FR_RFMIDAFMR)
Receive FIFO Frame ID Rejection Filter Value Register (FR_RFFIDRFVR)
Receive FIFO Frame ID Rejection Filter Mask Register (FR_RFFIDRFMR)
Receive FIFO Range Filter Configuration Register (FR_RFRFCFR)
Receive FIFO Range Filter Control Register (FR_RFRFCTR)
Field Description
WMA Watermark — This field defines the watermark value for the selected FIFO. This value is used to control the
WMB generation of the almost full interrupt flags.
SEL Select — This control bit selects the receiver FIFO for subsequent programming.
0 Receiver FIFO for channel A selected
1 Receiver FIFO for channel B selected
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 0 0 0 0
SIDXA/SIDXB
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
This register defines the message buffer header index of the first message buffer of the selected FIFO.
Table 26-66. FR_RFSIR Field Descriptions
Field Description
SIDXA Start Index — This field defines the number of the message buffer header field of the first message buffer of the
SIDXB selected FIFO. The CC uses the value of the SIDX field to determine the physical location of the receiver FIFO’s
first message buffer header field.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0
FIFO_DEPTHA/FIFO_DEPTHB ENTRY_SIZEA/ENTRY_SIZEB
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
This register defines the structure of the selected FIFO, i.e., the number of entries and the size of each
entry.
Table 26-67. RFDSR Field Descriptions
Field Description
FIFO_DEPTHA FIFO Depth — This field defines the depth of the selected FIFO, i.e., the number of entries.
FIFO_DEPTHB Note: If the FIFO_DEPTH is configured to 0, FR_RFFIDRFMR[FIDRFMSK] must be configured to 0 too, to
ensure that no frames are received into the FIFO.
ENTRY_SIZEA Entry Size — This field defines the size of the frame data sections for the selected FIFO in 2 byte entities.
ENTRY_SIZEB
Base + 0x008C
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 0 0 0 0 RDIDX
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
This register provides the message buffer header index of the next available FIFO A entry that the
application can read.
Table 26-68. FR_RFARIR Field Descriptions
Field Description
RDIDX Read Index — This field provides the message buffer header index of the next available FIFO message buffer
that the application can read.
NOTE
If the FIFO is empty, the RDIDX field points to an physical message buffer
with invalid content.
Base + 0x008E
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 0 0 0 0 RDIDX
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
This register provides the message buffer header index of the next available FIFO B entry that the
application can read.
Table 26-69. FR_RFBRIR Field Descriptions
Field Description
RDIDX Read Index — This field provides the message buffer header index of the next available FIFO message buffer
that the application can read.
NOTE
If the FIFO is empty, the RDIDX field points to an physical message buffer
with invalid content.
26.5.2.61 Receive FIFO Fill Level and POP Count Register (FR_RFFLPCR)
Base + 0x00EE
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R FLB FLA
W PCB PCA
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 26-62. Receive FIFO Fill Level and POP Count Register (FR_RFFLPCR)
This register provides the current fill level of the two receiver FIFOs and is used to pop a number of entries
from the FIFOs.
Table 26-70. FR_RFFLPCR Field Descriptions
Field Description
FLB Fill Level FIFO B — This field provides the current number of entries in the FIFO B.
FLA Fill Level FIFO A— This field provides the current number of entries in the FIFO A.
PCB Pop Count FIFO B — This field defines the number of entries to be removed from FIFO B.
PCA Pop Count FIFO A— This field defines the number of entries to be removed from FIFO A.
NOTE
If the pop count value PCA/PCB is greater than the current FIFO fill level
FLB/FLA, than the FIFO is empty after the update. No notification is given
that not the required number of entries was removed.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R
MIDAFVALA/MIDAFVALB
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 26-63. Receive FIFO Message ID Acceptance Filter Value Register (FR_RFMIDAFVR)
This register defines the filter value for the message ID acceptance filter of the selected FIFO. For details
on message ID filtering see Section 26.6.9.9, “FIFO Filtering”.
Table 26-71. FR_RFMIDAFVR Field Descriptions
Field Description
MIDAFVALA Message ID Acceptance Filter Value — Filter value for the message ID acceptance filter.
MIDAFVALB
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R
MIDAFMSKA/MIDAFMSKB
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 26-64. Receive FIFO Message ID Acceptance Filter Mask Register (FR_RFMIDAFMR)
This register defines the filter mask for the message ID acceptance filter of the selected FIFO. For details
on message ID filtering see Section 26.6.9.9, “FIFO Filtering”.
Table 26-72. FR_RFMIDAFMR Field Descriptions
Field Description
MIDAFMSKA Message ID Acceptance Filter Mask — Filter mask for the message ID acceptance filter.
MIDAFMSKB
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 0 0 0
FIDRFVALA/FIDRFVALB
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 26-65. Receive FIFO Frame ID Rejection Filter Value Register (FR_RFFIDRFVR)
This register defines the filter value for the frame ID rejection filter of the selected FIFO. For details on
frame ID filtering see Section 26.6.9.9, “FIFO Filtering”.
Table 26-73. FR_RFFIDRFVR Field Descriptions
Field Description
FIDRFVALA Frame ID Rejection Filter Value — Filter value for the frame ID rejection filter.
FIDRFVALB
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 0 0 0
FIDRFMSKA/FIDRFMSKB
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 26-66. Receive FIFO Frame ID Rejection Filter Mask Register (FR_RFFIDRFMR)
This register defines the filter mask for the frame ID rejection filter of the selected FIFO. For details on
frame ID filtering see Section 26.6.9.9, “FIFO Filtering”.
Table 26-74. FR_RFFIDRFMR Field Descriptions
Field Description
FIDRFMSK Frame ID Rejection Filter Mask — Filter mask for the frame ID rejection filter.
Base + 0x0098 16-bit write access required Write: WMD, IBD, SEL: Any Time
SID: POC:config
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0
IBD SEL SIDA/SIDB
W WMD
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
This register provides access to the four internal frame ID range filter boundary registers of the selected
FIFO. For details on frame ID range filter see Section 26.6.9.9, “FIFO Filtering”.
Table 26-75. FR_RFRFCFR Field Descriptions
Field Description
WMD Write Mode — This control bit defines the write mode of this register.
0 Write to all fields in this register on write access.
1 Write to SEL and IBD field only on write access.
IBD Interval Boundary — This control bit selects the interval boundary to be programmed with the SID value.
0 program lower interval boundary
1 program upper interval boundary
Field Description
SEL Filter Selector — This control field selects the frame ID range filter to be accessed.
00 select frame ID range filter 0.
01 select frame ID range filter 1.
10 select frame ID range filter 2.
11 select frame ID range filter 3.
SIDA Slot ID — Defines the IBD-selected frame ID boundary value for the SEL-selected range filter.
SIDB
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 0 0 0 0 0 0
F3MD F2MD F1MD F0MD F3EN F2EN F1EN F0EN
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
This register is used to enable and disable each frame ID range filter and to define whether it is running as
acceptance or rejection filter.
Table 26-76. FR_RFRFCTR Field Descriptions (Sheet 1 of 2)
Field Description
F3MD Range Filter 3 Mode — This control bit defines the filter mode of the frame ID range filter 3.
0 range filter 3 runs as acceptance filter
1 range filter 3 runs as rejection filter
F2MD Range Filter 2 Mode — This control bit defines the filter mode of the frame ID range filter 2.
0 range filter 2 runs as acceptance filter
1 range filter 2 runs as rejection filter
F1MD Range Filter 1 Mode — This control bit defines the filter mode of the frame ID range filter 1.
0 range filter 1 runs as acceptance filter
1 range filter 1 runs as rejection filter
F0MD Range Filter 0 Mode — This control bit defines the filter mode of the frame ID range filter 0.
0 range filter 0 runs as acceptance filter
1 range filter 0 runs as rejection filter
F3EN Range Filter 3 Enable — This control bit is used to enable and disable the frame ID range filter 3.
0 range filter 3 disabled
1 range filter 3 enabled
F2EN Range Filter 2 Enable — This control bit is used to enable and disable the frame ID range filter 2.
0 range filter 2 disabled
1 range filter 2 enabled
Field Description
F1EN Range Filter 1 Enable — This control bit is used to enable and disable the frame ID range filter 1.
0 range filter 1 disabled
1 range filter 1 enabled
F0EN Range Filter 0 Enable — This control bit is used to enable and disable the frame ID range filter 0.
0 range filter 0 disabled
1 range filter 0 enabled
Base + 0x009C
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 0 0 0 LASTDYNTXSLOTA
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
This register provides the number of the last transmission slot in the dynamic segment for channel A. This
register is updated after the end of the dynamic segment and before the start of the next communication
cycle.
Table 26-77. FR_LDTXSLAR Field Descriptions
Field Description
LASTDYNTX Last Dynamic Transmission Slot Channel A — protocol related variable: zLastDynTxSlot channel A
SLOTA Number of the last transmission slot in the dynamic segment for channel A. If no frame was transmitted during
the dynamic segment on channel A, the value of this field is set to 0.
Base + 0x009E
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 0 0 0 LASTDYNTXSLOTB
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
This register provides the number of the last transmission slot in the dynamic segment for channel B. This
register is updated after the end of the dynamic segment and before the start of the next communication
cycle.
Field Description
LASTDYNTX Last Dynamic Transmission Slot Channel B — protocol related variable: zLastDynTxSlot channel B
SLOTB Number of the last transmission slot in the dynamic segment for channel B. If no frame was transmitted during
the dynamic segment on channel B the value of this field is set to 0.
0 A
1 B
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R
action_point_offset static_slot_length
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0
macro_after_first_static_slot
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R
minislot_after_action_point number_of_static_slots
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R
wakeup_symbol_rx_low minislot_action_point_offset[4:0] coldstart_attempts
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R
cas_rx_low_max wakeup_symbol_rx_window
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R
tss_transmitter wakeup_symbol_tx_low wakeup_symbol_rx_idle
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0
symbol_window_after_action_point macro_initial_offset_a
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R
decoding_correction_b micro_per_macro_nom_half
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R max_without_clock_ max_without_clock_
wakeup_symbol_tx_idle
W correction_fatal correction_passive
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R sym
mini bol_
slot_ win offset_correction_out
exists dow_
W exists
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R single wake
_slot up_
macro_per_cycle
_en chan
W abled nel
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R key_
key_
slot_
slot_
used_
used_ offset_correction_start
for_
W start for_
sync
up
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R
allow_passive_to_active key_slot_header_crc
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R
first_minislot_action_point_offset static_slot_after_action_point
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R
rate_correction_out listen_timeout[20:16]
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R
listen_timeout[15:0]
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R
macro_initial_offset_b noise_listen_timeout[24:16]
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R
noise_listen_timeout[15:0]
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R
wakeup_pattern key_slot_id
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R
decoding_correction_a payload_length_static
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R
micro_initial_offset_b micro_initial_offset_a
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R extern_rate_
latest_tx
W correction
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R
R* comp_accepted_startup_range_a micro_per_cycle[19:16
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R
micro_per_cycle[15:0]
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R micro_per_cycle_min
cluster_drift_damping max_payload_length_dynamic
W [19:16]
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R
micro_per_cycle_min[15:0]
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R allow
_halt_
micro_per_cycle_max
due comp_accepted_startup_range_b
W _to_ [19:16]
clock
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R
micro_per_cycle_max[15:0]
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R dynamic_slot
macro_after_offset_correction
W _idle_phase
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R extern_offset_
minislots_max
W correction
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 0 0 0 0 0 0 0 0 0 0
sync_node_max
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
DRNE_OF
DRCE_OF
LRNE_OF
LRCE_OF
DRNE_IF
DRCE_IF
LRNE_IF
LRCE_IF
R
DRNE_IE
DRCE_IE
LRNE_IE
LRCE_IE
0
0
W w1c w1c w1c w1c w1c w1c w1c w1c
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 26-102. ECC Error Interrupt Flag and Enable Register (FR_EEIFER)
This register provides the means to control the ECC related interrupt request lines and provides the
corresponding interrupt flags. The interrupt flags are cleared by writing 1, which resets the corresponding
report registers. For a detailed description see Section 26.6.24.2, “Memory Error Reporting”.
Table 26-81. FR_EEIFER Field Descriptions
Field Description
LRNE_OF LRAM Non-Corrected Error Overflow Flag — This flag is set to 1 when at least one of the following events
appears:
a) memory errors are detected but not corrected on CHI LRAM and interrupt flag LRNE_IF is already 1.
b) memory errors are detected but not corrected on at least two banks of CHI LRAM
0 no such event
1 Non-Corrected Error overflow detected on CHI LRAM
LRCE_OF LRAM Corrected Error Overflow Flag — This flag is set to 1 when at least one of the following events
appears:
a) memory errors are detected and corrected on CHI LRAM and interrupt flag LRCE_IF is already 1.
b) memory errors are detected and corrected on at least two banks of CHI LRAM
0 no such event
1 Corrected Error overflow detected on CHI LRAM
Note: Error Correction not implemented on CHI LRAM, flag will never be asserted.
DRNE_OF DRAM Non-Corrected Error Overflow Flag — This flag is set to 1 when at least one of the following events
appears:
a) memory errors are detected but not corrected on PE DRAM and interrupt flag DRNE_IF is already 1.
b) memory errors are detected but not corrected on at least two banks of the PE DRAM
0 no such event
1 Non-Corrected Error overflow detected on PE DRAM
DRCE_OF DRAM Corrected Error Overflow Flag — This flag is set to 1 when at least one of the following events
appears:
a) memory errors are detected and corrected on PE DRAM and interrupt flag DRCE_IF is already 1.
b) memory errors are detected and corrected on at least two banks of PE DRAM
0 no such event
1 Corrected Error overflow detected on PE DRAM
Field Description
LRNE_IF LRAM Non-Corrected Error Interrupt Flag — This interrupt flag is set to 1 when a memory error is detected
but not corrected on the CHI LRAM.
0 no such event
1 Non-Corrected Error detected on CHI LRAM
LRCE_IF LRAM Corrected Error Interrupt Flag — This interrupt flag is set to 1 when a memory error is detected and
corrected on the CHI LRAM.
0 no such event
1 Corrected Error detected on CHI LRAM
Note: Error Correction not implemented on CHI LRAM, flag will never be asserted.
DRNE_IF DRAM Non-Corrected Error Interrupt Flag — This interrupt flag is set to 1 when a memory error is detected
but not corrected on PE DRAM.
0 no such event
1 Non-Corrected Error detected on PE DRAM
DRCE_IF DRAM Corrected Error Interrupt Flag — This interrupt flag is set to 1 when a memory error is detected and
corrected on PE DRAM.
0 no such event
1 Corrected Error detected on PE DRAM
LRNE_IE LRAM Non-Corrected Error Interrupt Enable — This flag controls if the LRAM Non-Corrected Error
Interrupt line is asserted when the LRNE_IF flag is set.
0 Disable interrupt line
1 Enable interrupt line
LRCE_IE LRAM Corrected Error Interrupt Enable — This flag controls if the LRAM Corrected Error Interrupt line is
asserted when the LRCE_IF flag is set.
0 Disable interrupt line
1 Enable interrupt line
DRNE_IE DRAM Non-Corrected Error Interrupt Enable — This flag controls if the DRAM Non-Corrected Error
Interrupt line is asserted when the DRNE_IF flag is set.
0 Disable interrupt line
1 Enable interrupt line
DRCE_IE DRAM Corrected Error Interrupt Enable — This flag controls if the DRAM Corrected Error Interrupt line is
asserted when the DRCE_IF flag is set.
0 Disable interrupt line
1 Enable interrupt line
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R BSY 0 0 0 0 0 0 0 0 0 0
ERS ERM EIM EIE
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 26-103. ECC Error Report and Injection Control Register (FR_EERICR)
This register configures the error injection and error reporting and provides the selector for the content of
the report registers.
Table 26-82. FR_EERICR Field Descriptions
Field Description
BSY Register Update Busy— This field indicates the current state of the ECC configuration update and controls
the register write access condition IDL specified in “Section 26.5.2.2, “Register Write Access”
0 ECC configuration is idle
1 ECC configuration is running
ERS Error Report Select — This field selects the content of the ECC Error reporting registers.
00 show PE DRAM non-corrected error information
01 show PE DRAM corrected error information
10 show CHI LRAM non-corrected error information
11 show CHI LRAM corrected error information
ERM Error Report Mode — This bit configures the type of data written into the internal error report registers on
the detection of a memory error.
0 store data and code as delivered by ecc decoding logic.
1 store data and code as read from the memory.
EIM Error Injection Mode — This bit configures the ECC error injection mode.
0 use FR_EEIDR[DATA] and FR_EEICR[CODE] as XOR distortion pattern for error injection.
1 use FR_EEIDR[DATA] and FR_EEICR[CODE] as write value for error injection.
EIE Error Injection Enable — This bit configures the ECC error injection on the memories.
0 Error injection disabled
1 Error injection enabled
Base + 0x00F4
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
Reset 0 1 1 1 0 0 0 0 0 0 0 0 0 0 0 0
This register provides the memory identifier, bank, and address for which the memory error is reported.
Field Description
MID Memory Identifier — This flag provides the memory instance for which the memory error is reported.
0 PE DRAM
1 CHI LRAM
BANK Memory Bank — This field provides the BANK for which the memory error is reported.
111 reset value, indicates no error found after reset.
For MID=0:
000 PE DRAM [7:0]
001 PE DRAM [15:8]
others - not used
For MID=1: Refer to Table 26-84 for the assignment of the LRAM banks.
ADDR Memory Address — This field provides the address of the failing memory location.
BANK Register
111
Base + 0x00F6
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R DATA
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
This register provides the data related information of the reported memory read access. The assignment of
the bits depends on the selected memory and memory bank as shown in Table 26-86.
Field Description
DATA Data — The content of this field depends on the report mode selected by FR_EERICR[ERM]
ERM=0: Ecc Data, shows data as generated by the ecc decoding logic.
ERM=1: Memory Data, shows data as read from the memory.
MEM BANK 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
PE DRAM 0 PE DRAM[7:0]
PE DRAM 1 PE DRAM[15:8]
Base + 0x00F8
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 0 0 0 0 0 0 0 0 0 CODE
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
This register provides the ecc related information of the reported memory read access.
Table 26-87. FR_EERSR Field Descriptions
Field Description
CODE Code — The content of this field depends on the report mode selected by FR_EERICR[ERM]
ERM=0: Syndrome. Shows the ecc syndrome generated by the ecc decoding logic.
The coding of the PE DRAM syndrome is shown in Section 26.6.24.2.2, “PE DRAM Syndrome”
The coding of the CHI LRAM syndrome is shown in Section 26.6.24.2.4, “CHI LRAM Syndrome”.
ERM=1: Checkbits. Shows the ecc checkbits read from the memory.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R
MID BANK ADDR
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
This register defines the memory module, bank, and address where the ECC error has to be injected.
Table 26-88. FR_EEIAR Field Descriptions
Field Description
MID Memory Identifier — This flag defines the memory instance for ECC error injection.
0 PE DRAM
1 CHI LRAM
BANK Memory Bank — This field defines the memory bank for ECC error injection.
For MID=0:
000 BANK0: PE DRAM [7:0]
001 BANK1: PE DRAM [15:8]
others reserved
For MID=1: Refer to Table 26-84 for the assignment of the LRAM banks.
ADDR Memory Address — This flag defines the memory address for ECC error injection.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R
DATA
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
This register defines the data distortion pattern for the error injection write. The number of valid bits
depends on the selected memory and memory bank as shown in Table 26-86.
Table 26-89. FR_EEIDR Field Descriptions
Field Description
DATA Data — The content of this field depends on the error injection mode selected by FR_EERICR[EIM].
EIM=0: This field defines the XOR distortion pattern for the data written into the memory.
EIM=1: This field defines the data to be written into the memory.
NOTE
The effect of the error injected depends from the LRAM content at the
address accessed and from the module internal usage of the data. Refer to
Section 26.6.24.3, “Memory Error Response” for details.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 0 0 0 0 0 0 0 0 0
CODE
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
This register defines the ecc code distortion pattern for the error injection write.
Table 26-90. FR_EEICR Field Descriptions
Field Description
CODE Code — The content of this field depends on the error injection mode selected by FR_EERICR[EIM].
EIM=0: This field defines the XOR distortion pattern for the ecc checkbits written into the memory.
EIM=1: This field defines the ecc checkbits written into the memory.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
The content of these registers comprises message buffer configuration data, message buffer control data,
message buffer status information, and message buffer interrupt flags. A detailed description of all flags
can be found in Section 26.6.6, “Individual Message Buffer Functional Description”
If the application writes 1 to the EDT bit, no write access to the other register bits is performed.
If the application writes 0 to the EDT bit and 1 to the LCKT bit, no write access to the other bits is
performed.
Table 26-91. FR_MBCCSRn Field Descriptions (Sheet 1 of 2)
Field Description
MTD Message Buffer Transfer Direction — This bit configures the transfer direction of a message buffer.
0 Receive message buffer
1 Transmit message buffer
CMT Commit for Transmission — This bit indicates if the transmit message buffer data are ready for transmission.
0 Message buffer data not ready for transmission
1 Message buffer data ready for transmission
EDT Enable/Disable Trigger — If the application writes 1 to this bit, a message buffer enable or disable is triggered,
depending on the current value of the EDS status bit.
0 No effect
1 Message buffer enable or disable is triggered
LCKT Lock/Unlock Trigger — If the application writes 1 to this bit and writes 0 to the EDT bit, a message buffer lock
or unlock is triggered, depending on the current value of the LCKS status bit.
0 No effect
1 Message buffer lock or unlock is triggered
MBIE Message Buffer Interrupt Enable — This control bit defines whether the message buffer will generate an
interrupt request when its MBIF flag is set.
0 Interrupt request generation disabled
1 Interrupt request generation enabled
Field Description
DUP Data Updated — This status bit indicates whether the frame header in the message buffer header field and the
data in the message buffer data field were updated after a frame reception.
0 Frame Header and Message buffer data field not updated
1 Frame Header and Message buffer data field updated
DVAL Data Valid — For receive message buffers this status bit indicates whether the message buffer data field
contains valid frame data. For transmit message buffers the status bit indicates if a message is transferred again
due to the state transmission mode of the message buffer.
0 receive message buffer contains no valid frame data / message is transmitted for the first time
1 receive message buffer contains valid frame data / message will be transferred again
EDS Enable/Disable Status — This status bit indicates whether the message buffer is enabled or disabled.
0 Message buffer is disabled.
1 Message buffer is enabled.
LCKS Lock Status — This status bit indicates the current lock status of the message buffer.
0 Message buffer is not locked by the application.
1 Message buffer is locked by the application.
MBIF Message Buffer Interrupt Flag — This flag is set when the slot status field of the message buffer was updated
after frame transmission or reception, or when a transmit message buffer was just enabled by the application.
0 No such event
1 Slot status field updated or transmit message buffer just enabled
Base + 0x0802 (FR_MBCCFR0) 16-bit write access required Write: POC:config or MB_DIS
Base + 0x080A (FR_MBCCFR1)
...
Base + 0x0BFA (FR_MBCCFR127)
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R
MTM CHA CHB CCFE CCFMSK CCFVAL
W
Reset - - - - - - - - - - - - - - - -
This register contains message buffer configuration data for the transmission mode, the channel
assignment, and for the cycle counter filtering. For detailed information on cycle counter filtering, refer to
Section 26.6.7.1, “Message Buffer Cycle Counter Filtering”.
Field Description
MTM Message Buffer Transmission Mode — This control bit applies only to transmit message buffers and defines
the transmission mode.
0 Event transmission mode
1 State transmission mode
CHA Channel Assignment — These control bits define the channel assignment and control the receive and transmit
CHB behavior of the message buffer according to Table 26-93.
CCFE Cycle Counter Filtering Enable — This control bit is used to enable and disable the cycle counter filtering.
0 Cycle counter filtering disabled
1 Cycle counter filtering enabled
CCFMSK Cycle Counter Filtering Mask — This field defines the filter mask for the cycle counter filtering.
CCFVAL Cycle Counter Filtering Value — This field defines the filter value for the cycle counter filtering.
NOTE
If at least one message buffer assigned to a certain slot is assigned to both
channels, then all message buffers assigned to this slot have to be assigned
to both channels. Otherwise, the message buffer configuration is illegal and
the result of the message buffer search is not defined.
Base + 0x0804 (FR_MBFIDR0) 16-bit write access required Write: POC:config or MB_DIS
Base + 0x080C (FR_MBFIDR1)
...
Base + 0x0BFC (FR_MBFIDR127)
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 0 0 0
FID
W
Reset 0 0 0 0 0 - - - - - - - - - - -
Field Description
FID Frame ID — The semantic of this field depends on the message buffer transfer type.
• Receive Message Buffer: This field is used as a filter value to determine if the message buffer is used for
reception of a message received in a slot with the slot ID equal to FID.
• Transmit Message Buffer: This field is used to determine the slot in which the message in this message buffer
should be transmitted.
Base + 0x0806 (FR_MBIDXR0) 16-bit write access required Write: POC:config or MB_DIS
Base + 0x080E (FR_MBIDXR1)
...
Base + 0x0BFE (FR_MBIDXR127)
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 0 0 0 0 0 0
MBIDX
W
Reset 0 0 0 0 0 0 0 0 - - - - - - - -
Field Description
MBIDX Message Buffer Index — This field provides the index of the message buffer header field of the physical
message buffer that is currently associated with this message buffer.
The application writes the index of the initially associated message buffer header field into this register. The CC
updates this register after frame reception or transmission. Legal Values are 0 <= i <= 131. Illegal values will be
detected during the message buffer search.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R
MBDO
W
Reset - - - - - - - - - - - - - - - -
Field Description
MBDO Message Buffer Data Field Offset — This field provides the data field offset belonging to a particular Message
Buffer Index. For configuration constraints see Section 26.7.1.2, “Configure Data Field Offsets”.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R
LEETD
W
Reset - - - - - - - - - - - - - - - -
Field Description
LEETD LRAM ECC Error Test Data — This field contains the LRAM data belonging to the test register located in LRAM
Bank n.
SADR_MBDF
FlexRay Memory Area
Frame Data
SADR_MBHF
Frame Header Slot Status
Specification, Version 2.1 Rev A. A detailed description of the usage and the content of the frame header
is provided in Section 26.6.5.2.1, “Frame Header Description”.
(FR_MBIDXRn). The start address SADR_MBHF of the related message buffer header field in the flexray
memory area is determined according to Equation 1.
The data field belonging to a particular physical message buffer is characterized by the data field offset.
For each physical message buffer with MBIDX i the FR_MBDORi contains the offset of the
corresponding message buffer data field with respect to the CC flexray memory area base address as
provided by SMBA field in the System Memory Base Address Register (FR_SYMBADR)”.
The data field offset is used to determine the start address SADR_MBDF of the corresponding message buffer
data field in the flexray memory area according to Equation 2.
The FR_MBDORn are stored in the module internal memory LRAM. Refer to Section 26.7.2.3, “CHI
LRAM Initialization” for the setup of the data field offset values.
(min) MBDSR[MBSEG1DS] * 2 bytes / MBDSR[MBSEG2DS] * 2 bytes
SADR_MBDF
FlexRay Memory Area
Frame Data
SADR_MBHF
Frame Header Slot Status
FR_MBDOR131
Message Buffer Control Registers
FR_MBDORi
...
FR_MBDOR0
• all physical message buffers associated to individual message buffers that belong to the same
message buffer segment must have message buffer data fields of the same length
• the minimum length of the message buffer data field for individual message buffers in the first
message buffer segment is 2 * FR_MBDSR[MBSEG1DS] bytes
• the minimum length of the message buffer data field for individual message buffers assigned to the
second segment is 2 * FR_MBDSR[MBSEG2DS] bytes.
The length required for the message buffer data field depends on the message buffer segment that the
receive shadow buffer is assigned to. For the receive shadow buffers assigned to the first message buffer
segment, the length must be the same as for the individual message buffers assigned to the first message
buffer segment. For the receive shadow buffers assigned to the second message buffer segment, the length
must be the same as for the individual message buffers assigned to the second message buffer segment.
The receive shadow buffer assignment is described in Receive Shadow Buffer Index Register
(FR_RSBIR).
Frame Data
SADR_MBHF
Frame Header Slot Status
RSBIDX[0]
RSBIDX[1]
RSBIDX[2]
RSBIDX[3] FR_MBDOR131
FR_MBDORi
...
FR_MBDOR0
The start byte address SADR_MBHF[n] of the last message buffer header field that belongs to the receive
FIFO in the flexray memory area is determined according to Equation 5.
The required information to access the current entry of the FIFO is given in the following registers:
• The registers Receive FIFO A Read Index Register (FR_RFARIR) and Receive FIFO B Read
Index Register (FR_RFBRIR) provide the index of the physical message buffer belonging to the
current entry.
The data field offset belonging to the current FIFO entry RF_DFO[X] must be calculated using the
current read index i according to the following formula:
NOTE
The current read index loops up starting at the number given in the
FR_RD[A/B]RDIDX register for the required number of entries.
Refer to Section 26.6.9.8, “FIFO Update” for details about updating the
FIFO read pointer.
All message buffer header fields assigned to a receive FIFO are within a
contiguous region defined by FR_RFSIR[SIDX] and
RFDSR[FIFO_DEPTH].
The data sections of all FIFO entries within on receive FIFO are of the same
length defined by RFDSR[FIFO_SIZE].
RFDSR[FIFO_DEPTH]
+ Frame Data[n]
SADR_MBDF[i]
Frame Data[i]
SADR_MBDF[1]
FlexRay Memory Area
Frame Data[1]
SADR_MBHF[n]
RFDSR[FIFO_DEPTH]
+ Frame Header[n] Slot Status[n]
SADR_MBHF[i]
Frame Header[i] Slot Status[i]
SADR_MBHF[1]
Frame Header[1] Slot Status[1]
NOTE
The actual values of the data field offsets RF_DFO[A/B] need to be
calculated according to Equation 6. They are not stored in a register.
System Memory
Receive FIFO B
Frame Header Slot Status
Frame Header Slot Status
Message Buffer Header Fields
Receive FIFO A
Frame Header Slot Status
Frame Header Slot Status
FR_SYMBADR[SMBA] 8 bytes
Area
System Memory
FR_RFSYMBADR[SMBA]
FR_SYMBADR[SMBA] 8 bytes
2. The start byte address SADR_MBHF of each message buffer header field for the FIFO must fulfill
Equation 8.
3. The message buffer header fields for each FIFO have to be a contiguous area.
2. The message buffer header fields for each FIFO have to be a contiguous area.
Figure 26-122. Frame Header Structure (Receive Message Buffer and Receive FIFO)
The structure of the frame header in the message buffer header field for transmit message buffers is given
in Figure 26-123. A detailed description is given in Table 26-100. The checks that will be performed are
described in Frame Header Checks.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
0x0 R PPI NUF SYF SUF FID
0x2 CYCCNT PLDLEN
0x4 HDCRC
The structure of the frame header in the message buffer header field for transmit message buffers assigned
to key slot is given in Figure 26-124.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
0x0 R PPI NUF SYF SUF FID
0x2 CYCCNT PLDLEN
0x4 HDCRC
= not used
Figure 26-124. Frame Header Structure (Transmit Message Buffer for Key Slot)
For transmit message buffers assigned to the dynamic segment, the PLDLEN value must be less than or
equal to the value of the max_payload_length_dynamic field in the Protocol Configuration Register 24
(FR_PCR24). If this is not fulfilled, the dynamic payload length error flag DPL_EF in the CHI Error Flag
Register (FR_CHIERFR) is set when the message buffer is under transmission. A syntactically and
semantically correct dynamic frame is generated with PLDLEN payload words and the payload length
field in the frame header set to PLDLEN.
Table 26-99. Frame Header Field Descriptions (Receive Message Buffer and Receive FFO)
Field Description
R Reserved Bit — This is the value of the Reserved bit of the received frame stored in the message buffer
PPI Payload Preamble Indicator — This is the value of the Payload Preamble Indicator of the received frame stored
in the message buffer.
NUF Null Frame Indicator — This is the value of the Null Frame Indicator of the received frame stored in the message
buffer.
SYF Sync Frame Indicator — This is the value of the Sync Frame Indicator of the received frame stored in the
message buffer.
SUF Startup Frame Indicator — This is the value of the Startup Frame Indicator of the received frame stored in the
message buffer.
FID Frame ID — This is the value of the Frame ID field of the received frame stored in the message buffer.
CYCCNT Cycle Count — This is the number of the communication cycle in which the frame stored in the message buffer
was received.
PLDLEN Payload Length — This is the value of the Payload Length field of the received frame stored in the message
buffer.
HDCRC Header CRC — This is the value of the Header CRC field of the received frame stored in the message buffer.
Field Description
R Reserved Bit — This bit is not used, the value of the Reserved bit is generated internally according to FlexRay
Communications System Protocol Specification, Version 2.1 Rev A.
PPI Payload Preamble Indicator — This bit provides the value of the Payload Preamble Indicator for the frame
transmitted from the message buffer.
NUF Null Frame Indicator — This bit is not used, the value of the Null Frame Indicator is generated internally
according to FlexRay Communications System Protocol Specification, Version 2.1 Rev A.
SYF Sync Frame Indicator — This bit is not used, the value of the Sync Frame Indicator is generated internally
according to FlexRay Communications System Protocol Specification, Version 2.1 Rev A.
SUF Startup Frame Indicator — This bit is not used, the value of the Startup Frame Indicator is generated internally
according to FlexRay Communications System Protocol Specification, Version 2.1 Rev A.
FID Frame ID — This field is checked as described in Frame Header Checks.
Field Description
CYCCNT Cycle Count — This field is not used, the value of the transmitted Cycle Count field is taken from the internal
communication cycle counter.
PLDLEN Payload Length — This field is checked and used as described in Frame Header Checks.
HDCRC Header CRC — This field provides the value of the Header CRC field for the frame transmitted from the message
buffer.
Individual Receive Message Buffer assigned to both channels see Figure 26-125
FR_MBCCFRn[CHA]=1 and FR_MBCCFRn[CHB]=1
The meaning of the bits in the slot status structure is explained in Table 26-102.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R VFB SYB NFB SUB SEB CEB BVB CH VFA SYA NFA SUA SEA CEA BVA 0
Reset – – – – – – – – – – – – – – – –
Figure 26-125. Receive Message Buffer Slot Status Structure (ChAB)
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 0 0 0 0 0 0 VFA SYA NFA SUA SEA CEA BVA 0
Reset – – – – – – – – – – – – – – – –
Figure 26-126. Receive Message Buffer Slot Status Structure (ChA)
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R VFB SYB NFB SUB SEB CEB BVB 1 0 0 0 0 0 0 0 0
Reset – – – – – – – – – – – – – – – –
Figure 26-127. Receive Message Buffer Slot Status Structure (ChB)
Field Description
SYB Sync Frame Indicator Channel B — protocol related variable: vRF!Header!SyFIndicator channel B
0 vRF!Header!SyFIndicator = 0
1 vRF!Header!SyFIndicator = 1
NFB Null Frame Indicator Channel B — protocol related variable: vRF!Header!NFIndicator channel B
0 vRF!Header!NFIndicator = 0
1 vRF!Header!NFIndicator = 1
SUB Startup Frame Indicator Channel B — protocol related variable: vRF!Header!SuFIndicator channel B
0 vRF!Header!SuFIndicator = 0
1 vRF!Header!SuFIndicator = 1
CH Channel first valid received — This status bit applies only to receive message buffers assigned to the static
segment and to both channels. It indicates the channel that has received the first valid frame in the slot. This flag
is set to 0 if no valid frame was received at all in the subscribed slot.
0 first valid frame received on channel A, or no valid frame received at all
1 first valid frame received on channel B
NFA Null Frame Indicator Channel A — protocol related variable: vRF!Header!NFIndicator channel A
0 vRF!Header!NFIndicator = 0
1 vRF!Header!NFIndicator = 1
Field Description
SUA Startup Frame Indicator Channel A — protocol related variable: vRF!Header!SuFIndicator channel A
0 vRF!Header!SuFIndicator = 0
1 vRF!Header!SuFIndicator = 1
Individual Transmit Message Buffer assigned to both channels see Figure 26-128
FR_MBCCFRn[CHA]=1 and FR_MBCCFRn[CHB]=1
The meaning of the bits in the slot status structure is described in Table 26-102.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R VFB SYB NFB SUB SEB CEB BVB TCB VFA SYA NFA SUA SEA CEA BVA TCA
Reset – – – – – – – – – – – – – – – –
Figure 26-128. Transmit Message Buffer Slot Status Structure (ChAB)
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 0 0 0 0 0 0 VFA SYA NFA SUA SEA CEA BVA TCA
Reset – – – – – – – – – – – – – – – –
Figure 26-129. Transmit Message Buffer Slot Status Structure (ChA)
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R VFB SYB NFB SUB SEB CEB BVB TCB 0 0 0 0 0 0 0 0
Reset – – – – – – – – – – – – – – – –
Figure 26-130. Transmit Message Buffer Slot Status Structure (ChB)
Table 26-104. Transmit Message Buffer Slot Status Structure Field Descriptions
Field Description
SYB Sync Frame Indicator Channel B — protocol related variable: vRF!Header!SyFIndicator channel B
0 vRF!Header!SyFIndicator = 0
1 vRF!Header!SyFIndicator = 1
NFB Null Frame Indicator Channel B — protocol related variable: vRF!Header!NFIndicator channel B
0 vRF!Header!NFIndicator = 0
1 vRF!Header!NFIndicator = 1
SUB Startup Frame Indicator Channel B — protocol related variable: vRF!Header!SuFIndicator channel B
0 vRF!Header!SuFIndicator = 0
1 vRF!Header!SuFIndicator = 1
SYA Sync Frame Indicator Channel A — protocol related variable: vRF!Header!SyFIndicator channel A
0 vRF!Header!SyFIndicator = 0
1 vRF!Header!SyFIndicator = 1
NFA Null Frame Indicator Channel A — protocol related variable: vRF!Header!NFIndicator channel A
0 vRF!Header!NFIndicator = 0
1 vRF!Header!NFIndicator = 1
SUA Startup Frame Indicator Channel A — protocol related variable: vRF!Header!SuFIndicator channel A
0 vRF!Header!SuFIndicator = 0
1 vRF!Header!SuFIndicator = 1
Table 26-104. Transmit Message Buffer Slot Status Structure Field Descriptions
Field Description
NOTE
The CC will not access any locations outside the message buffer data field
boundaries given by Table 26-105.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
0x0 DATA0 / MID0 / NMV0 DATA1 / MID1 / NMV1
0x2 DATA2 / NMV2 DATA3 / NMV3
... ... ...
0xN-2 DATA N-2 DATA N-1
The message buffer data field is located in the flexray memory area; thus, the CC has no means to control
application write access to the field. To ensure data consistency, the application must follow a write and
read access scheme.
Field Description
MID 0, Message Identifier — If the payload preamble bit PPI is set in the message buffer frame header, the MID field
MID 1 holds the message ID of a dynamic frame located in the message buffer. The receive FIFO filter uses the received
message ID for message ID filtering.
NMV 0, Network Management Vector — If the payload preamble bit PPI is set in the message buffer frame header, the
NMV 1, network management vector field holds the network management vector of a static frame located in the message
... buffer.
NMV 11 Note: The MID and NMV bytes replace the corresponding DATA bytes.
Before an individual message buffer can be used, it must be configured by the application. After the initial
configuration, the message buffer can be reconfigured later. The set of the configuration data for individual
message buffers is given in Section 26.6.3.4.1, “Individual Message Buffer Configuration Data”.
FR_MBCCSRn
Individual Message Buffer Description
MTD MBT
0 0 Receive Message Buffer
0 1 Reserved
FR_MBCCSRn
Individual Message Buffer Description
MTD MBT
1 0 Transmit Message Buffer
1 1 Reserved
FR_MBCCSRn[CMT] CMT
MSG
Message Buffer Data Field: DATA[0-N]
FR_MBCCFRn[MTM/CHA/CHB/CCF*] SR
FR_MBFIDRn[FID]
Access from
Region Region used for
Application Module
CFG read/write - Message Buffer Configuration
MSG read/write - Message Data and Slot Status Access
NF - read-only Message Header Access for Null Frame Transmission
TX - read/write Message Transmission and Slot Status Update
CM - read-only Message Buffer Validation
SR - read-only Message Buffer Search
The trigger bits FR_MBCCSRn[EDT] and FR_MBCCSRn[LCKT], and the interrupt enable bit
FR_MBCCSRn[MBIE] are not under access control and can be accessed from the application at any time.
The status bits FR_MBCCSRn[EDS] and FR_MBCCSRn[LCKS] are not under access control and can be
accessed from the CC at any time.
The interrupt flag FR_MBCCSRn[MBIF] is not under access control and can be accessed from the
application and the CC at any time. CC clear access has higher priority.
The CC restricts its access to the regions depending on the current state of the message buffer. The
application must adhere to these restrictions in order to ensure data consistency. The transmit message
buffer states are given in Figure 26-133. A description of the states is given in Table 26-110, which also
provides the access scheme for the access regions.
The status bits FR_MBCCSRn[EDS] and FR_MBCCSRn[LCKS] provide the application with the
required message buffer status information. The internal status information is not visible to the application.
RESET_STATE
HD
SU
HDis Idle CCSu
HE DSS
HL HL SA
HU HU DSS SSS
DSS
Application Transitions
The application transitions can be triggered by the application using the commands described in
Table 26-111. The application issues the commands by writing to the Message Buffer Configuration,
Control, Status Registers (FR_MBCCSRn). Only one command can be issued with one write access. Each
command is executed immediately. If the command is ignored, it must be issued again.
Message Buffer Enable and Disable
The enable and disable commands issued by writing 1 to the trigger bit FR_MBCCSRn[EDT]. The
transition that will be triggered by each of these command depends on the current value of the status bit
FR_MBCCSRn[EDS]. If the command triggers the disable transition HD and the message buffer is in one
of the states CCSa, HLckCCSa, CCMa, HLckCCMa, CCNf, HLckCCNf, or CCTx, the disable transition
has no effect (command is ignored) and the message buffer state is not changed. No notification is given
to the application.
If the communication controller is started as a non-coldstart node, and the message buffers are configured
and enabled in the POC config state for Slot 1, then the message buffer cannot be disabled in the
INTEGRATION_LISTEN state by directly writing 1 to the EDT bit. To facilitate this, a FREEZE
command needs to be issued just before running the message buffer disable for slot 1. Executing this
command enables the message buffer disable during the LISTEN states.
Message Buffer Lock and Unlock
The lock and unlock commands issued by writing 1 to the trigger bit FR_MBCCSRn[LCKT]. The
transition that will be triggered by each of these commands depends on the current value of the status bit
FR_MBCCSRn[LCKS]. If the command triggers the lock transition HL and the message buffer is in the
state CCTx, the lock transition has no effect (command is ignored) and message buffer state is not changed.
In this case, the message buffer lock error flag LCK_EF in the CHI Error Flag Register (FR_CHIERFR)
is set.
Table 26-111. Transmit Message Buffer Application Transitions
Module Transitions
The module transitions that can be triggered by the CC are described in Table 26-112. Each transition will
be triggered for certain message buffers when the related condition is fulfilled.
Table 26-112. Transmit Message Buffer Module Transitions
dynamic slot start or Dynamic Slot or Segment Start. - Start of dynamic slot or symbol window or NIT.
DSS symbol window start or
NIT start
slot start or Slot or Segment Start - Start of static slot or dynamic slot or symbol window or
SSS symbol window start or NIT.
NIT start
Transition Priorities
The application can trigger only one transition at a time. There is no need to specify priorities among them.
As shown in the first part of Table 26-113, the module transitions have a higher priority than the
application transitions. For all states except the CCMa state, both a lock/unlock transition HL/HD and a
module transition can be executed at the same time. The result state is reached by first applying the
application transition and subsequently the module transition to the intermediately reached state. For
example, if the message buffer is in the HLck state and the application unlocks the message buffer by the
HU transition and the module triggers the slot assigned transition SA, the intermediate state is Idle and the
resulting state is CCSa.
The priorities among the module transitions is given in the second part of Table 26-113.
Table 26-113. Transmit Message Buffer Transition Priorities
MA TX SSS SU
Idle CCMa CCTx CCSu Idle
rt
slot start
slot start
slot start
sta
MT
MA HU TX SSS
HLck HLckCCMa CCMa CCTx Idle
rt
slot start
sta
slot start
slot start
MT
search[s+1] message transmit
slot s slot s+1 slot s+2
The amount of message data read from the flexray memory area and transferred to the FlexRay bus is
determined by the following three items
1. the message buffer segment that the message buffer is assigned to, as defined by the Message
Buffer Segment Size and Utilization Register (FR_MBSSUTR).
2. the message buffer data field size, as defined by the related field of the Message Buffer Data Size
Register (FR_MBDSR)
3. the value of the PLDLEN field in the message buffer header field, as described in
Section 26.6.5.2.1, “Frame Header Description”
If a message buffer is assigned to message buffer segment 1, and PLDLEN > MBSEG1DS, then
2 * MBSEG1DS bytes will be read from the message buffer data field and zero padding is used for the
remaining bytes for the FlexRay bus transfer. If PLDLEN <= MBSEG1DS, the CC reads and transfers
2*PLDLEN bytes. The same holds for segment 2 and MBSEG2DS.
SA STS SSS
Idle CCSa CCNf Idle
rt
sta
slot start
slot start
slot start
MT
search[s+1] null frame transmit
slot s slot s+1 slot s+2
A message buffer timing and state change diagram for null frame transmission from HLck state is given
in Figure 26-137.
SA STS SSS
HLck HLckCCSa HLckCCNf HLck
rt
slot start
slot start
slot start
sta
MT
search[s+1] null frame transmit
slot s slot s+1 slot s+2
If a transmit message buffer is in the CCSa or HLckCCSa state at the start of the transmission slot, a null
frame is transmitted in any case, even if the message buffer is unlocked or committed before the
transmission slot starts. A transmit message buffer timing and state change diagram for null frame
transmission for this case is given in Figure 26-138.
SA HU STS SSS
HLck HLckCCSa CCSa CCNf Idle
rt
slot start
sta
slot start
slot start
MT
search[s+1] null frame transmit
slot s slot s+1 slot s+2
Figure 26-138. Null Frame Transmission from HLck state with unlock
Since the null frame transmission will not use the message buffer data, the application can lock/unlock the
message buffer during null frame transmission. A transmit message buffer timing and state change
diagram for null frame transmission for this case is given in Figure 26-139.
SA STS HL SSS
Idle CCSa CCNf HLckCCNf HLck
rt
sta
slot start
slot start
slot start
MT
search[s+1] null frame transmit
slot s slot s+1 slot s+2
Figure 26-139. Null Frame Transmission from Idle state with locking
FR_MBIDXRn[MBIDX]
FR_MBCCSRn[DVAL/DUP]
FR_MBCCSRn[MTD]
FR_MBCCFRn[CHA/CHB/CCF*] SR
FR_MBFIDRn[FID]
Access from
Region Region used for
Application Module
CFG read/write - Message Buffer Configuration, Message Data and Status Access
MSG read/write - Message Data, Header, and Status Access
RX - write-only Message Reception and Status Update
SR - read-only Message Buffer Search Data
The trigger bits FR_MBCCSRn[EDT] and FR_MBCCSRn[LCKT] and the interrupt enable bit
FR_MBCCSRn[MBIE] are not under access control and can be accessed from the application at any time.
The status bits FR_MBCCSRn[EDS] and FR_MBCCSRn[LCKS] are not under access control and can be
accessed from the CC at any time.
The interrupt flag FR_MBCCSRn[MBIF] is not under access control and can be accessed from the
application and the CC at any time. CC set access has higher priority.
The CC restricts its access to the regions depending on the current state of the message buffer. The
application must adhere to these restrictions in order to ensure data consistency. The receive message
buffer states are given in Figure 26-141. A description of the message buffer states is given in
Table 26-110, which also provides the access scheme for the access regions.
The status bits FR_MBCCSRn[EDS] and FR_MBCCSRn[LCKS] provide the application with the
required status information. The internal status information is not visible to the application.
RESET_STATE
HD
SU
HDis Idle CCSu
HE
HL HL BS
HU HU SNS SSS
SLS
HDisLck CCBs CCRx
HE HL HL
HD HU HU
SNS
SLS
HLck HLckCCBs HLckCCRx
BS
SSS
Application Transitions
The application transitions that can be triggered by the application using the commands described in
Table 26-116. The application issues the commands by writing to the Message Buffer Configuration,
Control, Status Registers (FR_MBCCSRn). Only one command can be issued with one write access. Each
command is executed immediately. If the command is ignored, it must be issued again.
Message Buffer Enable and Disable
The enable and disable commands issued by writing 1 to the trigger bit FR_MBCCSRn[EDT]. The
transition that will be triggered by each of these command depends on the current value of the status bit
FR_MBCCSRn[EDS]. If the command triggers the disable transition HD and the message buffer is in one
of the states CCBs, HLckCCBs, or CCRx, the disable transition has no effect (command is ignored) and
the message buffer state is not changed. No notification is given to the application.
If the communication controller is started as a non-coldstart node, and the message buffers are configured
and enabled in the POC config state for Slot 1, then the message buffer cannot be disabled in the
INTEGRATION_LISTEN state by directly writing 1 to the EDT bit. To facilitate this, a FREEZE
command needs to be issued just before running the message buffer disable for slot 1. Executing this
command enables the message buffer disable during the LISTEN states.
Message Buffer Lock and Unlock
The lock and unlock commands issued by writing 1 to the trigger bit FR_MBCCSRn[LCKT]. The
transition that will be triggered by each of these commands depends on the current value of the status bit
FR_MBCCSRn[LCKS]. If the command triggers the lock transition HL while the message buffer is in the
state CCRx, the lock transition has no effect (command is ignored) and message buffer state is not
changed. In this case, the message buffer lock error flag LCK_EF in the CHI Error Flag Register
(FR_CHIERFR) is set.
Module Transitions
The module transitions that can be triggered by the CC are described in Table 26-117. Each transition will
be triggered for certain message buffers when the related condition is fulfilled.
Table 26-117. Receive Message Buffer Module Transitions
SNS symbol window start or Symbol Window or NIT Start - Start of either Symbol Window or NIT.
NIT start
SSS slot start or Slot or Segment Start - Start of either Static Slot, Dynamic Slot, Symbol Window,
symbol window start or or NIT.
NIT start
SU status updated Status Updated - Slot Status field, message buffer status flags, header index
updated. Interrupt flag set.
Transition Priorities
The application can trigger only one transition at a time. There is no need to specify priorities among them.
As shown in Table 26-118, the module transitions have a higher priority than the application transitions.
For all states except the CCRx state, a module transition and the application lock/unlock transition HL/HU
and can be executed at the same time. The result state is reached by first applying the module transition
and subsequently the application transition to the intermediately reached state. For example, if the message
buffer is in the buffer subscribed state CCBs and the module triggers the slot start transition SLS at the
same time as the application locks the message buffer by the HL transition, the intermediate state is CCRx
and the resulting state is locked buffer subscribed state HLckCCRx.
Table 26-118. Receive Message Buffer Transition Priorities
vRF!Header!NFIndicato
vSS!ValidFrame Update description
r
1 1 Valid non-null frame received.
- Message Buffer Data Field updated.
- Frame Header Field updated.
- Slot Status Field updated.
- DUP:= 1
- DVAL:= 1
- MBIF:= 1
vRF!Header!NFIndicato
vSS!ValidFrame Update description
r
1 0 Valid null frame received.
- Message Buffer Data Field not updated.
- Frame Header Field not updated.
- Slot Status Field updated.
- DUP:= 0
- DVAL not changed
- MBIF:= 1
0 x No valid frame received.
- Message Buffer Data Field not updated.
- Frame Header Field not updated.
- Slot Status Field updated.
- DUP:= 0
- DVAL not changed.
- MBIF:= 1, if the slot was not an empty dynamic slot.
Note: An empty dynamic slot is indicated by the following frame and slot
status bit values:
vSS!ValidFrame = 0 and vSS!SyntaxError = 0 and
vSS!ContentError = 0 and vSS!BViolation = 0.
NOTE
If the number of the last slot in the current communication cycle on a given
channel is n, then all receive message buffers assigned to this channel with
FR_MBFIDRn[FID] > n will not be updated at all.
When the receive message buffer update has finished the status updated transition SU is triggered, which
changes the buffer state from CCSu to Idle. An example receive message buffer timing and state change
diagram for a normal frame reception is given in Figure 26-142.
BS SLS SSS SU
Idle CCBs CCRx CCSu Idle
rt
slot start
sta
slot start
slot start
MT
The amount of message data written into the message buffer data field of the receive shadow buffer is
determined by the following two items:
1. the message buffer segment that the message buffer is assigned to, as defined by the Message
Buffer Segment Size and Utilization Register (FR_MBSSUTR).
2. the message buffer data field size, as defined by the related field of the Message Buffer Data Size
Register (FR_MBDSR)
3. the number of bytes received over the FlexRay bus
If the message buffer is assigned to the message buffer segment 1, and the number of received bytes is
greater than 2*FR_MBDSR.MBSEG1DS, the CC writes only 2*FR_MBDSR.MBSEG1DS bytes into the
message buffer data field of the receive shadow buffer. If the number of received bytes is less than
2*FR_MBDSR.MBSEG1DS, the CC writes only the received number of bytes and will not change the
trailing bytes in the message buffer data field of the receive shadow buffer. The same holds for the message
buffer segment 2 with FR_MBDSR.MBSEG2DS.
The message buffer search is a sequential algorithm which is invoked at the following protocol related
events:
1. NIT start
2. slot start in the static segment
3. minislot start in the dynamic segment
The message buffer search within the NIT searches for message buffers assigned or subscribed to slot 1.
The message buffer search within slot n searches for message buffers assigned or subscribed to slot n+1.
In general, the message buffer search for the next slot n considers only message buffers that are
• Enabled (FR_MBCCSRn[EDS] = 1) and
• Matches the next slot n (FR_MBFIDRn[FID] = n)
On top of that, for the static segment only those message buffers are considered, that match the condition
of at least one row of Table 26-120. For the dynamic segment only those message buffers are considered,
that match the condition of at least one row of Table 26-121. These message buffers are called matching
message buffers.
For each enabled channel the message buffer search may identify multiple matching message buffers.
Among all matching message buffers the message buffers with highest priority according to Table 26-120
for the static segment and according to Table 26-121 for the dynamic segment are selected.
Table 26-120. Message Buffer Search Priority (static segment)
(highest) 0 1 0 1 1 transmit buffer, matches cycle count, not locked and committed MA
2 1 - - - transmit buffer SA
(highest) 0 1 0 1 1 transmit buffer, matches cycle count, not locked and committed MA
If there are multiple message buffer with highest priority, the message buffer with the lowest message
buffer number is selected. All message buffer which have the highest priority must have a consistent
channel assignment as specified in Section 26.6.7.2, “Message Buffer Channel Assignment Consistency”.
Depending on the message buffer channel assignment the same message buffer can be found for both
channel A and channel B. In this case, this message buffer is used as described in Section 26.6.3.1,
“Individual Message Buffers”.
CYCCNT & MBCCFRn CCFMSK = MBCCFRn CCFVAL & MBCCFRn CCFMSK Eqn. 13
According to Table 26-121 the transmit buffer is only found if the cycle counter filter matches, and the
buffer is not locked and committed. In all other cases, the receive buffer will be found. Thus, if the block
has no data to transmit in a dynamic slot, it is able to receive frames on that slot.
1. The FIFO reception is not affected by the search errors. Additionally, if no rx buffer has been found due to an search error, the
received frame is considered for FIFO reception.
RC2 RC1
RC1 single RX single TX
26.6.9.1 Overview
The two receive FIFOs implement the queued message buffer concept defined by the FlexRay
Communications System Protocol Specification, Version 2.1 Rev A. One FIFO is assigned to channel A,
the other FIFO is assigned to channel B. Both FIFOs work completely independent from each other.
The message buffer structure of each FIFO is described in Section 26.6.3.3, “Receive FIFO”. The area in
the flexray memory area for each of the two FIFOs is characterized by:
• The FIFO system memory base address
• The index of the first FIFO entry given by Receive FIFO Start Index Register (FR_RFSIR)
• The data field offset of the data field belonging to the first FIFO entry given by Receive FIFO Start
Data Offset Register (FR_RFSDOR)
• The number of FIFO entries and the length of each FIFO entry as given by Receive FIFO Depth
and Size Register (RFDSR)
A message frame reception is directed into the FIFO, if no individual message buffer is assigned for
transmission or subscribed for reception for the current slot. In this case the FIFO filter path shown in
Figure 26-145 is activated.
If the FIFO filter path indicates that the received frame has to be appended to the FIFO and the FIFO is
not full, the CC writes the received frame header into the message buffer header field indicated by the CC
internal FIFO write index. The frame payload data are written into the corresponding message buffer data
field. If the status of the received frame indicates a valid non-null frame, the slot status information is
written into the message buffer header field and the CC internal FIFO write index is updated by 1 and the
FIFO fill level FLA (FLB) in the Receive FIFO Fill Level and POP Count Register (FR_RFFLPCR) is
incremented.If the status of the received frame indicates an invalid or null frame, the frame is not appended
to the FIFO.
described in Section 26.6.3.3, “Receive FIFO”. When the application has read the message buffer data and
status information, it can update the FIFO as described in Section 26.6.9.8, “FIFO Update”.
The CC provides three sets of FIFO filters. The FIFO filters are applied to valid non-null frames only. The
FIFO will not receive invalid or null-frames. For each FIFO filter, the pass criteria is specified in the
related section given below. Only frames that have passed all filters will be appended to the FIFO. The
FIFO filter path is depicted in Figure 26-145.
Yes Individual
Message Buffer Found
?
No
Frame ID Else
Range Rejection Filter
?
Passed
Frame ID Else
Range Acceptance Filter
?
Passed
No Frame Received
in Dynamic Segment
?
Yes
No Message ID
(vRF!Header!PPIndicator=1)
?
Yes
Message ID Else
Acceptance Filter
?
Passed
No
FIFO full
?
Ignore frame
A received frame passes the FIFO filtering if it has passed all three type of filter.
The RX FIFO Frame ID Value-Mask Rejection Filter can be configured to pass all frames by the following
settings.
• FR_RFFIDRFVR[FIDRFVAL]:= 0x000 and FR_RFFIDRFMR[FIDRFMSK]:= 0x7FF
Using the settings above, only the frame with frame ID 0 will be rejected, which is an invalid frame. All
other frames will pass.
The RX FIFO Frame ID Value-Mask Rejection Filter can be configured to reject all frames by the
following settings.
• FR_RFFIDRFMR[FIDRFMSK]:= 0x000
Using the settings above, Equation 14 can never be fulfilled (0!= 0) and thus all frames are rejected; no
frame will pass. This is the reset value for the RX FIFO.
FID FR_RFRFCFR SEL SID IBD = 0 or FR_RFRFCFR SEL SID IBD = 1 FID Eqn. 15
Consequently, all frames with a frame ID that fulfills Equation 16 for at least one of the enabled rejection
filters will be rejected and thus not pass.
FR_RFRFCFR SEL SID IBD = 0 FID FR_RFRFCFR SEL SID IBD = 1 Eqn. 16
the Receive FIFO Range Filter Control Register (FR_RFRFCTR). The RX FIFO Frame ID range filters
apply to all received valid frames. A received frame with the frame ID FID passes the RX FIFO Frame ID
Range acceptance filters if either no acceptance filter is enabled, or, for at least one of the enabled RX FIFO
Frame ID Range acceptance filters, i.e., FR_RFRFCTR[FiMD] = 0 and FR_RFRFCTR[FiEN] = 1,
Equation 17 is fulfilled.
The RX FIFO Message ID Acceptance Filter can be configured to accept all frames by setting
• FR_RFMIDAFMR[MIDAFMSK]:= 0x000
Using the settings above, Equation 18 is always fulfilled and all frames will pass.
FLEXRAY
CHI PE
reg(A) FR_A_RX
FlexRay Channel A
FR_A_TX FlexRay Bus Driver
channel 0 Channel A
cfg(A) FR_A_TX_EN
cCrcInit[A]
reg(B) FR_B_RX
FlexRay Channel B
FR_B_TX FlexRay Bus Driver
channel 1 Channel B
cfg(B) FR_B_TX_EN
cCrcInit[B]
FLEXRAY
CHI PE
reg(A) FR_A_RX
FlexRay Channel A
FR_A_TX FlexRay Bus Driver
channel A Channel A
cfg(A) FR_A_TX_EN
cCrcInit[A]
reg(B) FR_B_RX
channel B FR_B_TX
cfg(B) FR_B_TX_EN
cCrcInit[B]
FLEXRAY
CHI PE
FR_A_RX
reg(A) FlexRay Channel B
FR_A_TX FlexRay Bus Driver
channel A Channel A
FR_A_TX_EN
cfg(A)
reg(B) FR_B_RX
channel B FR_B_TX
cfg(B) FR_B_TX_EN
cCrcInit[B]
If the rate correction for the cycle pair [2n+2, 2n+3] shall be affect by the external offset correction, the
ERC_AP field must be written to after the start of cycle 2n and before the end of the static segment start
of cycle 2n+1. If this field is written to after the end of the static segment of cycle 2n+1, it is not guaranteed
that the external correction value is applied in cycle pair [2n+2, 2n+3]. If the value is not applied for cycle
pair [2n+2, 2n+3], then the value will be applied for cycle pair [2n+4, 2n+5]. Refer to Figure 26-150 for
details.
static segment NIT static segment NIT static segment NIT static segment NIT
cycle 2n cycle 2n+1 cycle 2n+2 cycle 2n+3
NOTE
Only synchronization frames that have passed the synchronization frame
filters are considered for clock synchronization and appear in the sync frame
tables.
FR_SFTCCSR
Description
OPT SDVEN SIDEN
0 0 0 No Sync Frame Table copy
0 0 1 Sync Frame ID Tables will be copied continuously
0 1 0 Reserved
0 1 1 Sync Frame ID Tables and Sync Frame Deviation Tables will be copied continuously
1 0 0 No Sync Frame Table copy
1 0 1 Sync Frame ID Tables for next even-odd-cycle pair will be copied
1 1 0 Reserved
1 1 1 Sync Frame ID Tables and Sync Frame Deviation Tables for next even-odd-cycle pair will be
copied
The Sync Frame Table generation process is described in the following for the even cycle. The same
sequence applies to the odd cycle.
If the application has enabled the sync frame table generation by setting FR_SFTCCSR[SIDEN] to 1, the
CC starts the update of the even cycle related tables after the start of the NIT of the next even cycle. The
CC checks if the application has locked the tables by reading the FR_SFTCCSR[ELKS] lock status bit. If
this bit is set, the CC will not update the table in this cycle. If this bit is cleared, the CC locks this table and
starts the table update. To indicate that these tables are currently updated and may contain inconsistent
data, the CC clears the even table valid status bit FR_SFTCCSR[EVAL]. Once all table entries related to
the even cycle have been transferred into the flexray memory area, the CC sets the even table valid bit
FR_SFTCCSR[EVAL] and the Even Cycle Table Written Interrupt Flag EVT_IF in the Protocol Interrupt
Flag Register 1 (FR_PIFR1). If the interrupt enable flag EVT_IE is set, an interrupt request is generated.
To read the generated tables, the application must lock the tables to prevent the CC from updating these
tables. The locking is initiated by writing a 1 to the even table lock trigger FR_SFTCCSR[ELKT]. When
the even table is not currently updated by the CC, the lock is granted and the even table lock status bit
FR_SFTCCSR[ELKS] is set. This indicates that the application has successfully locked the even sync
tables and the corresponding status information fields SFRA, SFRB in the Sync Frame Counter Register
(FR_SFCNTR). The value in the FR_SFTCCSR[CYCNUM] field provides the number of the cycle that
this table is related to.
The number of available table entries per channel is provided in the FR_SFCNTR[SFEVA] and
FR_SFCNTR[SFEVB] fields. The application can now start to read the sync table data from the locations
given in Figure 26-151.
After reading all the data from the locked tables, the application must unlock the table by writing to the
even table lock trigger FR_SFTCCSR[ELKT] again. The even table lock status bit FR_SFTCCSR[ELKS]
is reset immediately.
If the sync frame table generation is disabled, the table valid bits FR_SFTCCSR[EVAL] and
FR_SFTCCSR[EVAL] are reset when the counter values in the Sync Frame Counter Register
(FR_SFCNTR) are updated. This is done because the tables stored in the flexray memory area are no
longer related to the values in the Sync Frame Counter Register (FR_SFCNTR).
even table write odd table write
FR_SFTCCSR.[OPT,SIDEN,SDVEN] write window
The application enables or disables the generation of the MTS on either channel by setting or clearing the
MTE control bit in the MTS A Configuration Register (FR_MTSACFR) or MTS B Configuration Register
(MTSBCFR). If an MTS is to be transmitted in a certain communication cycle, the application must set
the MTE control bit during the static segment of the preceding communication cycle.
The MTS is transmitted over channel A in the communication cycle with number CYCCNT, if
Equation 20, Equation 21, and Equation 21 are fulfilled.
The MTS is transmitted over channel B in the communication cycle with number CYCCNT, if
Equation 19, Equation 22, and Equation 23 are fulfilled.
0 0 normal frame
0 1 normal frame1
1 0 sync frame
1 1 startup frame
1
The frame transmitted has an semantically incorrect header and will be detected as an invalid frame at the receiver.
NOTE
Sync frames are transmitted in the static segment only. Thus FID <= 1023.
NOTE
Sync frames are transmitted in the static segment only. Thus FID <= 1023.
This section provides detailed timing information of the strobe signals with respect to the protocol engine
clock.
The strobe signals display internal PE signals. Due to the internal architecture of the PE, some signals are
generated several PE clock cycles before the actual action is performed on the FlexRay Bus. These signals
are listed in Table 26-12 with a negative clock offset. An example waveform is given in Figure 26-153.
PE Clock
Strobe Signal
-2
Other signals refer to events that occurred on the FlexRay Bus some cycles before the strobe signal is
changed. These signals are listed in Table 26-12 with a positive clock offset. An example waveform is
given in Figure 26-154.
PE Clock
Strobe Signal
YCTR CTCCNT & FR_TI1CYSR T1_CYC_MSK = FR_TI1CYSR T1_CYC_VAL & FR_TI1CYSR T1_CYC_MSK
Eqn. 28
If the timer 1 interrupt enable bit TI1_IE in the Protocol Interrupt Enable Register 0 (FR_PIER0) is
asserted, an interrupt request is generated.
The status bit T1ST is set when the timer is triggered, and is cleared when the timer expires and is
non-repetitive. If the timer expires but is repetitive, the T1ST bit is not cleared and the timer is restarted
immediately. The T1ST is cleared when the timer is stopped.
status(sym.win)
status(slot k)
status(slot 1)
status(slot n)
status(NIT)
status(NIT)
cycle start
NIT start
slot start
cycle start
slot start
MT
MT
MT
MT
MT
MT
slot 1
NOTE
The slot status for the NIT of cycle n is provided after the start of cycle n+1.
Status Content
status(sym.win)
status(slot n)
status(slot k)
status(NIT)
status(NIT)
cycle start
NIT start
slot start
slot start
cycle start
MT
MT
MT
MT
MT
MT
slot 1
The PE provides the status of the NIT in the first slot of the next cycle. Due to these facts, the FR_SSCRn
register reflects, in cycle n, the status of the NIT of cycle n-2, and the status of all static slots and the
symbol window of cycle n-1.
The increment condition for each slot status counter consists of two parts, the frame related condition part
and the slot related condition part. The internal slot status counter FR_SSCRn_INT is incremented if at
least one of the conditions is fulfilled:
1. frame related condition:
• (FR_SSCCRn[VFR] | FR_SSCCRn[SYF] | FR_SSCCRn[NUF] | FR_SSCCRn[SUF]) // count on
frame condition
= 1;
and
• ((~FR_SSCCRn[VFR] | vSS!ValidFrame) & // valid frame restriction
(~FR_SSCCRn[SYF] | vRF!Header!SyFIndicator) & // sync frame indicator restriction
(~FR_SSCCRn[NUF] | ~vRF!Header!NFIndicator) & // null frame indicator restriction
(~FR_SSCCRn[SUF] | vRF!Header!SuFIndicator)) // startup frame indicator restriction
= 1;
NOTE
The indicator bits SYF, NUF, and SUF are valid only when a valid frame
was received. Thus it is required to set the VFR always, whenever count on
frame condition is used.
2. slot related condition:
• ((FR_SSCCRn[STATUSMASK[3]] & vSS!ContentError) | // increment on content error
(FR_SSCCRn[STATUSMASK[2]] & vSS!SyntaxError) | // increment on syntax error
(FR_SSCCRn[STATUSMASK[1]] & vSS!BViolation) | // increment on boundary violation
(FR_SSCCRn[STATUSMASK[0]] & vSS!TxConflict)) // increment on transmission conflict
= 1;
If the slot status counter is in single cycle mode (FR_SSCCRn[MCY] = 0), the internal slot status counter
FR_SSCRn_INT is reset at each cycle start. If the slot status counter is in the multicycle mode
(FR_SSCCRn[MCY] = 1), the counter is not reset and incremented, until the maximum value is reached.
The behavior of the CC after the occurrence of a system bus access failure is described in
Section 26.6.19.2, “System Bus Access Failure Response”.
If a frame is received when the system bus failure occurs, the reception is aborted and the related receive
message buffer is not updated.
Normal operation is resumed after the start of next communication cycle.
FR_PIFR0[15:0]
16
FR_PIER0[15:0] &
FR_GIFER[PRIF]
OR Protocol Interrupt
FR_PIFR1[9:0] &
10 FR_GIFER[PRIE]
FR_PIER1[9:0] &
FR_CHIERFR[15:0]
16
FR_GIFER[CHIF]
CHI Interrupt
& OR
FR_GIFER[CHIE]
FR_GIFER[WUPIF]
PE Wakeup Interrupt
FR_GIFER[WUPIE] &
FR_GIFER[FAFAIF]
RX FIFO A RX FIFO A Almost Full Interrupt
FR_GIFER[FAFAIE] &
FR_GIFER[FAFBIF]
RX FIFO B RX FIFO B Almost Full Interrupt
FR_GIFER[FAFBIE] &
FR_MBCCSRn[MBIF]
n
FR_MBCCSRn[MBIE] & n FR_GIFER[RBIF]
& OR Receive Message Buffer Interrupt
n RXBUF FR_GIFER[RBIE] &
FR_MBCCSRn[MTD]
n FR_GIFER[TBIF]
& OR Transmit Message Buffer Interrupt
TXBUF FR_GIFER[TBIE] &
Protocol Interrupt
CHI Interrupt
Wakeup Interrupt
RX FIFO A Almost Full Interrupt FR_GIFER[MIF] Module Interrupt
OR
RX FIFO B Almost Full Interrupt &
FR_GIFER[MIE]
Receive Message Buffer Interrupt
Transmit Message Buffer Interrupt
FR_EEIFER[LRNE_IF]
LRAM Non-Corrected Error Interrupt
FR_EEIFER[LRNE_IE] &
LRAM ECC
FR_EEIFER[LRCE_IF]
LRAM Corrected Error Interrupt
FR_EEIFER[LRCE_IE] &
FR_EEIFER[DRNE_IF]
DRAM Non-Corrected Error Interrupt
FR_EEIFER[DRNE_IE] &
DRAM ECC
FR_EEIFER[DRCE_IF]
DRAM Corrected Error Interrupt
FR_EEIFER[DRCE_IE] &
Figure 26-159.
16
FR_CHIERFR[15:0] FR_CIFR[CHIF]
OR
FR_CIFR[WUPIF]
PE
FR_CIFR[FAFAIF]
RX FIFO A
FR_CIFR[FAFBIF]
RX FIFO B
FR_MBCCSRn[MBIF]
n
n FR_CIFR[RBIF]
& OR
n RXBUF
FR_MBCCSRn[MTD]
n FR_CIFR[TBIF]
& OR
TXBUF
FR_CIFR[MIF]
OR
pSamplesPerMicrotick
gdSampleClockPeriod
cSamplesPerBit
cStrobeOffset
pdMicrotick
FlexRay Channel
[ns]
[ns]
Bit Rate FR_MCR[BITRATE]
[Mbit/s]
NOTE
The bit rate of 8 Mbit/s is not defined by the FlexRay Communications
System Protocol Specification, Version 2.1 Rev A.
...
The FlexRay module provides means to access the PE DRAM from the application. The PE DRAM
application access is initiated and controlled via PE DRAM Access Register (FR_PEDRAR) and PE
DRAM Data Register (FR_PEDRDR). This functionality is used to check the memory error detection.
3. val = FR_PEDRDR[DATA];
// read PE DRAM data
The read access is handled by the PE internal CPU with the lowest execution priority. This may cause an
response delay with a maximum of 1000 PE clock cycle (25us).
...
...
PE DRAM
PE DRAM
CHI LRAM Three or more one out of {No error, Non-Corrected Error}, defined by coding
Bits Flipped given in Section 26.6.24.2.3, “CHI LRAM Checkbits” and
Section 26.6.24.2.3, “CHI LRAM Checkbits”
CODE DATA
CODE
3 2 1 0 7 6 5 4 3 2 1 0
1 X X X X X X X X X X X X
4
32 - - - - X X X X - - - -
2 - - - - X - - - X X X -
1 - - - - - X X - X X - X
0 - - - - - X - X X - X X
1
The checkbit CODE[4] is set to 1 if and only if there is a even number of 1’s in columns with X.
2 The checkbits CODE[3]... CODE[0] are set to 1 if and only if there is a odd number of 1’s in all columns with X.
This coding of the checkbit ensures that neither 0x000 nor 0xFFF are valid code words and written into
the memory.
FR_EERCR[CODE]
Description
[4] [3:0]
0x0 0x0 If data == 0: Non Corrected Error (Dedicated Handling of All Zero Code Word)
If data!= 0: Corrected Error (Parity Bit 4)
DATA
CODE1
15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
4 X X X X X - - - - - - - - - - -
3 - - - - - X X X X X X X - - - -
2 X X - - - X X X X - - - X X X -
1 - - X X - X X - - X X - X X - X
0 X - X - X X - X - X - X X - X X
1
The checkbit CODE[n] is set to 1 if and only if there is a odd number of 1’s in all columns with X.
FR_EERCR[CODE] Description
If the affected message buffer is a tx message buffer, no frame will be transmitted from this
message buffer in the next slot. If the affected message buffer is a rx message buffer, no frame will
be received to this message buffer in the next slot.
• If the LRAM address belongs to the data field offset area and the related physical message buffer
is used for Rx or Tx the first access to the system memory caused by payload read or write yields
to the assertion of the FR_CHIERFR[ILSA_EF]. No memory access occurs w.r.t. payload access
is performed for the complete frame.
26.6.24.3.4 PE DRAM Error Response after Application Read in POC:default config state
If the CC detects an non-corrected memory error during an application triggered read from any PE DRAM
address and the protocol is in the POC:default config state, this is considered as an fatal protocol error and
the module enters the protocol freeze state. This behavior allows for checking the freeze functionality in
case of the detection of non-corrected errors.
26.6.24.3.5 PE DRAM Error Response after Application Read out of POC:default config
If the CC detects an non-corrected memory error during an application triggered read from any PE DRAM
address, and the protocol is not in the POC:default config state, this error is not considered as an fatal error
and the protocol state is not changed. This prevents any interference of the running protocol by PE DRAM
error injection reads.
The injector has the same behavior for FlexRay module memory writes and application memory writes.
When the FlexRay module is in POC:default config, there are no limitations for the error injection and no
impacts of error injection to the application. For error injection out of POC:default config see
Section 26.7.3.2, “PE DRAM Error Injection out of POC:default config”.
Injector Setup:
1. FR_MCR[ECCE]:= 1;
// enable ecc functionality
2. FR_EERICE[EIE]:=I_MODE;
// configure error injection mode
3. FR_EEIAR[MID]:= 0;
// select PE DRAM for error injection
4. FR_EEIAR[BANK]:= I_BANK;
// define bank for error injection; I_BANK = {0,1}
5. FR_EEIAR[ADDR]:= I_ADDR;
// define address for error injection; I_ADDR <= 0x7F
6. FR_EEIDR[DATA]:= D_DIST;
// define data distortion pattern
7. FR_EEICR[CODE]:= C_DIST;
// define checkbit distortion pattern
8. FR_EERICE[EIE]:=1;
// enable error injection
Application Write Access (e.g. I_ADDR=0x70):
1. FR_PEDRAR:= 0x30E0;
// INST=0x3; ADDR=0x70
2. wait until FR_PEDRAR[DAD] == 1;
// wait for end of PE DRAM access
3. val = FR_PEDRDR[DATA]; |
// get read back PE DRAM data
Note: The write access to the PE DRAM triggers an subsequent read access from PE DRAM in the next
cycle, which triggers the detection of the distorted data.
For a given SYMATOR[TIMEOUT] value, fCHI can be increased without causing unreliable operation of
the CC. The same holds for reducing the SYMATOR[TIMEOUT] value for a given fCHI.
Some examples for maximum values of the SYMATOR[TIMEOUT] for a minimum CHI frequency are
given in Table 26-133.
Table 26-133. Maximum SYMATOR[TIMEOUT] examples
1. see Section 26.3, “Controller Host Interface Clocking” for all constraints of minimum CHI clock frequency.
(FR_MBSSUTR), a configured minislot length gdMinislot, and a configured nominal macrotick length
gdMacrotick1.
Additional constraints for the minimum CHI clock frequency are given in Section 26.3, “Controller Host
Interface Clocking”.
The CC uses a sequential search algorithm to determine the individual message buffer assigned or
subscribed to the next slot. This search is started at the start of slot and must be finished before the start of
the next slot.
The shortest FlexRay slot is an corrected empty dynamic slot. An corrected empty dynamic slot is a
minislot and consists of gdMinislot corrected macroticks with a duration of gdMacrotick. The minimum
duration of an corrected macrotick is gdMacrotickmin = 39 µT. This results in a minimum length of an
correct slot
The message buffer search engine runs on the CHI clock and evaluates one individual message buffer per
CHI clock cycle. For internal status update operations and to account for clock domain crossing jitter, an
additional amount of 27 CHI clock cycles is required to ensure correct search engine operation.
For a given number of utilized message buffers FR_MBSSUTR[LAST_MB_UTIL] + 1 and for a given
CHI clock frequency fchi, this results in a search duration of
1
search = -------- FR_MBSSUTR[LAST_MB_UTIL]+27 Eqn. 32
f chi
The message buffer search must be finished within one slot which requires that Equation 33 must be
fulfilled:
This results in the formula given in Equation 34 which determines the required minimum CHI frequency
for a given number of message buffers that are utilized.
FR_MBSSUTR[LAST_MB_UTIL]+27
f chi ---------------------------------------------------------------------------------------------------- Eqn. 34
39 pdMicrotick gdMinislot
The required minimum CHI Clock frequency for a selected set of relevant protocol parameters and for the
LAST_MB_UTIL field in the Message Buffer Segment Size and Utilization Register (FR_MBSSUTR) set
to 127 is given in Table 26-134.
1. see Section 26.3, “Controller Host Interface Clocking” for all constraints of minimum CHI clock frequency.
Table 26-134. Minimum fchi [MHz] examples (128 message buffers used)
gdMinislot
pdMicrotick
[ns]
2 3 4 5 6 7
NOTE
If the minimum CHI frequency is not met the CHIERFR[MBS_EF] flag is
set. Refer to Section 26.5.2.17, “CHI Error Flag Register (FR_CHIERFR)”
for details.
FREEZE (highest) 1
READY 2
none
CONFIG_COMPLETE 3
ALLOW_COLDSTART 5
FREEZE,
RUN 6 FREEZE,
READY,
CONFIG_COMPLET, fatal protocol error
WAKEUP 7 fatal protocol error FREEZE,
fatal protocol error
DEFAULT_CONFIG 8 FREEZE,
fatal protocol error
CONFIG 9
CCFMSK 000011
cycle set = {4n} = {0,4,8,12,...}
CCFVAL 000000
The availability of data in the transmit buffer is indicated by the commit bit FR_MBCCSRt[CMT] and the
lock bit FR_MBCCSRt[LCKS].
The receive message buffer has the message buffer number r and has following configuration
Table 26-137. Receive Buffer Configuration
CCFMSK 000001
cycle set = {2n} = {0,2,4,6,...}
CCFVAL 000000
Furthermore the assumption is that both message buffers are enabled (FR_MBCCSRt[EDS] = 1 and
FR_MBCCSRr[EDS] = 1)
NOTE
The cycle set {4n+2} = {2,6,10,...} is assigned to the receive buffer only.
The cycle set {4n} = {0,4,8,12,...} is assigned to both buffers.
RX RX RX RX RX RX RX
0 1 2 3 4 5 6 7 8 59 60 61 62 63
TX RX TX RX TX TX RX
0 1 2 3 4 5 6 7 8 59 60 61 62 63
316 x Processor 1
Processor 1 Vector Table 1 Hardware
6-bits End of Entry Size Vector Enable
Interrupt 1
Register
Software Processor 0
Priority Block
Set/Clear Hardware
Select Configuration
Interrupt Vector Enable
Registers Register
Registers 1
Processor 0
End of
316 x Interrupt Vector Table 1
Highest Lowest
6-bits Register Entry Size
Flag Bits Priority Vector Processor 0
Peripheral Interrupt Interrupt Interrupt Interrupt
Interrupt 8 Requests Request Vector Vector
Processor 0
Requests Priority Request Vector 9 Interrupt 9
Arbitrator Selector Encoder Acknowledge
Register
4 Highest Priority
Pushed New
Priority Priority
4 4 Interrupt
Processor 0 Update Interrupt Vector 1
Processor 0 Popped Current Request to
Current Priority
Priority Priority Priority 1 Processor 0
Priority Comparator
LIFO 4 4
Register Interrupt
Acknowledge
from
1 Processor 0
Processor 0 Push/Update/Acknowledge 1
Processor 0 Pop 1 Slave Peripheral
Interface Bus
Processor 1 Push/Update/Acknowledge 1 for Reads
Memory Mapped Registers
Processor 1 Pop 1 & Writes
Non-Memory Mapped Logic
Typical program flow for software vector mode is shown in Figure 27-3.
Address Instructions Address Instructions
VTBA ISR 0 address ISR 0 ISR
Prolog
(Including ISR 1 address ISR 1 ISR
IRQ[n] IVPR + IVOR4 using IACKR • •
IACKR • •
taken to get vector • •
then bl ISR_n ISR n address ISR n ISR
• •
• •
• •
Epilog ISR N – 1 address ISR N – 1 ISR
N is the maximum number of usable interrupt vectors and includes eight software-settable IRQ vectors.
The common interrupt exception handler address is calculated by hardware as shown in Figure 27-4. The
upper half of the interrupt vector prefix register (IVPR) is added to the offset contained in the external input
interrupt vector offset register (IVOR4). Note that since bits IVOR4[28:31] are not part of the offset value,
the vector offset must be located on a quad-word (16-byte) aligned location in memory.
IVPR
0 15 16 31
PREFIX 0x0000
+ IVOR4
0 15 16 27 28 31
0x0000 OFFSET 0x00
= Interrupt exception
handler address
0 15 16 27 28 31
PREFIX OFFSET 0x00
Figure 27-4. Software Vector Mode: Interrupt Exception Handler Address Calculation
As shown in Figure 27-3, the common interrupt exception handler reads the INTC_IACKR_PRCn to
determine the vector of the interrupt request source. The INTC_IACKR_PRCn register contains a 32-bit
address for a vector table base address (VTBA) plus an offset to access the interrupt vector (INTVEC).
The address is then used to branch to the corresponding routine for that peripheral or software interrupt
source.
Reading the INTC_IACKR_PRCn acknowledges the INTC’s interrupt request and negates the interrupt
request to the processor. The interrupt request to the processor does not clear if a higher priority interrupt
request arrives. Even in this case, INTVEC does not update to the higher priority request until the lower
priority interrupt request is acknowledged by reading the INTC_IACKR_PRCn. The reading also pushes
the PRI value in the INTC current priority register (INTC_CPR_PRCn) onto the LIFO and updates PRI in
the INTC_CPR_PRCn with the priority of the interrupt request. The INTC_CPR_PRCn masks any
peripheral or software settable interrupt request at the same or lower priority of the current value of the
PRI field in INTC_CPR_PRCn from generating an interrupt request to the processor.
The interrupt exception handler must write to the end-of-interrupt register (INTC_EOIR_PRCn) to
complete the operation. Writing to the INTC_EOIR_PRCn ends the servicing of the interrupt request. The
INTC’s LIFO is popped into the INTC_CPR_PRCn’s PRI field by writing to the INTC_EOIR_PRCn, and
the size of a write does not affect the operation of the write. Those values and sizes written to this register
neither update the INTC_EOIR_PRCn contents nor affect whether the LIFO pops. For possible future
compatibility, write four bytes of all 0s to the INTC_EOIR_PRCn. The timing relationship between
popping the LIFO and disabling recognition of external input has no restriction. The writes can happen in
either order.
However, disabling recognition of the external input before popping the LIFO eases the calculation of the
maximum stack depth at the cost of postponing the servicing of the next interrupt request.
not delay the execution of higher priority ISRs. Since each individual application has different priorities
for each source of interrupt request, the priority of each interrupt request is configurable.
Typical program flow for hardware vector mode is shown in Figure 27-5.
Address Instructions
NOTE:
‘b ISR_n’ is technically IVPR + offset[0] b handler 0 handler 0 Prolog
part of the handler. •
• ISR
•
IVPR + offset[1] b handler 1 Epilog
• •
• •
• •
IVPR + offset[2] b handler 2 handler n Prolog
•
• ISR
•
IRQ[n] IVPR + n [0x0010]
b handler n Epilog
taken
• •
• •
• •
IVPR + offset[N – 1] b handler N – 1 handler N Prolog
Address IVPR + offset[N – 1] contains the last interrupt vector and is the last usable ISR
interrupt vector address in the interrupt memory map for this device. Epilog
N is the maximum number of usable interrupt vectors and includes eight software-settable IRQ vectors.
In hardware vector mode, the interrupt exception handler address is specific to the peripheral or software
settable interrupt source rather than being common to all of them. No IVOR is used. The interrupt
exception handler address is calculated by hardware as shown in Figure 27-6. The upper half of the
interrupt vector prefix register (IVPR) is added to an offset which corresponds to the peripheral or software
interrupt source which caused the interrupt request. The offset matches the value in the Interrupt Vector
field, INTC_IACKR_PRCn[INTVEC]. Each interrupt exception handler address is aligned on a quad
word (16-byte) boundary. IVOR4 is not used in this mode, and software does not need to read
INTC_IACKR_PRCn to get the interrupt vector number.
IVPR
0 15 16 31
PREFIX 0x0000
+ Hardware vector
mode offset
0 15 16 18 19 27 28 31
0x0000 0b000 INTC_IACKR[INTVEC] 0b0000
= Interrupt exception
handler address
0 15 16 18 19 27 28 31
PREFIX 0b000 IRQ SPECIFIC OFFSET 0b0000
Figure 27-6. Hardware Vector Mode: Interrupt Exception Handler Address Calculation
The processor negates INTC’s interrupt request when automatically acknowledging the interrupt request.
However, the interrupt request to the processor do not negate if a higher priority interrupt request arrives.
Even in this case, the interrupt vector number does not update to the higher priority request until the lower
priority request is acknowledged by the processor.
The assertion of the interrupt acknowledge signal pushes the PRI value in the INTC_CPR_PRCn onto the
LIFO and updates PRI in the INTC_CPR_PRCn with the new priority.
Offset from
Reset
INTC_BASE_ADDR Register Access Section/Page
Value
(0xFFF4_8000)
0x0004 Reserved
0x0008 INTC_CPR_PRC0—INTC current priority register for processor 0 R/W 0x0000_000F 27.3.2.2/27-10
(Core 0)
0x00C INTC_CPR_PRC1—INTC current priority register for processor 1 R/W 0x0000_000F 27.3.2.3/27-11
(Core 1)
0x0020 INTC_SSCIR0_3—INTC software set/clear interrupt register 0–3 R/W 0x0000_0000 27.3.2.8/27-15
Offset from
Reset
INTC_BASE_ADDR Register Access Section/Page
Value
(0xFFF4_8000)
0x0024 INTC_SSCIR4_7—INTC software set/clear interrupt register 4–7 R/W 0x0000_0000 27.3.2.8/27-15
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R 0 0 VTES_ 0 0 0 0 HVEN_ 0 0 VTES_ 0 0 0 0 HVEN_
W PRC1 PRC1 PRC0 PRC0
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 27-7. INTC Module Configuration Register (INTC_MCR)
Field Description
VTES_PRC1 For software mode only, the Vector Table Entry Size for Processor 1 (Core 1). The VTES_PRC1 bit controls the number
of 0s to the right of INTVEC_PRC1 in INTC_IACKR_PRC1. If the contents of INTC_IACKR_PRC1 are used as an
address of an entry in a vector table, then the number of right-most 0s will determine the size of each vector table entry.
0 4 bytes.
1 8 bytes.
HVEN_PRC1 Hardware Vector Enable for Processor 1 (Core 1). The HVEN bit controls whether the INTC is in hardware vector mode
or software vector mode. Refer to Section 27.1.3, “Modes of Operation,” for details of handshaking with the processor
in each mode.
0 Software vector mode.
1 Hardware vector mode.
VTES_PRC0 For software mode only, the Vector Table Entry Size for Processor 0 (Core 0). The VTES_PRC0 bit controls the number
of 0s to the right of INTVEC_PRC0 in INTC_IACKR_PRC0. If the contents of INTC_IACKR_PRC0 are used as an
address of an entry in a vector table, then the number of right-most 0s will determine the size of each vector table entry.
0 4 bytes.
1 8 bytes.
HVEN_PRC0 Hardware Vector Enable for Processor 0 (Core 0). The HVEN bit controls whether the INTC is in hardware vector mode
or software vector mode. Refer to Section 27.1.3, “Modes of Operation,” for details of handshaking with the processor
in each mode.
0 Software vector mode.
1 Hardware vector mode.
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R 0 0 0 0 0 0 0 0 0 0 0 0
PRI
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 1 1 1 1
Figure 27-8. INTC Current Priority Register for Processor 0 (Core 0) (INTC_CPR_PRC0)
Field Description
PRI Priority. PRI is the priority of the currently executing Core 0 ISR according to the following field values.1111Priority
15 (highest)
1110 Priority 14
...
0001 Priority 1
0000 Priority 0 (lowest)
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R 0 0 0 0 0 0 0 0 0 0 0 0
PRI
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 1 1 1 1
Figure 27-9. INTC Current Priority Register for Processor 1 (Core 1) (INTC_CPR_PRC1)
Field Description
PRI Priority. The function of this field is the same as described for processor 0 (Core 0) in Section 27.3.2.2, “INTC Current
Priority Register for Processor 0 (Core 0) (INTC_CPR_PRC0).”
However, the time for the processor to recognize the assertion or negation
of the external input to it is not defined by the book E architecture and can
be greater than 0. Therefore, insert instructions between the reading of the
INTC_IACKR_PRCn and the setting of MSR[EE] that consumes at least
two processor clock cycles. This length of time allows the interrupt request
negation to propagate through the processor before MSR[EE] is set.
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R VTBA_PRC0 INTVEC_PRC01 0 0
W (least significant five bits)
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
1
When the VTES_PRC0 bit in INTC_MCR is asserted, INTVEC_PRC0 is shifted to the left one bit. Bit 29 is read as a 0.
VTBA_PRC0 is narrowed to 20 bits in width.
Figure 27-10. INTC Interrupt Acknowledge Register for Processor 0 (Core 0) (INTC_IACKR_PRC0)
Field Description
VTBA_PRC0 Vector Table Base Address for Processor 0 (Core 0). VTBA_PRC0 can be the base address of a vector table of addresses
of ISRs for processor 0 (Core 0). The VTBA_PRC0 only uses the left-most 20 bits when the VTES_PRC0 bit in
INTC_MCR is asserted.
INTVEC_PRC0 Interrupt Vector for Processor 0 (Core 0). INTVEC_PRC0 is the vector of the peripheral or software settable interrupt
request that caused the interrupt request to the processor. When the interrupt request to the processor asserts, the
INTVEC_PRC0 is updated, whether the INTC is in software or hardware vector mode.
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R VTBA_PRC1 INTVEC_PRC11 0 0
W (5 least-significant bits)
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
1
When the VTES_PRC1 bit in INTC_MCR is asserted, INTVEC_PRC1 is shifted to the left one bit. Bit 29 is read as 0.
VTBA_PRC1 is narrowed to 20 bits wide
Figure 27-11. INTC Interrupt Acknowledge Register for Processor 1 (Core 1) (INTC_IACKR_PRC1)
Field Description
VTBA_PRC1 Vector Table Base Address for Processor 1 (Core 1). VTBA_PRC1 can be the base address of a vector table of addresses
of ISRs for processor 1 (Core 1). The VTBA_PRC1 only uses the left-most 20 bits when the VTES_PRC1 bit in
INTC_MCR is asserted.
INTVEC_PRC1 Interrupt Vector for Processor 1 (Core 1). INTVEC_PRC1 is the vector of the peripheral or software settable interrupt
request that caused the interrupt request to the processor. When the interrupt request to the processor asserts, the
INTVEC_PRC1 is updated, whether the INTC is in software or hardware vector mode.
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R
W INTC_EOIR_PRC0
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 27-12. INTC End-of-Interrupt Register for Processor 0 (Core 0) (INTC_EOIR_PRC0)
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R
W INTC_EOIR_PRC1
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 27-13. INTC End-of-Interrupt Register for Processor 1 (Core 1) (INTC_EOIR_PRC1)
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R 0 0 0 0 0 0 0 0 0 0 0 0 0 0
CLR2 CLR3
W SET2 SET3
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 27-14. INTC Software Set/Clear Interrupt Register 0–3 (INTC_SSCIR[0:3])
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R 0 0 0 0 0 0 0 0 0 0 0 0 0 0
CLR6 CLR7
W SET6 SET7
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 27-15. INTC Software Set/Clear Interrupt Register 4–7 (INTC_SSCIR[4:7])
Field Description
SET Set Flag Bits. Writing a 1 sets the corresponding CLRn bit. Writing a 0 has no effect. Each SETn is always read as a 0.
CLR Clear Flag Bits. CLRn is the flag bit. Writing a 1 to CLRnx clears it provided that a 1 is not written simultaneously to
its corresponding SETn bit. Writing a 0 to CLRn has no effect.
0 Interrupt request not pending within INTC.
1 Interrupt request pending within INTC.
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R 0 0 0 0
PRC_SEL2 PRI2 PRC_SEL3 PRI3
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 27-16. INTC Priority Select Register 0–3 (INTC_PSR0–3)
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R PRC_ 0 0 PRC_ 0 0
PRI510 PRI511
W SEL510 SEL511
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Figure 27-17. INTC Priority Select Register 508–511 (INTC_PSR508–511)
Field Description
PRC_SEL0– Processor Select. If an interrupt source is enabled, PRC_SELn selects whether the interrupt request is to be sent to
PRC_SEL511 processor 0 (Core 0), processor 1 (Core 1), or both. See Table 27-9.
PRI0– Priority Select. PRIn selects the priority for interrupt requests. Refer to Section 27.4.2, “Priority Management.”
PRI511 1111 Priority 15 (highest)
1110 Priority 14
...
0001 Priority 1
0000 Priority 0 (lowest)
NOTE
The PRC_SELn or PRIn field of an INTC_PSRn_n must not be modified
while the corresponding peripheral or software settable interrupt request is
asserted.
Table 27-9. Selected Processor for Interrupt Request
PRC_SELn Meaning
10 Reserved
154 INTC_PSR152_155
175 INTC_PSR172_175
194 INTC_PSR192_195
195 INTC_PSR192_195
196 INTC_PSR196_199
282 INTC_PSR280_283
310 INTC_PSR308_311
329 INTC_PSR328_331
330 INTC_PSR328_331
331 INTC_PSR328_331
332 INTC_PSR332_335
333 INTC_PSR332_335
334 INTC_PSR332_335
335 INTC_PSR332_335
336 INTC_PSR336_339
337 INTC_PSR336_339
338 INTC_PSR336_339
339 INTC_PSR336_339
340 INTC_PSR340_343
341 INTC_PSR340_343
342 INTC_PSR340_343
343 INTC_PSR340_343
344 INTC_PSR344_347
345 INTC_PSR344_347
346 INTC_PSR344_347
347 INTC_PSR344_347
348 INTC_PSR348_351
349 INTC_PSR348_351
358 INTC_PSR356_359
359 INTC_PSR356_359
360 INTC_PSR360_363
361 INTC_PSR360_363
362 INTC_PSR360_363
363 INTC_PSR360_363
364 INTC_PSR364_367
365 INTC_PSR364_367
474 INTC_PSR472_475
475 INTC_PSR472_475
484 INTC_PSR484_487
485 INTC_PSR484_487
486 INTC_PSR484_487
487 INTC_PSR484_487
504 INTC_PSR504_507
505 INTC_PSR504_507
NOTE
The peripheral or software settable interrupt request asserts when the PRIn
value in the interrupt priority select register (INTC_PSRn) is greater than
the PRIn value in interrupt current priority register (INTC_CPR).
If an asserted peripheral or software settable interrupt request negates before
the processor acknowledges its request, the interrupt request can reassert
and remain asserted. If this occurs, the processor uses the INTC_PSRn value
to locate the IRQ vector, and updates the PRIn value in the INTC_CPR with
the PRIn value in INTC_PSRn.
Clearing the peripheral interrupt request enable bit for the peripheral
initiating the request, or setting the IRQ mask bit has the same consequences
as clearing its flag bit. Setting its enable bit or clearing its mask bit while its
flag bit is asserted has the same effect on the INTC as an interrupt event
setting the flag bit.
The time from the write to the SETn bit to the time that the INTC starts to drive the interrupt request to the
processor is four clocks.
Clock
Interrupt Request
to Processor
Hardware Vector
Enable
Interrupt Vector 0
Interrupt
Acknowledge
Read
INTC_IACKR_PCRn
Write
INTC_EOIR_PCRn
INTVEC in
INTC_IACKR_PCRn 0 108
PRI in
INTC_CPR_PCRn 0 1 0
Peripheral Interrupt
Request 100
Clock
Interrupt Request
to Processor
Hardware Vector
Enable
Interrupt
Acknowledge
Read
INTC_IACKR_PCRn
Write
INTC_EOIR_PCRn
INTVEC in
INTC_IACKR_PCRn 0 108
PRI in
INTC_CPR_PCRn 0 1 0
Peripheral Interrupt
Request 100
epilog:
code to restore most of context required by e500 EABI
# Popping the LIFO after the restoration of most of the context and the disabling of processor
# recognition of interrupts eases the calculation of the maximum stack depth at the cost of
# postponing the servicing of the next interrupt request.
mbar # ensure store to clear flag bit has completed
lis r3,INTC_EOIR_PRCn@ha # form adjusted upper half of INTC_EOIR address
li r4,0x0 # form 0 to write to INTC_EOIR_PRCn
wrteei 0 # disable processor recognition of interrupts
stw r4,INTC_EOIR_PRCn@l(r3) # store to INTC_EOIR_PRCn, informing INTC to lower priority
code to restore SRR0 and SRR1, restore working registers, and delete stack frame
rfi
vector_table_base_address:
address of ISR for interrupt with vector 0
address of ISR for interrupt with vector 1
.
.
.
address of ISR for interrupt with vector 510
address of ISR for interrupt with vector 511
ISRx:
code to service the interrupt event
code to clear flag bit which drives interrupt request to INTC
interrupt_exception_handler_continuedx:
code to create stack frame, save working register, and save SRR0 and SRR1
epilog:
code to restore most of context required by e500 EABI
# Popping the LIFO after the restoration of most of the context and the disabling of processor
# recognition of interrupts eases the calculation of the maximum stack depth at the cost of
# postponing the servicing of the next interrupt request.
mbar # ensure store to clear flag bit has completed
lis r3,INTC_EOIR_PRCn@ha # form adjusted upper half of INTC_EOIR_PRCn address
li r4,0x0 # form 0 to write to INTC_EOIR_PRCn
wrteei 0 # disable processor recognition of interrupts
stw r4,INTC_EOIR_PRCn@l(r3) # store to INTC_EOIR_PRCn, informing INTC to lower priority
code to restore SRR0 and SRR1, restore working registers, and delete stack frame
rfi
ISRx:
code to service the interrupt event
code to clear flag bit which drives interrupt request to INTC
If a task shares a resource with an ISR and the PCP is being used to manage that shared resource, then the
task’s priority can be elevated in the INTC_CPR_PRCn while the shared resource is being accessed.
An ISR whose PRIn in INTC priority select registers (INTC_PSR0–INTC_PSR511) has a value of 0 does
not cause an interrupt request to the selected processor, even if its peripheral or software settable interrupt
request is asserted. For a peripheral interrupt request, not setting its enable bit or disabling the mask bit
causes it to remain negated, which consequently also does not cause an interrupt request to the processor.
Since the ISRs are outside the control of the RTOS, this ISR does not run unless called by another ISR or
the interrupt exception handler, perhaps after executing another ISR.
Either just before or at the same time as the first store, the INTC asserts the interrupt request to the
processor because the peripheral interrupt request for ISR2 has asserted.
As the processor is responding to the interrupt request from the INTC, and as it is aborting transactions
and flushing its pipeline, it is possible that both of these stores will be executed. ISR2 thereby thinks that
it can access the data block coherently, but the data block has been corrupted.
When the Current Priority Register’s (CPR’s) PRI field in the INTC is updated by software, external
interrupts from the INTC to the Core can be disabled so that an external interrupt will never be taken in
the window of time when a system resource (PRI field) is being changed. Disabling interrupts and
re-enabling them after the PRI elevation, as well as providing additional core clocks of delay after
interrupts have been enabled, provides enough delay for the ISR that has elevated its PRI to be interrupted
by a pending ISR before the ISR elevating PRI accesses a shared memory block.
To ensure coherent access to the shared data block, modifications to PRI in INTC_CPR_PRCx can be
made by services managing shared resources with the following code sequence:
• disable processor recognition of interrupts
• PRI modification (guarded, cache inhibited)
• enable processor recognition of interrupts
• delay 5 core clocks
• coherent data access
The delay of 5 clocks minimum can be achieved by the following series of instructions:
or r1, r1, r1
or r1, r1, r1
or r1, r1, r1
or r1, r1, r1
or r1, r1, r1
The or r1, r1, r1 is not dual issued because the destination of one “or” instruction is the source of the next,
hence they can not be executed in parallel.
Clock
B
Interrupt Request
to Processor
Hardware Vector
Enable
Interrupt Vector 0
Interrupt
Acknowledge C
Write
INTC_CPR E
Read
INTC_IACKR H
Write
INTC_EOIR
INTVEC in
INTC_IACKR 108 208
D F I
PRI in
INTC_CPR 1 3 2 3
Peripheral Interrupt
Request 100 A
G
Peripheral Interrupt
Request 200
Event Description
A Peripheral interrupt request 200 asserts during execution of ISR108 running at priority 1.
B Interrupt request to processor asserts. INTVEC in INTC_IACKR updates with vector for that peripheral interrupt request.
C ISR108 writes to INTC_CPR to raise priority to 3 before accessing shared coherent data block.
D PRI in INTC_CPR now at 3, reflecting the write. This write, just before accessing data block, is the last instruction the processor
executes before being interrupted.
F PRI of 3 pushed onto LIFO. PRI in INTC_CPR updates to 2, the priority of ISR208.
G ISR208 clears its flag bit, deasserting its peripheral interrupt request.
I LIFO pops 3, restoring the raised priority onto PRI in INTC_CPR. Next value to pop from LIFO is the priority from before
peripheral interrupt request 100 interrupted. ISR108 now can access data block coherently after interrupt exception handler
executes rfi instruction.
After generating a software settable interrupt request, the higher priority ISR completes. The lower priority
ISR is scheduled according to its priority. Execution of the higher priority ISR is not resumed after the
completion of the lower priority ISR.
whose ISR presently is executing. This negating of a peripheral interrupt request outside of its ISR can be
a desired effect.
When you are finished examining the LIFO contents, you can restore it in software vector mode using the
following code sequence:
push_lifo:
load stacked PRI value and store to INTC_CPR_PRCn
load INTC_IACKR_PRCn
if stacked PRI values are not depleted, branch to push_lifo
NOTE
Reading the INTC_IACKR_PRCn acknowledges the interrupt request to
the processor and updates the INTC_CPR_PRCn[PRI] with the priority of
the preempting interrupt request. If the processor recognition of interrupts is
disabled during the LIFO restoration, interrupt requests to the processor can
go undetected. However, since the peripheral or software settable interrupt
requests are not cleared, the peripheral interrupt request to the processor
re-asserts when INTC_CPR_PRCn[PRI] is lower than the priorities of those
peripheral or software settable interrupt requests.
XBAR
ports
Core 0
Core 1 EBI
FlexRay PBRDIGE_B
Table 28-1 enumerates the MPU Ports that are attached to slave modules. The Master IDs of all bus master
modules are also shown, as their values are required to configure certain MPU registers described in this
chapter.
Table 28-1. XBAR Switch Ports
28.1.2 Features
The MPU has these major features:
• Support for 16 memory region descriptors, each 128 bits in size
— Specification of start and end addresses provide granularity for region sizes from 32 bytes to
4 GB
— MPU is invalid at reset, thus no access restrictions are enforced
— Two types of access control definitions: processor core bus master (e200z7) supports the
traditional {read, write, execute} permissions with independent definitions for supervisor and
user mode accesses; the remaining non-core bus masters (eDMA_A, eDMA_B, FlexRay)
support {read, write} attributes
— Automatic hardware maintenance of the region descriptor valid bit removes issues associated
with maintaining a coherent image of the descriptor
— Alternate memory view of the access control word for each descriptor provides an efficient
mechanism to dynamically alter the access rights of a descriptor only
— For overlapping region descriptors, priority is given to permission granting over access
denying as this approach provides more flexibility to system software
• Support for four AHB slave port connections
— PBRIDGE_A, PBRIDGE_B, EBI (development bus), general purpose SRAM
— MPU hardware monitors every AHB slave port access using the pre-programmed memory
region descriptors
— An access protection error is detected if a memory reference does not hit in any memory region
or the reference is flagged as illegal in all memory regions where it does hit; in the event of an
access error, the AHB reference is terminated with an error response and the MPU inhibits the
bus cycle being sent to the targeted slave device
— 64-bit error registers, one for each AHB slave port, capture the last faulting address, attributes,
and detail information
Offset from
MPU_BASE Register Bits Access Reset Value Section/Page
(0xFFF1_0000)
Offset from
MPU_BASE Register Bits Access Reset Value Section/Page
(0xFFF1_0000)
Offset from
MPU_BASE Register Bits Access Reset Value Section/Page
(0xFFF1_0000)
Field Description
0–7 MPU port n Error (where the MPU port number matches the bit number (see Figure 28-1)). Each bit in this read-only
SPERR field represents a flag maintained by the MPU for signaling the presence of a captured error contained in the
MPU_EARn and MPU_EDRn registers. The individual bit is set when the hardware detects an error and records the
faulting address and attributes. It is cleared when the corresponding bit is written to a logical one. If another error is
captured at the exact same cycle as a write of a logical one, this flag remains set. A find-first-one instruction (or
equivalent) can be used to detect the presence of a captured error.
0 The corresponding MPU_EARn/MPU_EDRn registers do not contain an unread captured error
1 The corresponding MPU_EARn/MPU_EDRn registers do contain an unread captured error
Note: Bit 0 indicates an EBI protection error, bit 1 indicates an SRAM protection error, bit 2 indicates a peripheral
bridge B protection error, and bit 3 indicates a peripheral bridge A protection error.
8–11 Reserved
12–15 Hardware Revision Level. This 4-bit read-only field specifies the MPU’s hardware and definition revision level. It can
HRL be read by software to determine the functional definition of the module. This field reads as 0 on this device.
16–19 Number of MPU ports. This 4-bit read-only field specifies the number of slave ports connected to the MPU.
NSP This field reads as 0b0100 on this device.
Field Description
20–23 Number of Region Descriptors. This 4-bit read-only field specifies the number of region descriptors implemented in
NRGD the MPU. The defined encodings include:
0000 8 region descriptors
0010 16 region descriptors
This field reads as 0b0010 on this device.
24–30 Reserved
31 Valid. This bit provides a global enable/disable for the MPU.
VLD 0 The MPU is disabled
1 The MPU is enabled
While the MPU is disabled, all accesses from all bus masters are allowed.
Field Description
0–31 Error Address. This read-only field is the reference address from MPU port n that generated the access error.
EADDR
Field Description
0–15 Error Access Control Detail. This 16-bit read-only field implements one bit per region descriptor and is an indication
EACD of the region descriptor hit logically-ANDed with the access error indication. The MPU performs a
reference-by-reference evaluation to determine the presence/absence of an access error. When an error is
detected, the hit-qualified access control vector is captured in this field.
If the MPU_EDRn register contains a captured error and the EACD field is all zeroes, this signals an access that did
not hit in any region descriptor. All non-zero EACD values signal references that hit in a region descriptor(s), but
failed due to a protection error as defined by the specific set bits.
16–23 Error Process Identification. This 8-bit read-only field records the process identifier of the faulting reference. The
EPID process identifier is typically driven by processor cores only; for other bus masters, this field is cleared.
24–27 Error Master Number. This 4-bit read-only field records the logical master number of the faulting reference. This field
EMN is used to determine the bus master that generated the access error.
28–30 Error Attributes. This 3-bit read-only field records attribute information about the faulting reference. The supported
EATTR encodings are defined as:
000 User mode, instruction access
001 User mode, data access
010 Supervisor mode, instruction access
011 Supervisor mode, data access
All other encodings are reserved. For non-core bus masters, the access attribute information is typically wired to
supervisor, data (0b011).
31 Error Read/Write. This 1-bit read-only field signals the access type (read, write) of the faulting reference.
ERW 0 Read
1 Write
Field Description
0–26 Start Address. This field defines the most significant bits of the 0-modulo-32 byte start address of the memory
SRTADDR region.
27–31 Reserved
Field Description
0–26 End Address. This field defines the most significant bits of the 31-modulo-32 byte end address of the memory
ENDADDR region. There are no hardware checks to verify that ENDADDR > SRTADDR; the software must properly load
these region descriptor fields.
27–31 Reserved
identification field within the definition. Bus masters 4–7 are typically reserved for data movement
engines and their capabilities are limited to separate read and write permissions. For these fields, the bus
master number refers to the logical master number defined as the AHB hmaster[3:0]signal.
For the processor privilege rights, there are three flags associated with this function: {read, write, execute}.
In this context, these flags follow the traditional definition:
• Read (r) permission refers to the ability to access the referenced memory address using an operand
(data) fetch.
• Write (w) permission refers to the ability to update the referenced memory address using a store
(data) instruction.
• Execute (x) permission refers to the ability to read the referenced memory address using an
instruction fetch.
The evaluation logic defines the processor access type based on multiple AHB signals: read or write as
specified by the hwrite signal and the low-order two bits of hprot[1:0], which identify a data reference
versus an instruction fetch and the operating mode (supervisor, user) of the requesting processor.
For non-processor data movement engines (bus masters 4–7), the evaluation logic simply uses hwrite to
determine if the access is a read or write. The hprot[1:0] signal is ignored for these masters.
Writes to this word clear the region descriptor’s valid bit. Because it is also expected that system software
may adjust only the access controls within a region descriptor (MPU_RGDn.Word2) as different tasks
execute, an alternate programming view of this 32-bit entity is provided. If only the access controls are
being updated, this operation should be performed by writing to MPU_RGDAACn (alternate access
control n) as stores to these locations do not affect the descriptor’s valid bit.
Offset: MPU_BASE + 0x400 + (16*n) + 0x8 (MPU_RGDn.Word2) Access: User read/write
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 0 0 0 0 0 0 0 0
M6RE M6WE M5RE M5WE M4RE M4WE
W
Reset
0 0 0 0 0 0 0 0 0 1 1 0 0 0 0 1
(n=0)
Reset
0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
(n>0)
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R 0 0 0 0 M1UM M0UM
M1PE M1SM M0PE M0SM
W r w x r w x
Reset
1 0 0 0 0 1 1 0 0 0 0 0 0 0 0 0
(n=0)
Reset
0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
(n>0)
Note: Refer to Table 28-1to see the Master ID assignments.
Figure 28-7. MPU Region Descriptor, Word 2 Register (MPU_RGDn.Word2)
Field Description
Note: For future code compatibility, do not change the value of reserved bits from their reset value
0–1 Reserved
2 Bus Master ID n Read Enable. If set, this flag allows bus master ID n to perform read operations. If cleared, any
4 attempted read by bus master ID n terminates with an access error and the read is not performed.
6 Note: See Table 28-1 for the MPU Master ID list.
MnRE
3 Bus Master ID n Write Enable. If set, this flag allows bus master ID n to perform write operations. If cleared, any
5 attempted write by bus master ID n terminates with an access error and the write is not performed.
7 Note: See Table 28-1 for the MPU Master ID list.
MnWE
8–25 Reserved
M1PE Bus Master ID 1Process Identifier Enable. If set, this flag specifies that the process identifier and mask defined in
MPU_RGDn.Word3 are to be included in the region hit evaluation. If cleared, the region hit evaluation does not
include the process identifier.
Note: See Table 28-1 for the MPU Master ID list.
M1SM Bus Master ID 1Supervisor Mode Access Control. This 2-bit field defines the access controls for bus master ID 1
when operating in supervisor mode. The M1SM field is defined as:
00 r, w, x = read, write and execute allowed
01 r, –, x = read and execute allowed, but no write
10 r, w, – = read and write allowed, but no execute
11 Same access controls as that defined by M1UM for user mode
Note: See Table 28-1 for the MPU Master ID list.
M1UM Bus Master ID 1User Mode Access Control. This 3-bit field defines the access controls for bus master ID 1when
operating in user mode. The M1UM field consists of three independent bits, enabling read, write, and execute
permissions: {r,w,x}. If set, the bit allows the given access type to occur; if cleared, an attempted access of that
mode may be terminated with an access error (if not allowed by any other descriptor) and the access not performed.
Note: See Table 28-1 for the MPU Master ID list.
26 Bus Master ID 0 Process Identifier Enable. If set, this flag specifies that the process identifier and mask defined in
M0PE MPU_RGDn.Word3 are to be included in the region hit evaluation. If cleared, the region hit evaluation does not
include the process identifier.
Note: See Table 28-1 for the MPU Master ID list.
27–28 Bus Master ID 0 Supervisor Mode Access Control. This 2-bit field defines the access controls for bus master ID 0
M0SM when operating in supervisor mode. The M0SM field is defined as:
00 r, w, x = read, write and execute allowed
01 r, –, x = read and execute allowed, but no write
10 r, w, – = read and write allowed, but no execute
11 Same access controls as that defined by M0UM for user mode
Note: See Table 28-1 for the MPU Master ID list.
29–31 Bus Master ID 0 User Mode Access Control. This 3-bit field defines the access controls for bus master ID 0 when
M0UM operating in user mode. The M0UM field consists of three independent bits, enabling read, write, and execute
permissions: {r, w, x}. If set, the bit allows the given access type to occur; if cleared, an attempted access of
that mode may be terminated with an access error (if not allowed by any other descriptor) and the access not
performed.
Note: See Table 28-1 for the MPU Master ID list.
Field Description
0–7 Process Identifier. This 8-bit field specifies that the optional process identifier is to be included in the determination
PID of whether the current access hits in the region descriptor. This field is combined with the PIDMASK and included
in the region hit determination if MPU_RGDn.Word2[MxPE] is set.
8–15 Process Identifier Mask. This 8-bit field provides a masking capability so that multiple process identifiers can be
PIDMASK included as part of the region hit determination. If a bit in the PIDMASK is set, the corresponding bit of the PID is
ignored in the comparison. This field is combined with the PID and included in the region hit determination if
MPU_RGDn.Word2[MxPE] is set. For more information on the handling of the PID and PIDMASK, see
Section 28.3.1.1, “Access Evaluation—Hit Determination”.
16–30 Reserved
31 Valid. This bit signals the region descriptor is valid. Any write to MPU_RGDn.Word{0,1,2} clears this bit, but a write
VLD to MPU_RGDn.Word3 sets or clears this bit depending on bit 31 of the write operand.
0 Region descriptor is invalid
1 Region descriptor is valid
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R 0 0 0 0 M1UM M0UM
M1PE M1SM M0PE M0SM
W r w x r w x
Reset
1 0 0 0 0 1 1 0 0 0 0 0 0 0 0 0
(n=0)
Reset
0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
(n>0)
Because the MPU_RGDAACn register is another memory mapping for MPU_RGDn.Word2, the field
definitions shown in Table 28-10 are identical to those presented in Table 28-8.
Table 28-10. MPU_RGDAAC Bit Field Descriptions
Field Description
Note: For future code compatibility, do not change the value of reserved bits from their reset value
0–1 Reserved
2 Bus Master ID n Read Enable. If set, this flag allows bus master ID n to perform read operations. If cleared, any
4 attempted read by bus master ID n terminates with an access error and the read is not performed.
6 Note: See Table 28-1 for the MPU Master ID list.
MnRE
3 Bus Master n Write Enable. If set, this flag allows bus master n to perform write operations. If cleared, any attempted
5 write by bus master n terminates with an access error and the write is not performed.
7 Note: See Table 28-1 for the MPU Master ID list.
MnWE
8–25 Reserved
Field Description
M1PE Bus Master ID 1Process Identifier Enable. If set, this flag specifies that the process identifier and mask defined in
MPU_RGDn.Word3 are to be included in the region hit evaluation. If cleared, the region hit evaluation does not
include the process identifier.
Note: See Table 28-1 for the MPU Master ID list.
M1SM Bus Master ID 1Supervisor Mode Access Control. This 2-bit field defines the access controls for bus master ID 1
when operating in supervisor mode. The M1SM field is defined as:
00 r, w, x = read, write and execute allowed
01 r, –, x = read and execute allowed, but no write
10 r, w, – = read and write allowed, but no execute
11 Same access controls as that defined by M1UM for user mode
Note: See Table 28-1 for the MPU Master ID list.
M1UM Bus Master ID 1User Mode Access Control. This 3-bit field defines the access controls for bus master ID 1when
operating in user mode. The M1UM field consists of three independent bits, enabling read, write, and execute
permissions: {r,w,x}. If set, the bit allows the given access type to occur; if cleared, an attempted access of that
mode may be terminated with an access error (if not allowed by any other descriptor) and the access not performed.
Note: See Table 28-1 for the MPU Master ID list.
26 Bus Master 0 Process Identifier Enable. If set, this flag specifies that the process identifier and mask (defined in
M0PE MPU_RGDn.Word3) are to be included in the region hit evaluation. If cleared, then the region hit evaluation does
not include the process identifier.
27–28 Bus Master 0 Supervisor Mode Access Control. This 2-bit field defines the access controls for bus master 0 when
M0SM operating in supervisor mode. The M0SM field is defined as:
00 r, w, x = read, write and execute allowed
01 r, –, x = read and execute allowed, but no write
10 r, w, – = read and write allowed, but no execute
11 Same access controls as that defined by M0UM for user mode
Note: See Table 28-1 for the MPU Master ID list.
29–31 Bus Master 0 User Mode Access Control. This 3-bit field defines the access controls for bus master 0 when
M0UM operating in user mode. The M0UM field consists of three independent bits, enabling read, write, and execute
permissions: {r, w, x}. If set, the bit allows the given access type to occur; if cleared, an attempted access of
that mode may be terminated with an access error (if not allowed by any other descriptor) and the access not
performed.
Note: See Table 28-1 for the MPU Master ID list.
can retrieve the captured error address and detail information simply be reading the
MPU_E{A,D}Rn registers. Information on which error registers contain captured fault data is
signaled by MPU_CESR[SPERR].
6. Finally, consider the use of overlapping region descriptors. Application of overlapping regions can
reduce the number of descriptors required for a given set of access controls. In the overlapping
memory space, the protection rights of the corresponding region descriptors are logically summed
together (the boolean OR operator). In the following example of a dual-core system, there are four
bus masters: the two processors (CP0, CP1) and two DMA engines (eDMA, a traditional data
movement engine transferring data between RAM and peripherals, and FlexRay, a second engine
transferring data to/from the RAM only). Consider the following region descriptor assignments:
Region Description RGDn CP0 CP1 eDMA FlexRay
In this example, there are eight descriptors used to span nine regions in the three main spaces of
the system memory map (flash, RAM, and peripheral space). Each region indicates the specific
permissions for each of the four bus masters and this definition provides an appropriate set of
shared, private and executable memory spaces.
Of particular interest are the two overlapping spaces: region descriptors 2 and 3, and 3 and 4.
The space defined by RGD2 with no overlap is a private data and stack area that provides
read/write access to CP0 only. The overlapping space between RGD2 and RGD3 defines a shared
data space for passing data from CP0 to CP1 and the access controls are defined by the logical OR
of the two region descriptors. Thus, CP0 has (rw- | r--) = (rw-) permissions, while CP1 has
(--- | r--) = (r--) permission in this space. Both DMA engines are excluded from this shared
processor data region. The overlapping spaces between RGD3 and RGD4 defines another shared
data space, this one for passing data from CP1 to CP0. For this overlapping space, CP0 has (r--
| ---) = (r--) permission, while CP1 has (rw- | r--) = (rw-) permission. The
non-overlapped space of RGD4 defines a private data and stack area for CP1 only.
The space defined by RGD5 is a shared data region, accessible by all four bus masters. Finally, the
slave peripheral space mapped onto the peripheral bus is partitioned into two regions: one (RGD6)
containing the MPU’s programming model accessible only to the two processor cores, and the
remaining peripheral region (RGD7) accessible to both processors and the traditional eDMA
master.
This example is intended to show one possible application of the capabilities of the memory
protection unit in a typical system.
29.1.1 Overview
This section describes the function of the Periodic Interrupt Timer block (PIT_RTI). The PIT is an array
of timers that can be used to generate interrupts. It also provides a dedicated Real Time Interrupt Timer
(RTI), which runs on a separate clock and can be used for system wakeup from low power mode.
Independent
RTI Oscillator
PIT_RTI
Clock
load_value
RTI
timeout
Peripheral PIT
Bus Registers
Timer 0
.
Interrupts .
.
.
.
.
Timer 3
Peripheral
Bus Clock
29.1.3 Features
The main features of this block are:
• Timers can be configured to generate interrupts
• All interrupts are maskable
• Independent timeout periods for each timer and RTI
• RTI can be used to generate a CPU wake-up interrupt
• RTI clock source is the crystal oscillator, no pre-scalars are used
• PIT timer clock source is the peripheral clock, no pre-scalars are used
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
0
R 0 0 0 0 0 0 0 0 0 0 0 0 MDIS
MDIS FRZ
W _RTI
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Field Description
0–2 Reserved
29 Module Disable - RTI section. This is used to disable the RTI timer. This bit should be enabled before
MDIS_RTI any RTI setup is done.
0 Clock for RTI is enabled
1 Clock for RTI disabled
Field Description
30 Module Disable - (PIT section). This is used to disable the standard timers. The RTI timer is not affected
MDIS by this bit. This bit should be enabled before any other setup is done.
0 Clock for PIT Timers is enabled
1 Clock for PIT Timers is disabled
31 Freeze. Allows the timers to be stopped when the device enters debug mode.
FRZ 0 = Timers continue to run in debug mode.
1 = Timers are stopped in debug mode.
Field Description
0–31 Time Start Value Bits. These bits set the timer start value. The timer counts down until it reaches 0,
TSV then it generates an interrupt and loads this register value again. Writing a new value to this register
does not restart the timer, instead the value is loaded once the timer expires. To abort the current
cycle and start a timer period with the new value, the timer must be disabled and enabled again (see
Figure 29-8).
Field Description
0–31 Current Timer Value. These bits represent the current timer value. Note that the timer uses a
TVL downcounter.
NOTE: The timer values are frozen in Debug mode if the FRZ bit is set in the PIT Module Control
Register (see Figure 29-2)
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R 0 0 0 0 0 0 0 0 0 0 0 0 0 0
TIE TEN
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Field Description
0–29 Reserved
30 Timer Interrupt Enable Bit.
TIE 0 Interrupt requests from Timer x are disabled
1 Interrupt is requested whenever TIF is set
When an interrupt is pending (TIF set), enabling the interrupt immediately causes an interrupt event.
To avoid this, the associated TIF flag must be cleared first.
31 Timer Enable Bit.
TEN 0 Timer is disabled
1 Timer is active
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 TIF
W w1c
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Field Description
0–30 Reserved
31 Time Interrupt Flag. TIF is set to 1 at the end of the timer period.This flag can be cleared only by
TIF writing it with a 1. Writing a 0 has no effect. If enabled (TIE = 1), TIF causes an interrupt request.
0 Time-out has not yet occurred
1 Time-out has occurred
29.4.1 General
This section gives detailed information on the internal operation of the module. Each timer can be used to
generate a unique interrupt vector.
29.4.1.1 Timers
Once enabled, the timers can be configured to generate interrupts at periodic intervals. The timer loads its
start value, as specified in the LDVAL register, then counts down until the count reaches 0. Then the value
in the LDVAL register is loaded again and the process repeats. Each time the timer reaches 0, an interrupt
is generated if enabled, and the interrupt flag is set.
All interrupts can be enabled or masked (by setting the TIE bits in the TCTRL registers). A new interrupt
can be generated only after the previous one is cleared.
If desired, the current counter value of the timer can be read via the CVAL registers.
The counter period can be restarted, by first disabling, then enabling the timer with the TEN bit (see
Figure 29-7).
The counter period of a running timer can be modified, by first disabling the timer, setting a new load value
and then enabling the timer again (see Figure 29-8). In the case of the RTI, because of the different clock
domains (system clock / oscillator clock), a delay must be respected between setting the new value and
re-enabling the RTI.
It is also possible to change the counter period without restarting the timer by writing the LDVAL register
with the new load value. This value is loaded after the next trigger (counter reaches 0) event (see
Figure 29-9).
Trigger
Event
p1 p1 p1 p1
Trigger
Event
p1 p1 p1 p2 p2
29.4.2 Interrupts
All of the timers support interrupt generation. Refer to Section 27.4.1, “External Interrupt Request
Sources”, for related vector addresses and priorities.
Timer interrupts can be disabled by setting the timer PIT_CHn_TCTRL[TIE] bit to zero. The
PIT_CHn_TFLG[TIF] bit is set to 1 when a timeout occurs on the associated timer, and is cleared by
writing a 1 to that bit.
// RTI
PIT_RTI_LDVAL = 0x004C4B3F; // setup RTI for 5000000 cycles
PIT_RTI_TCTRL[TIE] = 1; // let RTI generate interrupts
PIT_RTI_TCTRL[TEN] = 1; // start RTI
// Timer 1
PIT_CH1_LDVAL = 0x0003E7FF; // setup timer 1 for 256000 cycles
PIT_CH1_TCTRL[TIE] = 1; // enable Timer 1 interrupts
PIT_CH1_TCTRL[TEN] = 1; // start timer 1
29.5.2 Low Power Mode – Using the RTI for System Wakeup
This section describes the use of the low power mode, both with and without use of the RTI timer for
wakeup.
6. At the programmed RTI time interval, the RTI timer triggers an interrupt that is serviced by the
interrupt controller. (The interrupt controller is not put in low power mode by the SIU_HALT
register.) This interrupt also re-enables the CPU clock so that full CPU operation is restored.
7. In the RTI interrupt handler, the SIU_HALT register may be modified to restore operation as
desired. In some cases where periodic operation is preferred, the interrupt handler may perform a
set of tasks, and then write the SIU_HALT register mask and re-enter the low power mode by
executing the ‘msync’, ‘isync’, and ‘wait’ instructions again. The next RTI timeout repeats the
process.
NOTE
The RTI is a convenient mechanism for waking up the CPU in a controlled state once placed in low power
mode. However, the CPU will also exit low power mode under any of the following conditions:
• Any external interrupt from interrupt controller
• Critical interrupt
• NMI event
• Core watchdog timeout
• Core fixed interval timeout
• Core decrementer timeout
• Various debug events
30.1.1 Terminology
Table 30-1. Terms and Acronyms
Terms Description
Pipeline Act of initiating a bus cycle while another bus cycle is in progress. Thus, the bus can have
multiple bus cycles pending at one time.
Slave A bus slave is a device that responds to a bus transaction, but never initiates a cycle on the
bus.
Transaction A bus transaction consists of an address transfer (address phase) and one or more data
transfer(s) (data phase).
AXBS
MUX Logic
32
AMBA AHB 32
Peripheral On-Chip Peripherals
32 Bridge
AMBA AHB (PBRIDGE) 32
AMBA AHB
30.1.3 Features
The PBRIDGE has these major features:
• PBRIDGE supports the slave interface signals. This interface is meant for slave peripherals only.
• PBRIDGE supports 32-bit peripherals. (Byte, halfword, and word reads and write are supported to
each.)
• Read and write accesses of 32 bits or less require two clocks, provided they do not cross a 32-bit
boundary.
— Read and write accesses that cross a 32-bit boundary are not supported.
• The peripherals connected to the PBRIDGE may be configured in groups to run at less than the
system clock frequency.
• If a peripheral’s clock is disabled, PBRIDGE will generate a bus termination error if an access to
that peripheral is attempted.
Term Description
SoC System-on-Chip
31.1.2 Features
The STCU contains the following features:
• Supports software to test the CPU Cores during normal operation.
• Allows software to run LBIST individually.
• Does not allow programming until unlocked by a specific key sequence.
• Able to stop in mid-sequence of the test by writing to the STCU_ABORT bit.
REG IF: Register Interface interacts with the internal bus to program the registers that are defined in the
Memory Map Section.
Watchdog Timer: The Watchdog Timer provides a method of aborting LBIST execution after a
programmable number of system clocks has elapsed. After the STCU starts, the watchdog timer starts
counting from the value loaded in the TIMEOUT register. When the watchdog timer reaches zero the first
time, the STCU issues an interrupt and reloads the watchdog timer with the initial TIMEOUT value. If the
SoC does not react to the interrupt before the watchdog timer expires, the STCU requests a reset. When
the STCU finishes testing, it resets the watchdog timer with the TIMEOUT value.
CRC: The Cyclic Redundancy Code uses the CRC-8-Dallas/Maxim polynomial (x8+x5+x4+x1). The
CRC-8 engine monitors the outputs of the LBIST interface logic to make sure that the correct output
sequence is sent to the LBIST State Machine.
STCU FSM: The STCU FSM coordinates the LBIST sequences and reports the status of the LBIST and
watches for the watchdog expiring. After the STCU FSM finishes, it generates an interrupt to the Interrupt
Controller to allow software to check the status of the STCU.
LBIST Interface Logic: The LBIST Interface Logic controls the LBIST and Clock Control outputs during
an STCU test.
Interrupt Logic: The Interrupt Logic monitors the watchdog expired flag and the STCU Done flag. When
an interrupt condition occurs, the STCU asserts its interrupt so that software can check the STCU.
Absolute address
(hex) + Register name Width (in bits) Access Reset value Section
0xC3FF_4000
Absolute address
(hex) + Register name Width (in bits) Access Reset value Section
0xC3FF_4000
Bit 31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16
LBIST_CLK_DIV
R 0 0 0 0 0
SOFT_RESET
W
LBE FLF FCF
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Bit 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
R 0 0
IE
W o
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Field Description
31 This read-only bit is reserved and always has the value zero.
Reserved
29 This read-only bit is reserved and always has the value zero.
Reserved
28 This read-only bit is reserved and always has the value zero.
Reserved
25 This read-only bit is reserved and always has the value zero.
Reserved
21–17 This read-only bit-field is reserved and always has the value zero.
Reserved
Field Description
16 When this bit is asserted, the STCU resets its internal state machines and the following memory mapped
SOFT_RES registers/bit-fields.
ET • STCU_ENABLE[STCU_START]
• STCU_STAT[STCUR,LBISTR, DNE, LDNE, ABORT, INIT_SEQ, WDE, CRC_RESULT]
• STCU_LBIST_STATUS
The SOFT_RESET bit can be asserted directly by the CPU when it writes to the CTRL register, but it is also
asserted when global soft reset is requested at the MCU level. Since soft reset is synchronous and has to
follow a request/acknowledge procedure across clock domains, it may take some time to fully propagate its
effect. The SOFT_RESET bit remains asserted while reset is pending, and is automatically negated when
reset completes. Therefore, software can poll this bit to know when the soft reset has completed.
0 No reset requested.
1 Resets the registers mentioned in the field description.
15–9 This read-only bit-field is reserved and always has the value zero.
Reserved
8 Interrupt Enable
IE
The Interrupt Enable bit allows interrupts to be sent to the Interrupt Controller. Internal interrupts are
generated and stored without regard to this bit.
0 Disable asynchronous interrupts to the system. System software must poll the INTERRUPT[IFLAG] bit-field
to know if an interrupt has occurred.
1 Enable asynchronous interrupts to the system.
7–0 This read-only bit-field is reserved and always has the value zero.
Reserved
Bit 31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16
R 0 0
STCU_ABORT
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Bit 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
R 0 0
STCU_START
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Field Description
31–17 This read-only bit-field is reserved and always has the value zero.
Reserved
Field Description
15–1 This read-only bit-field is reserved and always has the value zero.
Reserved
Bit 31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16
LBISTR
STCUR
LDNE
0 0 0 DNE 0 0 0
Reset 0 0 0 0 0 0 0 0 0 ? ? 0 0 0 0 0
Bit 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
ABORT
R
LOCK
Reset 0 ? 1 ? ? ? ? 0 1 1 1 1 1 1 1 1
* Notes:
• WDE bit-field: DNE, LDNE, ABORT, INIT_SEQ, and WDE can only be cleared by a software reset. A hard reset does not
change the values of these registers.
Field Description
31–27 This read-only bit-field is reserved and always has the value zero.
Reserved
24 This read-only bit is reserved and always has the value zero.
Reserved
23 This read-only bit is reserved and always has the value zero.
Reserved
20 This read-only bit is reserved and always has the value zero.
Reserved
19–17 This read-only bit-field is reserved and always has the value zero.
Reserved
16 This read-only bit is reserved and always has the value zero.
Reserved
15 This read-only bit is reserved and always has the value zero.
Reserved
12–11 00 The STCU did not run before the last reset.
INIT_SEQ 01 The STCU was started by the IPS-interface
10 The JTAG Interfaces started the STCU. (Future Use)
11 Flash Fuse Loader started the STCU. (Future Use)
Field Description
8 This read-only bit is reserved and always has the value zero.
Reserved
Bit 31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
R
WATCHDOG_TIMER
W
Reset 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1
Field Description
Bit 31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
R 0
W STCU_KEY
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Field Description
Bit 31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16
R 0 0 0 0
WINDOW_SIZE PFT SCAN_ENABLE_ON SCAN_ENABLE_OFF
W
Reset 0 1 1 1 0 0 0 0 0 0 0 0 0 0 0 0
Bit 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
DEBUG
R 0 0 0
LSER
SHIFT_SPEED
W
Reset 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0
Field Description
31 This read-only bit is reserved and always has the value zero.
Reserved
27 This read-only bit is reserved and always has the value zero.
Reserved
24 This read-only bit is reserved and always has the value zero.
Reserved
23–20 Tells the controller how many clock cycles to delay the capture clock’s rising edge after the scan enable signal
SCAN_ENA is deasserted. For most applications, this is a zero, but if a speed path is expected, delaying the capture clock
BLE_ON is a way of diagnosing a speed path.
0000 0 delay cycles. The Capture Clock occurs on the next rising edge.
0001 1 delay cycle. The capture clock is not enabled for 1 cycle. The Capture Clock happens 2 rising edges
later.
0010 2 delay cycles.
0011 3 delay cycles.
0100 4 delay cycles.
0101 5 delay cycles.
0110 6 delay cycles.
0111 7 delay cycles.
1000 8 delay cycles
1001 9 delay cycles
1010 10 delay cycles
1011 11 delay cycles
1100 12 delay cycles
1101 13 delay cycles
1110 14 delay cycles
1111 15 delay cycles
Field Description
19–16 The SCAN_ENABLE_OFF values tell the LBIST controller how many clocks to mask after the capture clock
SCAN_ENA and turning the scan_enable block on. The capture clock cycle occurs, then on the negative edge the
BLE_OFF scan_enable signal asserts.
0000 0 delay cycles. There are no clocks masked after the capture clock.
0001 1 delay cycle. There is 1 clock masked after the capture clock and scan_enable asserting.
0010 2 delay cycles.
0011 3 delay cycles.
0100 4 delay cycles.
0101 5 delay cycles.
0110 6 delay cycles.
0111 7 delay cycles.
1000 8 delay cycles.
1001 9 delay cycles.
1010 10 delay cycles.
1011 11 delay cycles.
1100 12 delay cycles.
1101 13 delay cycles.
1110 14 delay cycles.
1111 15 delay cycles.
15–11 This read-only bit-field is reserved and always has the value zero.
Reserved
7–5 This read-only bit-field is reserved and always has the value zero.
Reserved
3–1 This read-only bit-field is reserved and always has the value zero.
Reserved
0 Sets up the LBIST engines and only runs 256 clock cycles to see that the LBIST engine was configured
DEBUG correctly and ran. This is different from the Diagnostics Mode by not stopping after each pattern and using
clock cycles.
Bit 31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
R
PC_START
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Field Description
Bit 31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
R
PC_END
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Field Description
Bit 31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
R
LBIST_PRPGH
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Field Description
Bit 31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
R
LBIST_PRPGL
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Field Description
Bit 31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
R 0 L L
B B
W E E
1 0
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Field Description
31–2 This read-only bit-field is reserved and always has the value zero.
Reserved
Bit 31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16
LBD1
LBD0
R
0
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 ? ?
Bit 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
R 0
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
* Notes:
• LBD0 bit-field:
Field Description
31–18 This read-only bit-field is reserved and always has the value zero.
Reserved
15–0 This read-only bit-field is reserved and always has the value zero.
Reserved
Bit 31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16
R 0
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Bit 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
IFLAG
R
0
W w1c
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Field Description
31–1 This read-only bit-field is reserved and always has the value zero.
Reserved
0 Interrupt Acknowledge
IFLAG
The Interrupt Flag can be read by the system software to see if an interrupt has occurred. This is useful if the
system software implements a polling technique and not interrupt-driven software code.
Writing a 1 to this bit clears the interrupt. Please note that the source of the interrupt (STCU Done, Watchdog
Timeout) must be cleared for the interrupt to be cleared.
0 No interrupt is pending.
1 An interrupt is pending. Writing a 1 to this bit clears this bit.
Bit 31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
R WATCHDOG_TIMER
Reset x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x*
* Notes:
• x = Undefined at reset.
Field Description
Bit 31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
R LBIST_MISRH0
W
Reset x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x*
* Notes:
• x = Undefined at reset.
Field Description
31–0 The LBIST_MISRH0 contains the most significant word of the MISR value for LBIST Engine 0. This is a
LBIST_MIS read-only register and contains the MISR value from the last run of the LBIST. It is the responsibility of the
RH0 User software to determine whether the MISR value is correct by comparing this register value to the
expected value provided by Freescale.
Bit 31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
R LBIST_MISRL0
Reset x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x*
* Notes:
* x = Undefined at reset.
Field Description
31–0 The LBIST_MISRL0 contains the least significant word of the MISR value for LBIST Engine 0. This is a
LBIST_MIS read-only register and contains the MISR value from the last run of the LBIST. It is the responsibility of the
RL0 User software to determine whether the MISR value is correct by comparing this register value to the
expected value provided by Freescale.
Bit 31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
R LBIST_MISRH1
Reset x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x*
* Notes:
• x = Undefined at reset
Field Description
31–0 The LBIST_MISRH1 contains the most significant word of the MISR value for LBIST Engine 1. This is a
LBIST_MIS read-only register and contains the MISR value from the last run of the LBIST. It is the responsibility of the
RH1 User software to determine whether the MISR value is correct by comparing this register value to the
expected value provided by Freescale.
Bit 31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
R LBIST_MISRL1
Reset x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x* x*
* Notes:
• x = Undefined at reset.
Field Description
31–0 The LBIST_MISRL1 contains the least significant word of the MISR value for LBIST Engine 1. This is a
LBIST_MIS read-only register and contains the MISR value from the last run of the LBIST. It is the responsibility of the
RL1 User software to determine whether the MISR value is correct by comparing this register value to the
expected value provided by Freescale.
Description
Initialize STCU_CTRL.
Write STCU_WDGT.
Initialize STCU_LBIST_CTRL.
Initialize STCU_LBIST_PC_START.
Initialize STCU_LBIST_PC_END.
Initialize STCU_LBIST_PRPGH.
Initialize STCU_LBIST_PRPGL.
Initialize STCU_LBIST_ENABLE.
Set STCU_ENABLE[STCU_START].
The above figure shows the system programming the STCU, the STCU programming the LBIST
controller, and the LBIST running and finishing.
0 peripheral_master
2
= =
master_eq_cpn 0 wdata bus
31
= = =
wdata_eq_{unlock, cp[0-1]_lock}
addr bus
decode
mux
0 rdata bus
cp0_semaphore_int cp1_semaphore_int 31
Peripheral Bus
32.1.2 Features
The semaphores module implements hardware-enforced semaphores as a peripheral device and has these
major features:
• Support for 16 hardware-enforced gates in a dual-processor configuration
— Each hardware gate appears as a three-state, 2-bit state machine, with all 16 gates mapped as
an array of bytes
– Three-state implementation
if gate = 0b00, then state = unlocked
if gate = 0b01, then state = locked by core 0 (master ID = 0)
if gate = 0b10, then state = locked by core 1 (master ID = 1)
– Uses the bus master ID number as a reference attribute plus the specified data patterns to
validate all write operations
– After it is locked, the gate must be unlocked by a write of zeroes from the locking processor
— Optionally enabled interrupt notification after a failed lock write provides a mechanism to
indicate the gate is unlocked
— Secure reset mechanisms are supported to clear the contents of individual semaphore gates or
notification logic, and clear_all capability
Offset from
Section/
SEMA4_BASE Register Access Reset Value
Page
(0xFFF2_4000)
0x0010–0x003F Reserved
0x0042–0x0047 Reserved
0x004A–0x07F Reserved
0x008A–0x00FF Reserved
0x0102 Reserved
Offset from
Section/
SEMA4_BASE Register Access Reset Value
Page
(0xFFF2_4000)
0x0106–0x3FFF Reserved
Field Description
GTFSM Gate Finite State Machine. The hardware gate is maintained in a three-state implementation, defined as:
00 The gate is unlocked (free).
01 The gate has been locked by core 0.
10 The gate has been locked by core 1.
11 This state encoding is never used and therefore reserved. Attempted writes of 0x03 are treated as no operation
and do not affect the gate state machine.
Note: The state of the gate reflects the last processor that locked it, which can be useful during system debug.
Field Description
INEn Interrupt Request Notification Enable n. This field is a bitmap to enable the generation of an interrupt notification
from a failed attempt to lock gate n.
0 The generation of the notification interrupt is disabled.
1 The generation of the notification interrupt is enabled.
Field Description
GNn Gate n Notification. This read-only field is a bitmap of the interrupt request notification from a failed attempt to lock
gate n.
0 No notification interrupt generated.
1 Notification interrupt generated.
Field Description
RSTGSM Reset Gate Finite State Machine. The reset state machine is maintained in a 2-bit, three-state implementation,
defined as:
00 Idle, waiting for the first data pattern write.
01 Waiting for the second data pattern write.
10 The 2-write sequence has completed. Generate the specified gate reset(s). After the reset is performed, this
machine returns to the idle (waiting for first data pattern write) state.
11 This state encoding is never used and therefore reserved.
Reads of the SEMA4_RSTGT register return the encoded state machine value. Note the RSTGSM = 0b10 state
is valid for a single machine cycle only, so it is impossible for a read to return this value.
RSTGMS Reset Gate Bus Master. This 3-bit read-only field records the Master ID of the bus master performing the gate
reset function. The reset function requires that the two consecutive writes to this register be initiated by the same
bus master to succeed. This field is updated each time a write to this register occurs.
Master Master ID
core 0 0
core 1 1
— 2
— 3
eDMA_A 4
eDMA_B 5
FlexRay 6
— 7
RSTGTN Reset Gate Number. This 8-bit field specifies the specific hardware gate to be reset. This field is updated by the
second write.
If RSTGTN < 64, then reset the single gate defined by RSTGTN, else reset all the gates. The corresponding
secure IRQ notification state machine(s) are also reset.
RSTGDP Reset Gate Data Pattern. This write-only field is accessed with the specified data patterns on the two consecutive
writes to enable the gate reset mechanism. For the first write, RSTGDP = 0xe2 while the second write requires
RSTGDP = 0x1d.
Field Description
RSTNSM Reset Notification Finite State Machine. The reset state machine is maintained in a 2-bit, three-state
implementation, defined as:
00 Idle, waiting for the first data pattern write.
01 Waiting for the second data pattern write.
10 The two-write sequence has completed. Generate the specified notification reset(s). After the reset is
performed, this machine returns to the idle (waiting for first data pattern write) state.
11 This state encoding is never used and therefore reserved.
Reads of the SEMA4_RSTNTF register return the encoded state machine value. Note the RSTNSM = 0b10 state
is valid for a single machine cycle only, so it is impossible for a read to return this value.
RSTNMS Reset Notification Bus Master. This 3-bit read-only field records the Master ID of the bus master performing the
notification reset function. The reset function requires that the two consecutive writes to this register be initiated
by the same bus master to succeed. This field is updated each time a write to this register occurs.
Master Master ID
core 0 0
core 1 1
— 2
— 3
eDMA_A 4
eDMA_B 5
FlexRay 6
— 7
RSTNTN Reset Notification Number. This 8-bit field specifies the specific IRQ notification state machine to be reset. This
field is updated by the second write.
If RSTNTN < 64, then reset the single IRQ notification machine defined by RSTNTN, else reset all the
notifications.
RSTNDP Reset Notification Data Pattern. This write-only field is accessed with the specified data patterns on the two
consecutive writes to enable the notification reset mechanism. For the first write, RSTNDP = 0x47 while the
second write requires RSTNDP = 0xb8.
and stores a 1 into the lock variable. The single winner will see the 0, and the losers will see a 1
that was placed there by the winner. (The losers will continue to set the variable to the locked value,
but that doesn’t matter.) The winning processor executes the code after the lock and then stores a
0 into the lock when it exits, starting the race all over again. Testing the old value and then setting
to a new value is why the atomic swap instruction is called test and set in some instruction sets.”
[Hennessy/Patterson, Computer Architecture: A Quantitative Approach, ppg. 472-473]
The sole drawback to a hardware-based semaphore module is the limited number of semaphores versus
the infinite number that can be supported with Power Architecture reservation instructions.
if (i == 0)
locked_value = CP0_LOCK;
else
locked_value = CP1_LOCK;
/* read the current value of the gate and wait until the state == UNLOCK */
do {
current_value = gate[n];
} while (current_value != UNLOCK);
/* the current value of the gate == UNLOCK. attempt to lock the gate for this
33.1.1 Overview
The Software Watchdog Timer (SWT) is a peripheral module that can prevent system lockup in situations
such as software getting trapped in a loop or if a bus transaction fails to terminate. When enabled, the SWT
require periodic execution of a watchdog servicing operation. The servicing operation resets the timer to
a specified time-out period. If this servicing action does not occur before the timer expires the SWT
generates an interrupt or hardware reset. The SWT can be configured to generate a reset or interrupt on an
initial time-out; a reset is always generated on a second consecutive time-out.
The SWT interrupt is ‘ORed’ with the critical interrupt signal from the SIU and routed to the critical
interrupt inputs of the CPU; see the SIU chapter for details.
The SWT includes an interrupt status bit so the ISR software can determine if the critical interrupt request
came from the SWT or the external critical interrupt pin (WKPCFG_GPIO213).
The SWT can assert a reset when the watchdog timer expires. This reset will cause a system reset
equivalent to assertion of the RESET pin. The SIU_RSR register in the SIU indicates that an SWT was the
source of the reset.
33.1.2 Features
The SWT has the following features:
• 32-bit time-out register to set the time-out period
• Programmable selection of system or oscillator clock for timer operation
• Programmable selection of window mode or regular servicing
• Programmable selection of reset or interrupt on an initial time-out
• Programmable selection of fixed or keyed servicing
• Master access protection
• Hard and soft configuration lock bits
SWT_B_BASE 0xFFF3_4000
SWT_A_BASE 0xFFF3_8000
Offset from
SWT_A_BASE or Register Bits Access Reset Value Section/Page
SWT_B_BASE
NOTES:
1
Reset value is determined by SWT_MCR reset defined in Table 33-3.
2
If neither HLK or SLK lock bit in the SWT_MCR is set, the SWT_SK can be initialized by software to a non-zero value.
A 0xFF00010B1
B 0xFF00010A
NOTES:
1 This value is present after a hardware reset and
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
Reset 1 1 1 1 1 1 1 1 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
Reset 0 0 0 0 0 0 0 1 0 0 0 0 1 0 1 *1
Field Description
0–1 Master Access Protection for Master n where n represents the bus Master ID. A Nexus port shares its
4–7 core's protection attribute.
MAPn 0 = Access for the master is not enabled
1 = Access for the master is enabled
Once set, MAPn bit is cleared only by other masters that are not disabled, or only after the reset.
2–3 Reserved
8–21
24 Window Mode.
WND 0 = Regular mode, service sequence can be done at any time
1 = Windowed mode, the service sequence is only valid when the down counter is less than the value in
the SWT_WN register.
27 Soft Lock. This bit is cleared by writing the unlock sequence to the service register.
SLK 0 = SWT_MCR, SWT_TO, SWT_WN and SWT_SK are read/write registers if HLK=0
1 = SWT_MCR, SWT_TO, SWT_WN and SWT_SK are read only registers
28 Clock Selection. Selects the clock that drives the internal timer.
CSL 0 = System clock.
1 = Oscillator clock.
29 Reserved
30 Debug Mode Control. Allows the watchdog timer to be stopped when the device enters debug mode.
FRZ 0 = SWT counter continues to run in debug mode
1 = SWT counter is stopped in debug mode
31 Watchdog Enabled.
WEN 0 = SWT is disabled
1 = SWT is enabled
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
0
R 0 0 0 0 0 0 0 0 0 0 0 0 0 0 TIF
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Field Description
0–30 Reserved
31 Time-out Interrupt Flag. The flag and interrupt are cleared by writing a 1 to this bit. Writing a 0 has no
TIF effect.
0 = No interrupt request.
1 = Interrupt request due to an initial time-out.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R WTO
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 1 1 1 1 1 1 1 0 0 1 1 0 1 0 0 0 0
Field Description
0–31 Watchdog time-out period in clock cycles. An internal 32-bit down counter is loaded with this value or
WTO 0x100 which ever is greater when the service sequence is written or when the SWT is enabled.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R WST
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Field Description
0–31 Window start value. When window mode is enabled, the service sequence can only be written when the
WST internal down counter is less than this value.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
W WSC
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Field Description
0–15 Reserved
16–31 Watchdog Service Code.This field is used to service the watchdog and to clear the soft lock bit
WSC (SWT_MCR[SLK]). If the SWT_MCR[KEY] bit is set, two pseudorandom key values are written to service
the watchdog, see section Section 33.4, “Functional Description”, for details. Otherwise, the sequence
0xA602 followed by 0xB480 is written to the WSC field. To clear the soft lock bit (SWT_MCR[SLK]), the value
0xC520 followed by 0xD928 is written to the WSC field.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R CNT
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Field Description
0–31 Watchdog Count. When the watchdog is disabled (SWT_MCR[WEN]=0) this field shows the value of the
CNT internal down counter. When the watchdog is enabled the value of this field is 0x0000_0000. Values in this
field can lag behind the internal counter value for up to six system plus eight counter clock cycles.
Therefore, the value read from this field immediately after disabling the watchdog may be higher than the
actual value of the internal counter.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 SK1
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
NOTES:
1 If neither HLK or SLK lock bit in the SWT_MCR is set, the SWT_SK can be initialized by software to a non-zero
value.
Field Description
0–15 Reserved
16–31 Service Key. This field is the previous (or initial) service key value used in keyed service mode. If
SK SWT_MCR[KEY] is set, the next key value to be written to the SWT_SR is (17*SK+3) mod 216.
Accesses to SWT registers occur with no peripheral bus wait states. (The peripheral bus bridge may add
one or more system wait states.) However, due to synchronization logic in the SWT design, recognition of
the service sequence or configuration changes may require up to three system plus seven counter clock
cycles.
If window mode is enabled (SWT_MCR[WND] bit is set), the service sequence must be performed in the
last part of the time-out period defined by the window register. The window is open when the down counter
is less than the value in the SWT_WN register. Outside of this window, service sequence writes are invalid
accesses and generate a bus error or reset depending on the value of the SWT_MCR[RIA] bit. For
example, if the SWT_TO register is set to 5000 and SWT_WN register is set to 1000 then the service
sequence must be performed in the last 20% of the time-out period. There is a short lag in the time it takes
for the window to open due to synchronization logic in the watchdog design. This delay could be up to
three system plus four counter clock cycles.
The interrupt then reset bit (SWT_MCR[ITR]) controls the action taken when a time-out occurs. If the
SWT_MCR[ITR] bit is not set, a reset is generated immediately on a time-out. If the SWT_MCR[ITR] bit
is set, an initial time-out causes the SWT to generate an interrupt and load the down counter with the
time-out period. If the service sequence is not written before the second consecutive time-out, the SWT
generates a system reset. The interrupt is indicated by the time-out interrupt flag (SWT_IR[TIF]). The
interrupt request is cleared by writing a one to the SWT_IR[TIF] bit. Refer to Section 27.4.1, “External
Interrupt Request Sources”, and Section 3.2.1.5, “DMA/Interrupt Request Enable Register
(SIU_DIRER)”, for details on the enabling and routing of the SWT interrupt signals.
The SWT_CO register shows the value of the down counter when the watchdog is disabled. When the
watchdog is enabled this register is cleared. The value shown in this register can lag behind the value in
the internal counter for up to six system plus eight counter clock cycles.
The SWT_CO can be used during a software self test of the SWT. For example, the SWT can be enabled
and not serviced for a fixed period of time less than the time-out value. Then the SWT can be disabled
(SWT_MCR[WEN] cleared) and the value of the SWT_CO read to determine if the internal down counter
is working properly.
Chapter 35
System RAM (SRAM)
35.1 Introduction
The MPC5676R includes 384KB on-chip general-purpose SRAM including 48KB of standby RAM. The
first 48K of SRAM is powered by its own power supply pin during standby operation.
35.2 Features
The SRAM controller includes these features:
• Supports read/write accesses mapped to the SRAM memory from any master
• 48K- block powered by separate supply for standby operation
• Byte, halfword, word and doubleword addressable
• 7-bit ECC
Standby Switch
VDD
SRAM
48 KB VSTBY
336 KB
2. The write data bytes (1- or 2-byte segment) are merged with the corrected 32 bits on the data bus.
3. The ECC is then calculated on the resulting 32 bits formed in the previous step.
4. The 7-bit ECC result is appended to the 32 bits from the data, and the 39-bit value is then written
to SRAM.
Idle 01 / 12
Read 01/ 12
Read
32 or 64-bit write 01 / 12
8 or 16-bit write 11 / 22
Idle 0
Read 0
32 or 64-bit write
32 or 64-bit write 0
8 or 16-bit write 1
Idle 0
Read 0
8 or 16-bit write
32 or 64-bit write 0
8 or 16-bit write 1
1
Applies if additional SRAM read wait state in ECSM_MUDCR is disabled
2 Applies if additional SRAM read wait state in ECSM_MUDCR is enabled
Chapter 36
System Timer Module (STM)
36.1 Introduction
The System Timer Module (STM) is a 32-bit timer designed to support commonly required system and
application software timing functions. The STM includes a 32-bit up counter and four 32-bit compare
channels with a separate interrupt source for each channel. The counter is driven by the system clock
divided by an 8-bit prescale value (1 to 256).
Address offset Register name Register description Size (bits) Access Location
0x0008 Reserved — — —
0x000C Reserved — — —
0x001C Reserved — — —
Address offset Register name Register description Size (bits) Access Location
0x002C Reserved — — —
0x003C Reserved — — —
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R 0 0 0 0 0 0
CPS FRZ TEN
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Field Description
FRZ Freeze
Allows the timer counter to be stopped when the device enters debug mode
0 = STM counter continues to run in debug mode.
1 = STM counter is stopped in debug mode.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R
CNT
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Field Description
CNT Timer count value used as the time base for all channels
When enabled, the counter increments at the rate of the system clock divided by the prescale value. Also,
you can write the required starting value of the counter into this register, and the counter starts the
increment from the specified value.
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
0
R 0 0 0 0 0 0 0 0 0 0 0 0 0 0
CEN
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Field Description
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
R 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
CIF
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Field Description
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R
CMP
W
Reset 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Field Description
Chapter 37
Temperature Sensor
37.1 Overview
MPC5676R MCUs include an on-board temperature sensor that monitors device temperature and produces
a voltage directly proportional to the internal junction temperature. Internal junction temperature must be
calculated by software based on the sampled temperature sensor voltage, sampled bandgap voltage and
calibration parameter values stored in internal flash memory.
VBG
VBG(TLOW)
T
JUNCTION
TLOW THIGH
VTSENS
VTSENS(THIGH)
VTSENS(TLOW)
T
JUNCTION
TLOW THIGH
TTSENS_CODE(T) x – TTSENS_CODE(TLOW)
T = TLOW + x (THIGH – TLOW)
TTSENS_CODE(THIGH) – TTSENS_CODE(TLOW)
where:
VTSENS(TLOW) 14
TTSENS_CODE(TLOW) = x2 (Stored in device flash during factory calibration)
Vref0
VTSENS(THIGH) 14
TTSENS_CODE(THIGH) = x2 (Stored in device flash during factory calibration)
Vref0
VBG(TLOW)
VBG_CODE(TLOW) = x 214 (Stored in device flash during factory calibration)
Vref0
VBG(T)
VBG_CODE(T) = x 214
Vref
VTSENS(T)
TTSENS_CODE(T) = x 214
Vref
VBG_CODE(TLOW)
=
VBG_CODE(T)
Notes:
• VTSENS(T) is the temperature sensor output sampled by the ADC
• VBG(T) is the bandgap voltage sampled by the ADC
• Vref is the ADC reference voltage
• Vref0 is the ADC reference voltage during factory calibration
• TLOW is the low temperature factory calibration temperature (stored in device flash)
• THIGH is the hot factory calibration temperature (stored in device flash)
The following sections detail the values required and where to get them.
37.3.3 VBG_CODE(TLOW)
VBG_CODE(TLOW) is the value of the bandgap voltage sampled during low temperature factory calibration.
This value is stored in shadow flash memory during factory calibration. See Section 37.3.6.2,
“Temperature Calculation Constants Register 1”, for details.
37.3.6 Registers
The calibration constants described previously, i.e., TLOW, THIGH, TSENS_CODE(TLOW), TSENS_CODE(THIGH) and
VBG_CODE(TLOW), are stored in device shadow flash memory during factory test. This section details the
registers where the values reside.
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R TLOW TSCV1
W
RESET: x x x x x x x x x x x x x x x x
= Unimplemented or Reserved
Figure 37-3. Temperature Calculation Constants Register 0
Field Description
0–1 The THIGH field contains a value indicating the hot factory calibration temperature (THIGH). The values
THIGH are as follows:
00: THIGH = Reserved
01: THIGH = 125 °C
10: THIGH = 145 °C
11: THIGH = 150 °C
2–15 Temperature sensor output at hot factory calibration temperature (TSENS_CODE(THIGH)).
TSCV2
TSCV2 is the temperature sensor voltage sampled and converted by the eQADC during factory test
with device at hot temperature (THIGH). This is the TSENS_CODE(THIGH) parameter value referenced in
the temperature calculation formula (see Figure 37-2).
16–17 The TLOW field contains a code indicating the low factory calibration temperature (TLOW). The values
TLOW are as follows:
00: TLOW = 25 °C
01: TLOW = 40 °C
10: TLOW = –45 °C
11: TLOW = Reserved
18–31 Temperature sensor output at the low factory calibration temperature (TSENS_CODE(TLOW)).
TSCV1
TSCV1 is the temperature sensor voltage sampled and converted by the eQADC during factory test
with device at the low calibration temperature. This is the TSENS_CODE(TLOW) parameter value
referenced in the temperature calculation formula (see Figure 37-2).
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
R
Reserved
W
RESET: 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
= Unimplemented or Reserved
Figure 37-4. Temperature Calculation Constants Register 1
Field Description
0–1 Reserved
2–15 Bandgap voltage sampled and converted by ADC during factory test. This is the
TSCV3 VBG_CODE(TLOW) parameter value referenced in the temperature calculation formula
(see Figure 37-2).
16–31 Reserved
Chapter Description
Enhanced Queued Updated the note in the “Variable Gain Amplification (VGA) for Pre-gain” section.
Analog-to-Digital
Converter (eQADC)
Enhanced Serial • Updated the “TXDIR” bit description of the “eSCI_CR2” register.
Communications • Replaced the following text with a note in the “Single Wire Mode” section: “The TXDIR bit
Interface (eSCI) (eSCI_CR2[1]) determines whether the TXD pin is going to be used as an input (TXDIR = 0) or
an output (TXDIR = 1) in this mode of operation”.
Error Correction Status Updated the register and bit field descriptions of the “Miscellaneous User-Defined Control Register
Module (ECSM) (MUDCR)”.
Chapter Description
Device Overview Updated the “Calibration bus” value for “MPC5676R” in the “MPC5500/MPC5600 Family
Comparison” table.
Resets Removed “PLL” line from the “Reset Configuration Timing” diagram.
Clocking Updated the “MPC5676R System Level Clock Diagram”: Updated “DIV” ”CLKOUT” and “Core0”
“CLK Gate” connections.
Debug Updated the description of the “TM” bit field (1XX and XX1 values) and added a footnote to the “DC1
Field Description” table.
Enhanced Queued • Updated the “Overview” section and the “Analog to Digital Conversion Sub-system” diagram.
Analog-to-Digital • Updated “DEST” description in the “ADC_ACR1-8 Field Descriptions” table.
Converter (eQADC) • Updated “Overview” section of “ADC Calibration Feature”.
• Added a note to the “Variable Gain Amplification (VGA) for Pre-gain” section.
• Removed the following sentence from “Features” section: Selectable common mode conversion
range (0–5V; 0–2.5V; 0–1.25V).
• Moved the following note from “ADC0/1_EMUX” to “ADC0/1_EN” in the “EQADC_CFxRw Field
Descriptions” table: “Both ADC0 and ADC1 of an eQADC module pair must be enabled before
calibrating or using either ADC0 or ADC1 of the pair. Failure to enable both ADC0 and ADC1 of
the pair can result in inaccurate conversions.”
Temperature Sensor • Updated the channel information in the “Bandgap reference voltage” section.
• Updated the “01: THIGH” and “10: TLOW” values in the “Temperature Calculation Constants
Register 0 Field Descriptions” table.
Chapter Description
System Integration Unit Updated the “IFEE_NMI8” description in the “SIU_IFEER Bit Field Descriptions” table.
(SIU, SIU_B) Updated the “eQADC Trigger Input” for “00000” and “00111” in the “eTSEL0ADV_B Bit Field
Descriptions” table.
Changed the order of the bit-fields of the SIU_DECFIL1, SIU_DECFIL2, and SIU_DECFIL3 register.
Made minor editorial changes and corrections.
Reordered the bits of the SIU_DECFIL4 and SIU_DECFIL5 registers.
Added a paragraph to the “RSTVEC” descriptions in the “SIU_RSTVEC0/SIU_RSTVEC1 Field
Descriptions” tables.
Replaced “Core 0” with “Core 1” in “RSTVEC” description in the “SIU_RSTVEC1 Field Descriptions”
table.
Boot Assist Module Added a paragraph to the “Download Protocol Execution” note.
(BAM)
Frequency Modulated Previous errata err001111 integrated into the reference manual: Updated the “LOLF” field
Phase-Locked Loop description in the “SYNSR Bit Field Descriptions” table.
(FMPLL) Added a footnote to the “ESYNCR2 Bit Field Descriptions” table.
Power Management Updated the SMPS and LDO voltage values in the features sections.
Controller (PMC) Updated the nominal value of the “REGCTL” pin in the “PMC Signals” table.
Updated the “PMC Internal 1.2V Voltage Regulator Selection” section.
Updated the “Internal Regulator 1.2V LDO and SMPS” diagram: Changed “SI5656DC” to “SI3460”.
Debug Added notes to the “Message Data Out (MDO[11:0] or [15:0])” and “Message Start/End Out
(MSEO[1:0])” sections.
Decimation Filter Made minor changes to the “Overview section: Changed two instances of “eQADC” to “eQADC_A”.
Updated the “OSEL” descriptions in the “DECFILT_x_IB and DECFILT_x_IB Field Descriptions”
tables.
Deserial Serial Peripheral Previous errata err001147 integrated into the reference manual: Added a note to the “Parallel
Interface (DSPI) chaining” section.
Previous errata err000575 integrated into the reference manual: Added a warning to the
“Continuous Selection Format” section.
Added a note to the “Continuous selection format” section.
Updated the bullets in the “Continuous serial communications clock” section.
Added information about the following registers:
• DSPI DSI Serialization Source Select Register (DSPI_SSR)
• DSPI DSI Parallel Input Select Register 0 (DPSI_PISR0)
• DSPI DSI Parallel Input Select Register 1 (DPSI_PISR1)
• DSPI DSI Parallel Input Select Register 2 (DPSI_PISR2)
• DSPI DSI Parallel Input Select Register 3 (DPSI_PISR3)
• DSPI DSI Deserialized Data Interrupt Mask Register (DSPI_DIMR)
DSPI DSI Deserialized Data Polarity Interrupt Register (DSPI_DPIR)
Chapter Description
Enhanced Modular Updated the “eMIOS200 Block Diagram” and the “IPM Example” diagram.
Input/Output Subsystem Updated the “External Signal Description”, “Output Disable Input — eMIOS200 Output Disable Input
(eMIOS200) Signal”, and “eMIOS[n]” sections.
Updated the “ETB”, GPREN, and SRV descriptions in the “EMIOS_CCR[n] Field Descriptions”
table.
Updated the “ODISSL” and “UCPREN” descriptions of the “EMIOS_CCR[n] Field Descriptions”
table.
Added the following to the “On the next system clock cycle after the A1...” sentence in the “Modulus
Counter Buffered (MCB) Mode” section: “and the FLAG bit is set to '1'”.
Changed “$1” to “0x00_0001” in the Modulus Counter Buffered (MCB) Mode and Center-Aligned
Output PWM Buffered with Dead Time (OPWMCB) Mode.
Removed a paragraph from the “Application Information” section.
Enhanced Queued Previous errata err000652 integrated into the reference manual:
Analog-to-Digital • Added a footnote to the “Pin Mapping to Channel Mapping” table.
Converter (eQADC) • Updated the description of the “(b) 0010_1010 channel” description in the “Multiplexed and
non-multiplexed channel assignments” table.
Updated the “DSM” description in the “EQADC_MCR Field Descriptions” table.
Updated the “DEST” description in the “ADC_ACR1-8 Field Descriptions” table.
Previous errata err002449 integrated into reference manual: Added a note to the
“ADC0/1_EMUX” description of the “EQADC_CFxRw Field Descriptions” table.
Enhanced Time Removed information about the ETPUWDSR_A and ETPUWDSR_B registers; removed the second
Processing Unit (eTPU) list item from the “Watchdog” section and updated a bullet item in the section.
Replaced “STAC signals” with “STAC Bus” in the “eTPU A/B Module Block Diagram”.
Updated the “eTPU Channel Output Disable Signals” section.
Updated the “High Level Memory Map” footnote.
Updated the footnotes of the “Detailed Memory Map A/B and eTPU C” tables.
Updated the “ETPUSCMOFFDATAR” section.
Added a table to the “ETPUREDCR” section.
Removed “Unimplemented or Reserved” from the following registers: “ETPUCDCR”,
“ETPUMISCCMPR”, and “ETPUSCMOFFDATAR”.
Removed figure footnotes from the following registers: ETPUMECR, ETPUDEIAR, ETPUDEIDPR,
ETPUDEIPPR, ETPUDERAR, ETPUDERDR, ETPUDERSR, ETPUMESR, ETPUCEIAR,
ETPUCEIDPR, ETPUCEIPPR, ETPUCERAR, ETPUCERDR, ETPUCERSR, and ETPUCEFR
Flash Memory Array and Updated the “Shadow Block Memory Map” table.
Control Added a footnote and corrected a reset value in the “Flash Configuration Register Memory Map”
table.
Updated the “FLASH_BIUCR3” section.
Corrected the ordering of the “M0PFE” bit of the “Flash Bus Interface Configuration Register 3
(FLASH_BIUCR3)” register
Chapter Description
FlexCAN Module Made editorial changes in the “Module Disable Mode” (“Modes of Operation” and “Modes of
Operation Details” sections).
Made editorial changes in the “Transmit Process” section.
Added a note to the “Transmission Abort Mechanism” section.
Previous errata err002360 integrated into the reference manual: Added “Precautions when
using Global Mask and Individual Mask registers” and “CAN protocol related features.
Interrupts and Interrupt Updated “Software Vector Mode” and “External Interrupt Request Sources” sections.
Controller (INTC)
Memory Protection Unit Updated the reset value of the “MPU_CESR” register.
(MPU) Updated the reset values of the “M1SM” bit fields of “MPU_RGD0, Word 2” and “MPU_RGDAAC0”
registers.