Voltage changes when multiple leds are on

Hi. I'm not sure if this is the correct place to ask... i'm using multiplexers and shifters so i guess ...
It's not a very annoying problem but i want to know if this is normal.
I'm making a midi sequencer with 32 pots and 8 leds. 32 pots with 2x 4051 and a 1x 4067(not yet ) and a hc595 for the 8 leds.
I'm supposed to read 0-1023 on analog input, this is right. When a led is on(on the hc595), i read 4-1021, when like 5 or 6 leds are on, it's worse, it reads 80-960~. It doesn't bother me too much because i just need one led to be on at a time...
I measure voltage at 5v pin and its 5v when a led is off, and 5.06v when it's on.
Right now i don't have schematics, and the code is just the shifter library example from bildr plus mux code. If schematics are needed tell me and i draw, i have to do it anyways.
thanks

Need schematics please.

Here's a start for you using expresspcb schematic software.
Pretty easy to use.
http://www.expresspcb.com/ExpressPCBHtm/Download.htm

Can highlight components & CTRL-C, CTRL-V to copy & paste.
Don't forget 0.1uF caps on the IC's power pins.

Arduino_muxes.sch (8.81 KB)

CrossRoads:
Need schematics please.

Here's a start for you using expresspcb schematic software.
Pretty easy to use.
http://www.expresspcb.com/ExpressPCBHtm/Download.htm

Can highlight components & CTRL-C, CTRL-V to copy & paste.
Don't forget 0.1uF caps on the IC's power pins.

Hi. Will draw it.
Earlier i said power is 5.06v when led is off, it's the inverse.
Now i tried with 8 leds on the 595 and power went down to 4.5v. I wasn't using decoup caps, i'll add on each IC to see if the behaviour changes.
thanks

edit: Added decoup caps on the 3 ICs. With 8 leds on, it got better, but not yet... 40 to 1009. Maybe a bigger cap? Anyways, right now i just care about just 1 led at a time, and with the caps it's now reading 0-1023, so i'll leave 0.1uf. Thanks for the tip :slight_smile:

It might be your wiring. Don't have the ground from the pots go over the wires of the ground for the LEDs. Have them seprate and only join them back at the arduino.

Grumpy_Mike:
It might be your wiring. Don't have the ground from the pots go over the wires of the ground for the LEDs. Have them seprate and only join them back at the arduino.

Ahá. I have 3 breadboard filled up. Each one with a line of ground that goes to arduino. But on the same board i have eight pots plus the leds sharing the same point of ground... Thanks, i'll have it on count when making the pcb