Problem with  ADC on MC68HC908JL16

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Problem with  ADC on MC68HC908JL16

1,770 Views
matri
Contributor I
Good morning!

To develope my project I'm using the emulator EML08JLJKE for the MCU MC68HC908JL16.
I have observed a wrong behavoir on two ADC channels (ADC12 and ADC9) specially when they work booth. On the signal is possible to see a spike, similar to capacitance's discharge, it is periodic, I think that the period is equal to the time used to come at the same instruction in the while for-ever loop.

I have setting the ADC module to work at bus frequency/8 (my bus frequency is 6MHz then the ADC clock frequency is 750KHz). I use single conversion mode, 10bit right justified with ADCSC write triggered mode enabled, long sample time configuration and obvious I have selected internal bus clock as the input source clock.
Every time I want read one channel, I set ADCSC register (ADCSC = channel_number) and when the flag COCO is set, I read the registers ADRH:ADRL.

I hope that the explanation is clear. Every suggestion is welcome, thanks.

Mari


Labels (1)
0 Kudos
Reply
2 Replies

671 Views
PeterHouse
Contributor I
Mari,

This is from memory . . . I believe the input to the ADC has a sample and hold capacitor which must be charged.  You need to make sure your driving source has a low enough impedance to charge this capacitor.   You may need to install a voltage follower of some type to condition your high impedance sensor on these two channels - the other channels probably have a low enough driving impedance.

Good Luck,

Peter House
0 Kudos
Reply

671 Views
matri
Contributor I
Thanks Peter House!

I have changed the input impedance for these two ADC channel, now it's low.
The signal from these two channel it's good.

Bye!
0 Kudos
Reply