Texas Instruments TMS320DM646x 사용자 설명서
![Texas Instruments](https://files.manualsbrain.com/attachments/b46f99d826b2b0e0e5f558c5fb6483942eb9216b/common/fit/150/50/c15ea36eb1fb1cce99a3b94668675bfc78ce832d8d727d9a7bb51a125510/brand_logo.gif)
www.ti.com
Architecture
Example 4. EMAC Control Module Initialization Code
Uint32 tmpval ;
/* Disable all the EMAC/MDIO interrupts in the control module */
EmacControlRegs->CONTROL.C_RX_EN
EmacControlRegs->CONTROL.C_RX_EN
= 0;
EmacControlRegs->CONTROL.C_TX_EN
= 0;
EmacControlRegs->CONTROL.C_RX_THRESH_EN = 0;
EmacControlRegs->CONTROL.C_MISC_EN
EmacControlRegs->CONTROL.C_MISC_EN
= 0;
/* Wait about 100 cycles */
for( I=0; i<5; I++ )
for( I=0; i<5; I++ )
tmpval = ECTL_REGS->EWCTL ;
#ifdef INTT_PACING
/* Set the control related to pacing of TX and RX interrupts */
/* Set the control related to pacing of TX and RX interrupts */
EmacControlRegs->INTR_COUNT->C_RX_IMAX = 0x4; // 4 RX intt/ms
EmacControlRegs->INTR_COUNT->C_TX_IMAX = 0x4; // 4 TX intt/ms
EmacControlRegs->INT_CONTROL = 0x30000; //bit16,bit17 for enabling TX and Rx intt pacing.
EmacControlRegs->INT_CONTROL |= 0x258; // 600 clocks of 150MHz in 4us time
EmacControlRegs->INTR_COUNT->C_TX_IMAX = 0x4; // 4 TX intt/ms
EmacControlRegs->INT_CONTROL = 0x30000; //bit16,bit17 for enabling TX and Rx intt pacing.
EmacControlRegs->INT_CONTROL |= 0x258; // 600 clocks of 150MHz in 4us time
#endif
/* Initialize MDIO and EMAC Module */
[Discussed later in this document]
[Discussed later in this document]
/* Enable all the EMAC/MDIO interrupts in the control module */
EmacControlRegs->CONTROL.C_RX_EN
EmacControlRegs->CONTROL.C_RX_EN
= 0xff;
EmacControlRegs->CONTROL.C_TX_EN
= 0xff;
EmacControlRegs->CONTROL.C_RX_THRESH_EN = 0xff;
EmacControlRegs->CONTROL.C_MISC_EN
EmacControlRegs->CONTROL.C_MISC_EN
= 0xf;
SPRUEQ6 – December 2007
Ethernet Media Access Controller (EMAC)/Management Data Input/Output (MDIO)
53