holding ckt causing problem!!!!

hi all, i am using HEF4051 as address decoder and to send analog voltage through that channel now what i am doing is to send address bit and after that some analog voltage to be sent in that channel. i need to use all the channel simultaneously so connected capacitors to hold the value for few milliseconds. i first send address bit after that analog voltage and then address of next channel and its analog value and keep on doing it in a loop.Thus all values get refreshed after a particular time interval. Now my problem is that when i do so i didn't get the voltage retained by capacitors. After some efforts i got voltage to be retained but it is the average voltage of the channels not the needed voltage, So can anyone explain this why is this happening and solution as well. thanx in advance!!!!!

Do you set the Enable pin HIGH (disabled) before you change address bits?

nope !!! can this cause error, BTW i am trying it now. I will let you know the outcome!!! thanx!!!

As long as Enable is LOW the input voltage is connected to one of the outputs. If you change the input voltage without setting Enable HIGH you will be connecting the new voltage to the currently addressed capacitor. If you change the address pins without setting Enable HIGH you will be connecting the old voltage to the newly addressed capacitor, and if you need to change more then one address bit there will be multiple intermediate capacitors.

@ johnwasser, Thanx i tried you suggestion and it worked for me :) Now i am not getting average voltage at capacitors.I used capacitor of 1000uf (electrolytic), this value is too large so i want to replace it with 1-10uf (polyester) for that i calculated its charging time constant which is 0.2 ms for 1uf and 2ms for 10uf, i provided charging time 0.5 ms(for 1uf),and i didn't connected any load to this capacitors.Thus capacitor should hold charge for long time.(but i apply signal after every 0.5*8 channels=4 ms). Logically this should work but i am not getting expected results(practically value across capacitors oscillates from 0 to 2 volt for each channel). So anyone have any idea why is this happening???? :~ :~

What are you using for the variable voltage source? Hope it's not a PWM pin since they are switching between 0V and 5V very quickly.

IIRC unless you mess with the clocks, PWM cycles at about 490 Hz, about 1 ms HIGH then 1 ms LOW.

I'm sure there should be a simple filter to flatten PWM.