I am working on a robotics project with FIRST components, and I'm trying to keep costs as low as possible so I can still afford things like tuition and ramen.
I need my drivetrain motor to have some degree of variable speed, but Victors are very expensive. My low-cost solution is to use a Spike, and turn it on and off quickly to vary the speed. The way I see it is that I can get five different speeds (0-4) by having the Spike turned on for x out of every four program cycles, and then off for the remainder. Four program cycles is a very short duration of time, about 1/10 of a second, so I'm thinking that the output would just seem like a lower voltage to the motor.
Has anyone done anything like this? Is there any reason why I wouldn't be able to do this? I see that the switching time for the Spike is 5ms, which is far less than the 26.4ms program loop, so that shouldn't be a problem. Any advice would be appreciated.