
Enhanced Time Processing Unit (eTPU2)
MPC5644A Microcontroller Reference Manual, Rev. 6
992
Freescale Semiconductor
The Filter Delay varies with the filter clock (ETPU_ECR field FPSCK) and the filter mode used, as shown
in the
. For any given transition, it depends on the phase of the filter clock when the input
transition happens. In integration mode (TCRCLK filtering only), it also depends on the state of the
integrator counter. The Total Delay is defined as the number of system clock rising edges between the input
transition and the setting of TDLA/B, TCR1/2 incrementing, or EAC tooth sensing (TCRCLK) in angle
mode. The synchronizer delay is 2 or 3 system clocks, depending on the phase of the synchronizer when
the input transition happens. The edge detection takes 1 more system clock. The total delays are, thus:
Min. Total Delay = Min. Synchronizer Delay + Min. Filter Delay + Edge Detection Delay
Min. Total Delay = 3 + Min. Filter Delay
Max. Total Delay = Max. Synchronizer Delay + Max. Filter Delay + Edge Detection Delay
Max. Total Delay = 4 + Max. Filter Delay
The channel filters can be bypassed, so nullifying the filter delays in the equations above.
The channel output flip-flops drive the eTPU output signals directly, without any synchronous delays.
Consult the MCU Reference Manual for information on additional delays added at the integration.
24.7.2
Initialization code example
The code example below initializes ETPU_1 engine and configures eTPU UART FUNCTION to perform
the receiver at channel 1 and the transmitter at channel 0. The function works without parity and the data
word is 8 bits in size. The initialization code assumes the microcode function previously loaded into SCM.
***********************************************************************************
// Initilization program for eTPU engine 1, function microcode previously loaded into SCM.
// No angle mode, eTPU UART FUNCTION configured to perform at channels 0 and 1.
// Channel0 - Tx_UART
// Channel1 - Rx_UART
// UART Specifications:
// Data word size: 8 bits
// Parity: disabled
// ***************************** Definitions ***********************************
//Bases
#define ETPU_BASE 0x000 //MCU-dependent
#define SPRAM_BASE 0x000 //MCU-dependent
//General Configuration Registers
#define ETPU_MCR_OFFSET 0x000 //Module Configuration Register
#define ETPU_TBCR_1_OFFSET 0x020 //Time Base Configuration Register
#define ETPU_ECR_1_OFFSET 0x014 //Engine Configuration Register
#define ETPU_CIER_1_OFFSET 0x240 //Channel Interrupt Enable Register
#define ETPU_CDTRER_1_OFFSET 0x250 //Data TransF Interrupt Enable Register
//channel0 configuration registers
#define ETPU_C0CR_1_OFFSET 0x400 //Channel0 Configuration Register
#define ETPU_C0SCR_1_OFFSET 0x404 //Channel0 Status Control Register
#define ETPU_C0HSRR_1_OFFSET 0x408 //Channel0 Host Service Req. Register
Summary of Contents for MPC5644A
Page 2: ...MPC5644A Microcontroller Reference Manual Rev 6 2 Freescale Semiconductor...
Page 24: ...MPC5644A Microcontroller Reference Manual Rev 6 24 Freescale Semiconductor...
Page 26: ...MPC5644A Microcontroller Reference Manual Rev 6 26 Freescale Semiconductor...
Page 52: ...Introduction MPC5644A Microcontroller Reference Manual Rev 6 52 Freescale Semiconductor...
Page 56: ...Memory Map MPC5644A Microcontroller Reference Manual Rev 6 56 Freescale Semiconductor...
Page 1228: ...Decimation Filter MPC5644A Microcontroller Reference Manual Rev 6 1228 Freescale Semiconductor...
Page 1440: ...FlexCAN Module MPC5644A Microcontroller Reference Manual Rev 6 1440 Freescale Semiconductor...