2011-12-02 09:15 AM
Hello, i am working on small oscilloscope,
but i can't get adc value from PC0 leg (ADC123_IN10) can some one give code or example how to read adc value on demand ? like that: while(i<480){ int i,a=0; a[i]=ADC_READ; i++; }2011-12-02 11:50 AM
I'm pretty sure you're going to have to wait for the conversion to complete, as it is not an instantaneous process. Either have it converting on a period basis, or initiate the conversion before you need the result.
The fw library has several clear ADC examples as I recall. You could abstract ADC_READ as a function that waits for the current conversion to complete, returning that result after starting another conversion.2011-12-02 01:34 PM
i found working code for my application in examples folder.
now i have nice looking oscilloscope :) thank you clive1 for continuous help (y)