|
Re: What's the best way to test?
In your zipped code, you've wired the throttle to your ball accumulator.
From what I've learned through the various errors I've stumbled upon, when the throttle is fully rotated forward (towards the +), it's interpreted as a -1. When it's fully rotated downward (towards the -), it's interpreted as a 1. There's no marking or physical click for 0.
So, depending on the physical setup of your ball collection system, setting the throttle to full forward might turn your collection motor in the opposite direction you want it to go.
If you want to stick with the throttle, just negate the output of the axis. This tool is under Programming>>Operations.
I've coded our collection motor to intake a ball (set the ball collection motor to -1) when button 2 is pressed and held down. The ball is spit out (collection motor to 1) when button 3 is pressed and held down. This might be better for your application.
|