Driver for National Semiconductor ADC128Sxxx family of analog to digital converters
Revision 3:e304ec6ed416, committed 2011-04-27
- Comitter:
- shimniok
- Date:
- Wed Apr 27 19:36:50 2011 +0000
- Parent:
- 2:f6c4a79f2ee0
- Commit message:
- Fixed compile time errors.
Changed in this revision
ADC128S.h | Show annotated file Show diff for this revision Revisions of this file |
diff -r f6c4a79f2ee0 -r e304ec6ed416 ADC128S.h --- a/ADC128S.h Wed Apr 27 19:07:26 2011 +0000 +++ b/ADC128S.h Wed Apr 27 19:36:50 2011 +0000 @@ -50,12 +50,12 @@ */ void setChannel(int channel); - /** Set channel to be used for the next conversion. + /** Convert the current channel and return the result and prepare to read the next channel. + * The channel will count to 7 and then wrap around to 0. See also: setChannel() * - * @param channel is the adc channel you want to read with next call to read() + * @param returns conversion for the curent channel and prepares to read the next channel */ - void setChannel(int channel); - + unsigned int read(void); /** Read in analog value from the specified ADC channel * @@ -67,4 +67,5 @@ private: SPI _adc; DigitalOut _cs; + int _channel; }; \ No newline at end of file