We lost our coder and are starting with someone new need help we keep getting an error and do not know what to do. No instance of constructor and argument types are errors. Any help would be appreciated we are just trying to get mechem drive running.
// Copyright (c) FIRST and other WPILib contributors.
// Open Source Software; you can modify and/or share it under the terms of
// the WPILib BSD license file in the root directory of this project.
#include <frc/Joystick.h>
#include <frc/TimedRobot.h>
#include <frc/drive/MecanumDrive.h>
#include <frc/motorcontrol/PWMSparkMax.h>
#include <ctre/phoenix/motorcontrol/can/WPI_TalonSRX.h>
#include <ctre/phoenix/motorcontrol/can/TalonSRX.h>
#include <ctre/phoenix/motorcontrol/can/WPI_TalonSRX.h>
#include <ctre/Phoenix.h>
/**
- This is a demo program showing how to use Mecanum control with the
- MecanumDrive class.
*/
class Robot : public frc::TimedRobot {
public:
void RobotInit() override {
// Invert the right side motors. You may need to change or remove this to
// match your robot.
m_frontRight.SetInverted(true);
m_rearRight.SetInverted(true);
}
void TeleopPeriodic() override {
/* Use the joystick Y axis for forward movement, X axis for lateral
* movement, and Z axis for rotation.
*/
m_robotDrive.DriveCartesian(-m_stick.GetY(), -m_stick.GetX(), -m_stick.GetZ());
}
public:
static constexpr int kFrontLeftChannel = 0;
static constexpr int kRearLeftChannel = 1;
static constexpr int kFrontRightChannel = 2;
static constexpr int kRearRightChannel = 3;
static constexpr int kJoystickChannel = 0;
TalonSRX m_frontLeft{kFrontLeftChannel};
TalonSRX m_rearLeft{kRearLeftChannel};
TalonSRX m_frontRight{kFrontRightChannel};
TalonSRX m_rearRight{kRearRightChannel};
frc::MecanumDrive m_robotDrive {{m_frontLeft, m_rearLeft, m_frontRight, m_rearRight}};
frc::Joystick m_stick{kJoystickChannel};
};
#ifndef RUNNING_FRC_TESTS
int main() {
return frc::StartRobot();
}
#endif