8-bit shift register 74LS164 not working
I resolved my problem. The register was clocking multiple times because the clock signal wasn't enough clean. So I added a schmitt trigger between the raspberry pi and the register clock input, and now it shifts exactly the number I want.

Thanks for all your advices and suggestions, have a nice day ;)