/* Sets the DMA Edge for the specified pin(s).  */
void GPIODMAEdgeSet(unsigned long ulPort, unsigned long ulPins, unsigned long ulDMAEdge)
/* Sets the DMA Edge for the specified pin(s).  */
void GPIODMAEdgeSet(unsigned long ulPort, unsigned long ulPins, unsigned long ulDMAEdge)
{
    unsigned long ulPortBase;
    unsigned long ulBit;
    xASSERT(GPIOBaseValid(ulPort));
    ulPortBase = GPIOToPortGet(ulPort);
    for(ulBit = 0; ulBit < 32; ulBit++)
    {
        if(((ulPins >> ulBit) & 1) != 0)
        { 
	    xHWREG(ulPortBase + PORT_PCR + ulBit * 4) &= ~PORT_PCR_IRQC_M;
    	    xHWREG(ulPortBase + PORT_PCR + ulBit * 4) |= ulDMAEdge;
        }
    }
}