Skip to content

IO Layers optimized#43

Open
27MahoneyKeirnan wants to merge 15 commits into
mainfrom
KeirnanTest
Open

IO Layers optimized#43
27MahoneyKeirnan wants to merge 15 commits into
mainfrom
KeirnanTest

Conversation

@27MahoneyKeirnan

Copy link
Copy Markdown
Contributor

Practice bot IO layer now extends Comp bot IO layer for each subsystem. Note that this branch was also used as a demonstration, so ensure no test code is still present. The only changes that were supposed to have been made were the IO layer changes in subsystems.

@27MahoneyKeirnan 27MahoneyKeirnan self-assigned this Oct 1, 2025
// }
// }

System.out.println("hello world");

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Can you remove this print because it causes a performance hit and it's not providing any diagnostic utility?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

done

public class AlgaeRollerIOPB extends AlgaeRollerIOCB {

/** Creates a new AlgaeIntakeRollerIOPB. */
public AlgaeRollerIOPB() {

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

You'll need to include the super(); keyword

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

How do I implement the keyword? Do I use it after extends and then state the class a second time (with IOCB layer)?

private final SparkMax wheelMotor = new SparkMax(CompBotConstants.CLIMBER_ROLLER_ID, MotorType.kBrushless);
private final RelativeEncoder encoder = wheelMotor.getEncoder();
private final PIDController pid = new PIDController(0, 0, 0); // TODO: find pid values
protected final SparkMax wheelMotor;

@JRTaylord JRTaylord Oct 2, 2025

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

The climberwheel no longer exists on main so this isn't needed and will go away once you merge in from main

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Should I delete the file or just the code I changed?

…alized, converting many constants to variables. The code builds
public class AlgaeArmIOPB extends AlgaeArmIOCB{

/** Creates a new AlgaeArmIOPB. */
public AlgaeArmIOPB() {

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Needs to call super(); in the constructor

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

If the config code below is identical to the config code in the super class, delete this

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.

4 participants