![NXP Semiconductors MPC5605BK Reference Manual Download Page 304](http://html.mh-extra.com/html/nxp-semiconductors/mpc5605bk/mpc5605bk_reference-manual_1721852304.webp)
Chapter 17 eDMA Channel Multiplexer (DMA_MUX)
MPC5606BK Microcontroller Reference Manual, Rev. 2
304
Freescale Semiconductor
4. In the PIT, configure the corresponding timer.
5. Select the source to be routed to the eDMA channel. Write to the corresponding CHCONFIG
register, ensuring that the ENBL and TRIG bits are set.
Example 17-1. Configure source #3 Transmit for use with eDMA Channel 2, with periodic triggering
capability
1. Write 0x00 to CHCONFIG2 (Base A 0x02)
2. Configure Channel 2 in the eDMA, including enabling the channel
3. Configure Timer 4 in the Periodic Interrupt Timer (PIT) for the desired trigger interval
4. Write 0xC3 to CHCONFIG2 (Base A 0x02)
The following code example illustrates steps #1 and #4 above:
In File
registers.h:
#define DMAMUX_BASE_ADDR 0xFC084000/* Example only ! */
/* Following example assumes char is 8 bits */
volatile unsigned char *CHCONFIG2 = (volatile unsigned char *) (DMAMUX_BA0x0002);
In File
main.c:
#include "registers.h"
:
:
*CHCONFIG2 = 0x00;
*CHCONFIG2 = 0xC3;
17.8.2.2
Enabling a source without periodic triggering
The following describes how to enable a source without periodic triggering:
1. Determine with which eDMA channel the source will be associated. Remember that only eDMA
channels 0–3 have periodic triggering capability.
2. Clear the ENBL and TRIG bits of the eDMA channel.
3. Ensure that the eDMA channel is properly configured in the eDMA. The eDMA channel may be
enabled at this point.
4. Select the source to be routed to the eDMA channel. Write to the corresponding CHCONFIG
register, ensuring that the ENBL is set and the TRIG bit is cleared.
Example 17-2. Configure source #5 Transmit for use with eDMA Channel 2, without periodic triggering
capability
1. Write 0x00 to CHCONFIG2 (Base A 0x02)
2. Configure Channel 2 in the eDMA, including enabling the channel
3. Write 0x85 to CHCONFIG2 (Base A 0x02)
The following code example illustrates steps #1 and #3 above:
In File
registers.h:
#define DMAMUX_BASE_ADDR 0xFC084000/* Example only ! */
/* Following example assumes char is 8 bits */
volatile unsigned char *CHCONFIG2 = (volatile unsigned char *) (DMAMUX_BA0x0002);
In File
main.c:
Summary of Contents for MPC5605BK
Page 2: ...This page is intentionally left blank...
Page 20: ...MPC5606BK Microcontroller Reference Manual Rev 2 20 Freescale Semiconductor...
Page 103: ...MPC5606BK Microcontroller Reference Manual Rev 2 Freescale Semiconductor 103 Clocks and power...
Page 645: ...MPC5606BK Microcontroller Reference Manual Rev 2 Freescale Semiconductor 643 Timers...
Page 715: ...MPC5606BK Microcontroller Reference Manual Rev 2 Freescale Semiconductor 713 ADC system...
Page 787: ...MPC5606BK Microcontroller Reference Manual Rev 2 Freescale Semiconductor 787 Memory...
Page 893: ...MPC5606BK Microcontroller Reference Manual Rev 2 Freescale Semiconductor 893 Integrity...
Page 943: ...MPC5606BK Microcontroller Reference Manual Rev 2 Freescale Semiconductor 943 Debug...