10 bit experiment
well i did the 16 bit vs 10 bit experiment,
in setting up the experiment i did my best to make it fair.
same TX pulse, same fly back delay, running average at 100. Most important adjustment was the value i call the "threshold offset" i had to "hand dial" these in by usuing a trim pot hook up to another adc port.
well here's the code:
The results:
the air test show about a 4 to 5 inch (10 to 12 cm) increase for the 16 bit adc over the 10 bit adc. for both the metal plate and small box of gold nuggets
metal plate 15" to 20"
box of nuggets 4" to 9"
conclusion:
moodz is correct.....
10 bits is hobbyist grade 
16 bits is a "good start"
for those of you wanting to use the on board ADC in the chipkit, do it you'll have a great starting point, and its easy to work with
I have some real encourgement to step up to an 18 bit adc in the near future
comments and questions?
Philip
next experiment:
Auto Calibration of the threshold offset
Auto Calibration of the Fly back delay
well i did the 16 bit vs 10 bit experiment,
in setting up the experiment i did my best to make it fair.
same TX pulse, same fly back delay, running average at 100. Most important adjustment was the value i call the "threshold offset" i had to "hand dial" these in by usuing a trim pot hook up to another adc port.
well here's the code:
Code:
void profile_CK() // this is an event, it's basically an idea for the // sequencing of pulses in order to make a metal detector work // this is usuing the Chipkit's 10 bit adc { mosfetC(); // tx pulse length adc_fly(); // fly back delay CK_sample(); // sample from Chipkit's 10 bit adc running_average (); // running average for target sample GB_delay(); // delay for ground balance CK_Bsample(); // sample from ground balance Brunning_average (); // ground balance running average averageS = averageS - CT_offset; // threshold offset if (averageS > BaverageS) // simple logic { mPORTDToggleBits(BIT_0); // RED LED ON } else { mPORTDClearBits(BIT_0); // RED LED OFF } } void CK_sample(){ // target sample adc_on(); adcvalue = analogRead(signal_input); sample_1=adcvalue; adcvalue = analogRead(signal_input); sample_2=adcvalue; adc_off(); average=(sample_1+sample_2)/2; } void CK_Bsample(){ // ground balance sample adc_on(); adcvalue = analogRead(signal_input); Bsample_1=adcvalue; adcvalue = analogRead(signal_input); Bsample_2=adcvalue; adc_off(); Baverage=(Bsample_1+Bsample_2)/2; }
the air test show about a 4 to 5 inch (10 to 12 cm) increase for the 16 bit adc over the 10 bit adc. for both the metal plate and small box of gold nuggets
metal plate 15" to 20"

box of nuggets 4" to 9"

conclusion:
moodz is correct.....
That experiment is pretty much like comparing a 3 digit voltmeter with a 4 digit one. So you will measure 1.00 volts vs 1.000 volts. ... Pretty much like dropping a brick on your foot to see if it hurts.

16 bits is a "good start"

for those of you wanting to use the on board ADC in the chipkit, do it you'll have a great starting point, and its easy to work with

I have some real encourgement to step up to an 18 bit adc in the near future
comments and questions?
Philip
next experiment:
Auto Calibration of the threshold offset
Auto Calibration of the Fly back delay
Comment