Page 1 of 1
ADC SAMPLING WITHIN TIMER GROUP INTERRUPT
Posted: Sat Jul 22, 2017 12:16 am
by rinripper
Hi, I`m trying to use timer groups to make a interrupt to take a sample from ADC with a regular interval. But code hangs without a error in console.
Thanks in advance.
Mauricio
Re: ADC SAMPLING WITHIN TIMER GROUP INTERRUPT
Posted: Sat Jul 22, 2017 2:09 am
by ESP_Sprite
...okay, and what exactly are you trying to do and what is the error exactly?
Re: ADC SAMPLING WITHIN TIMER GROUP INTERRUPT
Posted: Tue Jul 25, 2017 3:04 pm
by rinripper
Hi ESP_Sprite, I'm trying to sampling music. I need to sampling at least 50 KHz. I'm using the timer group because it´s accurate. So,I´m trying to make an ADC sample every timer group´s interrupt. The results the program crash or ADC sampling rate vary. The manual says something about a fast ADC: DIG SAR ADC, but iI can´t find it. What can I do to ADC sampling in regular intervals at 50KHz ?
Sorry for my bad english and Thanks.
Re: ADC SAMPLING WITHIN TIMER GROUP INTERRUPT
Posted: Wed Jul 26, 2017 2:21 am
by ESP_Sprite
There is a way to connect the ADC to the I2S peripheral, to get fully automatic sampling using DMA. It's documented in the TRM IIRC, but the I2S driver does not support it yet.