Skip to content

Commit

Permalink
Added Motor functionality
Browse files Browse the repository at this point in the history
  • Loading branch information
stebb1976 committed Mar 6, 2021
1 parent 1f5cf5c commit e98a139
Show file tree
Hide file tree
Showing 4 changed files with 182 additions and 130 deletions.
5 changes: 3 additions & 2 deletions src/main/java/frc/robot/RobotContainer.java
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
import frc.robot.Utility.Gyro;
import frc.robot.Utility.Limelight;
import frc.robot.Utility.Motor;
import frc.robot.Utility.Motor.MotorType;
import frc.robot.commands.Drivetrain.*;
import frc.robot.commands.Drivetrain.TrackObject.WhatToTrack;
import frc.robot.subsystems.DifferentialDrivetrain;
Expand Down Expand Up @@ -45,8 +46,8 @@ public class RobotContainer {

DifferentialDrivetrain m_drivetrain = new DifferentialDrivetrain(
0.154,
new Motor(1,"TalonSRX"), new Motor(4, "TalonSRX"),
new Motor[]{new Motor(2, "TalonSRX")}, new Motor[]{new Motor(5, "TalonSRX")}
new Motor(1, MotorType.TalonSRX), new Motor(4, MotorType.TalonSRX),
new Motor[]{new Motor(2, MotorType.TalonSRX)}, new Motor[]{new Motor(5, MotorType.TalonSRX)}
);

public RobotContainer() {
Expand Down
2 changes: 2 additions & 0 deletions src/main/java/frc/robot/Utility/Accelerometer.java
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@
// 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.

package frc.robot.Utility;

import frc.robot.Constants;
import com.kauailabs.navx.frc.AHRS;
import edu.wpi.first.wpilibj.SPI;
Expand Down
Loading

0 comments on commit e98a139

Please sign in to comment.