/* DAC Channel DMA Disable. 
Disable a digital to analog converter channel DMA mode. */
void dac_dma_disable(uint32_t dac, int channel)
/* DAC Channel DMA Disable. 
Disable a digital to analog converter channel DMA mode. */
void dac_dma_disable(uint32_t dac, int channel)
{
	switch (channel) {
	case DAC_CHANNEL1:
		DAC_CR(dac) &= ~DAC_CR_DMAEN1;
		break;
	case DAC_CHANNEL2:
		DAC_CR(dac) &= ~DAC_CR_DMAEN2;
		break;
	case DAC_CHANNEL_BOTH:
		DAC_CR(dac) &= ~(DAC_CR_DMAEN1 | DAC_CR_DMAEN2);
		break;
	default:
		break;
	}
}