Skip to content

Conversation

@ashtonbradley45274
Copy link

Please keep this open until all the code is done . We still have to make the command class and integrate it with the joysticks.

  • Also we will need to set the addresses for the devices.

@Alijah2424 You can set the addresses with the phoenix tuner and identify the address of the other devices
https://store.ctr-electronics.com/software/

You would need to connect through the roborio

@ashtonbradley45274
Copy link
Author

@Alijah2424 - if you want to simulate the source ...

./gradlew build
./gradlew InstallAllTools
./gradlew simulateJava

image

FRONT_HOOKS_REVERSE_SPEED = 0.25,
FRONT_HOOKS_SPEED = 0.25,
REAR_HOOKS_REVERSE_SPEED = 0.25,
REAR_HOOKS_SPEED = 0.25;
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I made up some speeds for the hooks we would have test and adjust these.


public static final int HOOK_LEFT_REAR_MOTOR = 15,
HOOK_RIGHT_REAR_MOTOR = 16,
HOOK_FRONT_MOTOR = 17;
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I made up some motor addresses for this , we would need to use the tuner to assign these. If it has nto been assigned already we would beable to see that when we connect the tuner.

private final JoystickButton m_intakeButton = new JoystickButton(m_manipulatorStick, F310Controller.Button.kBumperRight.getValue());

/** The container for the robot. Contains subsystems, OI devices, and commands. */
public RobotContainer() {
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is where we add the controls for the hooks. @Alijah2424


import com.ctre.phoenix.motorcontrol.can.WPI_TalonFX;

public class HookArm extends WPI_TalonFX {
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I extended this to the new talo class in case we need to add extra which I doubt

import edu.wpi.first.wpilibj.motorcontrol.MotorControllerGroup;
import edu.wpi.first.wpilibj2.command.SubsystemBase;

public class HookClimbingSubSystem extends SubsystemBase {
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I made the subsystem for the hooks here @Alijah2424

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We would have to add the stop , and run and any other functions , I made build and interface for the most common

public void robotInit() {
// Instantiate our RobotContainer. This will perform all our button bindings, and put our
// autonomous chooser on the dashboard.
m_robotContainer = new RobotContainer();
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is where the rooto container is started.

@CardcaptorRLH85
Copy link
Member

As a note, this isn't the right robot for the hooks. You're looking for FRC322Java2022, our 2022 robot code.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants