i am sensing 24 Batteries of 12 VDC on ADC of uC but facing problem of Fluctuation. Values Fluctuate up to 150mV. i am using 3 Multiplexers to sense 24 batteries. Please help me that whether fluctuation is due to 4051 or any other issue?
i used three 4051 multiplexers for sensing 24 batteries (8 batteries each) and output of mux to the ADC of uC. i used latch switch 4094 to select the select pins of muxes.. when i use these mux to sense the batteries, volts fluctuates and when i connect the out put of op-amp directly to the adc value gets stable. i think mux gives some problem please help me
this is not your working Schematic any how by considering you have sufficient decoupling cap for all ICs and ADC reference.
before Starting the ADC select the ATmega16 ADC channel (in your case channel 0 ADC0 ) and then select the 4051 channel and delay few micro seconds to settle and start convert ADC and also discard the first few ADC Conversation.
Between Power pins and close to IC and if your using Internal reference voltages then between aref and GND.
Check this link https://www.edaboard.com/threads/214249/
Did you see this fluctuation with the oscolosope or through your software? If you haven't used osciloscope yet, then do that. Put channel 1 on U4-pin13, channel 2 on pin U4-pin3, make X0 input to be active all the time and see if there is any difference between input - output.
very very thanks for your continuous reply. i dont know how to use noise reduction mode of adc? i changed the resistor to 5K. some values got stable. Little bit have been stabilized. but not whole. there is still fluctuation. i also added 50ms delay after selecting the channel and then read the value of ADC. i changed the clock prescaler to 150KHz. it was 1000KHz before.
In the MCUCR Register you have to set some of the bit.... please read the data sheet for ADC Noise Reduction Mode and Analog Noise Canceling Techniques. you can use MSB 8bits for stable Value.