We are essentially a rookie team every year we compete and our new programmer is having trouble with getting all four cims to work. We are using mplab and two joysticks. We are in search of any code and would also like to know if the PWM numbers matter…is 1-4 better than 13-16? Thanks
although i do not have any code on hand that I can send you, PWM numbers are only a way of identifying the ports and have nothing different about how they are wired in the board or how the react when you send a command to them in programming.
If you’re putting two CIMs on the same gearbox, you can use a pwm Y cable to control both of their Victors from the same pwm output. Then just program it as if it were one motor.
Using pwm outputs 13-16 is fine as long as you don’t have a lot of interrupt sources active (from shaft encoders, gear tooth sensors, fancy timers, and the like). If you have added anything like that, they’ll act jittery and occasionally even make motors run when you want them to be stopped. You can avoid those outputs, or you can install Kevin Watson’s fancy pwm support library to tame them.
Thanks for the replies. Where can I get a pwm y cable?
You should have two of them in your Kit Of Parts.
they have the black/yellow/red wires.
Thank you!!!