How can I vary the sampling rate for the ADC i.e. I need to read 250 times at intervals of 4ms. Is it possible?
Also where can I find documents which explains about ADUcm3029?
The ADuCM3029 ADC sampling rate can be varied up to 1.8 Msps using the multiple conversion mode. But for sample rates lower that 10ksps you must do dummy reads due to the ADC must not be remain idle for more than 100uS.
For your requirement, it is advisable to use RTC or Timers to generate timings for that 250 sps sampling rate. You can setup the RTC or Timers to generate an interrupt every 4mS then get the sampled value of the ADC in single conversion mode. While waiting for the interrupt, you may put the microcontroller into low power modes (flexi or hibernate) or you can do other tasks.
You may refer to the ADuCM302x BSP example projects on how to use the ADC, RTC and Timers.
For more information about the ADuCM3029/ADuCM3027, you can browse the product page at:
For the Hardware Reference Manual:
For the Board Support Package of ADuCM302x EZ-Kit:
Retrieving data ...