You are not logged in. Your edit will be placed in a queue until it is peer reviewed.
We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.
Required fields*
-
1Did you try taking the reading twice? The datasheet says: "The first ADC conversion result after switching reference voltage source may be inaccurate, and the user is advised to discard this result."Edgar Bonet– Edgar Bonet03/05/2015 15:48:14Commented Mar 5, 2015 at 15:48
-
Yes, I ran them in a loop and get consistent results. The first one read correctly, but then the second one won't work. If the first one is commented, the second one works OK.rslite– rslite03/05/2015 16:03:33Commented Mar 5, 2015 at 16:03
-
Actually you are right, I didn't understand your comment clearly the first time. I loop both reads one after another so it doesn't help. Looping the second one gets to the right value after a while (~5 ms) so I need to read once then wait 5 ms and read again. Please put your comment in an answer so I can accept it.rslite– rslite03/05/2015 17:19:28Commented Mar 5, 2015 at 17:19