Sampling ADC at 1.2 MHz

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 
已解决

Sampling ADC at 1.2 MHz

跳至解决方案
1,972 次查看
nadine
Contributor III

Hi,

 

I'm using a FRDM-K64 board. I need to sample the ADC at 1.2 MHz.

I have use the PDB timer to program hardware interrupt. The program works but

the interruption function takes almost half of the CPU time (47%), and I need more time

for the data computing in the main program.

Is there a better way to do, for sampling ADC at high speed. I was thinking to an hardware FIFO

where the data conversion of the ADC would be stored.

 

Thanks for your help

Best Regards

Nadine

标签 (1)
0 项奖励
1 解答
1,028 次查看
xiangjun_rong
NXP TechSupport
NXP TechSupport

Hi, Nadine,

Unfortunately, I have not the example code using ADC/DMA/PIT for K64.

Pls refer to the community for the example code:

PIT- ADC- DMA Example for FRDM-KL25z, FRDM-K64F, TWR-K60D100 and TWR-K70

Hope it can help you.

BR

Xiangjun Rong

在原帖中查看解决方案

4 回复数
1,028 次查看
xiangjun_rong
NXP TechSupport
NXP TechSupport

Hi, Nadine,

As you know that the K64 has eDMA module, which can fetch the data from ADC module to memory automatically, after the number of data specified has been transferred, the eDMA can generate an interrupt. in the ISR, you can reconfigure the eDMA so that eDMA can fectch the ADC sample to another memory location, at the same time, you can handle the data the eDMA has fetched, this is called Ping-Pong mode.

Hope it can help you.

BR

XiangJun Rong

0 项奖励
1,028 次查看
nadine
Contributor III

Hi Xiangjun,

Thanks for the answer.

I will try to configure and use the eDMA driver.

Do you know if there is a demo available using the eDMA and the ADC ?

It is very helpful to start with such a program.

For now, it is not obvious for me to link the ADC data and the eDMA

channels.

Best Regards

Nadine

TALUKO

<mailto:CRE@TVT> CRE@TVT NUMERIQUE

Bâtiment A, 1er étage

Place Besagne

83000 Toulon

<http://www.taluko.com> www.taluko.com

Tel : +(33) 4 98 07 74 52

Mobile: +(33) 6 66 27 85 66

0 项奖励
1,029 次查看
xiangjun_rong
NXP TechSupport
NXP TechSupport

Hi, Nadine,

Unfortunately, I have not the example code using ADC/DMA/PIT for K64.

Pls refer to the community for the example code:

PIT- ADC- DMA Example for FRDM-KL25z, FRDM-K64F, TWR-K60D100 and TWR-K70

Hope it can help you.

BR

Xiangjun Rong

1,028 次查看
xiangjun_rong
NXP TechSupport
NXP TechSupport

Hi,

I suppose that the K64 ADC sampling frequency can not reach up to 1.2MHz, the maximum ADC sampling frequency is 818KHz with 13 bit resolution.

If you want to get 1.2MHz sampling frequency, I suggest you use KV5x, the KV5X has cyclic ADC,  the cyclic ADC of KV5x can reach up to 1.2MSPS.

Hope it can help you.

BR

Xiangjun Rong

pastedImage_0.png

0 项奖励