Skip to content

Commit

Permalink
Merge pull request #37 from frc937/ur-mom
Browse files Browse the repository at this point in the history
Ur mom
  • Loading branch information
Jack-Haefele authored Feb 1, 2024
2 parents 4dd5492 + cca2e8f commit 97822b0
Show file tree
Hide file tree
Showing 3 changed files with 82 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/main/java/frc/robot/RobotContainer.java
Original file line number Diff line number Diff line change
Expand Up @@ -16,13 +16,15 @@
import edu.wpi.first.wpilibj2.command.Commands;
import edu.wpi.first.wpilibj2.command.button.CommandXboxController;
import frc.robot.commands.DeployPneumatics;
import frc.robot.commands.DeployUrMom;
import frc.robot.commands.EnterXMode;
import frc.robot.commands.RunBelts;
import frc.robot.commands.RunIntake;
import frc.robot.commands.drive.DriveFieldOriented;
import frc.robot.commands.drive.DriveRobotOriented;
import frc.robot.subsystems.Drive;
import frc.robot.subsystems.Intake;
import frc.robot.subsystems.UrMom;
import frc.robot.subsystems.mailbox.MailboxBelts;
import frc.robot.subsystems.mailbox.MailboxPneumatics;

Expand Down Expand Up @@ -51,6 +53,9 @@ public class RobotContainer {
/** Singleton instance of {@link Intake} for the whole robot. */
public static Intake intake = new Intake();

/** Singleton instance of {@link UrMom} for the whole robot. */
public static UrMom urMom = new UrMom();

/*
* ************
* * COMMANDS *
Expand All @@ -63,6 +68,7 @@ public class RobotContainer {
private DeployPneumatics deployPneumatics = new DeployPneumatics();
private RunBelts runBelts = new RunBelts();
private RunIntake runIntake = new RunIntake();
private DeployUrMom deployUrMom = new DeployUrMom();

/*
* ***********************
Expand Down
47 changes: 47 additions & 0 deletions src/main/java/frc/robot/commands/DeployUrMom.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
// 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.

/*
* Asimov's Laws:
* The First Law: A robot may not injure a human being or, through inaction, allow a human being to come to harm.
* The Second Law: A robot must obey the orders given it by human beings except where such orders would conflict with the First Law.
* The Third Law: A robot must protect its own existence as long as such protection does not conflict with the First or Second Law.
*/

package frc.robot.commands;

import edu.wpi.first.wpilibj2.command.Command;
import frc.robot.RobotContainer;
import frc.robot.subsystems.UrMom;

/** Prints "your mom" */
public class DeployUrMom extends Command {
private UrMom urMom;

/** Creates a new DeployUrMom. */
public DeployUrMom() {
this.urMom = RobotContainer.urMom;
addRequirements(urMom);
}

// Called when the command is initially scheduled.
@Override
public void initialize() {
urMom.printUrMom();
}

// Called every time the scheduler runs while the command is scheduled.
@Override
public void execute() {}

// Called once the command ends or is interrupted.
@Override
public void end(boolean interrupted) {}

// Returns true when the command should end.
@Override
public boolean isFinished() {
return true;
}
}
29 changes: 29 additions & 0 deletions src/main/java/frc/robot/subsystems/UrMom.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
// 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.

/*
* Asimov's Laws:
* The First Law: A robot may not injure a human being or, through inaction, allow a human being to come to harm.
* The Second Law: A robot must obey the orders given it by human beings except where such orders would conflict with the First Law.
* The Third Law: A robot must protect its own existence as long as such protection does not conflict with the First or Second Law.
*/

package frc.robot.subsystems;

import edu.wpi.first.wpilibj2.command.SubsystemBase;

/** Subsystem for printing "your mom" */
public class UrMom extends SubsystemBase {
/** Creates a new UrMom. */
public UrMom() {}

public void printUrMom() {
System.out.println("your mom");
}

@Override
public void periodic() {
// This method will be called once per scheduler run
}
}

0 comments on commit 97822b0

Please sign in to comment.