package org.firstinspires.ftc.teamcode.auto;

import com.qualcomm.robotcore.eventloop.opmode.Autonomous;
import com.qualcomm.robotcore.eventloop.opmode.LinearOpMode;
import com.qualcomm.robotcore.hardware.DcMotor;

import org.firstinspires.ftc.teamcode.Hardware;

@Autonomous(name = "Reset encoders + imu yaw")
public class ResetEncoders extends LinearOpMode {
    @Override
    public void runOpMode() {
        Hardware hardware = new Hardware(this);
        hardware.fl.setMode(DcMotor.RunMode.STOP_AND_RESET_ENCODER);
        hardware.fr.setMode(DcMotor.RunMode.STOP_AND_RESET_ENCODER);
        hardware.bl.setMode(DcMotor.RunMode.STOP_AND_RESET_ENCODER);
        hardware.br.setMode(DcMotor.RunMode.STOP_AND_RESET_ENCODER);
        hardware.spool.setMode(DcMotor.RunMode.STOP_AND_RESET_ENCODER);
        hardware.imu.resetYaw();
    }
}
