TI中文支持网
TI专业的中文技术问题搜集分享网站

MSP430FR5994 Using ADC12 With the DMA Controller 求TI员工解答

1. 想把ADC的数据通过DMA搬移到RAM,达到一定数量后再写入SD卡?应该如何操作,官网上似乎没有具体的示例代码?

2. 我想通过配置DMA,使能中断来实现,目标地址数据累计到一定量后,触发中断,但是发现配置后影响ADC也不工作了,下面是DMA配置代码,求解答

ptempData = malloc(DataSize);
__data16_write_addr((unsigned short) &DMA0SA,(unsigned long) &ADC12MEM0);// Source block address
__data16_write_addr((unsigned short) &DMA0DA,(unsigned long) ptempData); // Destination single address
DMA0SZ = DataSize; 
DMACTL0 |= DMA0TSEL_26;
DMA0CTL = DMADT_4 | DMASRCINCR_0 | DMADSTINCR_3 | DMAIE;
DMA0CTL |= DMAEN; //Enable DMA0

Gary Gao:

一样的换成  __data16_write_addr((unsigned short) &DMA0DA,(unsigned long) ptempData); // Destination single address

试一下

赞(0)
未经允许不得转载:TI中文支持网 » MSP430FR5994 Using ADC12 With the DMA Controller 求TI员工解答
分享到: 更多 (0)