This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

General A2D help.

Hi folks,

I am attempting to modify existing hardware and software to implement an LM335AZ temperature sensor as well as interface a Maxbotix ultrasonic sensor. The uC is a Silicon Labs C8051F121 . The ADC0 is 12bit and has 8 analog channels available for input as well as an 9th channel which is a built in on chip temperature sensor. The existing code has a scale factor to convert the "count" values from the AtoD into mV values. I had to change this number quite a bit to get accurate values. The previous code did not need great accuracy. Also the analog inputs seem to top out (4095 counts) at 2.65V, even though the VREFA is 3.28V. The VREFA appears to be very noisy when sampling is occurring, almost 200mV Pk2Pk. We implemented a software average to help smooth out the output.

My questions:

1. Why am I unable to get the AtoD to read the full range of voltage?
2. What is the PCA gain and when/how should I use it?
3. Is the "noise" on the VREFA during sampling normal?
4. Should I continue to use the slowest sample clock possible? if my math is right its 1.03125MHz
5. Would it help to lower the SYSCLK from 66MHz is we find we can deal with a slower clock?

Thanks,