Electronic – How should I alter the PISO shift register circuit so that it works with 3.3v instead of 5v

3.3vpullupresistorsshift-register

I've followed this Arduino guide to build a circuit using a CD4021BE PISO shift register, and 10k pulldown resistors. It works perfectly fine with the Arduino's 5v supply.

I then attempted to use this circuit with my Raspberry Pi's GPIO, which only supplies 3.3v, and I was getting very unreliable readings from the data pin. Increasing the clock delay to 1ms improved it a bit, but it's still very unreliable. (Some bits read high every few seconds, when everything should be low.)

I assume that running a CD4021BE shift register at 3.3v requires a different value for the pulldown resistors, so which value would you recommend? I have seen this answer to a similar question about pullup/pulldown resistors, but would like to know if there is any 'rule of thumb' for pulldown resistors in a 3.3v circuit. I would guess that a 5k resistor should solve the problem, but I wanted to get some advice before buying resistors and desoldering the existing ones.

Best Answer

The pullup/pulldown resistors for the buttons can take almost any value, limited only by power supply current capacity (1-10 ohm) and noise resistances (hundreds of kilohms).

So in the referenced schematics, you can put any resistor between 1K and 500K, and it will work, no matter what the power supply voltage is - 3.3 or 5V. I like using 4.7K resistors because I have a big box of them.

For more complex cases (I2C, etc..) the rules may be more complicated, but buttons/switches really do not care.