All,
I'm working to develop a piece of hardware that allows me to control 1000 outputs (servos) from a single output pin.
I'm using pigpio on a Raspberry Pi B3 with python. I'm also using an array of 74HC4051 multiplexers. I've created a board that contains 9 multiplexers and allows me to use the multiplexers to control up to 64 outputs.
I'm noticing an issue when testing real-time refresh rates for the servos.
When executing a program that randomly selects a value and sets all servos to that value before executing the next iteration of the loop, I'm unable to get reliable servo positions without adding a 0.05 second delay between each output selection.
Simple math tells me updating 1000 objects would take 50 seconds. If I decrease the amount of time that passes between driving each servo, this results in inconsistent positions, or some servos failing to be updated at all.
The datasheet for the multiplexer doesn't seem to indicate that it's incapable of switching fast enough, which leads me to believe that it could have something to do with the PWM/pigpio and things that are happening in that library with regard to how much time the servo needs to accurately update. The servo speed is specified as .1 second. I think that value is the speed it takes to reach the specified position once receiving a signal.
Where can I begin testing for constraints in this system so that I can speed up that horrible refresh rate? With a 0.05 second delay I'm able to update 1100 servos in 55 seconds. Is my only option better hardware? Open to any ideas.
Thanks in advance.