Hello, I have been trying to implement ADC continuous conversions using eDMA. I have a K24 series kinetis microcontroller on a custom board. There are two ADC pins which I will be making use of, they are ADC0_DP0 and ADC1_DP1. Unfortunately I did not find any information on whether I should enable the GPIO port and pin configurations which in this case was not possible because in the pinout diagram there were no pins or ports for these ADC inputs. So, I assume I don't have to do anything. Furthermore, I wanted to enable eDMA on both these pins but I am not sure which DMA channel must be used for either of these adc pins. Can anyone please provide me some examples or a reference code where I can see some implementation.?
The pins ADC0_DP0 and ADC1_DP1 do not multiplexed with GPIO function. So you do not need to config the PORT. For the eDMA ADC tranfer, please have a look at below application note at a first:
There also provide the sample code for this document:
I am not sure if you are using the KSDK, if yes, then please find the sample code here:( Provide by Marco Hess)
Thankyou for your Response. But I regret to inform you that it is absolutely frustrating just to understand your Concepts of Minor link and Major Link. I have gone through the Reference Manual, the Application Notes 4590, 4765 and also the document with the title "what is and how to configure the eDMA scatter / gather Feature". I have previously worked with other Microcontrollers and it was way easier to simply get Things working.
All I want to implement is , scan ADC measurements from three Independent Channels and save them in SRAM as three Elements of an Array. I want to start a ADC conversion only on one channel and the other ADC channels Need to start conversion one after the other in a cyclic manner. And the respective DMA conversions as well. And finally when the ADC and DMA conversions for the three Channels have finished, I want a DMA Interrupt so that I could do something with my Collected ADC measurements in SRAM.
I am stuck configuring the ADC and DMA in several different modes and configurations and nothing has worked till now. I would request you to please suggest me the right Mode of Settings and overcome this Problem. And also I have a Problem finding the right example Code for a similar Use case. The Code which you have suggested in your Link is outdated and I dont find any relation to the existing Code. I could not even assign negative values for the DLAST_SGA value which is stated in all the application documents.
Your Application Documents make Things more complicated than simply help to overcome a Problem.
Your Suggestions are gretly appreciated!