Anonymous
Not applicable
Dec 07, 2013
04:09 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Dec 07, 2013
04:09 PM
The ezADC looks great on paper for double correlated sampling. However, the data sheet leaves much to be desired and I am absolutely at a loss of how to actually get it to work. If I disable the offset compensation all is fine. If I enable offset compensation, all I can ever get is 0. It makes no sense. Any help would be appreciated in making this work. I could bypass ezADC and do the double compensated sampling manually, but if this does it... M
Labels
- Labels:
-
PSoC 1
3 Replies
Dec 07, 2013
09:36 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Dec 07, 2013
09:36 PM
Without seeing your project and code difficult to help. Post project
archive, "File", "Archive Project", post with any browser other than chrome.
I presume you are doing this via register writes to control PGA input -
- Offset Compensation
-
- This parameter enables or disables correlated double sampling. For more details on correlated double sampling, refer to AN2226 . To perform offset compensation, set PGA reference to AGND, connect the PGA input to AGND, and perform a single conversion. Store the output of the ADC in a RAM variable. During all other measurements, this offset value is subtracted from the ADC result.
- Regards, Dana.
Attachments are accessible only for community members.
Anonymous
Not applicable
Dec 08, 2013
09:05 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Dec 08, 2013
09:05 AM
Thank you for your response. I am simply using the code directly from the datasheet for the ezADC. There is the offset compensation setting which I simplistically assume to mean that it will automatically do offset compensation. Looking at the user module ezADCINT.asm, it looks like it does do this, only I do not get the effect. I attach a zip of my project. I could follow the method shown in the AN you indicated (also in the ezADC data sheet and it was the motivation for using ezADC), but ezADC seems to imply it does it. Is this correct?
Dec 08, 2013
09:52 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Dec 08, 2013
09:52 AM
There seems to be no indication that CDS is an automatic process based
on the way the offset compensation is described. And none of the APIs carry
notes to the effect that the reading will be automatically corrected. Or for that
matter a variable called out with the correction value. Or any timing of switching
the PGA to get its offset.
Post a CASE to confirm (and please update this thread) -
“Support”
“Technical Support”
“Create a MyCase”
Regards, Dana