CCS C Software and Maintenance Offers
FAQFAQ   FAQForum Help   FAQOfficial CCS Support   SearchSearch  RegisterRegister 

ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

CCS does not monitor this forum on a regular basis.

Please do not post bug reports on this forum. Send them to support@ccsinfo.com

TAD conversion time per bit

 
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion
View previous topic :: View next topic  
Author Message
PROMOD



Joined: 01 Feb 2018
Posts: 42

View user's profile Send private message

TAD conversion time per bit
PostPosted: Mon Oct 29, 2018 1:05 pm     Reply with quote

TAD=A/D conversion time per bit

Then why is 12TAD required per 10bit conversion? It should have been 10TAD!
temtronic



Joined: 01 Jul 2010
Posts: 9097
Location: Greensville,Ontario

View user's profile Send private message

PostPosted: Mon Oct 29, 2018 1:26 pm     Reply with quote

2TAD for discharge... that is shown and explained in the ADC section of the datasheet.Figure 17.4 of the PIC18F46K22, my goto PIC.

For more details as to why,there's a few good apnotes from Microchip, well worth spending an evening to learn how to get the best performance from the ADC section.

Jay
Ttelmah



Joined: 11 Mar 2010
Posts: 19215

View user's profile Send private message

PostPosted: Mon Oct 29, 2018 3:04 pm     Reply with quote

It also does change between chips.
Some of the DsPICs have half cycle steps involved.
Generally the input is disconnected from the capacitor, and one AD clock cycle later the conversion actually starts. Then a bit is generated after each clock, then one more clock is used to latch the final value into the result register.
Some older chips actually add two cycles at the start so 13 cycles rather than 12. Some others have a 2 cycle delay at the end after conversion before starting to reacquire.
temtronic



Joined: 01 Jul 2010
Posts: 9097
Location: Greensville,Ontario

View user's profile Send private message

PostPosted: Mon Oct 29, 2018 3:44 pm     Reply with quote

If we assume you're using the 18F4431 then from it's datasheet...

Section 20.9, page 257 ...

After the A/D conversion is completed or aborted, a
2 TAD wait is required before the next acquisition can
be started...

As Mr. T points out different PICS have different specs...ALSO a PIC can have different specs depending on what mode the ADC section has been programmed for. As the designer/programmer, you've got to know how the ADC is to be used and code accordingly.

Also be real careful when laying out the PCB. ANY design over 8 bits and you MUST properly layout the PCB, choose correct parts, power supply and
test for several conditions.

Jay
Display posts from previous:   
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion All times are GMT - 6 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group