mirror of
https://github.com/brendanhaines/mecanum.git
synced 2024-11-12 14:34:54 -07:00
sets knob as speed adjustment
This commit is contained in:
parent
23ae387dd5
commit
3de4778047
|
@ -6,9 +6,9 @@
|
||||||
///// USER PARAMETERS /////
|
///// USER PARAMETERS /////
|
||||||
|
|
||||||
// Tuning Parameters
|
// Tuning Parameters
|
||||||
#define throScale 1
|
double throScale = 1;
|
||||||
#define ruddScale 1
|
#define ruddScale 1
|
||||||
#define aileScale 2
|
#define aileScale 1
|
||||||
#define elevScale 1
|
#define elevScale 1
|
||||||
|
|
||||||
// Wiring Parameters
|
// Wiring Parameters
|
||||||
|
@ -83,10 +83,14 @@ public:
|
||||||
|
|
||||||
void TeleopPeriodic()
|
void TeleopPeriodic()
|
||||||
{
|
{
|
||||||
|
double ch6 = InterLink->getCh6();
|
||||||
double aile = InterLink->getAile();
|
double aile = InterLink->getAile();
|
||||||
double elev = InterLink->getElev();
|
double elev = InterLink->getElev();
|
||||||
double rudd = InterLink->getRudd();
|
double rudd = InterLink->getRudd();
|
||||||
SmartDashboard::PutNumber( "Rudder", rudd );
|
SmartDashboard::PutNumber( "Rudder", rudd );
|
||||||
|
SmartDashboard::PutNumber( "Throttle", ch6 );
|
||||||
|
|
||||||
|
throScale = ch6 + 1;
|
||||||
|
|
||||||
double driveAngle = atan2( -aile*aileScale, elev*elevScale );
|
double driveAngle = atan2( -aile*aileScale, elev*elevScale );
|
||||||
SmartDashboard::PutNumber( "Drive Angle", driveAngle );
|
SmartDashboard::PutNumber( "Drive Angle", driveAngle );
|
||||||
|
|
Loading…
Reference in New Issue
Block a user