This code allows you to use your Arduino and your Sabertooth (not RC models !!).
The DIP switches on the Sabertooth must be like that (2, 4 and 5 OFF) :
Here is how you need to wire (ok it's in french but you can easily understand it ) :
There is a mistake : Pot1 must be on A0 and Pot2 on A1
Your COM port must be configured like that (default settings) :
Config in GameEngine (choose the right Com Port) :
Here is my config file
In the code, this is what you maybe need to edit :
int DeadZone = 5; --> this is the Deadzone of the pot, 5 is recommended to reduce some vibrations
int ReadAnalog = 6; --> I read 6 times the pots value and make an average to prevent noise values. 6-8 is the value I recommend.
int FeedbackPin1 = A0; select the input pin for the potentiometer 1
int FeedbackPin2 = A1; select the input pin for the potentiometer 2
int FeedbackMax1 (and 2) = 962; Maximum position of pot 1 to scale, do not use 1023 because it cannot control outside the pot range
int FeedbackMin1 (and 2) = 62; Minimum position of pot 1 to scale, do not use 0 because it cannot control outside the pot range
You can change the PID variables too...
EDIT : you need to install these libraries (clic here)
If you find a bug, please feel free to contact me !
You must be a registered member to be able to access this page and to download game plugins. Please register here. It´s for free.
Do not try to cheat our system and do not post an unnecessary amount of useless posts only to earn credits here. We have a zero spam tolerance policy and this will cause a ban of your user account. Otherwise we wish you a pleasant stay here! Read the forum rules
Arduino code : 2 DOF for Sabertooth using Simplified Serial (Working) 1.23
Arduino + Sabertooth + 2 DOF