Skip to content

Commit

Permalink
reseet pose
Browse files Browse the repository at this point in the history
  • Loading branch information
Shom770 committed Feb 23, 2024
1 parent 877cead commit 60384a9
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 6 deletions.
12 changes: 8 additions & 4 deletions src/main/kotlin/com/team4099/robot2023/RobotContainer.kt
Original file line number Diff line number Diff line change
Expand Up @@ -13,15 +13,19 @@ import com.team4099.robot2023.subsystems.drivetrain.drive.DrivetrainIOSim
import com.team4099.robot2023.subsystems.drivetrain.gyro.GyroIO
import com.team4099.robot2023.subsystems.drivetrain.gyro.GyroIOPigeon2
import com.team4099.robot2023.subsystems.elevator.Elevator
import com.team4099.robot2023.subsystems.elevator.ElevatorIO
import com.team4099.robot2023.subsystems.elevator.ElevatorIONEO
import com.team4099.robot2023.subsystems.elevator.ElevatorIOSim
import com.team4099.robot2023.subsystems.feeder.Feeder
import com.team4099.robot2023.subsystems.feeder.FeederIO
import com.team4099.robot2023.subsystems.feeder.FeederIONeo
import com.team4099.robot2023.subsystems.feeder.FeederIOSim
import com.team4099.robot2023.subsystems.flywheel.Flywheel
import com.team4099.robot2023.subsystems.flywheel.FlywheelIO
import com.team4099.robot2023.subsystems.flywheel.FlywheelIOSim
import com.team4099.robot2023.subsystems.flywheel.FlywheelIOTalon
import com.team4099.robot2023.subsystems.intake.Intake
import com.team4099.robot2023.subsystems.intake.IntakeIO
import com.team4099.robot2023.subsystems.intake.IntakeIONEO
import com.team4099.robot2023.subsystems.intake.IntakeIOSim
import com.team4099.robot2023.subsystems.limelight.LimelightVision
Expand Down Expand Up @@ -67,10 +71,10 @@ object RobotContainer {
// CameraIONorthstar("backward")
)
limelight = LimelightVision(object : LimelightVisionIO {})
intake = Intake(IntakeIONEO)
feeder = Feeder(FeederIONeo)
elevator = Elevator(ElevatorIONEO)
flywheel = Flywheel(FlywheelIOTalon)
intake = Intake(object : IntakeIO {})
feeder = Feeder(object : FeederIO {})
elevator = Elevator(object : ElevatorIO {})
flywheel = Flywheel(object : FlywheelIO {})
wrist = Wrist(object : WristIO {})
} else {
// Simulation implementations
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,11 @@ package com.team4099.robot2023.auto.mode
import com.team4099.lib.trajectory.FieldWaypoint
import com.team4099.lib.trajectory.OdometryWaypoint
import com.team4099.robot2023.commands.drivetrain.DrivePathCommand
import com.team4099.robot2023.commands.drivetrain.ResetPoseCommand
import com.team4099.robot2023.subsystems.drivetrain.drive.Drivetrain
import edu.wpi.first.math.geometry.Rotation2d
import edu.wpi.first.wpilibj2.command.SequentialCommandGroup
import org.team4099.lib.geometry.Pose2d
import org.team4099.lib.geometry.Translation2d
import org.team4099.lib.units.base.feet
import org.team4099.lib.units.base.meters
Expand All @@ -17,6 +19,7 @@ class FourNoteAutoPath(val drivetrain: Drivetrain) : SequentialCommandGroup() {
addRequirements(drivetrain)

addCommands(
ResetPoseCommand(drivetrain, Pose2d(1.48.meters, 5.5.meters, 0.degrees)),
DrivePathCommand.createPathInFieldFrame(
drivetrain,
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -58,8 +58,8 @@ object DrivetrainConstants {
val SLOW_AUTO_VEL = 2.meters.perSecond
val SLOW_AUTO_ACCEL = 2.0.meters.perSecond.perSecond

val MAX_AUTO_VEL = 3.meters.perSecond // 4
val MAX_AUTO_ACCEL = 3.meters.perSecond.perSecond // 3
val MAX_AUTO_VEL = 0.5.meters.perSecond // 4
val MAX_AUTO_ACCEL = 0.5.meters.perSecond.perSecond // 3

val MAX_AUTO_BRAKE_VEL = 0.5.meters.perSecond // 4
val MAX_AUTO_BRAKE_ACCEL = 0.5.meters.perSecond.perSecond // 3
Expand Down

0 comments on commit 60384a9

Please sign in to comment.